Phillip Pearson - web + electronics notes

tech notes and web hackery from a new zealander who was vaguely useful on the web back in 2002 (see: python community server, the blogging ecosystem, the new zealand coffee review, the internet topic exchange).


Another OPML server...

By day this last week I've been writing microcontent schemas... by night I've been hacking together some Python code to perform more or less what Dave Winer's OPML Community Server does, only on Linux, etc.

I've set the software up to run on, so you can create a blog there by changing your community in your OPML Editor to and registering, then blogging as usual. You should see your name appear in the yellow box on the front page once you have registered.

One bug at the moment is that it doesn't seem to let you upload binary files, so don't panic if you get stuck with the default header graphic. At the moment it looks like this is a problem with the OPML Editor - it's sending JPEGs as XML-RPC strings rather than as binary objects. I'll post a note here and on my OPML blog when this is fixed.

This was really an experiment to write a web app that works properly under SCGI. The Topic Exchange uses SCGI, but in a pretty messy way (forking once per connection and reloading all the Python code each time), because it started out as CGI and depends on certain global variables not being set on startup. Yuck... but I've never got around to fixing it up, so like that it stays. opmlbox (the current name for this community server clone thing), on the other hand, does everything "the right way", keeping everything in class variables. It also loads and compiles the whole app on startup, so there's no per-request compiling to do. This means I need to restart the server process to get it to recompile any scripts, but it makes it much quicker than the Topic Exchange code. It should be interesting to see how it scales, as I don't have much free memory on my server... looks like it only takes up 2-3 megs at the moment, so if it stays that way there shouldn't be any problem.

Update: Dave mailed to ask me to reset people's expectations, as it sounds like some are getting carried away, so here goes: I'm not trying to clone the WHOLE functionality of the OPML CS here - just the bits I'm interested in: for the time being, just the blog hosting stuff. This is just a few evenings' work, remember :-)

... more like this: []