[Sugar-devel] Call for testing and feedback: alternative Journal implementation

Christophe Guéret c.d.m.gueret at vu.nl
Tue May 15 17:11:36 EDT 2012


As you rightly guessed, there are some parts of the API that still have to
be implemented.
The things I've tested so far work fine though: launch the emulator, create
some entries by using the activities and browse the content of the journal.

Christophe

On 15 May 2012 00:09, Sascha Silbe <silbe at activitycentral.com> wrote:

> "=?UTF-8?Q?Christophe_Gu=C3=A9ret?=" <c.d.m.gueret at vu.nl> writes:
>
> > The installation procedure is not super convenient but should be
> manageable
> > anyway: http://wiki.sugarlabs.org/go/Features/Semantic_Web/Testing
>
> I was able to install it on Debian Wheezy by using the distro packages
> libraptor2-dev, librasqal3-dev, librdf0-dev and python-sparqlwrapper and
> building redstore [1] (needs either pandoc or a fix to Makefile.am) and
> python-rdflib [2] from source.
>
> Adjusted file paths and python executable name in
> datastore/bin/datastore-service (inside semanticxo repository) and
> started it manually. Ran "redstore -v" in a separate xterm.
>
> Sugar (latest mainline master) starts up fine, but trying to resume a
> file from external storage (USB stick) fails with the following errors:
>
> shell.log:
> {{{
> 1337031865.456647 DEBUG root: get_file asked for file with path
> '/media/Debian Inst/Journal backup of Sascha Silbe (XO-1) (CSN7470103E) on
> 13.09.2010.xmj'
> 1337031865.457434 DEBUG root: model.write '' '/media/Debian Inst/Journal
> backup of Sascha Silbe (XO-1) (CSN7470103E) on 13.09.2010.xmj' True
> 1337031866.380370 DEBUG root: launch bundle_id=org.sugarlabs.Restore
> activity_id=a6c7ee02667a96e8e51e5656d22be575506e0e24
> object_id=dfe88839-6a71-4e7b-a16a-f0da7d5122ff uri=None
> 1337031866.521933 ERROR dbus.connection: Exception in handler for D-Bus
> signal:
> Traceback (most recent call last):
>   File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 214, in
> maybe_handle_message
>    self._handler(*args, **kwargs)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/sugar/datastore/datastore.py",
> line 61, in __datastore_created_cb
>    metadata = _get_data_store().get_properties(object_id, byte_arrays=True)
>  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 143, in
> __call__
>    **keywords)
>  File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 630, in
> call_blocking
>    message, timeout)
> DBusException: org.freedesktop.DBus.Python.TypeError: Traceback (most
> recent call last):
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 745, in
> _message_cb
>    _method_reply_return(connection, message, method_name, signature,
> *retval)
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 252, in
> _method_reply_return
>    reply.append(signature=signature, *retval)
> TypeError: Don't know how which D-Bus type to use to encode type "NoneType"
>
> 1337031866.567461 ERROR dbus.connection: Exception in handler for D-Bus
> signal:
> Traceback (most recent call last):
>   File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 214, in
> maybe_handle_message
>    self._handler(*args, **kwargs)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/model.py",
> line 507, in _datastore_created_cb
>    created.send(None, object_id=object_id)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/sugar/dispatch/dispatcher.py",
> line 125, in send
>     response = receiver(signal=self, sender=sender, **named)
>   File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/journalactivity.py",
> line 259, in __model_created_cb
>    self._check_for_bundle(kwargs['object_id'])
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/journalactivity.py",
> line 284, in _check_for_bundle
>    metadata = model.get(object_id)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/model.py",
> line 551, in get
>    metadata = _get_datastore().get_properties(object_id, byte_arrays=True)
>  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 143, in
> __call__
>    **keywords)
>  File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 630, in
> call_blocking
>    message, timeout)
> DBusException: org.freedesktop.DBus.Python.TypeError: Traceback (most
> recent call last):
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 745, in
> _message_cb
>    _method_reply_return(connection, message, method_name, signature,
> *retval)
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 252, in
> _method_reply_return
>    reply.append(signature=signature, *retval)
> TypeError: Don't know how which D-Bus type to use to encode type "NoneType"
> }}}
>
> org.sugarlabs.Restore-1.log:
> {{{
> 1337031878.858341 DEBUG root: datastore.get
> Traceback (most recent call last):
>   File "/home/sascha.silbe/sugar-jhbuild/install/bin/sugar-activity", line
> 146, in <module>
>    main()
>  File "/home/sascha.silbe/sugar-jhbuild/install/bin/sugar-activity", line
> 141, in main
>    instance = create_activity_instance(activity_constructor,
> activity_handle)
>  File "/home/sascha.silbe/sugar-jhbuild/install/bin/sugar-activity", line
> 34, in create_activity_instance
>    activity = constructor(handle)
>  File "/home/sascha.silbe/Activities/Restore.activity/restore.py", line
> 532, in __init__
>    activity.Activity.__init__(self, handle, create_jobject=False)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/sugar/activity/activity.py",
> line 330, in __init__
>    self._jobject = datastore.get(handle.object_id)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/sugar/datastore/datastore.py",
> line 297, in get
>    metadata = _get_data_store().get_properties(object_id, byte_arrays=True)
>  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 68, in
> __call__
>    return self._proxy_method(*args, **keywords)
>  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 143, in
> __call__
>    **keywords)
>  File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 630, in
> call_blocking
>    message, timeout)
> dbus.exceptions.DBusException: org.freedesktop.DBus.Python.TypeError:
> Traceback (most recent call last):
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 745, in
> _message_cb
>    _method_reply_return(connection, message, method_name, signature,
> *retval)
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 252, in
> _method_reply_return
>    reply.append(signature=signature, *retval)
> TypeError: Don't know how which D-Bus type to use to encode type "NoneType"
>
> 1337031878.921083 DEBUG root: _cleanup_temp_files
> 1337031878.922746 DEBUG root: _cleanup_temp_files
> Exited with status 1, pid 22293 data (None, <open file '<fdopen>', mode
> 'w' at 0x1200ee8>, 'a6c7ee02667a96e8e51e5656d22be575506e0e24')
> }}}
>
>
>
> Trying to view the Journal (after doing the above) also leaves entries
> in shell.log:
>
> {{{
> 1337032015.323311 DEBUG root: Selected volume: '/'.
> 1337032015.328395 DEBUG root: ListView.update_with_query
> 1337032015.329352 DEBUG root: ListView.refresh query {'mountpoints':
> ['/'], 'order_by': ['+timestamp']}
> 1337032015.331895 DEBUG root: ListView.__model_ready_cb 0.0
> Traceback (most recent call last):
>   File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/listmodel.py",
> line 214, in on_iter_next
>     if iterator >= self._result_set.length - 1:
>   File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/model.py",
> line 112, in get_length
>    entries, self._total_count = self.find(query)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/model.py",
> line 225, in find
>    byte_arrays=True)
>  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 143, in
> __call__
>    **keywords)
>  File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 630, in
> call_blocking
>    message, timeout)
> dbus.exceptions.DBusException: org.freedesktop.DBus.Python.TypeError:
> Traceback (most recent call last):
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 745, in
> _message_cb
>    _method_reply_return(connection, message, method_name, signature,
> *retval)
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 252, in
> _method_reply_return
>    reply.append(signature=signature, *retval)
> TypeError: Don't know how which D-Bus type to use to encode type "NoneType"
>
> Traceback (most recent call last):
>   File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/listmodel.py",
> line 113, in on_iter_n_children
>    return self._result_set.length
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/model.py",
> line 112, in get_length
>    entries, self._total_count = self.find(query)
>  File
> "/home/sascha.silbe/sugar-jhbuild/install/lib/python2.7/site-packages/jarabe/journal/model.py",
> line 225, in find
>    byte_arrays=True)
>  File "/usr/lib/python2.7/dist-packages/dbus/proxies.py", line 143, in
> __call__
>    **keywords)
>  File "/usr/lib/python2.7/dist-packages/dbus/connection.py", line 630, in
> call_blocking
>    message, timeout)
> dbus.exceptions.DBusException: org.freedesktop.DBus.Python.TypeError:
> Traceback (most recent call last):
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 745, in
> _message_cb
>    _method_reply_return(connection, message, method_name, signature,
> *retval)
>  File "/usr/lib/python2.7/dist-packages/dbus/service.py", line 252, in
> _method_reply_return
>    reply.append(signature=signature, *retval)
> TypeError: Don't know how which D-Bus type to use to encode type "NoneType"
> }}}
>
>
> The sugar-datastore test suite [3] may be useful for debugging the above
> errors, as it smells like SemanticXO doesn't fully and correctly
> implement the sugar-datastore API. The "current data store DBus API"
> section of [4] may help a bit as well. I'm working on a real
> specification for the Sugar data store API, but like many other projects
> I can work on it only occasionally, so it'll be some time until it's
> finished.
>
> Sascha
>
> [1] git://github.com/njh/redstore.git
> [2] https://github.com/RDFLib/rdflib/tarball/3.2.1
> [3] https://patchwork.sugarlabs.org/patch/640/
> [4]
> https://git.sugarlabs.org/versionsupport-project/mainline/blobs/raw/master/datastore-redesign.html
> --
> http://sascha.silbe.org/
> http://www.infra-silbe.de/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sugarlabs.org/archive/sugar-devel/attachments/20120515/4a904621/attachment-0001.html>


More information about the Sugar-devel mailing list