Monthly Archive for November, 2006

Agile modelling

A truly excellent article on Scaling Agile development through architecture over at Agile Journal. We’ve been discovering a lot of these rules ourselves are our project size and complexity increases, and I can recommend them all.

It’s still difficult though – we’ve certainly found that sometimes it’s virtually impossible to predict all the key points of an architecture early. The old agile stalwarts of good test coverage and lots-and-lots-of-refactoring have to come in.

MochiKit.Animator

The release of MochiKit.Animator feels like quite a major thing here. You can read some comments by Kevin Dangoor and Ajaxian.

It’s a fantastic API, and it really looks and smells far better than Scriptaculous, the current king of the javascript animation space.

What’s really nice about MochiKit.Animation is it’s use of the functional style, which produces terse but expressive source that is often “obviously” right – much better than Object Orientation for a lot of tasks. Seeing this applied so neatly to animation is fantastic.

Caching Archetypes ImageFields with Squid

This is an issue that has cropped up on a couple of our sites. We generally only use Squid to cache images, javascript and css. Cached Javascript and CSS are not a problem in Plone, because the resource tools change the url of the javascript and css every time a new version is released. That way we can have extremely aggressive caching strategies for them.

Images are another matter however. We certainly don’t want to serve them from Zope if we can avoid it – but caching is a problem when the images are changed.

Enter CMFSquidTool. This patches the catalog reindexing hook to generate a sequence of PURGE commands to Squid, for the item being reindexed. This works great if you are using a single Archetypes object to store your content, but if you have anything like an ImageField it doesn’t work so well. You get a PURGE generated for your object, but not for it’s dependent images — which might be what changed.

So, I’ve pached CMFSquidTool to look for ImageFields in the object it’s purging, and generate additional PURGE commands for all images, and all of their different sized thumbnails. This works well, and solves what is otherwise a difficult issue.

I’d like to produce an adaptor-based solution for this – With an interface for objects and fields that says what purgable urls they have, if any, and adapters for the base Archetype object and it’s various fields. Does anyone know if anything like this exists already?

IE7 Were they ready?

An interesting study of how well some major UK sites cope with IE7. IE7 was pushed onto Auto Updates yesterday, so presumably an awful lot of people have downloaded it already.

The Lyricator

Paul Lamere writes about The Lyricator, some python code for working out the mood of a piece of music.

For Sleevenotez we’ve been thinking about genres a lot – it’s a difficult problem, since it’s so subjective. I wonder if this could help?

Scrybe

This is one of the web 2.0 projects that is really making a splash – they’ve put loads of effort into their interface, and from watching the demo it looks gorgeous. You really should go check it out.

Tufte’s visualisation

We had an interesting visualisation and representation problem last week for Sleevenotez. Our next Iteration involves adding a lot of richness to the interface, which includes the presentation of quite a lot of complex data. However, we don’t want to make the interface very complex – we’d like to keep the simple stripped-down look and feel we have now.

We got properly stuck with the discography, and I turned to my books by Tufte for some inspiration. The problem is, as Jon Udell notes here: Scaling the Tufte effect, that Tufte’s brain doesn’t scale very well. He only has one, and it’s his.

Inspiration was unfortunately scarce, and we ended up spending many more hours thrashing about the problem. Jon Udell’s call there for a Tuftian visualisation library for the web is a very relevant and timely request, hwoever it is not without some significant hurdles.

Unlike a traditional charting library, I think part of the core of Tufte’s technique is his advocacy of thinking of the users of the data, and concentrating on usability. A lot of the terminology he uses is reminiscent of the patterns movement in fact, and I wonder if there is a potential angle of attack there, using some of the techniques that have emerged from the patterns movement to analyse how and when to use certain techniques.
Of course even better would be factoring this into a library. As others have noted (for example this excellent post at lesscode or even some of the notes in the Wikipedia page), it should be possible to factor a pattern properly into code – it’s just hard.

If we really could factor Tufte in this way, maybe he really would scale!