< | >

Hacker's Diary

A rough account of what I did with Emacs recently.

January 31
Truly I am a master of technology. The shiny new MacBook is sitting in front of me right now with a spinning pinwheel, not going anywhere. What did I do? I'm not 100% sure; iTunes was trying to do its "gapless playback analysis" when the network connection mysteriously died. It didn't recover from that, even when I recovered the network connection. So I figured I'd reboot the laptop, since I couldn't even quit iTunes. And it offered to "Force Quit" iTunes for me, to which I said, "sure", and that's all she wrote. My suspicion is that iTunes is trying to write something, the OS has marked this write as absolutely critical, and the whole thing is stuck in an uninterruptible I/O state. Oh well, time to learn how to hard-reboot my new computer, I guess.

Continuing in the same vein... I managed to get Mail.app using 175% CPU, even after I shut down the application. I don't think it likes my IMAP server very much since it also refused to handle folder subscriptions. Granted, my network is a bit tied up right now due to the aforementioned iTunes, which is connected via SMB to a way overloaded little server.

I should point out that I'm trying to "go native" here, i.e. I've not just launched Emacs and tried to run everything from a terminal window. No, I am attempting to use this toy like Steve intended. Except I'm sure he didn't intend for me to crash it... anyway. I shall collate all of this randomness into a more coherent whole at the weekend, when I'll have time to properly abuse the new toy.

January 30
So my MacBook arrived. Woohoo! I'd love to have spent the evening playing with it, but tonight was a gym night, so that took precedence. Seriously denting my geek credentials with that statement, I guess...

January 29
Hehehe. ktwittering.pl has a memory leak, apparently. I should probably address that.

Doing some more hacking on the Crazy Idea. I've got something that compiles now, but all I've done so far is rename some files...

Half-watched Conspiracy Theory while I was at other stuff. Seen it before; it's an okay movie.

January 28
For a while some bunch of people were continuing to provide updates for retired versions of Red Hat Linux, which suits me fine because one of my boxes runs Red Hat Linux 7.3 and while it's safely inside a firewall it's good to know that there's a source of security updates for it all the same. Unfortunately, the site shut down through, I dunno, lack of funds, apathy, or maybe both, and the problem is that I'm now left with a box which has updates from this expired source, and trying to add any new software to it results occasionally in a depedency loop as it tries to figure out how to cope with the missing packages. Of course, the "correct" way to clean this up is to identify all the offending packages and revert them to some available version, but none of the update tools seem to have been built with the concept of downgrading software in mind.

The album I ripped with the KDE CD ripper turns out to have had all its tracks truncated. So I'm redoing it with grip to see if that improves things. Grr.

Oh, and my MacBook has shipped. Woohoo!

Also, happy birthday, sis!

January 27
I hacked up something from the bits floating around the Internet to download the actual .flv movie files that power YouTube, because frankly my laptop is so underpowered when faced with Firefox that watching those clips in situ is a lost cause. I called the script "youtuber" so as to make a potato joke... anyway, last night I added a bit to the end of it to send a notify to my chat window when it's done downloading. This again reflects back on the universal notification thingy I mentioned a few days ago. I think what I'm trying to get at, or get to, is a system of multiple asynchronous data retrieval, with notifications being sent to me in such a way that I know they're there without actually having to acknowledge them. I hear tell that there are interesting tools to do this sort of thing on a Mac; I guess I'll find out soon enough.

Got a new programme at the gym. She said "these are core muscle exercises", but I think what she meant was "you will die in awesome pain".

Useful tip: if your KDE desktop stops automatically detecting removable devices (like USB keys and iPods, look for a file called /usr/share/hal/fdi/policy/gparted-disable-automount.fdi.. If it exists, remove it (unless, of course, you're running gparted, which owns the file).

Hmm. Last.FM's image-based track lists - which I've had stuck to the front page of this site for quite a while - seem to be pretty haphazard in their updating. So I've switched to one of their widgets instead. Not sure how it'll fit the alleged design of the front page, but hey. I figure most people don't even see that anyway.


January 26
What's wrong with Ocean's Thirteen? There's a little too much of a good thing. It's definitely far better than its immediate predecessor, but it doesn't quite have the clockwork slickness of the first of the series. In particular, there's a little too much of "let's refer to something by a name that everyone in the movie knows but we won't ever explain it to the viewers" (e.g. the Brody, the Gilroy, etc.) and the conversations made of unfinished sentences between Clooney and Pitt. That aside, however, it's stylish, and it's funny, and yet again it looks like the players had a hell of a good time making it, which carries the movie through some of the thinner parts. Definitely worth a look.

My post-Christmas splurge has happened! I've just plunked down my card for a black 13-inch MacBook plus the accompanying AppleCare package. Estimated delivery date is some time next week.

I hadn't intended spending another evening in front of the box, but there was the tail-end of Cool Runnings, followed by Backdraft. And it's not like I don't still have a stack of DVDs sitting in front of the stack of A/V equipment Media Centre.



January 25
Lethal Weapon 2 was on the box. I really, really dislike Joe Pesci's character, but aside from that I quite like this movie.

January 24
Met up with Stella and her fiancée for beers and chat.

Also, BoI decided to make a trivial wording change in their online banking, which broke my Perl modules for accessing same despite my general efforts to make them resilient. I've fixed it, but I'm waiting to see if this is a more-than-tranisent change before offering the new code for abuse. For those of you who are impatient, find the function that handles your PIN and replace "select" with "enter" (told you it was trivial...)

January 23
Fiddling around with some non-Jabber stuff again... why does Amazon allow me to do an ISBN-specific search on the US site, but not on the UK site? I mean, you can search by ISBN (if you strip out all the dashes) on the generic search, but that's not quite the same thing...

Ah, cunningly, you can. It's just that the Advanced Search page wasn't where I was looking for it.

January 22
Got distracted AGAIN. I did hack up a new toy: ktwittering.pl, which monitors Twitter and pops up a window whenever it sees an update. For some reason my KDE desktop does not appear to have anything that responds to "please pop up a little alert box in the bottom right of the screen", so instead I get mildly intrusive windows which go away after a few seconds. It was more an exercise in hacking than anything else. Oh, while writing this I was letting jabberd2 compile, so it wasn't a complete step away from the Crazy Idea.

What I actually wanted from this toy, and I suspect KDE4 may provide easier tools to do so, is a sort of accumulator; an applet in the system tray that shows the notification immediately (not just twitter, but also things like instant messages or, I dunno, email subject lines) and then keeps it on a pop-up list so I can, for example, wander away from the computer for a while and when I come back it's got all the interim updates sitting in a list for me. It'd also replace the notification tool I'd hacked together for xchat ages ago, and possibly a few other things... the more I think of this, the more it sounds like an RSS feed of notification events, which isn't a bad idea in its own right!

January 21
Man. More broken telemetry at the gym - one of the rowing machines is missing a simple sensor, so it doesn't record weight lifted, and the other has been crashed since about 11am this morning going by the clock on the display. Plus I got annoyed at the number of people I saw wasting their time (i.e. not using the equipment in a useful fashion) not because they were preventing me from using the machines, but just because they were doing it wrong. Obviously I'm ramping up to be a very cranky old man. While the data-recording part is a minor deal, the main thing that annoys me about the electronics being broken is that they're all preset to show me if I'm going through my full range of motion on the given machine, as calibrated when I signed up. And I'm not so good at this that I can do it accurately without the little power graph to tell me.

Found a silly bug in Big Seekrit Project code - small, but silly.

Started poking at the jabberd code base to see if I can quickly hack together a test implementation of the Crazy Idea. If I can't knock something together in short order I'll go back to the horrible Perl code and see if I can sort out the remaining glitches in librvp.

January 20
Met up with Lou for coffee and gossip. On a Sunday instead of a Monday. See, I'm not a stick-in-the-mud!


January 19
Happy birthday, Hannah!

Distracted by something unrelated to what I'd planned on doing, as usual: out of curiosity I poked at the performance of the toy I use to look at TV listings. It takes it 15 seconds to load the XML file using XMLTV's parsefile function. 15 seconds isn't a lot, but it's an eternity when you're waiting on a page to load. Of course, added to this is my laziness at not rewriting the code when I swtiched from my own random format to XMLTV; instead, I just wrote code to turn the parsed XMLTV data into something that would work with the unchanged code, and that adds another 4 seconds onto the script before it produces a single bit of HTML... I'm pretty appalled at the XMLTV performance, mind you.

In looking for performance tweaks I discovered someone's done a working XSLT TV listings toy (something I'd previously fiddled with, resulting in a crashed browser) and also that I can now get all my listings from a single source instead of scraping a couple of websites as I used do. The main problem with the XSLT lister I looked at is that it doesn't filter by the channels I actually have which is something my own toy does, albeit after having done that 15-second parse... back to poking at Jabber.

I think I could best describe Fantastic 4: The Rise Of The Silver Surfer as "undemanding". There's certainly nothing new in there; the whole "how can we be superheros and still live our lives as normal people" thing has been done in Spider-Man, Batman, and even The Incredibles, and presumably every other superhero franchise ever made since as a plot device it's a gimme. The Silver Surfer of the title doesn't actually do a whole lot, particularly in terms of explaining why he's there (beyond a fairly weak handwave with no detail). And what's with Dr. Doom? I'm not familiar with the source material, so I can only assume they decided to have a single nemesis (the Surfer notwithstanding) and therefore can't have him kept in a Doom-proof bucket forever. On the whole, this is entirely forgettable stuff, and certainly not worth the effort of seeking it out.

January 18
Continued investigation of the previously-mentioned Crazy Idea; it seems that most gatewaying basically treats the Jabber server as a client of the remote gateway, which is pretty much the exact opposite of what I want to do. jabberd2 seems to have the most approachable architecture for gluing on a new protocol - there's a c2s module (for, I assume, client to server) which the docs say is responsible for figuring out who the user is and then acting as a proxy for them. I'm currently poking in Openfire's source to see if it's got a similar notion.

January 17
Went out for a beer or two with the office.

Urp.

January 16
Gym telemetry was still offline when I arrived, but by the time I'd done a bit of treadmilling it was back. I'm still mildly annoyed, though.

Mostly spent the rest of the evening fiddling with system config stuff. Waste of time, really.

January 15
My plan, such as it was, was to wait for today's MacWorld keynote speech to see what new toys Steve would announce, and more to the point what effect that would have on the prices of existing products. Unfortunately, the MacBook Air is priced right in the middle of the current range, so there's no change in the cost of the MacBook I was looking at (15" Pro). Also, the site was pretty swamped when I had a look, so I gave up quickly. Looking at it now, I'm thinking I could maybe go for a regular MacBook rather than a Pro, losing a few points off processor speed and screen size, and use the money saved to buy an AppleCare package instead. Or, you know, keep it for beer or something. I've looked at the Air (what a... bland name), but aside from the risk of buying a bleeding-edge device, it's got a lower specification than pretty much any of the MacBooks and I'm not enough of a fanboy to want it just because it's all pretty'n'stuff..

My RSS feed for today features an item that kills Firefox 1.5 stone dead; doing some minimal digging, it looks like it ends up trying to release the same piece of memory twice and ends up stuck waiting for itself to finish the job or something. It's fully reproducible, too. Now I just have to care about it enough to actually narrow down the exact sequence of HTML and javascript that's causing the problem. Or maybe I'll go do something more productive with my time.

And so it's once again Crazy Idea time. The most recent crazy idea, hinted at previously, was to gateway RVP messaging - Microsoft's so-called Exchange Instant Messaging - to a Jabber server through use of a proxy which did the appropriate protocol conversions. This idea foundered on the fact that the common authentication mechanism used by RVP and Jabber is MD5 Digest Authentication, which is built such that the proxy idea won't work. So, I'm now looking at simply plugging a RVP proxy directly into the Jabber server such that there's no protocol translation going on - the RVP client talks to a RVP server, which just happens to keep its state and what not in a Jabber server. It looks like jabberd supports this sort of tomfoolery through its notion of a "foreign IM gateway", although I may need to do some tinkering to figure out exactly how this should work. Ideally, both Jabber and RVP would use the same backend user database, so if you can log into one you can log into the other. Anyway, that's the Crazy Idea. I'm going to look at it over the next few days, if for no other reason than that I need a more reliable RVP server to test librvp against than the horrible hack that is RVP.pm.

January 14
Well, that was annoying: the entire gym telemetry system was down. Or rather, there were notices up saying it was down, even though the screens and what not seemed to be running. As I left I saw a Windows "press ctrl-alt-delete to log in" box floating around, so at this point I'm suspecting either someone irretrievably corrupted the user database (i.e. that wherein my record of exercise is stored), or they're locked out of whatever Admin login is required and can't get in.

January 13
Back to Dublin again.

Reripping a CD that I'd screwed up the ripping of the first time around. Previously I'd used Grip for this; today I'm using the KDE ripper, KAudioCreator. Ugh, how unpleasant. It doesn't pay attention to the cached CDDB files, which means when I updated the cached file, it just goes off and does a CDDB lookup again. It also fails to encode files to MP3 if you don't set the genre. There doesn't seem to be an option to overwrite existing files, which is what I was trying to do. It's a surprisingly user-unfriendly tool for KDE.

Finally saw Infernal Affairs. Interesting to see which scenes were lifted for The Departed, and how they survived (or not) the transition. Funny how Sam's character changes from the prequel (IA II) to this - he's much less sympathetic, which is appropriate, since he's very definitely the bad guy. All in all, worth watching, especially if you've not see The Departed - or at least before you do so.


January 12
In which my car is serviced, I go shopping, it rains, and eventually there are cats, too much chinese food, some wine, some champage, good company and far too many movies, all in front of a nice blazing fire. I watched Ice Age, Something's Gotta Give, Jaws, and This Boy's Life; the last had yet another "Bob De Niro plays a character who has to repeat all his lines", which I'm really starting to get tired of. The rest was all good stuff, though.

January 11
Driving west.

January 10
Another gym night.

January 9
On the face of it, Infernal Affairs III is a more confusing film than II (there are many flashbacks, and one of the main characters is having delusions that he's one of the other characters), but I definitely had a better handle on what was going on. Still, not a great movie; the plot is far too tangled. Now I just have to wait for the first of the series to show up, which was my original intention.

January 8
Between going to the gym and watching the tail-end of a TV programme on Graham Linehan, I didn't get up to much by way of geekery this evening.

January 7
Grass (1999) is a documentary about America's not-quite-century-long war on marijuana, made up of archive footage with interstitial animations and a voice-over by Woody Harrelson. The only part of it I found particularly surprising was the non-trivial legalisation moves of the '70s, apparently cut short when Carter's drug czar of choice was himself caught up in a drugs scandal. Also, I didn't realise that the "...it's time for God's people to come out of the closet..." sample on The Shamen's Jesus Loves Amerika (Fundamental) was from an actual convention. The documentary's probably not really worth watching unless you're interested in the historical aspect; I can't see anyone changing their views on account of it.

Got a keyboard for my Palm. I was somewhat surprised to discover it connects via infra-red; I'd assumed it was bluetooth.

January 6
[Guide For Mom, Sunday Edition: lots of chat this week with no explanations. Here's what I've been on about:I think that about covers it!]


January 5
Doing one of those money↔mouth things: since I've gone to the trouble of hacking together a working Digest auth for Gaim/Pidgin, I'm trying to make it sufficiently standalone that someone else can use it if necessary. I'll most likely bundle the NTLM code into the same file or at least a similar one. Might even make a little plugin library out of them.

So I really wanted to see The French Connection, but Constantine was also on the box. I actually like this movie, despite the title character being rewritten from a wisecracking cynical blonde Englishman to, well, Keanu Reeves. Anyway, it overran the start of the former movie by half an hour, so I missed the setup, but that doesn't appear to have mattered; it struck me as one of those movies that was ground-breaking when it first appeared, but over the years has had its mystery quality (whatever it may have been) eroded by subsequent movies. Not that I didn't like it, just that I didn't come away thinking, "man, I'd watch that again!"

January 4
Discovery I didn't need to make: if you do a full backup of your Palm Tungsten E2 with WiFi card, then trash it such a way that you need to restore from that backup, it won't work. It took me two hours to find out that the problem was the WiFi driver stuff which for some reason only works if you re-apply the installer, as opposed to restoring the missing files.

So I had this crazy idea that essentially involved a proxy using MD5 authentication, but what I didn't know (and do now) is that said authentication bundles some details of the request into the MD5 hash, so you can't change (for example) the HTTP method the original request was using. Which was sort of what I wanted to do. Bah.

In related hacking, I redid the MD5 auth stuff for librvp. I've not fully tested it yet due to some problems with the server side of things, but I did find out a bunch of stuff about the Windows client and what it supports, which is somewhat useful. I will say that the RFC on the subject is confusing, the Gaim/Pidgin Jabber code is incomplete, and once again the Gaim/Pidgin folk have screwed plugin developers by not making the digest calculation code part of a general library instead of hiding it away in the Jabber module.

January 3
Set up a VPN so I can connect to my home LAN from the Palm. Surprisingly easy - install poptop, set up an account, tweak the firewall, tweak routing, and it's done. Of course, now I need to clean it up...

Sin City was on the box; I missed the first half-hour, but watched the rest of it while fiddling with some toys for the website.

January 2
Back to the gym for the first time this year, and for the first time since damaging my ankle; no problems with the ankle, but I was a little peeved that the two machines which were broken the last time I was at the gym are still broken, and have been joined by a third. Mitigating this is the fact that I figured out how to make one of them sufficiently non-broken to keep my happy (before anyone gets on my case about using broken equipment, it's only the telemetry that's borked, the mechanicals are fine). Also there was a nice note on my profile telling me I'd done a good job in visiting the gym regularly since I started. Yay me!

January 1
Happy New Year!

Had a minor fight with a bunch of Perl XML modules. Gah. What a mess. First "gah" of 2008, I guess.

previous month | current month | next month


Waider
Happy New Year!