I got code from bzr and built with --enable-dbus-api.
In /usr/share/dbus-1/services, I added org.inkscape.service: [D-BUS Service] Name=org.inkscape Exec=/usr/bin/inkscape
Code like import dbus bus = dbus.SessionBus() inkdoc1 = bus.get_object('org.inkscape', '/org/inkscape/desktop_0')
causes inkscape to start via dbus, but the bus.get_object doesn't succeed. I get an error from DBus:
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NameHasNoOwner: Could not get owner of name 'org.inkscape': no such name
What else do I need to do?
If I use the dbus API to call_verb "ru.cnc-club.filter.gcodetools_orientation_no_options_no_preferences", I get a crash. What's a good way to figure out what's happening?
On 2013-02-15 11:20 +0100, Brian Lewis wrote:
If I use the dbus API to call_verb "ru.cnc-club.filter.gcodetools_orientation_no_options_no_preferences", I get a crash. What's a good way to figure out what's happening?
Attached is a backtrace of the crash with r12126 (of limited use - I don't have a debug build for the dbus-api available).
Seems to affect all verbs based on extensions AFAICT:
Also reproducible with script-based color effects without dialog, e.g. "org.inkscape.color.negative" or those which open a dialog "org.inkscape.color.randomize" and with internal effects called without dialog like e.g. "org.inkscape.effect.filter.ColorDropShadow.noprefs"
On the other hand, this one "org.inkscape.effect.filter.ColorDropShadow" works, and allows to interactively apply the effect).
Possibly a regression, but I don't know for sure.
On 2013-02-15 11:20 +0100, Brian Lewis wrote:
If I use the dbus API to call_verb "ru.cnc-club.filter.gcodetools_orientation_no_options_no_preferences", I get a crash. What's a good way to figure out what's happening?
Oddly, it seems to work without crash if pausing updates before calling the verb, and resuming it afterwards:
Python sample code:
def testGCode2(doc): doc.pause_updates() doc.call_verb("ru.cnc-club.filter.gcodetools_orientation_no_options_no_preferences") doc.resume_updates()
participants (2)
-
Brian Lewis
-
~suv