radiac.net

diary - archive

November 2005

Can't Work All The Time

1st November 2005 at 01:592 comments
On Friday, at the request of Vas, I wrote a small and simple pattern matching engine to take a plain text reference and turn it into a BibTeX reference. It's a difficult task to do automatically, given that to interpret a plain text reference takes some human intelligence. My script takes simple formats like '%author%, %title% (%year%)', or you can extend it to match regular expressions, like '%/(\d+\. )%%author/.+?(?<!\b.)%. %title%.' Oh, and it does other things too; allows you to insert comments, and also lets you set the type.

It's not perfect; there appear to be some small glitches with certain regular expressions in certain places. But it's now able to successfully recognise over 60 plain text references with its current library of 20 formats, even with around 10 of those formats being pretty specific to certain examples Vas sent me. The script also has the ability to 'learn' - if you successfully match, you can add your format will be added to the library. And I don't think anyone would be lame enough to want to mess up the library on purpose.

It has also, at long last, given me an opportunity to put a tiny bit of my javascript out in the open. I've been writing some nifty javascript for several years, but it always seems to be either written for a specific need or event, or it ends up on admin-only interfaces for clients. This script has nothing special - just a Toggle class to display/hide objects, and turning some plain text into links to ensure graceful degradation for non-javascript browsing. But still, it makes a nice change to copy and pasting word documents, and generally makes the interface a bit niftier.

At the moment I find that my work is quite unrewarding from that point of view - most of the time I don't get a chance to do anything interesting, and when I do the only feedback I get is from the person I send it to. And nearly all of the time I'm the only person who ever sees and uses the behind-the-scenes admin interfaces and code libraries. This is the kind of thing I'm interested in and would like to spend more time working on, but I have too much work to get done first. Oh well, always the way, isn't it.

Anyway, I gave this plain text to BibTeX converter the imaginative name of text2bib, and put it online at services.uzeweb.com, which I took the opportunity to give a little facelift, having not touched it in around 4 years. Never enough time.

Now my eyes hurt from the halloween theme. Guess I should take it down now, but I don't want to :)

Back To Blue

3rd November 2005 at 09:4210 comments
Back to the old theme. I also decided it was about time to drop my little welcome message, seeing as it's been there for over 5 years.

Anyway, I just saw an advert for Titanic on DVD, with an alternative ending. Please, will somebody buy this and tell me if they all die?

When I'm a multi-millionaire, I'm going to film a new version of Titanic. Involving a hitman cyborg from the future, sent back through time to destroy the Rose before she can be saved and go on to recite her story for 194 minutes.

Damn that film sucked. No wonder the robots are going to kill us all.

Using Open Source Code

8th November 2005 at 11:165 comments
When it comes to using open source code in my projects, I hesitate. Even though I may find that the code I am about to write might have already been written by someone else and is sitting in front of me, I will often ignore theirs and write mine again from scratch. I am aware that we would never get anywhere without standing on the shoulders of others, but I frequently just can't bring myself to do it.

Part of it is that I enjoy solving problems, but the real issues for me are quality control and future-proofing.

If I write something, I know how it has been written, and how it has been tested. Without developing it from scratch, it can be difficult to fully test the code. If I miss a bug, data could be lost, users would get annoyed, and the image of me and my project would be damaged.

I am also in control of the future of my own code. If open source only takes me half the way and I have to do a lot of work to customise and extend it, when the original authors release a new version I either have to fork their project and port bug-fixes, or go back and re-do all of my changes.

Don't get me wrong - I'm not saying that I'm the best programmer out there and that everything everybody else writes is inferior. I know that there is going to be rock-solid code out there written by the best in the field, but there's also going to be bug-ridden barely-tested code written by incompetent amateurs. And it's not easy to tell the two apart - I've got it wrong in the past, and I've been stung many times.

In essence if I use something written by somebody else, I am making a leap of faith by trusting that a stranger has got it right. But if it goes wrong it's my problem - it's me who my customers will see as the incompetent amateur. I see the lack of accountability and responsibility in open source development as a very real price that I don't want to end up paying.

I see this as a long-standing problem with open source and I'm sure I can't be the only person who thinks this. I find myself wondering what should be done about the accountability of open source, if anything? Should there be a more recognised and accepted method of ensuring the reliability of open source code? Perhaps more standardised and publicised internal testing and peer review? Maybe SourceForge should have a mechanism to raise bounties for fixing bugs and introducing features to financially reward developers and keep projects active?

I'll be interested to hear your comments, but for now, back to my closed-source ActionScript :)

Open Source Ideas

11th November 2005 at 08:251 comment
Following on from the question I asked in my previous entry, today I am wondering where we draw the line between learning from others and stealing from others. To illustrate, I will give you some examples.

Imagine that I produce something that does the same job as another open source project, but has totally different code and was developed without any knowledge of the other project at all. Is that wrong? I would assume that here everyone would say no.

But what if I take an idea from that open source project and use it in mine? Is that wrong? What if I credit them? If I credit them for the idea, should I then obey the license that they released their code under?

You may say that only the code is covered by the license and that the ideas are free, but it is often difficult to decide where that is. It is clearly wrong to take code and pass it off as your own, and at the other end of the spectrum, people say that software patents concerning ideas are bad because they stifle innovation. But in open source, where do you draw the line between learning from others and taking from others?

What if what you learn is in the source code? I taught myself BBC BASIC purely by looking at other people's source code. I didn't copy and paste anything (partly because RISC OS didn't have copy and paste back then), but whenever I use the PRINT statement, should I credit the program where I first learnt about it? No. But what about if I learn how to use an obscure Javascript command by reading code rather than a tutorial? Should I credit the author of that code?

Again, I would assume that most people would say no, but where should the credit stop? Am I producing a derivative work, and as such should I obey the license they released their code under? I would say "do what feels right" - if I learn something obvious, that's free, if I learn something unique and special, give credit. And if I take something they wrote, abide by their license. But is that good enough?

I guess what I'm really asking is this; is it wrong to look at source code to see how something has been done, and to then go off and reproduce the effect without directly copying? And is it wrong to look at a running program and take ideas away from that without credit? Where do we draw the line between code-copying license violation, and building on the ideas of others?

Something Good And Something Bad

16th November 2005 at 08:102 comments
We all love speed cameras, so I'm sure you'll be as excited as I was when I read this story about how there will soon be license plate recognition at every 400 yards on UK motorways, not to mention sprinkled around town centres and petrol stations. And how your details will then be stored on a database for two years, even if you haven't done anything wrong.

And the much-anticipated Google Base has now opened its doors. Looks interesting, if not slightly scary - Google already currently knows your friends (Orkut), who you talk to (gmail), where you live and what your house looks like (maps), your shopping habits (Froogle), what's on your computer (desktop search), what sites you read (personalised home page) and very shortly what you're thinking (personalised search). Clear proof that Google is actually run by the Illuminati.

I have also decided that my diary is becoming too much about my work, and therefore has become too boring. This will now change.

I'd also like to remind you that in 14 days and 16 hours it will be December 1st. Your attendance is compulsory.

Thank you for your time. That is all.

AOL Instant Messanger Bots

17th November 2005 at 08:071 comment
Yesterday, AOL instant messenger added some bots for me to talk to, which livened up my day, let me tell you.

But am I the only one who finds it slightly amusing that they're called aimbots?

Thought so. Never mind.

New design

17th November 2005 at 22:443 comments
Today I updated the design on the Tonbridge School website. I think it looks much better, and works fine in the latest releases of Firefox, Opera and IE. And lynx.

Holiday Time!

20th November 2005 at 19:49Comment
Leela and I are off on holiday again tomorrow! We're flying up to Edinburgh for four days (it's not cold enough down here or something), and it will no doubt be fantastic. We have figured out what we're going to do, and it starts with driving to Bristol to fly up to Edinburgh. I was keen to drive, but then we probably wouldn't get there till next week, if at all. So flying is probably wise.

This has all spurred me on to finally retire my old mailserver and move the operation over to my new server, Uriel. This leaves chili free to become a linux desktop, although do you think a 450mhz P2 will be good enough? Only one way to find out.

Hello From Edinburgh!

22nd November 2005 at 08:355 comments
Flew to Edinburgh yesterday from Bristol. It was a quick and pleasant flight, once we got off the ground - the thick fog at the airport meant we had to wait for the pilot to pluck up courage to take off blind. Or something. We then got to our hotel, and wandered around the city in the dark and found somewhere to eat.

Today we will be doing lots of exciting things and taking lots of photographs. But first, time for breakfast!

Radiac's Scottish Adventure

27th November 2005 at 22:543 comments
Leela and I are now back from Edinburgh. We got back on Thursday actually, I just haven't got round to posting about it here, I'm lazy.

On Tuesday we headed into the centre of Edinburgh and started with the castle. Although it was incredibly cold, it was very interesting. I listened to an audio guide and listened to the Scottish propaganda about how evil the English are, and we saw the Scottish crown. After that we headed down the Royal Mile and went into various museums and saw lots of things, including the Museum of Childhood, a museum about Edinburgh, Holyroodhouse and the Scottish Parliament. We also went into the Edinburgh Dungeon, which was extremely silly, but fun.

The next morning we caught a bus from just outside our hotel, and went over to Ocean Terminal to see the former royal yacht, Brittania. We had those audio guides, and it was very interesting to look around - must have been pretty neat when it was all working. In the afternoon we wandered around the shops and went into an art gallery.

We didn't like to spend too long looking round on Thursday because we had a flight in the afternoon, but we still went out and had a look around, and found somewhere good to have lunch. The journey home was pretty uneventful, and arrived back at about 9pm.

It may seem obvious, but Edinburgh was pretty cold. Of course it was pretty cold down here when we got back - in fact, if we'd gone Tuesday to Friday as we'd originally planned, we'd have been stuck with the thousands of other travellers in the snow on Bodmin Moor - but more about the snow tomorrow.

Edinburgh was a lot of fun, and, if you can look past how much they hate the English, it was a nice change to go somewhere on holiday that didn't require foreign money or a travel dictionary. I'll definitely go back to Scotland at some point, but next time I think I'll try to get outside the city. Maybe I'll try and find my ancestral castle! Yes. That can be another adventure.

Photos to follow.

Snow Friday

30th November 2005 at 10:282 comments
Last Friday it snowed. Leela had taken the week off to go to Scotland, so she still had a day off, and wanted to do her Christmas shopping even though it was a whole month away - how efficient. We went into town just as it started snowing, and as we went around town we noticed the shops started getting emptier and emptier, and most shops sent their staff home and shut early. Luckily not all shops shut though, because I decided that it would be a good time to get myself my Christmas present.

In recent years I have taken to buying myself an exciting gadget - two years ago it was my PDA, last year it was my MP3 player, and this year I decided to get a Nintendo DS.

I've never owned any kind of gaming system, and have always been a bit reluctant to spend hundreds of pounds on one while I have a perfectly good desktop for playing games on. But I decided enough was enough, and decided that I wanted a DS.

So why not a PSP? Well, I was tempted (especially with Liberty City Stories on it) but I always wanted a gameboy, and I've always secretly been a bit of a Nintendo fanboy. I also couldn't see myself playing serious games on a portable console - I don't have time to play the serious games I have on my PC. I was looking for something I could dip into and play in the many spare 5 minutes that I usually spend twiddling my thumbs, so the main reasons to get a PSP were out (GTA, watching films etc). Oh, and for the price of a PSP, I could get a DS with five games.

I got a Mario Kart DS pack from HMV, and got a free extras pack (with holders and emergency charger) and a free game - Nintendogs, which is on order, apparently due to a national shortage. I then picked up Meteos and WarioWare from Game. Both shops gave me loyalty cards, and both shops will no doubt be seeing me again in the future.

Any suggestions for the next game to get? Having played Tony Hawk on the PC a few years ago, I'm quite tempted by American Sk8land, but I'm put off by the txtspeak title - any other ideas?

Just to remind you...

30th November 2005 at 16:003 comments
Eight hours left to go...

I had a hair cut. I look like an egg.