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 768706 - Reindexing files doesn't result in re-extraction
Reindexing files doesn't result in re-extraction
Status: RESOLVED INVALID
Product: tracker
Classification: Core
Component: General
git master
Other Linux
: Normal normal
: ---
Assigned To: tracker-general
tracker-general
Depends on:
Blocks:
 
 
Reported: 2016-07-12 00:32 UTC by Sam Thursfield
Modified: 2016-07-13 15:45 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Sam Thursfield 2016-07-12 00:32:15 UTC
You would expect that `tracker index ./file.mp3` would result in all metadata for ./file being added to the tracker-store. But it isn't so. If the file was already crawled, no new data will be inserted, even if the output of `tracker extract` is different to before.

I hit this with files handled by the GStreamer extractor, where on a new Fedora installation, I had Tracker crawl all your files, but then realised I needed to install more codec packages. Now, `tracker index --file foo.mp3` and `tracker index --reindex-mime-type audio/mpeg` achieve nothing.

I suspect this is due to the TrackerDecorator changes. The extractor is listening for GraphUpdated signals. If a file was already crawled by the miner-fs then there'll be no GraphUpdated signals.

Perhaps `tracker index --file` and `tracker index --reindex-mime-types` should delete all as the first step? That introduces a risk of something crashing after the existing data is deleted but before the new data is added, though. A second possibly would be to synthesize a suitable GraphUpdated signal to trigger the extractor.
Comment 1 Sam Thursfield 2016-07-12 00:37:51 UTC
I had Tracker crawl all *my* files, not your files, don't worry :-)
Comment 2 Sam Thursfield 2016-07-13 15:45:44 UTC
Actually, although I definitely have a problem in my local Tracker installation, it seems to have a different cause. I've now added a testcase that proves that this functionality is working as it should: https://git.gnome.org/browse/tracker/commit/?id=e4493c677f721193c3e6416103731ef52f636490