Navigation

home code debian images resume weblog wiki

Older news:

Feb 18, 2005:
Mixing whitespace
Jan 10, 2005:
The difference between dogs and cats
Dec 22, 2004:
Sunrise in winter
Dec 12, 2004:
New site layout
Winter in Rotterdam
Cyprus (November 2004)
Nov 26, 2004:
Python decorators

Browse:


Reporting bugs in software/programming

Posted on 2003-11-29 by ivo :: /programming :: link

For free software to work, it is essential that people report any bugs they may find to the authors. When the feedback is accurate and correct enough, they can then fix their software.

However, when you've finally tracked down a bug in a software package, it's sometimes a lot of very frustrating work to find out what exactly is causing the software to break. This is essential information to the programmers, without this they usually wouldn't know where to start looking for the cause of this problem (there are exceptions of course).

As a Debian developer, I know that having incomplete information in a report for a bug that doesn't manifest itself on my system can be extremely frustrating and annoying. Asking the user for more information can help, maybe he needs to be guided a little, for example by providing a way to get a gdb backtrace.

Here's the tale of my latest adventure in this area, as a user. About two weeks ago, a CGI script written in Perl was failing mysteriously on a production server. I had checked everything, even changed the locale the script was running in. The code was pretty simple:

if ($value =~ /^$allowed$/m) {

$allowed is .*, and $value contained some UTF-8 text, with an ä in it. Nothing out of the ordinary, but it wouldn't work. The match statement would always be false. After hours of debugging, it turned out that when $allowed was compared to .*, it wasn't equal. We could set it to .*, in which case the expression was true. (Using $allowed = join('', split('', $allowed)) didn't help either, but maybe perl optimized that a bit.)

So, we looked at the perl bugs. The system I was developing this on was running Debian stable (woody), which has perl 5.6. So you have to look at bugs in perl 5.6. Or Debian bugs for the stable release. The bug under examination may or may not have been fixed already, either in new releases, CVS code, Debian patches, mailing list posts, or somewhere else entirely.

On the other hand, the bug might not even be in perl. The value of $allowed is passed on via a complicated structure of hashrefs and arrays from a parsed XML file, using XML::Simple. So maybe that module is at fault. XML::Simple gets its data from expat, so it might even be expat.

All these little bits of information make it pretty hard to find out if a bug has been fixed or not. I have been trying to see if the bug exists in more recent versions of perl, but so far I haven't been able to reproduce the situation well enough. For one thing, I would have to setup a system that is exactly the same as the production platform, which may take up quite a bit of time. And of course, time is money.

So, what do you do, report the bug or not, knowing that the information you have is incomplete, probably inconsistent and maybe even incorrect; knowing that the developers may ignore or flame you for your report?

I didn't. Hacking around the problem by replacing ä with ä was much easier.

Musings on a cold saturday in autumn…/

Posted on 2003-11-22 by ivo :: / :: link


Python wrapper for gnutls/programming/python-gnutls

Posted on 2003-11-05 by ivo :: /programming/python-gnutls :: link

I've re-started on my little project to create a simple python wrapper for the GNU TLS library (gnutls). The code is available from CVS only for now. I'll create a more permanent website for it in the wiki, under PythonGnutls.

This time I'm not using SWIG, mostly because I couldn't find out how to create a custom class, without resorting to C++; and I wanted to understand better what SWIG is trying to do for me. Maybe I'll switch back at some time in the future, when the first issue is solved.

/site :: link

You may have noticed I added the "Hacker logo" to the bottom right of this page somewhere last week. Of course I first read about it when it appeared on slashdot. The reactions there were mostly negative, with arguments such as:

  • Hackers don't need a logo;
  • It will be abused by crackers and other dubious figures;
  • The media will use it for anything related with computers, and bedazzle its meaning;
  • Why does Eric Raymond want his statue carved in the face of the moon;
  • Why did he have to chose a glider that moves down?

Personally, I like the idea of having a logo. Like it says in the FAQ, having the logo on your website doesn't make you a hacker; that is a title you have to earn. Instead I want to show my sympathies to the hacker culture, show anyone that I share visions.

I agree somewhat with the sentiments that "a gun crazed wack job that would scare most moms out of the day care center". Like Richard Stallman once said at an edition of FOSDEM, It doesn't help your case for free software if you mingle your views with political statements. People will close their minds for your arguments for free software if you also make statements that they disagree with, even if they are in a different field.

But even so, Eric has done a lot of good work for the open source/free software world in general. I have never met him in person, I wouldn't know if he deserves any of the criticism he gets. In any case, it would be unfair to refuse to use the hacker logo solely because you disagree with Eric.

The idea to take a glider for the logo is brilliant, of course. It's simple, and could be represented in ASCII very well. I don't care much that Eric chose the one that goes down, any variant would do. Plus I think this one looks good :) I've just become interested in finite state machines and cellular automata.

I don't fear much for usage of the logo by people who aren't hackers in the original meaning; "we'll find some way to shame and reject you publicly if you mess with ours."

And the media, well… that's just a matter of consequently using the image as a link to Eric's explanation page. People will pick up its real meaning, and if they don't they should be politely corrected. I hope the real hackers among us are civilized enough to keep their anger down if anyone uses it in the wrong way.