Posts

  • The difficulty of bug reporting

    This can be pretty hard: Say the GNOME screensaver password prompt sometimes won't accept your password, no matter how many times you try. How do you check that you haven't mixed up your password with one of the other 500 that you have to remember if you're not using a password bookmarklet or a password manager or you change passwords every month (You do use different passwords, don't you?)? How do you make sure that you're typing all those special characters right, especially since you're using multiple keyboard layouts? Does the "Leave a message" function show you the same string that would be sent to the password checking routine? Is it possible that any other software is at fault, mangling or interrupting your input? How do you even find out which software you're typing the password in? Could a buggy keylogger be involved? Is there any debugging output, and where can you find it? Is Caps Lock or Num Lock on (EEE laptops don't have those handy LEDs)? Are encodings in any way involved? Where should the bug be reported? Should I ask in the official mailing list before submitting one? If so, what's the address and do I have to be a member to post? Is there some alternative forum which is more used? Is the list even active anymore? The bug is still marked as unconfirmed (although I've had to killall gnome-screensaver for months), so I guess we'll have to see...

  • Software bloat can be a good thing

    Remember Mozilla? Not the foundation, but the browser + news reader + email client + kitchen sink that spawned Firefox, the lean and mean browser accused of arriving at just the same kitchen sink stage while taking over the world. I think there's at least one (maybe more) very important software development lessons to be learned here:

  • Overselling Linux

    Shortly after starting college I heard about the wonderful strategy / ideology of open source (hey, I'm from the sticks, OK?). As I recall, I'd never seen a machine running GNU/Linux before. Being an over-the-top Windows tweaker (Windows 98 broke completely about every two weeks), all that control sounded like gravy to a fat f***.

  • How to teach users the command line

    Now that computers are firmly in the hands of casual users, is there some way to teach them how to use the command line without throwing them head first into grep? Of course, anyone with the time and inclination (and someone to contact when they get stuck) can learn to use the shell. Also, of course, there's an entire spectrum from those who would never touch a mouse to those who would never touch the keyboard if they could avoid it, so there must be room for shifting the bar to entry.

  • vCard 3.0 validator and parser

    Did you know that even the vCards listed in the official RFC are not valid? It clearly says The vCard object MUST contain the FN, N and VERSION types. Still, the example vCards are both clearly missing the N type. As somebody else remarked, releasing a format spec without some reference validator is bound to result in all sorts of invalid implementations.

  • Recursive unRAR and delete

    Just a continuation of a script mentioned at LinuxQuestions, to extract RAR archives in their respective directories in a directory tree. An additional option is available to delete the archive files after finishing extraction.

  • Sort blocks of text in files

    Ever had to sort a file alphabetically, only to realize that you'd have to do it manually because every item that needs to be sorted is spread over more than one line? This just happened when I exported my Gmail contacts to vCard, which it turned out were sorted by formatted name (FN) instead of name (N). The result was the following script, which takes two pattern and some input, and returns the sorted output. The example returned by ./sort_blocks.py --help is exactly the code to re-sort Gmail contacts. I'd love to know if you find any bugs or possible improvements to this script. Enjoy:

  • Range arithmetic in Python

    The XML 1.0 and 1.1 standards define some ranges of Unicode code points which are valid, and some "compatibility characters" which should not be used. CDS Invenio (a FOSS CMS; update: sorry, the link is dead) already has some code to clean up text to remove invalid characters, but it doesn't remove the compatibility characters. Using the existing code for HTML 4.01 made the W3C Markup Validation Service complain, so I wanted to exclude the compatibility character ranges from the valid ranges, and get the most concise hexadecimal ranges corresponding to the resulting set to plug into a Python regular expression. Here's the resultingsloppy and ugly code (I'll post updated code and/or a link to the source repository if this is included at some point):

  • Firefox profile folder cleanup script

    Here's a simple script which can be useful if you want to version control the Firefox profile folder, or just to keep it slim. Please see the embedded documentation for more information.

  • LHC beam again

    From the LHC operations web site, pages "LHC1" and "LHC3", taken as soon as the beam completed a round in the accelerator. See also the log book (Update: sorry, the link is dead) and the CMS e-commentary (Update: sorry, the link is dead).LHC beam 1st round