Temporary try..excepts while we stabilize the new datastore.
This commit is contained in:
parent
46eea8fc7f
commit
30114f9545
@ -193,7 +193,10 @@ class Activity(Window, gtk.Container):
|
|||||||
f = open(self.jobject.file_path, 'w')
|
f = open(self.jobject.file_path, 'w')
|
||||||
f.write('mec')
|
f.write('mec')
|
||||||
f.close()
|
f.close()
|
||||||
|
try:
|
||||||
datastore.write(self.jobject)
|
datastore.write(self.jobject)
|
||||||
|
except Exception, e:
|
||||||
|
logging.error(e)
|
||||||
else:
|
else:
|
||||||
self.jobject = None
|
self.jobject = None
|
||||||
|
|
||||||
|
@ -27,8 +27,12 @@ DS_DBUS_INTERFACE = "org.laptop.sugar.DataStore"
|
|||||||
DS_DBUS_PATH = "/org/laptop/sugar/DataStore"
|
DS_DBUS_PATH = "/org/laptop/sugar/DataStore"
|
||||||
|
|
||||||
_bus = dbus.SessionBus()
|
_bus = dbus.SessionBus()
|
||||||
|
try:
|
||||||
_data_store = dbus.Interface(_bus.get_object(DS_DBUS_SERVICE, DS_DBUS_PATH),
|
_data_store = dbus.Interface(_bus.get_object(DS_DBUS_SERVICE, DS_DBUS_PATH),
|
||||||
DS_DBUS_INTERFACE)
|
DS_DBUS_INTERFACE)
|
||||||
|
except Exception, e:
|
||||||
|
_data_store = None
|
||||||
|
logging.error(e)
|
||||||
|
|
||||||
def create(properties, filename):
|
def create(properties, filename):
|
||||||
logging.debug('dbus_helpers.create: %s, %s' % (properties, filename))
|
logging.debug('dbus_helpers.create: %s, %s' % (properties, filename))
|
||||||
|
Loading…
Reference in New Issue
Block a user