nick.recoil.org

First post!

Whilst engaged in a bit of post-lunch Google vanity browsing, I came across what must be my first post to Usenet from my old Demon Internet account.

Newsgroups: rec.games.mud.misc
From: Polomint@turing.demon.co.uk (Nick Ludlam)
Path: bga.com!news.sprintlink.net!
  howland.reston.ans.net!pipex!demon!
  turing.demon.co.uk!Polo
Subject: Starwars?
Organization: None
Reply-To: Polomint@turing.demon.co.uk
X-Newsreader: Demon Internet Simple News v1.29
Lines: 7
Date: Sun, 18 Sep 1994 21:38:34 +0000
Message-ID: <779924314snz@turing.demon.co.uk>
Sender: use...@demon.co.uk

Hi! I just wondered if there was a
MUD/MUSH/whatever related to the Starwars trilogy?

Thanks in advance,
Nick.

-- 
Nick Ludlam  -*- polomint@turing.demon.co.uk

This was around the time that I was really into MUDs and MUSHes, and was casting around for engaging ones, before I settled on Elephant MUD through which I met some very very good friends. As I remember it, this is when Demon also packaged the KA9Q software, which was a DOS implementation of a TCP/IP stack that was used to access all the various services, before Win95.

UPDATE:

I've also spotted the first bit of code that my brother Dominic posted to the internet in AMOS basic for the Commodore Amiga. In his words, 'That was, like, before the internet was popular!'

Testing sparklines...

Just a quick rendition of the four types of Sparklines as allowed via the library for ruby At the moment they are a bit throw-away, but if they can be integrated into some dynamic data where you care about trends rather than figures, such as load average, then it could be useful. The other feature I think it's missing is the lack of being able to tag a point with a value, such as this example up in the top left corner, as does the original post from Mr Tufte. This is crucial in presenting a single numeric value, and the reader being able to infer whether this is high, low, or average.

Anyway, on with the Typo show...

Update: Since I've now moved to Mephisto, I've ditched the content of this post

The last CopyFigher Drunken Brunch of the year

Dominic and I attended the last CopyFighters meeting of the year, where Dom gave an impromptu speech on the trend of technical standards bodies. Instead of merely creating specifications on how to package and distribute data, they are becoming increasingly intertwined with mandates on how these technologies become deployed in the market place, and what restrictions are placed against what can be done with the content.

Dominic Ludlam
Rufus Pollock
Lee Maguire


You can see more pictures on Flickr

Fixing rails console support in Tiger

Just a quick post to point out an invaluable article on repairing the rails console in Mac OS X 10.4. It involves fetching libreadline and the Ruby readline extension, and reinstalling over the top of your existing environment. Quick, painless and very useful.

Upgrading, 64bit style

In other news, I've hauled my home PC out of the 32bit stone age into the gleaming 64bit bronze age, with a reasonably priced Athlon64 3200+. This is in an effort to get reasonable framerates out of X3 Reunion, but unfortunately I've found out that the bottleneck sits more with the graphics card than it did with the CPU.

With modern games, it seems that having a decent GPU and a reasonable CPU is a much better situation than a decent CPU and an average graphics card. My GeForce 6600 GT simply doesn't cut it with Black and White 2, X3 or Valve's 'The Lost Coast', which is doing a nice job of demonstrating what it's like to have a decent optical physics model in games.

Now I'm left wondering at exactly what point I can buy a top-end graphics card without paying too much of a premium, taking into account that my gaming experience gets worse with each new game purchase.

Getting on with Ruby on Rails

I'm just about to deploy the first internal application written in Ruby on Rails for Framestore. This will hopefully mark a nice change in my group towards using frameworks such as RoR and Django for database-driven web applications.

The application in this case is the primary archiving tool for the company's long-term storage of assets. The code is a mixture of Perl for the scanning and writing data to DTF2 or SAIT tapes, and a web interface for browsing and searching on the data, and generating requests for the Data Operations team on behalf of the various artists and producers working on internal projects.

This web interface was previously written in PHP, in a relatively nice way, but utilised no frameworks or modules other than the Pear MySQL class. It was also rapidly growing out of control, as the database grew in size, and the complexity of queries was growing with the functionality of the application.

Since we had the luxury of a ground-up rewrite of the Perl code over the past month or so, I've instigated a schema change to bring the database in line with ActiveRecord's expectations, which has made a huge difference to the ease in which I can sketch out the Rails code. The only odd problem I had was related to tables which logically needed no primary key, as they represented the 'zero-or-one' part of a 'one-to-zero-or-one' table mapping. In my case, a file may be part of a sequence, but it may not, so there are file entries, along with optional sequence entries.

Within the SequenceEntry model, I had to set the primary key to be the same as the foreign key, as ActiveRecord demands some sort of unique way of distinguishing records.

1
2
3
4
5

  class SequenceEntry &lt; ActiveRecord::Base
      belongs_to ::file_entry
      set_primary_key :file_entry_id
  end

One of the more annoying aspects of ActiveRecord I can't seem to get away from is the double SQL query you seem to need when you're looking at pagination of complex queries. I have a block which looks like:

1
2
3
4
5
6
7
8

file_count = FileEntry.count_by_sql("SELECT COUNT(*) FROM file_entries
                 LEFT JOIN directory_entries ON directory_entries.id =
                           file_entries.directory_entry_id
                 LEFT JOIN runs ON directory_entries.run_id = runs.id
                 LEFT JOIN tapes ON runs.tape_id = tapes.id
                 WHERE filename LIKE '#{search_pattern}'
                 AND tapes.barcode = '#{barcode}'")

which returns the number of entries I will be fetching, and then the subsequent find() query, but since each query takes of the order of 20 seconds, it's making the user wait double the amount of time that should be necessary.

The only other thing I'm finding a little difficult is where to place the code that cleans up form input variables before they are passed to the find() statements. It may either be a case of using a helper object, or possibly the prepend_before_filter, but the DRY principle has got me seeking an elegant cross-method solution.

Search

Sections

About Nick

I am a freelance technology consultant and developer working in London, with a particular interest in web development and video media.

This site contains my thoughts about technology, the universe and everything. If you would like to get in contact, have a look at the About me page.