Do they belong to you? Claim these comments.
Neil
Is this you? Claim Profile »
2 months ago
in Ruby Best Practices - Hello World (Literally) on Ruby Best Practices Blog
• Who are you & where are you from?
I'm Neil Cauldwell, currently based in Stratford-Upon-Avon, UK (Shakespeare's hometown). I'm working on some web businesses and using Ruby/Rails to build them.
• What is the Ruby scene like where you live?
London is the nearest scene. There isn't much here.
• What would you like to see on the RBP blog?
More of the same, mixed in with examples of code improvement. There has to be tons of regular design patterns in Rails apps (for example; I do appreciate this isn't just a Rails blog) which could be improved with some RBPs.
I'm Neil Cauldwell, currently based in Stratford-Upon-Avon, UK (Shakespeare's hometown). I'm working on some web businesses and using Ruby/Rails to build them.
• What is the Ruby scene like where you live?
London is the nearest scene. There isn't much here.
• What would you like to see on the RBP blog?
More of the same, mixed in with examples of code improvement. There has to be tons of regular design patterns in Rails apps (for example; I do appreciate this isn't just a Rails blog) which could be improved with some RBPs.
2 months ago
in Ruby Best Practices - The Universe between begin and end on Ruby Best Practices Blog
Not a problem, thanks for the feedback. I'll add a comment for the rescue. Someone on rails IRC pointed out that I could do without the 'self' where I'm referencing the instance of the Site class. I was already aware of this, but I must admit to liking how it reads with self.attribute.
I doubt the Ruby Best Practices guys will ever run out of topics, but if you're ever looking for something, I'd definitely read a series on improving other peoples code, i.e. taking user-submitted design patterns and sprucing them up with RBPs wisdom.
I doubt the Ruby Best Practices guys will ever run out of topics, but if you're ever looking for something, I'd definitely read a series on improving other peoples code, i.e. taking user-submitted design patterns and sprucing them up with RBPs wisdom.
2 months ago
in Ruby Best Practices - The Universe between begin and end on Ruby Best Practices Blog
Great post , Robert, it's the kind of topic that people coming to Rails as a first time developer (like me) struggle to grasp. Last night I was tackling a 'token verification' method, with which I use Hpricot to parse a site URL for a unique verification token, to prove ownership. Unscientifically, I managed to get a rescue working for an OpenURI 404 error when no URL exists, but I certainly don't fully understand why I'm doing the rescue (I'm reading through your post 3 or 4 more times today) - I just know that it stopped the method from breaking;
http://pastie.org/466530
What would you guys do differently? I'm coming to the conclusion that the rescue should be using another class for handling the error, perhaps along the lines of the rescue Exception => e, as detailed by Phil Hagelberg here http://technomancy.us/114 (p.s. I have read the above post, and the linked-to posts - but I only really learn new things if someone critiques something I've attempted on my own).
http://pastie.org/466530
What would you guys do differently? I'm coming to the conclusion that the rescue should be using another class for handling the error, perhaps along the lines of the rescue Exception => e, as detailed by Phil Hagelberg here http://technomancy.us/114 (p.s. I have read the above post, and the linked-to posts - but I only really learn new things if someone critiques something I've attempted on my own).
1 reply
7 months ago
in Ruby on Rails Hosting Round-up | Ruby Pond on ruby pond
I recently signed-up to Engine Yard for a single production slice (eek, where's staging?! I know, I know, but money is tight, and it's private beta testing, for now) to run http://SoIndustry.com. It's going ok, a few mix-ups in the beginning getting the deploy.rb working with all the dependencies and background processes, but EY IRC is very helpful and overall I've been pretty happy. I also think it's too expensive, though. The Sterling falling from $1.80 (when I signed-up) to $1.46 (as it is now) against the Dollar, doesn't help.
Everyone seems to rave about SliceHost. Brightbox are another one to consider, if you're in the UK.
Everyone seems to rave about SliceHost. Brightbox are another one to consider, if you're in the UK.
7 months ago
in Black Friday 2008 on I Bought a Mac
John, that doesn't sound like a bad choice to me; I do a lot of coding so I prefer to touch type and use the touch pad on my MBP whenever keys don't do the biz, subsequently avoiding the mouse. A Mighty Mouse would be fine but I've had the MX1000 since before I bought a Mac (I'm in the same position as you, can't justify the expense on a mouse at the moment), but I do like the zillion buttons on it (Expose, tab through apps, show desktop, Return, forward/back through browers, etc).
I'm just waiting for the Mac 'Airboard', a wireless keyboard with a touch pad built in (think MBP but without the screen).
I'm just waiting for the Mac 'Airboard', a wireless keyboard with a touch pad built in (think MBP but without the screen).
7 months ago
in Black Friday 2008 on I Bought a Mac
Ooh thanks for the MX Revoution tip-off; my 'MX1000' has been refusing to drag things (i.e. it seems the left mouse button can no longer sustain/hold clicks). I'm very nearly fed-up with accidental attempts at opening Fireworks PNGs in iCal...
John, what mouse do you use?
John, what mouse do you use?
7 months ago
in People, sites, and software I am thankful for this year - Locomotivation, the technology blog from Squeejee on Locomotivation
No probs (almost typed 'ho probs' and posted it, I shoulda kept it in, it's a great typo!).
Talking of Shoulda, I believe many Rails devs would add said testing framework to the list (haven't had a chance to use it myself, but at least one friend has dropped Rspec entirely).
And I forgot a couple...
People:
• Pat Allen
Software:
• Thinking Sphinx
(this list could end up being rather long; it turns out that Rails has had an infinite number of cool new people, sites, and software in 2008 alone)
Talking of Shoulda, I believe many Rails devs would add said testing framework to the list (haven't had a chance to use it myself, but at least one friend has dropped Rspec entirely).
And I forgot a couple...
People:
• Pat Allen
Software:
• Thinking Sphinx
(this list could end up being rather long; it turns out that Rails has had an infinite number of cool new people, sites, and software in 2008 alone)
7 months ago
in People, sites, and software I am thankful for this year - Locomotivation, the technology blog from Squeejee on Locomotivation
People:
• Rails IRC
• Rails Forum
• Ryan Bates
• Ryan Townsend ThinkRefresh.com
Sites:
• Github + 1
• Hoptoad
Software:
• Workling
• Paperclip
• Yahoo reset.css (a component of YUI)
• Rails IRC
• Rails Forum
• Ryan Bates
• Ryan Townsend ThinkRefresh.com
Sites:
• Github + 1
• Hoptoad
Software:
• Workling
• Paperclip
• Yahoo reset.css (a component of YUI)
1 reply
pengwynn
Great additions, Neil!
Ryan Bates +1
Hoptoad +1 (We love this tool for our apps)
Paperclip +1 Also from Thoughtbot, how did I leave them off my list this year?
Ryan Bates +1
Hoptoad +1 (We love this tool for our apps)
Paperclip +1 Also from Thoughtbot, how did I leave them off my list this year?
7 months ago
in Online Storage Royal Rumble (sort of) on I Bought a Mac
Before I made the move to Mac I used to use Carbonite (it was ugly and Windows only, so it didn't make the jump). Loads of people seem to praise Mozy though, so it would be my first choice if I felt the need to buy in to cloud-based-backup again.
7 months ago
in Buddy Press Turns Wordpress Into Social Network on Social Times
Nick, unless I'm misunderstanding BuddyPress (each BuddyPress/WordPress MU community is isolated and requires a new user profile, correct?) I imagine you're betting on something like BackType (or the handful of other apps which handle decentralized commenting) over BuddyPress. Or perhaps one of the comment infrastructure plugins, or even FB Connect(?). Afterall, this really is just about aggregating comments, rather than a must-have new profile; I think most blog commentators would be happier linking straight to their own site than a BuddyPress profile which only then leads on to their site.
7 months ago
in My Techmeme Obsession on A VC
Doesn't Hacker News have a points system (karma, IIRC)? I seem to remember a guy called NickB being the first to reach a certain amount of karma points (and receiving a trophy-tastic, color:red; username to help him stand out from the crowd).
Yes, Twitter does work well for sourcing information that's relevant to you and your profession, but it doesn't appear to be packaged or promoted in that way. Are there third party tools to aid in sharing URLs on Twitter? I'm always on tinyURL.
Yes, Twitter does work well for sourcing information that's relevant to you and your profession, but it doesn't appear to be packaged or promoted in that way. Are there third party tools to aid in sharing URLs on Twitter? I'm always on tinyURL.
10 months ago
in MaxLength on a Textarea on Offbeatmammal
Thanks, offbeatmammal. I actually ended up not cutting off the input length. Instead, I'm going with a minus counter in combination with a submit.disable="disabled" attribute + class="disabled", so that the button is disabled & greyed out by CSS when the typist takes it past the pepsi max.
1 reply
Offbeatmammal
Nice solution - and makes the condition very clear to the user (and lets them edit with more flexibility). Wish I'd thought of it ;)
10 months ago
in MaxLength on a Textarea on Offbeatmammal
Sorry, I'm probably two years late to ask this; do you have a copy of Bens script? I just get a 404 when I click the link.
1 reply
Offbeatmammal
luckily enough I have a copy lurking here [http://blog.offbeatmammal.com/scripts/behaviour.js] that I used in my sample...
Ben might have a newer/better version - drop him a comment via his blog
Ben might have a newer/better version - drop him a comment via his blog
1 year ago
in Facebook Announces Profile Redesign Integration on AllFacebook
Supporting a developer platform really does slow down the internal development on your app, doesn't it?
To me at least, these changes indicate just how Facebook feel about apps; they provide little value. The boxes tab is going to see absolutely no traffic, and I see it following the Network link within 3 - 4 months of the re-design.
Nick, do you have any info on the average length of a Wall Post and Status Update? Character length, word count, no. of paragraphs, etc? I'd love to know where they sit in relation to Twitter's 140 character limit...
To me at least, these changes indicate just how Facebook feel about apps; they provide little value. The boxes tab is going to see absolutely no traffic, and I see it following the Network link within 3 - 4 months of the re-design.
Nick, do you have any info on the average length of a Wall Post and Status Update? Character length, word count, no. of paragraphs, etc? I'd love to know where they sit in relation to Twitter's 140 character limit...
1 year ago
in Web 3.0 Means Pay for Service on Social Times
I'm all for subscription-based premium services. Everyone's filling the Web with information, so someone needs to cut through the noise, find the best information, present it better than everyone else, and offer potential customers a fair price for the (Google Adsense-less, pun intended) privilege.
1 year ago
in Get a Sneak Peak of Your Facebook Chat on AllFacebook
Now that is a nice hack! And I never thought I'd find Facebook managing feature roll-out by simply hiding html elements...
1 year ago
in Why Not Make OpenID the Law? on Social Times
Very topical, Nick. Government control of OpenID has crossed my mind serveral times, but being a British citizen I tend to shiver every time it does.
You may have heard about a UK government employee attempting to post a CD with the personal identities of 25 million people, and the postal service subsequently losing the CD. If the government is allowing incidents like that to happen, I'd hate for them to have control over something that the experts are already handling, i.e. Mark Zuckerberg, Simon Willison, Data Portability etc.
What would a government really add to the equation? More paperwork and bureaucracy?
You may have heard about a UK government employee attempting to post a CD with the personal identities of 25 million people, and the postal service subsequently losing the CD. If the government is allowing incidents like that to happen, I'd hate for them to have control over something that the experts are already handling, i.e. Mark Zuckerberg, Simon Willison, Data Portability etc.
What would a government really add to the equation? More paperwork and bureaucracy?
1 year ago
in How to Organize Your Inbox on Fred BrunelThe recommendation for a single Archive folder is a good one.
I did an internship where I tried organising my inbox (Outlook) in to folders on a per-client basis. It just became too complicated.
I now prefer to treat my inbox as though it's the open web, and I use the Thunderbird search box just as I would Google. But it helps that I only report to myself at the moment!
1 year ago
in Facebook is on the Cusp of a Messaging Revolution on AllFacebook
That system only ranks communication by people, not by what those people have to say to you. So, you'll effectively be presuming that a person will only ever say something of a certain level of importance to you. That just wouldn't work for me, because I never know what people are going to say to me next.
I doubt I'll ever get in to GTD stuff, and I've tried once already. It turns into a hobby, and that's time you could be spending on actually doing stuff. I'd rather scramble through with a freestyle system, and only do what is most important to me right there and then. That's what you'll ultimately do anyway.
I doubt I'll ever get in to GTD stuff, and I've tried once already. It turns into a hobby, and that's time you could be spending on actually doing stuff. I'd rather scramble through with a freestyle system, and only do what is most important to me right there and then. That's what you'll ultimately do anyway.
1 year ago
in Beat Me Sideways With A Sandal on Matt's Journal
Join the club! I haven't been ill in years (touch wood), but I got the sniffles the other day, and although it didn't slow me down, it still annoyed me. I thought I had some kinda of mega-immune system. That, or I've spent so much time at my desk that I haven't been exposed to the common illnesses!
1 year ago
in Stumbleupon: The Richest Source Of Traffic? on Matt's Journal
Great - I might try submitting something to SU as an experiment. As a company, it's a huge success story, so it would be good to understand the user experience anyway!
1 year ago
in A Photographic Journey to Yahoo! HQ on theory.isthereason
Great snaps, have you shared them with the guy running OfficeSnapshots.com? I bet he'd love to post these.
Grilled chicken pasta sounds good to me. And free coffee would just send me off-the-rails!
Grilled chicken pasta sounds good to me. And free coffee would just send me off-the-rails!
1 year ago
in Tweet on Knuckle Sandwich
I was the same; I didn't want to become some kind of compulsive thought sharing freak, but Twitter is great! It's obvious that the head honchos at Facebook want a slice of the action, too. Slowly but surely, they're taking 'Status Updates' closer to the way Twitter works. 'What are you doing right now?'...
1 year ago
in Stumbleupon: The Richest Source Of Traffic? on Matt's Journal
I used StumbleUpon absolutely ages ago, but it never made it's way in to my fav apps collection. Since then, I've made a move to Mac, so I'll see if it works on Firefox on OS X and give it another punt. I'm having crazy ideas about setting aside 10 minutes each day just to check out something random from across the Web.
Just out of interest, how did the community at SU handle your submissions? I know the people over at Digg can be a bit negative about self-submissions. Would be interesting to know how the other voting sites feel about it.
Just out of interest, how did the community at SU handle your submissions? I know the people over at Digg can be a bit negative about self-submissions. Would be interesting to know how the other voting sites feel about it.
1 year ago
in Facebook Launches Extended Profile on AllFacebook
Doesn't look like they've shipped it to the UK just yet...

The only thing that stands out is that your rescue clause is empty. I would probably at least place a comment there which indicates why you do not do any specific handling of the exception.
Other than that the exception is likely caused by the page not being there or a network connection issue. The question is, whether you actually should rescue the exception here or whether surrounding code needs that information.
Btw, I just notice another thing: you do not close the file handle properly, because you do
doc = Hpricot(open("http://#{self.url}/#{page}"))