Curiouser and curiouser!

 31 October 2004

1:09:34 PM     : Hooray for Mozilla

Pat Niemeyer pointed out that I could also make Mozilla do automatic keywork searching by setting keyword.enabled to true using the about:config.. Pat Niemeyer pointed out that I could also make Mozilla do automatic keywork searching by setting keyword.enabled to true using the about:config. Cool! (Firefox sets setting keyword.enabled to true by default, but Mozilla doesn't.) [Cafe au Lait Java News and Resources]

First off Hooray!  You can get Mozilla to do automatic keyword searching in the address bar.  It already offers a quick way by adding "Search Google for" in the pull down list of URLs for auto-completion but this is so much easier.

Second about:config (type it as a URL in the Mozilla location bar).  This is so cool!  It looks like you can change everything about Mozilla without any tedious mucking about with .js files and chrome profiles.

 30 October 2004

10:21:21 PM     : Who loves ya, baby?

Cory Doctorow: "Apple's spending money seeing to it that features are removed from your iPod." [Scripting News]

9:45:14 PM     : One to ponder

I believe in coincidence. Coincidences happen every day. But I don't trust coincidences.
-- Garak

10:30:15 AM     : Your career is your calling

I hope you have found your calling. I hope it’s your job. I hope it pays well. The important thing is that you don’t sacrifice your calling for the sake of your job.

Your career is your calling, not your job. Don’t get them confused.  --  [ Gary North ]

I spend so much time in front of a computer that I've always figured my job was my calling.  Now that I'm doing the diploma in psychology and seeing new paths open up I'm not so sure.

Still, it's a nice problem to have.

 29 October 2004

12:00:52 PM     : Building Ruby on Windows

Something I did last night was document how I built Ruby on Windows.  I'm still using (and grateful for) the 1-click installer but hope eventually to be able to build everything myself.

10:42:41 AM     : Chill out.. it's just the price you have to pay for World Peace

100,000 Iraqi civilians dead, says study.

About 100,000 Iraqi civilians - half of them women and children - have died in Iraq since the invasion, mostly as a result of airstrikes by coalition forces, according to the first reliable study of the death toll from Iraqi and US public health experts.

The study, which was carried out in 33 randomly-chosen neighbourhoods of Iraq representative of the entire population, shows that violence is now the leading cause of death in Iraq. Before the invasion, most people died of heart attacks, stroke and chronic illness. The risk of a violent death is now 58 times higher than it was before the invasion.

Last night the Lancet medical journal fast-tracked the survey to publication on its website after rapid, but extensive peer review and editing because, said Lancet editor Richard Horton, "of its importance to the evolving security situation in Iraq". But the findings raised important questions also for the governments of the United Sates and Britain who, said Dr Horton in a commentary, "must have considered the likely effects of their actions for civilians"... [The Guardian]

[Seblogging News]
I think they did consider the likely effects. Someone will have said "Won't we kill lots of people by dropping all these munitions on civilian areas?" If the question didn't get asked aloud it's because everyone already knew the answer. Our problem is that we are governed by people who are philosophically committed to the doctrine of the end justifies any means. The death of 100,000 Iraqis, 200,000 Iraqis, a million Iraqi's... well... it's just the price you, regrettably, have to pay for world peace. Of course we know what we are really buying with all of this blood.

12:10:15 AM     : How badly can you spin something?

Yesterday I wrote about a BBC documentary called The Power of Nightmares. I've watched 2 of it's 3 parts and found it to be a thoughtful and though provoking piece of journalism. It alleges, in short, that Neoconservatives in America have consistently manipulated events to create a situation in which they can flourish and use their power to remake America in their image.

I asked 'ol SuperNode whether there was any way for US viewers to see the program and make their own minds up about it. He thought the best chance was probably BBC America. At the same time he pointed me to a FOX "news" item about the documentary written by David Asman.

What's most interesting about this rightwing propaganda passed off as journalism is how Asman conflates "the US/America" and "American neoconservatives". This is perhaps unsurprising since people of the neoconservative bent seem to think they are wholly representative of Americans. Now I don't know how biased against America the European media really is -- Probably there is enough of a bias to support the suspicion of a bigger one if that's what you think anyway. Things tend to work that way.

But I don't sense so much anti-Americanism as I do anti-Bushism or anti-Administrationism. Bush and his cronies are, rightly, being reviled and, by association, so is our own toady government. Despite this I remain pleased to meet & talk to all the Americans I know. Funny that, isn't it?

I think that Asman is completely baised and has a questionable sense of journalistic integrity.  Of course writing for Fox that is probably de rigeur.  In terms of the documentary I can only say that I asked my American housemate and she did not get any sense of anti-Americanism.

I wish there was some way for Americans to judge for themselves. For example I think it would be interesting if a lot of republicans were to watch this documentary and perhaps consider the history and roots of their own party and the changes they've seen since the right wing and the fundamentalist christian movements got in to bed together.

[Update: I edited the nature of my attack on David Asman. On reflection it was a rather angry.  I also changed some emphasis.]

 28 October 2004

11:32:34 PM     : It's your legal right

Political Wire: "What if you show up to vote next Tuesday and election workers say you are not registered?" [Scripting News]

 27 October 2004

3:03:05 PM     : Never get involved in a land war in Asia

Rumsfeld's War. Excellent PBS Frontline special tonight on Rumsfeld's War. Can't say there is any radically new material here, but it does a good job of peeling back the layers of politics and exposing the decision-making process, the personal battles, and the complete failure to anticipate the need for massive peacekeeping forces post-battle.

Lots of insight into the Joint Chiefs vs DOD battle. Make no mistake -- under the US Constitution the military answers to the executive branch. Thus it has always been. Thus it should be. But Rumsfeld and the Bush Administration charged ahead with a plan that had focused on the rebuilding of Iraq without accounting for the mess that would arise once the governing structure fell.

Rumsfeld and the neo-Conservatives had an aggressive, far-reaching strategy for the Middle East, starting with Iraq. What they didn't do was spend enough time thinking through what to do if part of the plan failed. All their scenarios required unequivocal victory. And as any good scenario planner knows -- if you don't have a few scenarios of failure you're going to get surprised.

Well worth watching if you can catch it on a rebroadcast. Wish I had known it was coming on I would have saved it on my DVR.
[b.cognosco]
How timely. Over lunch today I watched last weeks first part of The Power of Nightmares - a BBC documentary about how America has reached it's present state of affairs with Rumsfeld, Cheney and co. It's a long story which starts with the neocon view that liberalism and individual freedom have lead to moral decay in America and follows their path and from the philosophy of Leo Strauss to the Axis of Evil.

Intriguingly the basic neocon premise is exactly the same as that of the islamic jihad movement. That a sublime end justifies any means including whole sale slaughter. The neocons need the fight against the axis of evil/the war on terror to soften the people up for phase 2 -- in which, presumably, everyone becomes a fundamentalist christian. Both groups would have had a warm welcome at Uncle Joes dinner table:
"You cannot make a revolution with silk gloves" -- Joseph Stalin
The first part of the documentary covers the period of Nixon, Ford and early Reagan. Of particular interest to me where the role of Donald Rumsfeld and TeamB in helping to craft the lie that was how the American public saw the Soviet Union. It was both interesting and bothering the way the CIA's black propaganda in Europe came back to haunt them when the neocons began flexing their muscles.

If Bush gets re-elected we can expect more of the same. It's not only in the interest of neoconversatives to make people more frightened -- it's their basic plan! Expect more rigid state control. Expect more and nastier anti-terrorism legislation (and the terrorist acts it will be a response to). Expect more fundamentalist christian ideology in politics. Expect more sabre rattling. Expect more democracy at the point of a gun. Expect new and scary enemies (they're surely doing their best to create them).

And, if Kerry wins...? Well expect exactly the same thing. These guys are powerful and they're patient. When Rumsfeld and Cheney failed to get their way back in the 80's they didn't pack up their toys and go home. Instead they waited for a better opportunity. I don't see them or their cohorts giving up just yet. Not while Amerika remains to be saved.

By the way I loved Dave's suggestion that Europe and Asia should join forces and liberate America :-) I only hope we're not so stupid as to get involved in a land war in the USA.
You fell victim to one of the classic blunders, the most famous of which is "Never get involved in a land war in Asia", but only slightly less well known is this: "Never go in against a Sicilian, when *death* is on the line.". Hahahahahah. [Vizzini falls over dead] -- The Princess Bride
Part two of the documentary is tonight and covers how the neocons got into bed with the Islamic revolutionaries in Afghanistan.

 26 October 2004

2:41:20 PM     : Where's the trust?

Hired guns. There's a lot of discussion going on among bloggers of all lists about Marc Canter's proposal to pay bloggers to write about a product on their sites. Many bloggers are against this idea, starting from David Weinberger, Stowe Boyd and Jason Calacanis.

I cannot say if this approach to on-line marketing will work, but I'm not worried about the blogosphere integrity as others seem to be. I think that we are a group of smart people and that most of all we understand the value of being connected and how reputations are build.

Let's say that, for example, David Weinberger would start writing about some specific product, telling us that he's getting money for this. I assume these wouldn't be gratuitous links to a site, we are not talking about click through here, these would be posts discussing advantages or disadvantages about this product from David's point of view. Would be David be biased about this product? Of course he would! Just like he is when he talks about his PC or his weird power problems at home.

The key here is that I trust David, I know that he wouldn't lie to me. It's not because we've met a couple of times, it's because I have been reading what he writes every day for years and I think that whatever decision he would make about his weblog would be open and honest.

The same could be said for many other bloggers I read and of course the the contrary is also true: there are bloggers I don't trust regardless of who might be paying them or not.

What I mean is that I believe that the power of the relationships that we develop day by day in the blogosphere is stronger than a few dollars spread here and there by a marketing campaign. Yeah, some of us might end up being corrupted, but this is only a digital version of life, it's not perfect.
[Paolo Valdemarin: Paolo's Weblog]


I've missed this debate although Phil put the question to me about paid blogging a few days ago. After thinking about it for a bit I answered that, as long as I could be totally transparent about it, I would take the money.   Transparency would mean I couldn't become a corporate shill and anyone reading me can decide for themselves whether they think my writing changes because of it.

I think Paolo puts it elegantly:  What is at the core of this is trust.  If people trust you, then the chances are that they will be happy for you to be getting paid for writing the sorts of things that you write anyway.  If they don't trust you... well hard luck to the company flushing it's money into your pockets.  It's their job to to pay the "right" bloggers.

Will this change things?  Probably.  Some people will decide that reading bloggers who are getting paid is not for them, others won't care.  Readerships may go up as well as down, your milage may vary etc.. etc..

9:57:40 AM     : Eye opener

Ruby, Rails, and TextMate. Following the release of the updated PickAxe book, I’ve been taking my updated Ruby talk on the road. First I hit Amazon, and since then I’ve made it a standard part of my No Fluff Just Stuff repertoire.

It’s a fun talk to give for a number of reasons. First, I’ve started using the TextMate editor during the talk. It’s great for this kind of things. It knows about Ruby, it looks nice and clear when editing text on a projector, it supports folding, and I can run the code with a keychord. It takes a lot to get me off Emacs, but this editor just works for these presentations.

The other thing that makes it fun is when I build an application at the end. I start by screen scraping a sales rank from an Amazon page, then scrape n at a time using Ruby’s threads. I then publish the results as RSS and stick them in a database using RSS. The crowd really gets into it when I then say "but of course you’re probably more interested in an enterprise way of doing this. You’ll need an Object Relational mapping layer that gives you full transparency, CRUD support, linking, subclassing, etc etc…". And then I implement it in two lines of code using the ActiveRecord of RubyOnRails. Then we build up validation, event handling, and so on in a totally natural way. Then we finish off with a simple Web application written using Rails to query the sales rank data we’d previously fetched.

It’s generating some buzz—I think Rails may well be the framework to break Ruby into the mainstream.

[PragDave]


If you write web applications and hasn't seen Dave's 10 minute "show don't tell" video yet then please go watch it now -- It's a real eye opener about how easy web development can (and should) be!  Watch it even if you've no idea what Ruby is, or are wedded to Java/Python/Whatever.  You can't help but smile as Dave evolves a working database web application before your eyes and with so little effort.

 25 October 2004

7:45:17 PM     : Watch who you free associate with

Self-exploration: The watchword technique. Here's a different kind of self-exploration technique I just ran across. I haven't tried it yet, but it seemed interesting enough to throw out there for y'all to chew on. It's called The Watchword Technique, and it's in a pdf... [The Occupational Adventure (sm)]

What made reading this so interesting is that my lecture this afternoon was on Freud & psychodynamics.  The lecturer was attempting to both show Freud in his context and bring him into the modern psychological world - it made for a very interesting lecture.

 23 October 2004

12:20:38 PM     : Bayesian weblog detector?

Guessing if a link leads to a weblog or not?.

Technical weblog research question:

I have a list of links and I'd like to find out which of them lead to weblogs. Is there a way of doing this automatically?

Things that I thought about:

  • guessing from url - would work for weblogs hosted in most popular platforms
  • check if there is RSS/Atom feed - would exclude weblogs without feeds and include general sites with RSS feeds
  • match url against database of any weblog indexing site - would include only subset of weblogs and you have to get the database first
  • ...

Do you have any suggestions?

This post also appears on channel weblog research

[Mathemagenic]


I thought of various approaches to this one involving looking for <link> tags pointing to RSS feeds (Nope: the BBC correctly do that on their news pages), looking for author-information in the RSS, and so on.  None of them would be foolproof and all would be a pain to implement with lots of edge cases.

I think that if it was my problem then I would make like Jon Udell and rig up a Bayesian categorizer: train it on some weblogs and likely looking non-weblogs and then feed it the full data set and see what happened.

11:55:13 AM     : Pure Geek Pleasure

Non-programmers and programmers with experience of dynamic languages will probably both go "huh?" (for different reasons) and should probably skip this one but I wanted to record something I just did in Ruby which I found very cool.

Something I do from time to time in Java is use delegation. This can be a real PITA since it usually involves creating an interface for the methods you want to delegate, stub methods to forward calls, and code to manage the delegate instance. And this all has to be maintained. The solution I cooked up in Ruby blows the part of my mind that programs in Java.

When you start using Ruby you learn that all instance variables are private. In order for other objects to access them you create accessor and mutator methods. This is a pretty common idiom, C# offers properties which do the same job. In Ruby you do:

attr_reader :first_atribute, :second_attribute, :and_so_on
And attr_reader magically creates new accessor methods called first_attribute(), second_attribute(), and_son_on().

However the real magic came when I realised that attr_reader is not a special method generating keyword but just a plain 'ol method call: Ruby methods can extend existing classes with new methods! I immediately started to wonder: Could I do the same for delegating method calls?

What followed was a lot of help from the great crowd in #ruby-lang and quite a bit of learning about Ruby but I am now able to delegate method calls using exactly the same syntax and with as little effort as creating accessors:
delegate_methods :first_method, :second_method, :and_so_on { Delegate.new }
This is all that is required to delegate those method calls and manage the delegate object -- this feels totally cool to me! Like Lisp, Ruby is a language that offers the flexibility to change the language to suit your style and the type of problems you are solving.
"When I am working on a problem I never think about beauty. I only
think about how to solve the problem. But when I have finished, if the
solution is not beautiful, I know it is wrong."
- R. Buckminster Fuller
I think this is why I am liking Ruby so much. Many of the solutions come out beautiful first time!

BTW my Ruby delegate code is here. Please feel free to critique my style. (P.S. I was aware that the Ruby library already has delegation but I got interested in learning how to solve the problem myself)

11:13:58 AM     : abXULutely fabulous

[23/10/2004@11:05] okay, this is damn cool: http://www.faser.net/mab/chrome/content/mab.xul
[bitserf in #ruby-lang]
I'm amazed at how good a XUL interface can be. This is damn cool.  I'm hoping there is a Ruby interface to XUL since it looks like it could be a credible alternative to native toolkits like wxRuby, Ruby/tk, and FXRuby.   Although using Ruby to drive Flash GUI interfaces also looks pretty cool.

1:54:51 AM     : Slick Wiki

What could be a better thing to be doing at twenty to two in the morning than messing with Wiki software?

I've just managed to get MediaWiki (the software that runs Wikipedia) running on my Win2K box under IIS. According to the documentation this is about as unrecommended a configuration as you can get away with and have any chance of it working.

In fact the installation was pretty straightforward since I had already got PHP working with IIS for another project. I did need to monkey with a new root account in MySQL so that the installer could create it's database and I had to mess with Setup.php because for some reason the REQUEST_URI parameter (which is being dumped for debug purposes) doesnt seem to be defined. All in all though one of the less painful LAMP=>WAMP jobs.

Seems to be working well now though, even if it does creak along on my old Pentium II with 384Mb of memory. My next task is to figure out how to turn off page editing for non-logged in users.

Update: Easy just turn on whitelistedit mode.

12:56:21 AM     : Quickipedia

I find myself looking stuff up in Wikipedia more and more often but the front-page often loads really slowly. So I created myself a bookmarklet which prompts for a search term and then opens the Wikipedia search in a new browser window.

Caveat emptor: The bookmarklet is tested only in Mozilla 1.7. Although I try to set the focus on the new window it seems to be ignoring that call so that the new window is created in the background. Also the designers of Mozilla, in their infinite wisdom, decided that Javascript cannot create tabs so we have to open a new window for the search.

Once again I used the excellent Bookmarklet Builder.

 22 October 2004

10:48:59 AM     : Nuke the hundred acre wood immediately!

From there, the rest of the casting fell right into place. George W. Bush is playing the part of Winnie the Pooh himself. Anyone who has seen President Bush reading that other childhood classic, "My Pet Goat," will immediately be put in mind of the words of the song:

Winnie the Pooh doesn’t know what to do,
Got a honey jar stuck on his nose.

The part fits so well, we’re wondering if the "W" actually stands for Winnie!

Of course Vice President Dick Cheney bears a certain resemblance to Owl, except that Owl, who makes a great pretense of being wise, is actually foolish, while Cheney, on the other hand, is actually… well never mind! And they both live in hidey holes!

"I hope we don’t come across any Heffalumps today," said Pooh as he and Owl strolled through the Hundred Acre Wood.

"Yes," Owl instructed, "Heffalumps of mass destruction, Pooh! They’re being reconstituted right now!"

Just then Eeyore happened along. "Why the long face Eeyore?" asked Pooh.

"Don’t make fun of my long face," said Eeyore in his long, slow, deep voice. "At least I don’t go around all day with a honey jar stuck in my nose."

"Never mind all that," said Owl in an irritated tone. "Can’t you see we have more important things to do? We’re under imminent threat of Heffalumps! And they’re working closely with all the bees in the hive!"

"Oh," said Eeyore.

"Yes," said Pooh, who always acted like he knew what Owl was talking about.

Owl looked long and hard at Eeyore. "We’re going to have to take them out first before they take us out. We’re counting on your support Eeyore. You’re not going to go anti-Pooh Corner on us again are you?"

"Yes," said Pooh, trying to act important. "You’re either with us or you’re with the Heffalumps!"

Eeyore shook his head slowly and began a low, mournful, and awfully hard to figure out refrain:

I can’t say yes,
I can’t say no,
‘Cause I think it’s all a lie.
I just guess I’ll vote yes now,
And explain it bye and bye.

"Whatever," said Owl, making an effort to conceal that he was making an effort to conceal his impatience.

"Whatever," said Pooh peevishly, thinking the prickly tone he’d learned from Owl would come in handy if he ever got in a public argument with Eeyore.

....

[Steven and Charles Goyette]

Tails off a little at the end but I enjoyed it and it fits so well :-)

 21 October 2004

12:45:10 PM     : Alien Diner

Paolo took a neat picture of me in the Turkish restaurant we (he, Simone, and I) had dinner in on Tuesday night.  The view out of the window is kinda alien which makes it look like we were eating in a space-port somewhere!  The food was alien too but very good: I had brocolli soup followed by spinach & potato stew with rice & yoghurt and all washed down with some beers.  Yum!

12:38:56 AM     : The Secret of Life

The secret of life is honesty and fair dealing. If you can fake that,

you've got it made.

--Groucho Marx

 20 October 2004

3:39:02 PM     : Quite stylish

Ruby Style Guides here and here.  I've also found the library sources generally very easy to follow.

 18 October 2004

12:50:15 AM     : Something for the pocket

I'd really love a Ruby interpreter for my iPaq 4150 (running Pocket PC 2003).  I tried Pocket Scheme already but, interesting as it looks, it doesn't work on newer devices.  I have just installed Pocket C# which is an incredible achievement.  But what I really want is Ruby on the go!

 17 October 2004

10:49:31 PM     : The slippery end of the future

Google: selling your soul in pieces?.

Google does great things, but it asks for your data in return.

It says no evil... Of course, you don't have to sell your soul at once, it just will take it in pieces - find what you need on the web, get paid with AdSense, connect at Orkut, email at Gmail, share your ideas at Blogger , organise your photos with Picasa, and now also search your search your desktop - and pay with your data every time you do so.

It knows the tricks well: useful tools are difficult to resist and you don't mind to pay a bit in return (I use Gmail knowing how creepy it is - it makes life so much easier). Selling pieces of your invisible other self seems to be safe and it's so easy to forget how easy pieces of data could be connected.

Anyway, I wonder if there is another future... We are getting more and more connected, we want more and more integration and transparency, so may be letting our data go is just the price we have to pay? May be the only choices we have is to whom we sell pieces of our souls and how much we get in return?

Sharing your desktop with your Orkut friends anyone?

[Mathemagenic]


I think Lilia raises a really interesting point which I have been mulling for a while myself: is there another future?

We seem to be headed down a path whereby our information is forced from us by the government and teased from us by commercial concerns.  In both cases we are told it's for our own good but in both cases I think we are right to be suspicious.

However unless we can imagine a future that works a different way then we are doomed to a fate of increasing surveillance, screening, and "lists" in which we, citizens, will have decreasing rights and dimmer voices.  This will work well for the current crop of vested interests so I expect the path to get more slippery the further along we go.

What does this future look like?

10:37:27 PM     : Developing the academic mindset

The reason I am blogging at half past ten in the evening is that I have been good today.  I turned off the TV and computer and tried to catch up on the reading for my course.  I'm not quite there yet but I have done a good chunk of reading about developmental psychology (which has turned out to be much more interesting than I anticipated) including some of the theory of linguistic development which ties in to Stephen Pinkers The Language Instinct and Words and Rules which kindled my interest in linguistics a couple of years ago.

Something I have struggled to adapt to over the last couple of weeks is the requirement to study within fixed time bounds.  My life over the last couple of years has been a blended mix of the personal and professional where my work interests overlap continually with my personal ones. In effect my life became my work and vice verca.   Although i've now realised how dangerous this can become and started making some changes, it did have the benefit of offering a lot of flexibility for learning.

Now I find myself having to adapt to the schedules and learning plans of academic life.  As an undergraduate, frankly, I never cared to learned the discipline but I am trying to get it right now.  I'm hoping today has been the first step in mastering this.

10:21:36 PM     : How many perfectionists does it take to change a lightbulb?

You can't fail in an experiment. I've talked before about the idea of taking an "I wonder" approach to things. Not getting so caught up in needing everything you do to turn out perfectly, but treating your career efforts as a big lab experiment, building on... [The Occupational Adventure (sm)]

Perfectionism is something I have definitely struggled with throughout my professional career (although less so in my academic one!)  These days I am far more capable of taking a pragmatic "Is it good enough?" approach to things.  But I still have to bite my lip and tell myself to do this because, in my heart, I want to do it right.

I guess that mainly I've learned that there really isn't a right way, there is just the way that feels right to me.  I've also learned that being a perfectionist has both social and implementation costs which I no longer wish to pay.  In particular it has often lead to me being risk averse which turns out to be very counterproductive.

Being as risk is related to fear I guess that must be todays motif...

10:11:44 PM     : I don't wanna win

Do you fear success?. Strange as it may seem in our go-go, make-it-to-the-top culture, fear of success isn't uncommon. Here's a short quiz on the Fortune site to help you determine if fear of success might be an obstacle for you. It would appear... [The Occupational Adventure (sm)]

Apparently (well according to the rather flimsy test) I do have a problem with fear of success.  In fact I have had many problems with fear which have come to light over the last year or so and been brought into sharper focus by reading Susan Jeffers Feel the fear and do it anyway (a welcome gift!)  There's a bigger post here which I am still gestating.

11:28:20 AM     : Riding the rails

RubyGem of the Month - Rails. I’ve decided to highlight Rails this month, because it’s remarkably boring.

That’s right: Boring. Even David Heinemeier Hansson (its author) agrees.

I started writing a little web application for my other non-profit to put Rails through its paces. Armed with experience, let me step you slowly through its ever-so-boring pieces:

  • Installation is a total snoozer.

          [chad@mymachine]$ sudo gem install rails
          Attempting local installation of 'rails'
          Local gem file not found: rails.gem
          Attempting remote installation of 'rails'
          Install required dependency rake? [Yn]   y
          Install required dependency activerecord? [Yn]   y
          Install required dependency actionpack? [Yn]   y
          Successfully installed rails, version 0.6.0

    [chad@mymachine]$ mkdir -p ~/code/ruby [chad@mymachine]$ rails ~/code/ruby/mynewsite [chad@mymachine]$ cd ~/code/ruby/mynewsite [chad@mymachine]$ public/dispatch.servlet [2004-08-16 22:34:15] INFO WEBrick 1.3.1 [2004-08-16 22:34:15] INFO ruby 1.8.1 (2003-12-25) [i686-linux] [2004-08-16 22:34:15] WARN TCPServer Error: Address family not supported by protocol - socket(2) [2004-08-16 22:34:15] INFO WEBrick::HTTPServer#start: pid=21242 port=3000

Not only did this install Rails and all of its dependencies (using RubyGems, of course), but the last little bit setup a new Rails workspace with everything I needed to actually run a Rails application and then started it up with Webrick. Where are all of the XML config files that I love so much to squint at?

  • Writing database code is even worse. For the basics, you don’t have to do any coding. What kind of sick mind was behind ActiveRecord anyway? How are we programmers supposed to stay employed if there’s no work for us to do?

  • Gluing this all together to get an end-to-end web application working is the biggest non-event yet. Roughly:

          scaffold :tablename
    

That sets up "scaffolding" which creates (in the runtime environment) controller, view, and model code to fully manipulate the table that you point to. In case you missed it (it was quick), here it is again:

        scaffold :tablename
  

  • The most frustratingly boring part of all of this is the documentation. David’s got videos, wikis, tutorials and demo apps (all on www.rubyonrails.org), which means I didn’t get the fun of having to wade through Rails’ source code every time I wanted to implement a new feature for my web application.

Despite being arguably the most boring web framework I’ve ever seen, a lot of people seem to be coming to Rails from all over the place. Even the DotNet and Java guys, who definitely don’t seem to like being bored with nothing to do (All that Static Typing leads to lots of Typing) seem to be coming around to Ruby-land as a result of Rails.

I hear there are talks about porting this thing to languages like Python and TCL (Java, too? Is it possible in Java?).

Thankfully, though Rails itself is boring, it stays out of the way, and you can do really interesting things with it.

I hear that this is destined to be one of the more interesting examples…

[ChadFowler.com]


I've done some web development in a number of different environments (including some JSP based stuff recently) and Rails is looking very good right now.  I've already played some with ActiveRecord and it's a breeze -- it's how object oriented access to databases should be: simple, simple, simple ;-)

I couldn't help myself and bought a PDF copy of the new Programming Ruby book.  Even though the previous version is available online in lots of places I think this is such a well-written and useful book that I wanted a copy of the new edition.  I'll get a paper copy from Amazon when I have cash again.

 15 October 2004

12:06:02 AM     : Thank you Google, but no

I don't know, maybe I am becoming a Luddite -- I just uninstalled Google Desktop Search.

For me it was a bridge too far.  Even though they say they aren't collecting any personal information I guess I just don't trust Google enough to hand them the keys to my computer.  They'll have to make do with what they can mine from my web searches and personal email (although thanks to Lilia I am less comfortable with now too).

If I need desktop search I'll get it from someone else.  Maybe Omea...

 14 October 2004

6:24:05 PM     : Nothing to see here folks. Move right along or be killed.

Indymedia seizures: a trawl for Genoa G8 trial cover-up?. Injunction sought to prevent export of journalists' data [The Register]
The servers housed data belonging to a number of Indymedia journalists, including Mark Covell, who was beaten close to death by Genoa police, and is now involved in actions against them. One demonstrator was shot dead by police. Covell told The Register that email to his lawyers in Italy is likely to have been on the servers, and that a number of separate challenges to the seizures were pending. The injunction is likely to be sought by human rights solicitor Gareth Pierce within the next 24 hours.

MLATs, whose operation is cloaked by secrecy and gagging orders, are intended to provide a mechanism for signatories' security forces to obtain evidence and to make arrests internationally, and they are disturbingly dependent on the bona fides of the requesting party and the judgment of the requested one.

In this case, the latter is the Home Office, which is coming under pressure to explain itself. Richard Allan, Liberal Democrat MP for Sheffield, Hallam, has tabled a written question for David Blunkett for answer tomorrow (Friday). [The Register]

Our government assisting the Italian government in a cover-up?  Surely some mistake.

 13 October 2004

9:35:01 PM     : Taking a FreeRIDE

Now that I want to write some Ruby code I'm looking for a good IDE. Using IntelliJ IDEA has rather spoiled me and I expect a lot of intelligence from an IDE these days. I'm not sure the Ruby market is mature enough to meet my expectations, nevertheless I went hunting and here's what I found:

FreeRIDE and Mondrian are very similar having been built with the same toolkits. Of the two Mondrian seems the more polished (the author was intending to make it a commercial product but seems to be veering towards open source now) however I couldn't find a way to debug code and the editor didn't support folding. FreeRIDE, although a little rougher round the edges, has both of these features, a plug-in architecture, and some experimental refactoring support too.

VisualWX initially appeared quite promising with the its integrated GUI builder (which uses the cross-platform wxRuby toolkit) however it continually complained about not finding something called Mingw32, I couldn't find the debugger, and I couldn't get the GUI builder to work anyway.

Finally there is ArachnoRuby. This is available as a 60 day preview of an expected commercial release. Pricing is $59 for the personal edition and $109 for the professional edition although there is no comparison chart available to tell you what's different about the two.

Although ArachnoRuby was superficially the most polished of the IDEs I tried, it did have a number of shortcomings: The editor did not supporting code folding, the editor tab was constantly getting split in a most irritating way, and indenting behaviour was not to my taste.

More seriously I got a strange warning:
(eval):219: warning: statement not reached
every time I ran any code which didn't happen with the other IDE's. More seriously still the application crashed while picking from a popup context menu. On the plus side the debugger looks very impressive and they claim to be able to do code insight (although I couldn't see any evidence of it in my short test). This is one I'd like to see again in a few builds time.

For now I'll be using FreeRIDE which is, for me, the pick of the bunch. But i'd love to find a Ruby IDE that I could hold up to my beloved IntelliJ.

Update: Austin Gilbert pointed out to me that Eclipse has a Ruby mode. Although I have always loathed Eclipse for Java development work I figured it wasn't up against any stiff competition here so I installed Eclipse 3.01 + Ruby mode.

Well Eclipse may have gotten prettier since I last used it but it's just as complicated and unfriendly. The Ruby mode doesn't offer anything beyond FreeRIDE (less even) and for the life of me I cannot even figure out how to get it to run my test case. I keep getting presented with dialogs for defining configurations and something about perspectives but as to actually running the code... well, no.

So I still hate Eclipse, but thanks anyway for the suggestion Austin.

Update updated: I'm not sure why but I decided to give Eclipse another try this morning before deleting it.  After a considerable amount of gnashing of teeth I have managed to get it to run & debug my test case.  Why do they make it so hard?  When I click Run I expect something sensible to happen not to get into arcane, self-referential, dialog boxes.  And preferences under the Window menu?  Of course it's the first place you look!  Anyway the debugger seemed to work apart from not being able to Terminate.  I'm not  sure how annoying that might prove to be.

At this point I'll grudgingly accept that Eclipse may be a viable platform for Ruby development.

6:59:42 PM     : RSS Archives & the grand unified blog repository

Blog Research Repository. Wondering what would happen if I made Sigmund public, I have come to the conclusion that it is not as straightforward as it seems. The spidering problem, mentioned in the same post, is only a technical glitch. Matt Mower in... [Anjo Anjewierden]

Anjo posits the idea of a grand unified blog post repository where the text content (sans formatting) of every blog post could held. The idea is that authors of blog searching, and indexing tools could use the repository instead of spidering sites themselves. I'm working on a tool now which could make use of such a service and, if it existed, I probably would.

The likes of BlogLines, Feedster, and Technorati already have most, if not all, of the data but I think there are some significant challenges when you start thinking about how terms of service might have to work. Possibly an academic institution might be able to come up with something if they have the spare capacity to run such a thing on a non-commerical basis.

But I still think that RSS Archives are a good idea. I think they solve two problems in a decentralized way:

  1. To be able to access, in a standardized way, the entire contents of a weblog. Even with blogs which produce a page-per-post you have the problem that the home page will only link to recent posts. You have no reliable way to determine where the rest of the posts are and indexing the whole blog, Google style, is wasteful and likely to include lots of stuff which isn't really part of the blog content.
  2. To be able to access, in a standardized way, the content of each post. Which bit of, say, a Wordpress generated blog page contains the actual content of the post? The idea is to encode each post into a separate RSS file which is, theoretically, easy to read using standard RSS tools.
These two goals are achieved through the opml map file connecting the permalink of each post to the URL of the RSS archive for that post with the effect that, from my RSS archive, you have a predictable means of accessing only & all of the content of my weblog posts.

Further enhancements could include adding the publication date to the map which would make it trivial to retrieve intelligent subsets of the data (e.g., all posts from 2003). At this point I would probably start heading towards an XTM or XFML map instead to leverage what those standards can do (which is the direction I was heading in with liveTopics many moons ago).

5:09:59 PM     : Letters from the past

One year ago. One year ago I posted a list of Italian blogger girls posing nude. In the next 2 days I got the all time traffic peak of this site. :-)

Thanks to Steve Kirks for his excellent "On This Day" radio macro.
[Paolo Valdemarin: Paolo's Weblog]


I missed this macro, it's neat.  Thanks Steve.

1:20:41 PM     : Keeping tabs on encryption

Who is Reviewing My PGP Purchase?. I'm a long-time user of PGP encryption software. Though I don't use it for everything, I use it to sign and/or encrypt e-mails with sensitive or critical information. I also use it to encrypt confidential files on my computers. And sometimes I use the PGPWipe function to make sure things are really deleted. I have for years, so many years that I was still on version 4.something.

But with the new ThinkPad running WindozeXP Pro my old version of PGPMail wouldn't load. I also had a copy of the newer PGP 7.0 freeware, but it wouldn't load either. Both gave me error messages about being incompatible with the OS. Most likely not, since my old version ran fine on W2k, but still...

So I went looking for the latest freeware version of PGP. I downloaded the ZIP file but it contained a corrupt archive of the .exe file. I tried it again, figuring maybe there was some network error, but got the same corrupt result. I figured "What the heck? I haven't paid for this stuff in a long time, it's ok if I buy a new copy." So I went to the PGPStore and ordered a new copy of PGPDesktop 8.1. I filled in the forms, paid my money, and got my confirmation. This is what it said...

encryption_security.png

I wasn't aware we had reinstituted export restrictions on encryption tools. Six hours later I still don't have my software. And I want to know just who the hell is reviewing my purchase, and what are they looking at? Are they checking my name against the "Do Not Sell" list? Or maybe they're checking it against the same bogus list the airlines are using to trap terrorists on airplanes. Maybe they're looking at my credit card records to see if I made any bulk fertilizer purchases recently. Who knows?

I know one thing -- if PGP Corporation is the only one reviewing my name they don't have authority to look at anything and the whole idea of claiming a review is ludicrous. If someone other than PGP Corp. is reviewing this purchase data I want to know who, how, what, and why. And I want to know now.
[b.cognosco]


Terry's asking some pretty good questions.

12:53:31 PM     : Clustering algorithms, or: How to make your brain hurt

I'm currently reading Information Retrieval: Data Structures & Algorithms by Frakes & Baeza-Yates which I found in the LondonMet library (when I should have been looking for psychology books).  It's the first book I've found which has practical information on implementing algorithms for ranking & clustering data.  As books go I've found it reasonably easy to read although my math is very rusty which trips me up a lot.

What i'd really like to do is find someone working in this field already who I can learn from.  Anyone know anyone (academics maybe?) in London or surrounds who works in the text analysis and/or data-clustering?

I'm also looking into techniques like the Singular Value Decomposition (used in Latent Semantic Analysis) but that requires some matrices-related heavy lifting which I'm slowly working my way back up to (with lots of interesting diversions along the way).  I also came across something called Support Vector Machines which seems to have applications in this area.

I think I need an external brain pack, anyone got any liver..?

 12 October 2004

10:39:45 PM     : We may get to play with SubEthaEdit too

I don't know how real it is but Cherry OS is claimed to be a MacOS X emulator for the PC which runs at roughly 80% of the speed of the host machine.  PCWorld have a news item here.

 11 October 2004

11:57:21 PM     : A ruby in the rough

Over the last year or so I have toyed with both Lisp and Python as languages I could use to augment my use of Java (I'm using C# and .NET in another context but they don't really count; they're just Java only more Microsofty).  Although I enjoyed the challenge of learning Lisp, it felt too far removed from what I do day-to-day and I didn't really like the tools available to me.  I'll probably come back to it, but it's not what I'm looking for right now.  Python I've looked at several times and all I can say is "No sir. I just don't like it!"

Over the weekend, I came across Ruby for about the 3rd time and decided to take a closer look.  I read some of the Ruby guide, installed it locally, messed about, it felt good.  I think I have found a language I can work with.  It's a loosely typed scripting language ala Perl & Python but it isn't a mess like Perl and seems more regular to me than Python (don't ask me what I mean by that cos even I'm not sure!)

Ruby has powerful blocks & iterators, has a metamodel, is single inheritance but allows mixins.  Basically it fixes many of the the things that I have found restrictive about Java since I started playing with other, more flexible languages.  I've written a few programs using the Ruby IDE  (written in Ruby itself) and begun to feel at home.  I'm starting to think about re-starting one of my current Java projects in Ruby.  Or maybe building it as a hybrid using JRuby.

 09 October 2004

11:31:58 PM     : St. Martin-in-the-Fields (redux)

Just back from St. Martin-in-the-Fields where I heard the Belmont Ensemble give a performance of Handel's Gloria in Excelsis Deo and Dixit Dominus followed by Mozarts Requiem Mass K.626.  The music and singing were wonderful, enhanced by the candelight atmosphere of the church itself.

 07 October 2004

9:06:17 AM     : Florentine Birthday Felicitations

Doing it differently :).

Last two years I spent my birthday hard working. I thought I should do it differently this time, so I booked a ticket. I'm flying to Pisa, then take train to Florence and then I'll see how it goes before my flight back on Monday :)

I also thought that my weblog makes an impression that I'm more serious than I really am, and, as birthday party is a good opportunity to know someone better, I decided to write 100 things about me. Not sure if it will help you to know me better, but at least I had fun writing it :)

[Mathemagenic]


Happy Birthday Lilia!

 

Have fun & enjoy the Bridges :-)

 06 October 2004

1:51:15 PM     : Aw dude

Scott Rosenberg on the Edwards-Cheney debate. [Scripting News]

My take on the debate: Cheney managed to cram "Global war on Terrorism" and "9/11" into his first sentence.  I saw no reason to listen beyond that.

I'm much more interested in the footage I saw last night on Channel 4 news of an American F-16 attacking a group of what could be fleeing civilians.
  • The pilot tells ground control he can see numerous individuals on the road.
  • He asks if he should take them out?
  • Instantly he's told to take them out.
  • The pilot locks the bomb guidance system onto the crown running along the street.
  • The pilot's reaction: "Aw dude."
The callous disregard with which they were dispatched and the "Aw dude" are a frightening reminder that this is middle-America at war with anyone who looks funny.

11:47:24 AM     : Mozilla feature I want most

I use Mozilla a lot and by about midday (as today) I usually have about 5 windows open each with as many as a dozen tabs.  Basically a complete mess.

The feature I would most like to see is an option to consolidate all Mozilla tabs into one browser.  I would like a button I could push that would close all but one of the browser windows, moving all the tabs into the one remaining window.

That would be neat.

11:21:35 AM     : Good 'ol Mozilla

WTF?! -- firefox Wipes Out Program Files.

Holy cow! I just went to uninstall firefox 0.93 to do a clean install of 1.0PR. The damn thing wiped out most of my Program Files directory. WTF is that?

I had to spend about two hours reinstalling software. Thankfully, most of the apps went in without hiccup -- finding their preferences and registration info. Only a couple overwrote themselves and had to have their brain kickstarted to function.

But this is absurd. What idiot writes an uninstall routine that wipes out everything in the parent folder?! There are some messages at Mozillazine about this problem in 0.8, but I don't see anything about 0.93. This is not some minor issue. This is a show stopper. I mean, damn!

[b.cognosco]


Eek. Makes me glad I've stuck with good 'ol Mozilla :-)

11:00:23 AM     : Liars and Fools

I HAVE GOOD NEWS AND BAD NEWS

The good news is that we are seeing the erosion of state power. It is happening slowly. Politicians gain votes by promising to make things better. The fact is, there is very little they can do to make things better. What is even more amazing, there is progressively less and less they can do to make things worse.

[...Snip...]

But for tens of millions of American voters who still think that politicians are in a position to protect them from economic forces that seem to threaten them, a Presidential election year offers what they think is hope. The bad news for them is that it doesn’t. Yet that is really not bad news. It’s very good news. But it takes economic understanding to recognize this.

[...Snippity...]

CONCLUSION

America’s economy is becoming less and less dependent on the Federal government. The Federal government is 25% of the economy, but the economy is more and more part of the world economy. This is good news for liberty. The bond market responds to international economic pressures more than it does to a President’s whims.

Stocks may rise because of a reduction of political uncertainty. But political uncertainty is minor compared to central bank uncertainty.

This means that voting has become marginal economically. The voters perceive this. Defenders of democracy may wail in despair at the refusal of voters "to do their civic duty." Their wailing will do no good. Neither James Carville nor I hope to be reincarnated as the Electoral College.

[From LewRockwell.com]

Another excellent piece by Gary North. Sums up why I decided against getting involved in politics:

  • It's full of liars, fools, and lying fools.
  • It doesn't matter anyway.

I'd rather do something.

 05 October 2004

11:54:08 PM     : Making blogs spider friendly

I've been playing with indexing blogs and, mindful of Anjo's comments, decided to try an experiment in making my blog spider-friendly.  The original idea for this was Paolo's, we talked about it a while ago.

What I've done comes in 3 parts the first two of which are part of a Radio tool I will release shortly.

  1. Write each weblog post into it's own separate RSS file. That's right, I now have about 1583 little XML feeds which each contain a single post. Here is an example feed.
  2. Create a blogmap.opml file which maps each post from it's permalink to it's XML feed.
  3. I add a <link> tag to my blog pages which says where to find the blogmap OPML file.  This works the same way as the tag which says where to find your RSS feed.
The net result is that an application can now access the contents of my blog in a completely predictable way. From any page with the <link> tag (which, in theory, is every blog page) it should be able to locate the blogmap outline and from there it can find every post, or, using the permalink as a key, any individual post. Each post is encoded in it's own RSS file and can be read using any standard RSS2.0 parser.

Right now the tool has to be triggered manually and generates everything from scratch which is a complete waste of time (you don't want to upstream 1,000s of files every time). The next version should hook into Radio's publishing events to keep everything in sync quietly & automatically.

I would have thought similar implementations for MT, WordPress, TypePad and so on should be pretty trivial. Assuming, of course, that the idea makes sense in the first place...

6:36:14 PM     : New GMail contact lists

Speaking of GMail I've just noticed the new Contacts feature in the left hand menu.  Has it been there long?  It lets you see a list either of all your contacts or just the frequently used contacts.  If you select a contact it will show you all of your conversations with them.  This is where the flat structure of GMail shines since you don't have to worry about foldering.

Incredibly (to me) I am barely trying organise my GMail messages at all.  I currently have 2 only labels: one called Reg for marking emails containing registration details, receipts and so forth, and another called Hermes about which I may talk another time.

It's very liberating not to have to care where my email goes!

6:02:14 PM     : 1% and counting

So i'm at 1% of my GMail accounts 1GB allocation.

I'd been at 0% for so long I wasn't sure it would ever happen but, now that it has, I'm starting to wonder how quickly I might fill the whole thing and what might happen then?

So far I have only been deleting messages that I obviously won't ever want again and archiving the rest.  As far as I can tell this is the intended way of using it.

Have Google mentioned whether more storage can be obtained?  I looked for a way of sorting messages by size but couldn't find anything which would make pruning a bit tricky.

5:03:04 PM     : Sigmund says

Sigmund on the US Presidential Debate. Cameron Marlow has posted a listing of the most popular noun-phrases in the transcript of the US presidential debate between George W. Bush and John F. Kerry. I have applied Sigmund to the same transcript. Sigmund is a kind of... [Anjo Anjewierden]

Sigmund is a cool tool.  I look forward to the public release with eager anticipation!

2:06:30 PM     : Hurrah for the first day of school!

So i'm back at University after 8 years away. After I graduated in 1996 I was pretty happy to be out of education. The degree had been a 4 year labour of  love and, although I had some academic ambitions, I couldn't work up the enthusiasm for post grad study.

Now I'm really pleased to be back. Doing psychology is certainly a change in direction for me but, when I think about it , I guess i've been studying psychology on and off for a few years now; As i've faced problems and challenges in my life, I've often turned to people & books that can help me with new ways to understand how I think, feel, and act in any given situation. It feels good to put it on a firm footing at last.

Yesterday I started a course which I will study one day a week for 3 years, 2 modules per semester.  The first module is on developmental psychology which seems to be the study of how our cognitive processes develop from infancy. This introduced some theories by a chap called Piaget (who was big on experimenting on his own children) which looked at the age at which infants understand concepts like "an object still exists even when we can't see it" and "two objects cannot occupy the same physical space." (Don't go getting all metaphysical on me now!) The main thing I took from this was how the results are so open to interpretation and how the accepted interpretation can change pretty fast even backwards & forwards!

The afternoons lecture was an overview of the psychology of personality. This introduced 6 different paradigms of how psychologists attempt to define and understand personality from the biological theorists who think it's all in the genes to the humanists who think it's all the fault of our parents! At all times our lecturer Jo Lusher was keen to instill in us the idea that these things are to be questioned.  At first I was a little impatient to get on with it, but by the end I found i'd absorbed a great deal and had lots of questions to ponder about the different theories.

Something I found very comforting was that the lecturer is an active researcher in this area and spoke briefly about her own work on addictive personality and a particular gene which seems to be present in many addicts (she mentioned long allelles but I didn't catch the whole of it). It seems that the psychology department here has a very active research portfolio. It also seems a pretty vibrant place to study.

All in all a really good start, a fun day, who could ask for more?

1:23:55 PM     : Bloglines citation macro

A while ago I wrote a macro for Radio blogs which lets you add a Technorati Cosmos citations link to each post. Yesterday I did the same thing for BlogLines.

You can get the macro, called blogLinesCitations, here. This file should be downloaded and placed in the macros folder under your Radio Userland program folder. You may also need to restart Radio before it picks the new macro up.

To add the citation links to your blog you need to place a call to the macro into your #itemTemplate.txt file in an appropriate spot. The call should like like:

<%blogLinesCitations( <%itemNum%>, "Text you want to appear in front of the link" )%>
Radio will replace <%itemNum%> with id of the post number when it renders each page. New pages will automatically pick up the new citation link however to get it on old posts you will need to republish those pages (or even your entire weblog!)

Update: My thanks to Donovan Watts for pointing out an error in the example!

1:05:03 PM     : I should learn to keep my big mouth shut

So, just after saying how good it was to be back in the saddle of my blog I get a technical hitch that means I can't post :-)    Thanks to Paolo though it got sorted out pretty quickly and now I'm back.  If I can find time I'll post my experiences of my first day being a student again after 8 years!

 01 October 2004

8:02:51 PM     : PHP on Windows c'est facile

A couple of days ago I was asking about PHP and IIS.  Julien Couvreur says:

Very easy. Just run the windows installer for PHP, from http://www.php.net/downloads.php
"CGI only, MySQL support built-in, packaged as Windows installer to install and configure PHP, and automatically configure IIS, PWS and Xitami, with manual configuration for other servers. N.B. no external extensions included".
It hadn't occurred to me that it could be this simple.  Thank you Julien! :-)

12:13:01 AM     : I couldn't possibly talk about it

Listened to a very interesting programme (audio replay available for at least a week) on the Radio today.  It was all about the development of polite society in 18th century England and how a new philosophy of social interaction emerged which taught people how to talk to each other (and even that they should!).  Fascinating stuff.

12:08:16 AM     : Feeling the squeeze

Find more time to pursue your passion. One common complaint I hear is a lack of time for people to pursue their passions. They want to, but life just keeps getting in the way. Here's an article with an idea for how to whittle down the things... [The Occupational Adventure (sm)]

I'm anticipating my time being squeezed to the limit in the coming months.  I'm going to be trying to keep a roof over my head, study for my new course, and persue other passions.  I think I'm going to have to be much more organised with my focus to ensure I make best use of my time.