Revisiting Old Code

The problem with projects is that sometimes you have to come back to them months, or years, after the fact. When you’re digging around in the code, convinced that the person who wrote it originally (you) was a blithering idiot, and what the hell was I thinking when I did that, and you see something like this:


# Note: this will suck

You know you’re in trouble.


In this case it was right in the middle of an ugly, ugly sorting routine… or rather, set up for a sorting routine to sort a bunch of rows by date, maybe, sorta, defined by the user, sometimes, or something like that. I had used a perl module called DBIx::Recordset (which I ranted about before). It works well and allows you to do these sort of interesting things relatively easily.


If you are in the mindset of it! If you haven’t thought about the module for 6 months it’s a horrible, evil thing!


I did eventually back into the swing of things and get it going though. Since Firefly isn’t home tonight there was no one to tell me to get my ass into bed, so once again I’m up at 1am working. At least now I have one more thing on my TODO list checked off.