Bug 221540

Summary: Query issue with nepomuk
Product: [Applications] dolphin Reporter: Marco Carrai <carrai.marco>
Component: generalAssignee: Peter Penz <peter.penz19>
Status: RESOLVED DUPLICATE    
Severity: normal CC: sebastian, trueg
Priority: NOR    
Version: 16.12.2   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Marco Carrai 2010-01-06 15:52:07 UTC
Version:            (using Devel)
OS:                Linux
Installed from:    Compiled sources

Test case:
open dolphin, tag some files with tag "holiday2009", wait some time, so strigi can index files. Try search for tag "ricette" into dolphin. 
I get always no result or Nepomuk service is not running. Unable to answer queries without it.

Open krunner. Search for the tag, krunner will find int, and open dolphin with the right result.

The main difference i can see is in the query url:

krunner query url: nepomuksearch:/?sparql=select distinct ?r  where { ?r <http://www.semanticdesktop.org/ontologies/2007/08/15/nao#hasTag> <nepomuk:/res/eee89625-ed53-48b8-9e3f-99b13824f7f0> .    }

dolphin query url: nepomuksearch:/?sparql=select distinct ?r  where { { { ?r ?v1 ?v2 . ?v2 bif:contains "'ricette*'" . } UNION { ?r ?v1 ?v3 . ?v3 ?v4 ?v2 . ?v4 <http://www.w3.org/2000/01/rdf-schema#subPropertyOf> <http://www.w3.org/2000/01/rdf-schema#label> . ?v2 bif:contains "'ricette*'" . } . { ?r a ?v5 . ?v5 <http://www.w3.org/2000/01/rdf-schema#subClassOf> <http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#FileDataObject> . } UNION { ?r a ?v6 . ?v6 <http://www.w3.org/2000/01/rdf-schema#subClassOf> <http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#Folder> . } . } .    }


Folderview does not display anything with those two url.
Virtuoso version: 5.0.12-8.2
Soprano-backend: 2.3.70

Kde: Rpm Suse pkg ( updated on the 5th january 2010 )
Comment 1 Marco Carrai 2010-01-06 18:38:35 UTC
I am sorry, there is a little error:
open dolphin, tag some files with tag "holiday2009", wait some time, so strigi

becomes:
open dolphin, tag some files with tag "ricette", wait some time, so strigi
Comment 2 Marco Carrai 2010-01-08 20:28:55 UTC
Same on kde 4.4 RC1. Dolphin can't perform search, krunner can..
Comment 3 Sebastian Trueg 2010-01-20 10:25:13 UTC
what exactly do you type in dolphin and what exactly in krunner?
Comment 4 Marco Carrai 2010-01-20 14:08:59 UTC
If i tag a file\folder with "development", i search for "development"
Comment 5 Sebastian Trueg 2010-01-20 15:08:28 UTC
The queries are correct. I suppose you are experiencing one of the bugs that are still in rc1. querying in kde trunk or the 4.4 branch works perfectly here.
Comment 6 Marco Carrai 2010-01-21 19:32:55 UTC
I hope it will be fixed in rc2, i am waiting that openSUSE upgrades its package to RC2. I'll let you know here if there will be issues again :)
Thanks
Comment 7 Marco Carrai 2010-01-24 11:08:17 UTC
I tried 4.4 RC2 on kubuntu ( to be sure that the problem wasn't suse related ), and i still get the same problem.
I tagged the folder desktop with "holiday", then i searched holiday in the search bar and i got no result. Before upgrading to RC2 i removed .kde{4} to be sure it wasn't a config problem related. If you need some log ask me :)
Comment 8 Sebastian Trueg 2010-01-25 09:10:38 UTC
Please issue the following on the command line:

sopranocmd --dbus org.kde.NepomukStorage --model main list "" "nao:hasTag"
Comment 9 Marco Carrai 2010-01-25 17:00:39 UTC
It's printing lot of thing like: 
<nepomuk:/res/3a43f7b5-63fb-470d-8781-71adb86e284f> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#FileDataObject> <nepomuk:/ctx/f44fa267-7c18-4580-98e4-5f4fbd73d3f5>
<nepomuk:/res/3a43f7b5-63fb-470d-8781-71adb86e284f> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#Folder> <nepomuk:/ctx/f44fa267-7c18-4580-98e4-5f4fbd73d3f5>
<nepomuk:/res/3a43f7b5-63fb-470d-8781-71adb86e284f> <http://www.semanticdesktop.org/ontologies/2007/01/19/nie#isPartOf> <nepomuk:/res/aae9945b-f354-4d84-bb4e-64e588a89635> <nepomuk:/ctx/f44fa267-7c18-4580-98e4-5f4fbd73d3f5>
<nepomuk:/res/3a43f7b5-63fb-470d-8781-71adb86e284f> <http://www.semanticdesktop.org/ontologies/2007/01/19/nie#url> <file:///home/marco/virtual-drives> <nepomuk:/ctx/f44fa267-7c18-4580-98e4-5f4fbd73d3f5>
<nepomuk:/res/3a43f7b5-63fb-470d-8781-71adb86e284f> <http://www.semanticdesktop.org/ontologies/2007/01/19/nie#lastModified> "2010-01-16T10:39:07Z"^^<http://www.w3.org/2001/XMLSchema#dateTime> <nepomuk:/ctx/f44fa267-7c18-4580-98e4-5f4fbd73d3f5>
<nepomuk:/res/3a43f7b5-63fb-470d-8781-71adb86e284f> <http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#fileName> "virtual-drives"^^<http://www.w3.org/2001/XMLSchema#string> <nepomuk:/ctx/f44fa267-7c18-4580-98e4-5f4fbd73d3f5>
<nepomuk:/res/79cf0376-9beb-4b7e-99b7-9b5c282835d3> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#FileDataObject> <nepomuk:/ctx/470dbe33-edd7-4558-8098-f992165bd752>
..
..
The entire log is 31 Mb..
Comment 10 Sebastian Trueg 2010-01-25 21:26:23 UTC
I see. then your redland (aka librdf) installation is probably broken. In case 1.0.9 is installed please update to 1.0.10 or downgrade to 1.0.8.
Comment 11 Marco Carrai 2010-01-26 13:51:49 UTC
Same issue with 1.0.8 . I have no 1.0.9 right now, i'll try to search for it:)
Comment 12 Marco Carrai 2010-01-26 14:04:56 UTC
Issue also for 1.0.9..
Comment 13 Sebastian Trueg 2010-01-26 14:38:41 UTC
I think this is the same problem as in #222687. I found a bug which could be the culprit.

*** This bug has been marked as a duplicate of bug 222687 ***