Next month: December 1996
Of course, no-one on the WWW had the results by 9.00pm, so it wasn't until 9.15pm that I picked up Syndication UK and (surprisingly) Yearling results (no sign of Chris Prickett's updates because he'd failed to update the ALT tags !), causing my pages to be updated at 9.16pm. Some 30 seconds later, in came ITV teletext page 123 with their update (and a £10m estimated jackpot). For some unknown reason, someone switched off the external drive on the build machine for my lottery pages at 1am (Sunday morning), causing the remaining cron jobs to simply not run and hence there was no exact jackpot update :-(
I listened to the draw on BBC 1 TV live for the first time (no need to watch it of course - Alan Dedicoat can read them out a second before the ball comes to rest !), so that I could simulate a Live Update (at home only of course) to see what typical speeds I could get. The slowest page and graphics generation took 2.80 seconds - it typically takes me 2-3 seconds to type the number in and click on "Send Update", so I would reckon about 5 seconds per ball on average.
We had major internal network problems at Connect this afternoon, which prevented a colleague from completing the configuration on the Pipeline ISDN box I was due to take home this evening to enable my Net connection, so I'm still Net-less for this weekend. Still on the subject of networks, regular readers of this page will be interested to know that we're in the final stages of setting up a new 2 Mbit/s Internet connection to the Connect server that will take us off SuperJANET for good and speed up non-academic connections by a huge factor. More news on this during December - I'm moderately confident that we'll have it by Christmas.
Moved the first BBC 1 teletext page 555 request forward to 8.15pm on Saturday evening, now that they are doing quicker page updates. Mind you, with the irritating teletext mail server I'm using, it only checks the incoming requests every 30 minutes and often serves an old cached page - both appalling modes of behaviour for a dynamic news service like teletext.
One interesting change I've made to try and cope with ITV teletext jackpot pool parsing is to look for a monetary amount and the upper-case word "JACKPOT" in the same line - prior to this week, I'd looked for "jackpot" in any case and it turns out that both ITV and BBC teletext use that word (and a monetary amount) in the same line in the body of their pages as well, causing much chaos. The only place where upper-case "JACKPOT" appears on ITV or BBC teletext seems to be on ITV's sub-page headers listing the jackpot pool size.
Did another round of weblinting, linting, re-compiling with gcc, spell checking (2 mistakes) and internal link checking (old live updates page links removed). I no longer compute the InterLotto Best Performing tickets page during the Friday evening draw auto-update because it's now taking over 2 minutes to create. Instead, I have a separate cron job to generate it at 6pm (and again at 7pm in case the results were sent late).
Added code to handle ITV teletext when they decide to remove the commas (replacing them with spaces) between digits at the top of their lottery sub-pages. I'm sure they do it just to spite me ! When I submit numbers to the Live Updates system, a blocking file is now created, which prevents teletext, WWW or the fixed Saturday evening cron jobs from updating the lottery pages. This should stop them "regressing" my pages once I've put up the full results next Saturday for example.
The draw day 12.00am and 7.30pm cron jobs both ignore and delete that blocking file of course, to clear the way for the next draw. You might wonder why I'm keeping the old WWW and teletext mechanisms in place with the imminent arrival of my home Internet connection. Well, yes, they do get in the way (hence the new blocking file to disable them) providing I'm actually doing live updates on a Saturday evening of course. It's quite possible that I may not be able to do them some weeks (e.g. I'm ill, there's a power cut or the ISDN connection doesn't work are just a few of the possible scenarios), so I still want to leave them as backup systems, even in the long term.
Note that I still actually request the teletext pages, it's just that the parsing of the returned mail is blocked once I've supplied a live update. However, the WWW page grabs are treated differently - once I've updated the pages live, they are no longer grabbed. I've added an 8.00pm mirror back of the live update status files, so that the block file is mirrored back before any potential e-mail or WWW page grabs take place (assuming I've supplied an estimated jackpot by 8.00pm of course), ensuring that the block occurs on the build machine as well as the live server.
ITV teletext played silly beggars with the jackpot figure at the top of their lottery page - they used spaces instead of commas to separate the figure for the first time in 2 years....arrrgh ! This meant that I only picked up the first two parts of the number (11,713) and the wrong jackpot amount was put on the home page between 9.15pm today and 10am on Monday, but with a small period on Sunday (9.40am to 11.15am) reverting to the correct figure thanks to BBC 1 teletext jackpot parsing. I guess I'm lucky that this is the final weekend I'll be relying on ITV teletext for the jackpot figure.
Added two tables to the overall Live Updates status page. One details the quickest submissions for the winning numbers and jackpot prize pool (that have actually caused a page re-generation) and the other lists the frequency of the submissions of the 7 winning numbers and jackpot prize pool, although don't forget that my own submissions add 3 to the frequencies :-) This means that the status page finally contains conditional HTML or pre-formatted tables. Would you believe that this is the first time my lottery CGIs have produced HTML tables ?
The BBC teletext change didn't matter too much because the Computing Services Department decided to switch off their teletext service anyway ! The first site to have the winning numbers was Syndication UK as usual (8.10pm) and this was followed by Chris Prickett's site at 8.20pm, with my pages updating at 8.21pm. Only four people bothered registering for the Live Updates system and none of them even typed a number in - I was expecting this to be a flop really...
I now also allow the overall Live Updates status to be included in the scan for 2 sets of agreeing external WWW results (but both the WWW results and the Live Updates are overridden by incoming teletext results). In other words, if 3 people submit identical full results to the Live Updates system, then that is treated as one external WWW results site (and takes priority over other WWW results, providing it agrees with at least one other of course).
Proof-read all 104 individual lottery pages and made a few minor adjustments (no spelling mistakes though !). Changed the colour scheme of the Live Updates system, although it's now a pretty boring light grey. Hey, I'm running out of colours for backgrounds here and I can't use any dark ones for the Live Updates because of the words "Bonus Ball" on the 7-ball GIF are in black text and won't show up on dark backgrounds. The Camelot fax arrived (I didn't get one last week though), so I updated the mid-week results as usual. Bought another two tickets for the Super Draw.
Things left to do with the Live Updates system include:
Adjusted the speech link ("Winning numbers") so that only non-zero numbers are spoken during Live Updates. Properly passed the HTML table toggle status from the registration form through to the Live Updates CGI code. I also now provide two links from the index page so that non-registering users can select which format of overall status they want.
Changed the Super Draw (and rollover) estimating code to ignore draws more than a year old when trying to find the most similar single rollover to the top-up amount that Camelot are offering. This is because sales patterns from more than a year ago are significantly different from recent ones and badly influence the estimate.
In case you're wondering, I don't just use previous Super Draws to estimate the latest one for two good reasons - we've only had 2 previous ones [not enough data to work on] and they were both over 20 months ago, since when the sales patterns have significantly altered. Note that I remain the only UK lottery WWW site to calculate its own estimated jackpot pools, rather than relying on the underestimates that Camelot releases.
I think I'll adjust my code shortly w.r.t. the jackpot pool estimate in such a circumstance, in order to make it behave like a [£10m in this case] rollover week when estimating the jackpot pool. At the moment, it's an extremely crude standard £10m + top-up £10m estimate (= £20m, which I'm utterly convinced is several million pounds too low). We finally got our secure certificate today from VeriSign and at least it now lasts a full year, rather than the silly 6 months previous certificates lasted.
Fixed a dumb virtual lottery timezone bug (was closing the virtual lottery at 6.30pm on Saturday instead of 7.30pm !). We had a new HP UNIX workstation delivered recently - a C-Class machine (Model 777) which is now my own work machine (it's too big to sit under a monitor though...it's a tower system on the floor in my office). Performance is fractionally better with this new machine - the three main differences are less RAM (128MB instead of my old machine's 144MB), a built-in DAT drive and <gulp> HP-UX 10.10.
It's that last change (a major OS upgrade from the HP-UX 9.05 I'd previously been using) which meant that I had to spend most of the afternoon fixing my lottery scripts to remsh onto my old machine to do compilations ! The reason for this is that binaries built on my new machine will not run on the WWW server because of the OS mis-match (any CGIs, for instance, would core dump).
The first teletext e-mail with the winning numbers was actually BBC 2 teletext at 8.34pm (the second ITV teletext e-mail came back at 8.25pm with a cached copy of the 8.04pm e-mail...grrr) and it wasn't until 9.15pm that the exact jackpot and the winning numbers were supplied by ITV teletext.
Didn't get the mid-week fax from Camelot, so I had to phone them up and get the details (except the Lucky Dip, which will have to wait until Monday).
Improved the Super Draw coding so that the individual lottery page indicates which Super Draw it is (e.g. the 16th November Super Draw is the 3rd) and the "next lottery" page indicates an appropriately adjusted exact or estimated Super Draw jackpot pool. Did the usual battery of page testing, including re-compiling software with gcc, linting it, passing the pages through weblint and ispell and also internally link-checking them. Only one spelling mistake and some minor HTML composition errors to sort out. Removed the Lotto Fun Club from the list of UK lottery WWW sites to grab results from because their last update was 24th August 1996 :-(
Although the Live Updates coding is effectively complete, there's some "statistical sugar" to go on top at some point before it goes live on 16th November:
Fixed the last remaining major loophole in the Live Updates system - only one e-mail registration per numeric IP address is allowed. This stops people opening up 3 windows, giving 3 different e-mail addresses [none of which could be real of course] and then supplying 3 sets of live updates in order to force their updates to override other people's. The only people who would sneaky enough to do this would probably be my lottery WWW site rivals :-) Deleted the Live Updates proposal document.
Modified the Live Updates override concept so that when I submit something (using a special name), my submission is worth 3 "votes" rather than 1. This still virtually guarantees an update (unless 4 other people disagree), but leaves a narrow window open to a) ignore any mistakes I make and b) still credit anyone who agrees with me and submits quicker than I do.
Added timing code if the pages/GIFs get updated (timing code "stolen" from Robert Hyatt's excellent PD chess program Crafty) - I managed to get two pages and the 7-ball GIF generated in 1.87 seconds on my home system. I'm happy with this - anything under 2 seconds is probably unbeatable by anyone else attempting a Live Updates system (not that anyone else is !).
Previous month: October 1996