Archive for April, 2007

Rails not respecting primary keys

Wednesday, April 18th, 2007

There is some issue with Ruby on Rails not respecting primary key and other settings on columns when it does a schema dump of the db. It does this when you use a non-standard id column e.g. tablename_id and not just id.

There is a patch floating about that fixes this but a simpler way is to uncomment config.active_record.schema_format = :sql in your environment.rb. It then uses SQL and not Ruby for your schema and it respects your databases.

Browser war over

Wednesday, April 18th, 2007

I am skeptical about the consensus from a panel of internet browser developers (including Internet Explorer, Firefox and Opera) at the Web 2.0 Expo:

vendors plan to focus on positioning the browser as a development platform.

This just a day after SilverLight was announced which has no firm plans for anything but Mac OS X and Windows support.

I simply think that there will be critical disagreement and interference from corporate requirements. I’m not sure I can imagine Microsoft pushing an Internet Explorer that adheres to a platform standard that allows an app. to run on any operating system the browser can run on. I can see Mozilla and Opera doing that because they have little vested interest in the underlying OS. I can’t see Mozilla or Opera adopting XAML though or Mozilla ditching XUL. They have trouble adopting one Microsoft invented attribute on a minor element.

I also don’t see Adobe in this discussion and they own Flash as well as the upcoming Apollo platform. Flash is not dead and it is widely distributed. Sadly Adobe is not known for playing well with others either.

It is a nice idea but for the foreseeable future there is going to be forking, different platforms and all the joy that goes into developing for different and continually shifting browsers.

International sport

Tuesday, April 17th, 2007

England are currently 52/2 in their World Cup cricket match against South Africa.

What is funny is that currently there isn’t a single Englishman on the field. Both English batsmen, AJ Strauss and KP Pietersen, are South Africans by birth.

Makes for fierce slagging though with bowlers, fielders and batsmen all trying to outdo each other for national pride.

4×4 advertising

Sunday, April 15th, 2007

I am not sure which is worse. That a Honda make adverts showing a man on a quad-bike roaring along the shore of a beautiful, unspoilt beach in the early morning. Or that there are people who respond positively to such adverts.

Most adverts for 4×4s are equally poor in judgement. They show idylic, wild, natural settings and then a great big 4×4 flying through it, spraying mud and water in every direction, often coming to a grinding, gravel spraying stop.

I am not bashing 4×4s. I don’t know a single serious 4×4 driver who would charge a trail in that fashion. Most 4×4 owners I know truly love wild nature and take great pains to follow staked out trails.

This boy racer image 4×4 adverts are advertising is disappointing.

Photography on a Mac

Saturday, April 14th, 2007

iPhoto

Strange situation I find myself in on Mac OS X. Photographic management was, of all things, what I thought Mac OS X would be better at than Windows XP. But it isn’t. At least not for my situation.

iPhoto is proving to be largely useless (as you can see above) for what I want while Apple Aperture and Adobe Lightroom are too expensive and too complicated. Finder fails to beat even Windows Explorer.

My situation is that I use a Canon EOS 20D to produce RAW files which I use Adobe Photoshop to edit. I store my photographs on an external hard-drive in my own folder structure. I have close to 500gb of photos now from several years of photography.

The camera is great, Photoshop is still brilliant and my folder structure works well for me.

Where I am having problems is when I want to choose what photos I want to edit. Windows Explorer on Windows XP with the RAW plugin was strangely good. It loads directories of files quickly, caches thumbnails intelligently and lets me send a RAW file to Photoshop with two clicks. It provides both thumbnails and full-screen previews for finer detail.

Finder on the other hand provides thumbnails but when you want to do full screen previews it loads the Preview app. which is dog slow with RAW files. It takes a few seconds to flip between two files and doesn’t cache meaning a flip is always slow, not just slow the first time.

iPhoto on the other hand does cache and does it well. The new compare feature in the full-screen view is excellent. iPhoto handles 9000 files with ease.

But it has two major problems. To send a file to Photoshop you have to exit the full-screen view, back into the normal app view and right-click and Edit in External Editor. Why not just right-click in the full-screen view?

The other is that the cache is static and is stored on your local disc. A thumbnail cache of 500 gigs of photos is itself large, about 20gb.

iPhoto made that cache on import but I thought that if the cache was deleted it would repopulate it as you loaded photos. But no. It doesn’t. Once you delete the cache iPhoto just sits there showing a view like above and doesn’t regenerate thumbnails or full-screen previews. It does go off and fetch a preview of the file you are viewing in the full-screen view but it doesn’t cache that preview, making flipping useless.

iPhoto is obviously for much smaller photo libraries though I can’t see it remaining like this with people totting 10 megapixel pocket cameras.

Aperture and Lightroom are brilliant applicatons except they try too organise your files too much. I found far too much data was stored in Lightroom and it was a chore getting it out. That makes it a poor choice for long-term photo management. Aperture is just too expensive.

So I am left with no workable way of going through a few hundred photos I may have taken in a day.

All I want is a fast, intelligent RAW previewer app. Something that doesn’t try to tell me how to arrange my photos and makes sending files to Photoshop easy. Too much to ask?

Reusable vs. Disposable Cups

Saturday, April 14th, 2007

A study into the energy life-cycle of reusable vs. disposable cups is interesting. The findings are that disposable cups aren’t as bad as we expect mainly down to the high cost of washing a reusable cup.

One thing I’d like to know, and which I assume would help the reusable cup arguement, is the energy involved in transporting disposable cups. Both transporation to the place of use and then transporation to the rubbish dump. Or would the cost of transporting the heavier (and less space efficient) reusable cups make up for the unit cost of disposable cup transportation?

There are other environmental issues to think about too, beyond just energy use. Disposable cups get into the wild environment and can be litter and be dangerous to animals.

MySpace vs. The Internet

Thursday, April 12th, 2007

I’d personally rather re-write Windows Vista in Visual Basic on an Intel 286 than use MySpace but what with MySpace now blocking Photobucket content I felt compelled to email their tech support and complain. Vote with your feet and all that even if your feet never go near the place.

My simple, pleading email went:

From: me
Date: 4/11/2007 7:35:29 AM
To: mscontact@myspace.com
Subject: Not Found (-4) - no subject found in database (-4)

Please reallow Photobucket content again. If MySpace
continues to block then I’ll have to find another social
website as I have lots of vested content in Photobucket
which would be harder to move than moving from MySpace to
another social network website.

And their reply ran:

MySpace - Ireland - MSContact
to myspace

Hey there,

That issue is currently being resolved. Please be patient.

Thanks!

MySpace

Open Sourcing Flash, in the pan

Wednesday, April 11th, 2007

There is some buzz about the possibility, chance and point of open sourcing Flash.

As a web-developer I tend not to use Flash. If I can implement a feature without Flash I will. If I have to use Flash I keep it minimal. If people show me full-Flash apps. I want to know why they did it in Flash. The only two places Flash truly shines in my opinion are; as a video player in web-pages ala YouTube and for small, tricky, slick controls that are too finicky to do well in JavaScript/CSS/HTML.

Why do I try not to use Flash? Because I like text and am not a binary fan. Images (JPEG, GIF and PNG) are binary but they aren’t source. They aren’t applications, they don’t contain logic or have functionality like an SWF can. I can’t view-source on an SWF easily, I can’t hack a few characters, rerun it and see the change. I can’t easily mold an existing Flash into something else.

For me this is what CSS, HTML and JavaScript do so well. You can hack them, save them, view source, pipe them through a cheese grater and get something usable on the other end. Anything you see done with them you can figure out.

So open sourcing Flash isn’t going to make me sing hallelujah and start using it. A pity but there you go.

(As for Apollo I am really, really happy it isn’t a Flash container. It is a web container, it can house CSS, JavaScript and HTML without an ounce of Flash in sight.)

TwitterCamp

Wednesday, April 11th, 2007

TwitterCamp

TwitterCamp is an Adobe Apollo app. that displays a lovely view of your Twitter feed. Useful for Barcamps and other events where you want to display the buzz of the event.

South African Cricket

Wednesday, April 11th, 2007

To say I am relieved after yesterday’s win against the West Indies is to put it mildly. After the thrashing at the hands of Bangladesh, the near-loss against Sri Lanka and other lack-lustre performances I was feeling dispirited about South African cricket.

“We felt we were a little bit tentative against Bangladesh and we wanted to really come out and express ourselves this time,” Smith said. “We got ourselves to the top ranking by playing our natural game, and we discussed how we just occasionally put ourselves under pressure by not sticking to what we do best. We wanted to relax and go back to that today and play with freedom, and a bit of brain.”

That quote expresses exactly what I was feeling. We were going into games fearing the ball and bat, scared to dare. And yet when we stride out onto the pitch and play the game our way, we do so well. Not only do we do well but the game is enjoyable to watch, not the cringe worthy efforts of other games were I literally felt disgusted at the apparent attitude of our team.

The next game is against New Zealand, a team in the ascendancy. If we go into the game brimming with the joy of wanting to play good cricket then we will do well. We may not win but we will be good to watch and can say we are worthy.