Colin's Journal

Colin's Journal: A place for thoughts about politics, software, and daily life.

November 25th, 2009

Initial Impression of Google Wave



I’ve had a Google Wave account for a short while now, but (like many users I’m sure) the slow invite system resulted in me having very few people to test it with.  Last night I had my first real-time three way conversation, and it really highlighted the short-comings of the current user experience.

The most irritating issue with Wave’s current UI is that it’s slow as molasses when lots of things are going on.  Scrolling fails to work properly, clicks don’t register when they should, and you get false clicks as the screen re-draws under your cursor.  This is in an up-to-date version of Firefox (3.5.5), on a fast laptop and with a fast broadband connection.  I think a native client rather than a web app would be a significant improvement in this respect, though I doubt we’ll see one from Google.

The next challenge is fundamental to the way that Wave works.  Because any user can start a new response to any part of the wave, or edit any existing part of the wave, it quickly becomes difficult to track what is happening.  I admit that we were messing around, but the volume of text we had was relatively low, and it still became tedious tracking down which edits you’d read and which were new.

So my first impressions were not overly positive.  Having said that there are a number of features that Wave has that really do set it apart from email & IM:

  • With the Wave hosted on a server rather than on clients, adding a new person to the wave takes effect immediately.  The number of “looping x” emails I receive show there’s a real issue with the way we manage who is included on an email chain.
  • Real time typing makes the conversation more “alive”.  It helps drive home the fact that you are communicating with a person as you can see their thoughts happening in real time.  As an enhancement to IM this is great.  As most good email is reviewed and edited multiple times before sending it’s not going to be useful a lot of the time.
  • Breaking conversations up so that you can reply inline to a specific part.  This is fairly powerful and should make complex exchanges much easier to deal with.  The GUIs approach for marking bits as unread is clunky, but is still an improvement on email.

While I really like the principal behind Google Wave I’m yet to be convinced that the current implementation will be good enough to replace email and instance messaging.

September 10th, 2009

Fast Python

Wigan Pier in reflection

Wigan Pier in reflection

Python is my language of choice, something that I’ve used for a number of websites, applications and tools.  It’s speed of execution has never been an issue for me, even when using it to wrangle large XML files into something more useful.

Despite this, I’m happy to see the existence of the Unladen Swallow project.  Whether this tiny team of two Google engineers will really be able to make Python 5 times faster remains to be seen, but the attempt will surely be worthwhile.  Already improvements have been made, and brought back into the mainline of Python, and the approach being taken seems solid.

The project’s plan is both practical and well thought out.  There have been several attempts to re-implement or speed up Python before (PyPy, Pysco, IronPython, Jython), none of which have come close to challenging CPython in terms of adoption.  By accepting that CPython is the common implementation of choice, and concentrating on making it better, the project’s benefits should be widely felt.  Similarly, planning to gain the performance improvements through application of the relevant academic research, rather than trying to discover something new, should ensure a measure of success in a short period of time.

The weather is still mostly good, but with a chill in the evenings we are starting to use our wood burning stove in anger.  So far it’s proving a great investment, both enjoyable to use and very effective.

August 15th, 2009

Porting SimpleTAL to Python 3

I have finished porting SimpleTAL to Python 3.  Release 5.0 of SimpleTAL is for Python 3.1 and provides similar functionality as SimpleTAL 4.2 does for Python 2.5.  The differences between using 4.2 and 5.0 are documented on the SimpleTAL notes page.

Ivy and grave through a church window

Ivy and grave through a church window

At first the porting process was fairly easy.  I started by getting all test cases to run cleanly under Python 2.6 with the -3 flag, and then ran 2to3 to convert the basic syntax.  The next step was to run the test cases under Python 3 to highlight issues that required manual changes.  Sgmllib has been removed from the standard library, so I had to remove HTMLStructureCleaner from simpleTALUtils (it was unused within the library itself).  The Iterator protocol change from “next” to “__next__” meant my iterator detecting code had to be updated.

The changes to character set handling in Python 3 introduced slightly more complex changes for the template handling.  In Python 2.x the SimpleTAL library would handle all encoding / decoding itself, but in Python 3 this is not always required as there is now a clean separation between bytes and strings.

One issue that I hit when porting to Python 3 was the use of regular expressions.  In order for SimpleTAL to pass through singleton XML elements from the template (i.e. <tag /> rather than <tag></tag>) it needs to carry out a regex check against the raw XML that the SAX library provides.  This is done by retrieving the xml.sax.handler.property_xml_string property, which is documented as returning a string.  In practise however the Python 3 SAX implementation returns bytes, which at first I assumed the regex library would not work with.  A little bit of research later, and I learned that the regex library can work on bytes as well.

One final surprise was the huge performance gain moving from Python 2.6 to 3.1.  The SimpleTAL performance tests show a minimum speed increase of 60% (on the METAL test), with some tests clocking in 90% increases.  Both HTML and XML basic template expansions are now hitting over 1600 pages/sec on a single 1.7GHz CPU.

August 3rd, 2009

Old photos

Cat sitting in the sunshine on a grave

Cat sitting in the sunshine on a grave

I usually wait a while, often months, before going through my photos to pick out the good ones.  This has a number of disadvantages, particularly when it comes to remembering the names of places, but it does allow me to forget which photos I thought would be good at the time I took them.  This is particularly useful as I otherwise have a tendency to not really look at the photos critically, but rather to skim through them looking for the one that I thought would work.

I’ve started working through 2008’s collection now, and having made it to September I’ve rediscovered a number of nice shots.  The one attached to this post to my eye works really well, but at the time I was discounting it (and a few others like it) as not being ideal because I could not find a way to get the cat to look at the camera.  Now that I can see the results I’m glad that the picture has turned out this way.  It feels a much more natural shot than it would otherwise be.

There are still another 760 or so photos to go through before I’ve cleared the backlog.  I really do need to catch up as I’ve already skipped ahead a number of occasions, making it easy to forget which photos I’ve been through and which still need sorting.  I could start marking them to keep track I suppose, but then I’d have greater excuse to postpone going through them properly.

About a year ago my small camera bag developed a broken zip, which has resulted in me having to use my backpack for carrying the camera around.  This made carrying the camera a serious commitment, which resulted in fewer photos being taken.  For my birthday I’ve been given a new small camera bag, so I now need to get back into the habit of carrying my camera with me again.

July 31st, 2009

Owlfish on the move

Small green lizard

Resident green lizard at Kew.

The domain has moved hosts.  Up until now the site has run on a shared hosting service.  After 9 years like this it’s finally grown up and moved to a virtual server, hosted by slicehost.  The slice is actually the one that runs Splash of Wine, but as this is very lightly used it makes sense to host Owlfish on the same virtual machine.

One of the main motivators for doing this was to upgrade my weblog software.  I’ve been running this site on PubTal for a long time now, and while it’s easy to use, it does mean certain features are not available.  In particular I wanted to add comment facilities to my weblog, something that’s impossible to do with static HTML file generation.  I’m still using PubTal for the rest of the site, but the weblog has been migrated into WordPress.

The DNS change is still propagating through the system, so for the new next few hours there will be periodic glitches and possibly delayed email.  Looking at the initial set of logs the transition seems to have worked smoothly with no broken links – if something isn’t working please let me know.

March 2nd, 2009

First Post!

Purple Orchids at Kew GardensThe first post of the year, and so far it’s been a busy one. January and February charged past in a blur of social engagements and work. Progress on the house has been halting, but I’ve finally started the redecoration of my study. We’ve picked out the wood burning stove that we want, and have got one quote it and the associated work. The plan is to get another quote and then get the work lined up.

Stoves are still in great demand it would seem. Not just are show rooms still busy, despite the economic gloom, but they are often back-ordered for months. We had always expected to have the work completed only in time for next autumn, so it’s not too much of an inconvenience.

Last weekend we had a trip to Kew Gardens, my first time there. It’s a fabulous place for photography, even this early in the year (although none of my outdoor photos made the cut for the new album).

I’ll be shuttling between Manchester and London for the rest of the month by the looks of things, which will only serve to delay any future posts even further! As an aside for any Wii owners who read this – have a look for the World of Goo on Wiiware, it comes highly recommended.

Copyright 2015 Colin Stewart

Email: colin at