[Sugar-devel] sugar.datastore

Sascha Silbe sascha-ml-ui-sugar-devel at silbe.org
Fri Feb 20 18:24:55 EST 2009


After I fixed the Python search path in Pippy, I'm trying to get the 
data store part of the Slideshow example to work (it doesn't return any 
objects though there are JPEGs in the data store).
pippy.query seems outdated (uses direct DBus access, datastore is 
complaining about invalid parameters), so I'm trying sugar.datastore 
according to the howto on [1].
Is sugar.datastore.datastore working properly? It behaves quite 
unexpectedly for me:

1. datastore.find({'mime_type': 'image/jpeg'}) returns no objects
2. datastore.find({'title': 'Browse Activity'}) returns the same as
     datastore.find({}), i.e. probably all entries - but most of them
     don't match the given title
3. the metadata entries contain dbus.ByteArray's, not (unicode) strings 
like I'd expect
     BTW: an items() function would be nice


[1] 
http://sugarlabs.org/go/DevelopmentTeam/Almanac/sugar.datastore.datastore

CU Sascha

-- 
http://sascha.silbe.org/
http://www.infra-silbe.de/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 489 bytes
Desc: Digital signature
Url : http://lists.sugarlabs.org/archive/sugar-devel/attachments/20090221/8a3da08d/attachment.pgp 


More information about the Sugar-devel mailing list