Since February, I’ve been working on a pro bono project that launched last week. What’s in it for them is they got a brand new application that replaces an unwieldy bunch of paper and email-based processes. Before, they had a Web page that was protected by basic authentication and led to a set of form-to-mail scripts and downloadable Word documents. Now they have an application with real user accounts that can be carried over from year to year. There’s still a lot of work to do on the administrative side of the application, but I’m quite proud of the results so far.
What’s in it for me is I got to revisit Ruby on Rails after a couple of years away working primarily with Java and PHP. I also used Git, GitHub, Pivotal Tracker, and switched from TextMate to Vim for this project. The project has been very entertaining for me, aside from some stress as the release date moved closer to the early bird deadlines on some of the forms we were replacing.
I found it really easy to jump back into Rails, despite the fact that a lot of things have changed since the last time I used it. Most of the utility scripts that used to be run individually are now bundled under a single rails
script, and Rails is geared much more strongly toward using resource-oriented controllers rather than developers structuring controllers in their own way, but beyond that, things are basically the same. I also found that most of the things that are different are, in fact, improved. Rails 3 handles dependencies far, far more elegantly than its predecessors did, which makes deployment much better. It’s easier than it has ever been to set up deployment using Capistrano. The testing framework is more flexible and powerful.
For some time I wondered whether Rails was going to be an evolutionary dead end in terms of Web applications platforms, but I’m very impressed at where it is as a platform right now.
I used two plugins that were a huge help in terms of getting the application built. The first is the Devise plugin, which provides user registration and authentication functionality. I’ve been very impressed with its capabilities and ease of use. The second is CanCan, which provides a role-based authorization system that integrates nicely with Devise. The two of them saved me weeks of work.
The one big mistake I made was not taking a test-first approach to development. I had intended to, but I was in a rush and I ran into an inflector bug that caused me some grief. That bug prevented my tests from working properly, and rather than tracking down the issue, I did a bunch of development without writing accompanying tests. Now I’m backfilling the tests, which is never fun.
The organization I’m building this application for uses DreamHost for hosting, and I assumed I’d be able to use their existing hosting account to deploy this application. Unfortunately, while DreamHost does support Rails, they do not yet support Rails 3. I wound up having to deploy the application on my own slice running at Linode. I considered sites like Heroku, but they were just too expensive. I had thought we’d be closer to turnkey hosting for Rails by now, but that still appears not to be the case. On the other hand, getting the Rails application up and running from scratch on my own Linux server was simpler than it has ever been.
Rails is no longer the hot young thing that all of the developers are swooning over, but I’m finding it to be more excellent than ever. I still can’t imagine building an application in PHP if Ruby on Rails is also an option. The other takeaway is that developers need to be on GitHub, period. I’m using a private repository to host this project and it’s working beautifully.
Are movie theaters misdiagnosing their problems?
Last week, Roger Ebert wrote a piece about the effect improperly operated projectors have on the movie viewing experience. Most of the time, when you go to the movies, the bulb in the projector is insufficiently bright, usually because movie theaters are too lazy or incompetent to configure their digital 3D projectors to project 2D movies properly. (3D movies are inherently less bright than 2D movies, it’s a drawback.) He also points out that improper projection goes back before digital movies, it’s a long term problem in the movie industry.
The decline of movie theaters is blamed on many things, usually the rise of home entertainment. It’s funny, though, this is an area where the market has a perverse effect. Movie theaters compete on the comfort of the seating, but not on the quality of projection. You never see an ad that says, “Brightest projector bulb in the city.” So people go to the movies and have a subpar experience because the picture is difficult to see and then choose to watch something on Netflix Instant or get a DVD from Red Box. Movie theaters don’t have a feedback loop to tell them that the real problem might be the bad job they’re doing operating the projectors.
His piece reminded me of an essay from Slate last year, on the vanishing of professional projectionists. As is often the case, removing skilled professionals from the equation seems economical, but there are also costs, and those costs are probably being lost in the noise.