Annoyed with USA

My girlfriend is annoyed with USA timekeeping. More particularly with the way Sunday is the first day of the week in the Gnome calendar applet that shows up when you click on the time applet. After some searching I am unable to find how to change that short of changing the source code.

Help me, lazyweb!

Edit: yes it was meant to be Sunday and not Saturday.

Popularity: 23% [?]


SBackup 0.10 is out!

Get it while it’s hot! It has been uploaded to Debian and will get to the mirrors in a day or two, but if you really want it now, then grab 0.10 release from Sourceforge.

The last version of SBackup was released in last November so this has been long overdue, that is why I want to extend many thanks to Jonh Wendell, who reignited my motivation for SBackup. A large part of this release is his work.

We finally have two out of three most requested features: i18n and purging of old backups. Now the progress indication is the big thing people still want to see. And also lots and lots of small cornercase bugs have been fixed, some of them required rewriting chunks f the code, some others were oneliners that bothered many people.

I am very proud of this release and I am looking forward to what we can do for 0.11, one small step at a time.

P.S. I have already received emails of congratulation about the release and a bug report requesting the new version in Debian. :) Needless to say that the package has been uploaded and will go out in the next mirror push.

Popularity: 33% [?]


SBackup 0.10 delayed to tomorrow

Reasons:
* more testing for the new restore backend and of the purge function are needed to ensure that they work as expected in all expected situations;
* I need more time to review a last minute patch to add autotools support to SBackup and decide if I want that or not;
* My primary notebook is coming back from Dell Service tomorrow and I need it to test the upgrading of the package in Debian (and not just Ubuntu that I have on my old/secondary notebook).

So, translators, you still have time - go here or here to translate. Also beta testers might venture ahead and check out the SVN trunk version. There still might be some bugs lurking there, however, so YMMV.

Popularity: 38% [?]


Why? Oh Gods! Why?


$ mv .ssh/ .ssh.old/
$ python
>>>import gnomevfs
>>> gnomevfs.get_file_info( "ssh://aigarius:password@aigarius.com/home/aigarius" )
Traceback (most recent call last):
File "<stdin>", line 1, in ?
gnomevfs.AccessDeniedError: Access denied
>>>
$ ssh aigarius.com
The authenticity of host 'aigarius.com (85.254.216.40)' can't be established.
RSA key fingerprint is 6d:29:c0:f3:d0:84:c9:a9:d9:4c:7e:e3:1a:18:a2:e2.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'aigarius.com,85.254.216.40' (RSA) to the list of known hosts.
aigarius@aigarius.com's password: *******
[...]
aigarius.com$ exit
$ python
>>>import gnomevfs
>>> gnomevfs.get_file_info( “ssh://aigarius:password@aigarius.com/home/aigarius” )
<gnomevfs .FileInfo ‘aigarius’>
>>>

Of course, this is mentioned nowhere in the sparse documentation. Please keep me away from the person who wrote GnomeVFS and its Python bindings. Bloodshed might ensue. Bug reported

Why can’t someone write a nice, light, working network file transfer protocol abstraction library that would be independent of any desktop environment (bonus) and a working X server (I am looking at you, GnomeVFS). Something that would simply provided all file and folder manipulation operations in sync and async ways in such way that those operations work completely uniformly across all supported protocols. Support for at least ssh and ftp is essential, webdav, nfs, rsync and other protocols that allow writing files to remote locations and http, https and other protocols that only allow read only access to remote files would be very welcome. The library should be in C with bindings in C++, Python, Perl, Ruby, PHP and also a command line processor that would allow all commands to be used in a shell script.
Why something like this can not be written and obsolete the GnomeVFS and those KIOslaves. Freedesktop.org, I am looking at you, please!

Update: Apparently I only need to “import gnome.ui” and execute “gnome.ui.authentication_manager_init()” and my application will automagically get a proper authentication dialog in this case. Unfortunately it is not documented anywhere that I could find. :P

Popularity: 49% [?]


Middle-clicking files

A though came to my mind just now - the method of copying text around by just selecting it to copy and using middle-click to paste it. So I wonder, why could one not apply the same for file operations in Nautilus? I would love to just select and middle click to copy files and maybe a Ctrl or Alt key could be used at the paste stage to switch to moving files instead of copying.

Anyone up to the challenge of writing this functionality? Should not be too hard.

Popularity: 33% [?]


Another bug has pissed me enough to star…

Another bug has pissed me enough to start debugging. This time it is Totem-xine crashing on startup in Ubuntu dapper.

The first thing is that you cann’t rebuild totem from sources multiple time after ubuntu patches - ubuntu uses dpatch to patch something in automake files and after the build has been run, the unpatch fails thus preventing a rebuild, doh! Worked around that by removing that patch. (Bug not reported yet)

After installing totem-gstreamer, my main suspect is the change to the statusbar, that look very recent. Could it be that Totem developers forgot a critical fix to the xine backend? Could it be that the treat xine backend as a … second class citizen? To what? To that GStreamer? I tried to use GStreamer, I really did, but there are a few tiny issues: 1) it doesn’t open even half the files that xine does, 2) within 5 minutes of a movie audio-video can easily get out of sync by 5 seconds. I have never seen A-V sync in xine. Ever. I love telling our Windows using frends that my movies “just work” with totem-xine, please do not take that away!

Anyway - back to the bug we go.

As we have a clean crash, I recompiled totem with debugging symbols (”DEB_BUILD_OPTS=nostrip,noopt debuild -us -uc”) and run with gdb. When totem crashed, I got the code line, where it happened:

(totem:4608): GLib-GObject-WARNING **: invalid cast from ` ' to `TotemTimeLabel'

Program received signal SIGSEGV, Segmentation fault.0x08068659 in totem_time_label_set_time (label=0x8199a60, time=0, length=0) at totem-time-label.c:6969              if (time / 1000 == label->priv->time / 1000

Now, that is interesting, lets see, what we have here - time is an int, so no segfaults from there, but label is a TotemTimeLabel. Hmm, that error now makes sense. And when we take a look at label->priv, it appears to be a pointer to TotemTimeLabelPrivate with an address of 0xffffffff. That’s the problem, now we only need to backtrace trough the program and find the bug that is causing that.

Well all looks pretty nice - there is a “tick” event in the player that calls the time update. Not really clear, why there is such a discrepance between GtkLabel and TotemTimeLabel or why this structure is not inicialized in time. More strange is that gstreamer backend never calls this function. Wierd. Let’s see what happens if I just return from it without doing anything. Does not help - now statusbar is crashing.

Let’s try it from another angle - it worked before. Nothing much in totem changed since release of breezy. Installing the version from breezy, it works fine. Recompiling the version from breezy on dapper - crashes. Ouch! It looks like xine backend of totem has not been ported to that new crazy Gnome 2.12 thingie, like gstreamer backend was. Strange - that is a backend, it should not be dependent on the frontend, no? Anyway, it is not something I can do - I will have to install the breezy version, hack some dependencies to make it no conflict with one optional library and then file a critical bug on totem for breaking the xine backend.

But even that will have to wait ’till tomorrow, sleep is of the essence, anywere.

Popularity: 18% [?]


Another tiny note - why is it so that al…

Another tiny note - why is it so that all the Python wrappers for Gnome and Freedesktop related things (GnomeVFS and DBus in my experience) have absolutely no API documentation !!! PyGTK has a nice set of documentation for GTK work, but it doesn’t extend beyond that, sadly. When I was writing SBackup, I had to resort to using Python build-in function dir() to show me what names the gnomevfs module exported and guestimate my way from there. That was ugly as hell, but worked. Now I am trying to find any information about that “new” DBus thing that everyone was so excited about approximately a year ago - I can only find a few blog posts about rewrites of said API and a few simple programs that do not even work with the rewritten API. I mean - I can understand not having documentation for internal functions of a desktop program, but not having a public API document for a critical library of freedesktop.org desktop infrastructure - that is just plain dumb.

Edit: It seams that there is some kind of dbus tutorial with Python API section. I do not know, why it didn’t appear on first 10 pages of Google search for “dbus python” or “dbus python API”, but I hope this linking will help that a bit. Also, we will see, how useful it actually is - the rest of the document itself is quite cryptic to me.

Edit2: I am impressed, the Python chapter is definitely written by someone different from those that wrote the rest of the dbus tutorial - this part actually makes sense, is very detailed and hand-holding when it is needed. i got almost all my questions answered. Thanks to whoever wrote that!

Popularity: 25% [?]


Remote restore fixed. Full planned funct…

Remote restore fixed. Full planned functionality reached.
All that I planned to do for Simple Backup is done as of version 0.7.
Now I only need to wait for the evaluation from my mentors at Ubuntu and to fix all bugs they and all other users find :D

I also did a bit of refactoring in this release oriented towards less memory usage. Results:

  • Memory usage while restoring dropped by 30-50%
  • Memory usage while making a new backup reduced … tenfold?!?!

I like it :D

What I do not like is the performance of GnomeVFS over ssh (Bug #155872) and also a need to download all the backup image *twice* to restore anything (in the worst case). Sadly I can not do much in either case :(
( Of course I could fix the GnomeVFS ssh module and write a new tar implementation with an external file positioning cache, but I fear that it is somewhat beyond my capabilities :) )

Popularity: 22% [?]


Still writing a restore tool :(

Still writing a restore tool :(
Last two hours were spent debugging an interesting problem with TreeView in PyGTK. It was too slow to parse and add all files from a backup snapshot to the tree view at once (not to mention that it took 35 Mb of RAM :P), so I decided to load the tree as needed - I would add the children of a node only when this node gets expanded. So I happily wrote a handler to ‘row-expanded’ event that does just that - adds some children to the newly expanded node.
Note: as the node cannot expand if it doesn’t have some children already, I also add a dummy child to all directory nodes
Then the problem came up - once I enabled my handler, the nodes would not expand anymore: the expansion handles were there, I could click on them and see the CPU being chewed away by the parsing of the 6 Mb nodelist, but nothing changed in the interface - even the dummy node didn’t come up.
That confused not only me, but also #pygtk people. I wrote a 15 line simple script to replicate the problem, but everything worked fine there :O. At this point I started commenting stuff out at random and found out that breaking the link between treestore and treeview (recommended in docs to avoid excessive updates) resets the expansion state. Doh.
But it was not the end yet. After that I noticed that the nodes didn’t expand on the first try, but only on the second. 8) After some mental mummbo-jummbo I came to an idea that proved to be dumb, but correct. Prepare for a gem boys and girls - if, in the process of execution of row-expanded handler, at at least one point the expanding node has no children (like when you have removed the dummy node, but still haven’t added the real ones) - the expansion doesn’t happen!
Two bugs^Wfeatures with the same effect. Oh, the fun of debugging never stops :D

Popularity: 28% [?]


The python-gnome2 bindings for gnomevfs …

The python-gnome2 bindings for gnomevfs are completely undocumented :P
I so wish i could kick that developer in the^W^W^W^W^W donate small amount of money to have it fixed. :)

Popularity: 16% [?]