duplicity-talk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Duplicity-talk] dbus patch


From: Michael Terry
Subject: [Duplicity-talk] dbus patch
Date: Sun, 2 Nov 2008 12:45:34 -0400

OK, I went ahead and implemented the DBus bits that I mentioned last
week.  See patch https://savannah.nongnu.org/patch/index.php?6663

The API I went ahead with is described in the attached DBUS-README,
but I'll briefly lay it out here:

The interface is org.nongnu.duplicity

On startup, duplicity signals NewPid(uint pid) on the path /org/nongnu/duplicity

On fatal error, duplicity signals Error(uint code, string message) on
the path /org/nongnu/duplicity/pid/XXXX.

The code argument to Error is what's most useful to a frontend writer,
and hopefully one day each fatal error will have its own code.  If an
error doesn't have its own code, 'code' is 1.  Errors I defined in
this first patch are command line syntax errors ('code' == 2) and
source mismatch errors ('code' == 3).  Duplicity also returns the code
value via system.exit().

And yes, if dbus isn't available, it doesn't do anything extra.

Future work:
I'll add a signal for progress (probably Progress or something on
/org/nongnu/duplicity/pid/XXXX).  This can easily be done by signaling
once for each volume.  For this to be useful though, I'll need some
way for the caller to know how many volumes will be sent.

I see a --dry-run option was considered a while back?  Should I work
on that next?  It would do the work of creating the volumes, but
wouldn't send them...  That seems like it could take a lot of
time/waste a lot of cycles.  Are there better ideas for getting a
sense of how many volumes will be created?

-mt




reply via email to

[Prev in Thread] Current Thread [Next in Thread]