GNOME Bugzilla – Bug 770782
Don't use an undefined ?item variable
Last modified: 2016-11-18 15:53:39 UTC
according to locale I have LANG=de_DE.UTF-8 LANGUAGE= LC_CTYPE="de_DE.UTF-8" LC_NUMERIC="de_DE.UTF-8" LC_TIME="de_DE.UTF-8" LC_COLLATE="de_DE.UTF-8" LC_MONETARY="de_DE.UTF-8" LC_MESSAGES="de_DE.UTF-8" LC_PAPER="de_DE.UTF-8" LC_NAME="de_DE.UTF-8" LC_ADDRESS="de_DE.UTF-8" LC_TELEPHONE="de_DE.UTF-8" LC_MEASUREMENT="de_DE.UTF-8" LC_IDENTIFICATION="de_DE.UTF-8" LC_ALL= When running gnome-photos, I get an error 1.762: syntax error, use of undefined variable 'item' (see attached screenshot) When I use a different locale, like LANG=C gnome-photos or LANG=en_US.UTF-8 gnome-photos it seems to work properly.
Created attachment 334707 [details] gnome-photos failure
hm, the language settings seems to be a red herring. After a reboot I'm now also getting the failure for a C or en locale. on the console I get a lot of those errors: (gnome-photos:6775): Tracker-CRITICAL **: tracker_sparql_cursor_real_get_double: assertion '_tmp1_ == TRACKER_SPARQL_VALUE_TYPE_DOUBLE' failed (gnome-photos:6775): Tracker-CRITICAL **: tracker_sparql_cursor_real_get_integer: assertion '_tmp1_ == TRACKER_SPARQL_VALUE_TYPE_INTEGER' failed I wonder if it's related to the tracker update from 1.8.0 to 1.9.1
I have heard about this problem from multiple other people too. The behaviour of Tracker changed in 1.9.1 because gnome-photos master works fine with tracker-1.8.0. I have not bisected it yet to know whether tracker became stricter (and we need to fix our queries) or whether it is a regression. Any help with bisecting it will be very appreciated. :)
Maybe Carlos has an idea, added to CC
It's probably https://git.gnome.org/browse/tracker/commit/?id=003f7fdd96e3c3e2588de64a69c889f848e912ec , the earlier behavior was IIRC an spec break. Would be great to know the specific query/aggregate function that triggers this, TRACKER_VERBOSITY=3 should shed some more light.
(In reply to Carlos Garnacho from comment #5) > It's probably > https://git.gnome.org/browse/tracker/commit/ > ?id=003f7fdd96e3c3e2588de64a69c889f848e912ec , the earlier behavior was IIRC > an spec break. Would be great to know the specific query/aggregate function > that triggers this, TRACKER_VERBOSITY=3 should shed some more light. Thanks for digging into this, Carlos.
np :), it seems to be https://git.gnome.org/browse/gnome-photos/tree/src/photos-query-builder.c#n120 from a cursory look
Created attachment 334917 [details] [review] search-type-manager: Only look for nmm:Photos inside collections
Created attachment 334918 [details] [review] query-builder: Split out the COUNT into a separate variable
Created attachment 334919 [details] [review] query-builder: Don't use an undefined ?item variable
I tried those 3 patches with gnome-photos 3.21.90 with tracker 1.9.1, and gnome-photos works again.
(In reply to Jeremy Bicha from comment #11) > I tried those 3 patches with gnome-photos 3.21.90 with tracker 1.9.1, and > gnome-photos works again. Thanks for testing them out. I have pushed them to master now.
*** Bug 772003 has been marked as a duplicate of this bug. ***