Tech - July 2007 Archives

Flip You, Digg

I’ve been fiddling with parsing RSS and Atom feeds in Ruby lately (I currently use semi-manual parsing with Hpricot::XML, but I am considering ruby-feedparser), and I just discovered this today.

Digg hates open-uri. I believe they specifically block it. How do I know this?

I can read their RSS feed from my browser. I can get it using Mechanize. But open-uri times out!

Flip you, Digg. Frickin Pythonistas.

QotD: July 18

It can be tough to grasp at first, but with the right amount of ninja references, anything can be explained so someone can understand it.

AlternateIdea

Metaprogramming Unit Tests, Part 2

Last time I talked about DRYing up unit tests was quite a while ago. Recently, I had a need to specify a lot of unit tests for some complicated model manipulations. Every time I added a new parameter to the domain of possibilities, the number, complexity and obscurity of the unit tests increased. Having recently seen some ‘bootlegs’ of RejectConf, I was inspired by zenspider’s matrix idea. Now, this might be considered duplication of effort, but here’s what I came up with.