After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 709900 - Don’t return outdated thumbnails for local files
Don’t return outdated thumbnails for local files
Status: RESOLVED FIXED
Product: grilo
Classification: Other
Component: plugins
git master
Other All
: Normal normal
: ---
Assigned To: grilo-maint
grilo-maint
Depends on: 709898
Blocks:
 
 
Reported: 2013-10-11 10:30 UTC by Philip Withnall
Modified: 2013-11-05 08:00 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
filesystem: Only return thumbnails if they’re valid/up to date (4.84 KB, patch)
2013-10-11 10:33 UTC, Philip Withnall
none Details | Review
filesystem: Only return thumbnails if they’re valid/up to date (5.27 KB, patch)
2013-10-31 08:41 UTC, Philip Withnall
committed Details | Review

Description Philip Withnall 2013-10-11 10:30:41 UTC
Grilo currently happily returns old thumbnails for files which have been modified since, which is incorrect.

Using the G_FILE_ATTRIBUTE_THUMBNAIL_IS_VALID attribute from bug #709898, patch coming up to only return thumbnails which are valid (i.e. up to date with respect to the current contents of the media file).

This bumps Grilo’s GIO dependency to 2.39.0. I could make the changes conditionally compiled and avoid the dependency bump, though, if desired.
Comment 1 Philip Withnall 2013-10-11 10:33:25 UTC
Created attachment 256989 [details] [review]
filesystem: Only return thumbnails if they’re valid/up to date

Use G_FILE_ATTRIBUTE_THUMBNAIL_IS_VALID to ensure that only up to date
thumbnails are returned by the filesystem and local-metadata plugins.

This requires a GIO dependency bump to 2.39.0.
Comment 2 Juan A. Suarez Romero 2013-10-29 20:17:38 UTC
Philip, sorry for the delay.

Could you do changes conditionally?

GIO 2.39.0 is pretty new, and nobody is still using it. It would be great to not hard-depend on this so we can use new releases in current distributions.
Comment 3 Philip Withnall 2013-10-31 08:41:44 UTC
Created attachment 258635 [details] [review]
filesystem: Only return thumbnails if they’re valid/up to date

Use G_FILE_ATTRIBUTE_THUMBNAIL_IS_VALID to ensure that only up to date
thumbnails are returned by the filesystem and local-metadata plugins.

This uses an optional GIO dependency bump to 2.39.0. If that version of GIO
isn’t available, the new functionality won’t be used.
Comment 4 Juan A. Suarez Romero 2013-11-05 07:58:57 UTC
commit 41594ba590ab1115b48e3d1182c4a6673c0c79c2
Author: Philip Withnall <philip.withnall@collabora.co.uk>
Date:   Fri Oct 11 11:31:42 2013 +0100

    filesystem: Only return thumbnails if they’re valid/up to date
    
    Use G_FILE_ATTRIBUTE_THUMBNAIL_IS_VALID to ensure that only up to date
    thumbnails are returned by the filesystem and local-metadata plugins.
    
    This uses an optional GIO dependency bump to 2.39.0. If that version of GIO
    isn’t available, the new functionality won’t be used.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=709900

 src/filesystem/grl-filesystem.c         | 23 ++++++++++++++++++++---
 src/local-metadata/grl-local-metadata.c | 29 ++++++++++++++++++++++++-----
 2 files changed, 44 insertions(+), 8 deletions(-)