Jabberwocky

This site is work in progress ...

Rails Bugmash

August 7th 2009

This weekend, we have an unique opportunity to get involved (or attempt to) in the Rails core development: the Rails Bugmash, organized by RailsBridge. The idea is to resolve as many bugs as possible on the stable version of Rails (2.3.x) - with some assistance of established Rails core members (through IRC on Freenode #railsbridge). A level of playfulness, or competition, is added by the fact that you get awarded points for bug reduction, and there's a few small prizes. The main prize, in my opinion, is the opportunity to participate to a well-managed open source project like Rails.

You'll find relevant information here. And what to do to have your environment ready: here. The railscast is also a good intro.

A few notes that might be useful:

  • Update: Install rvm of course !! I installed a variant of Relevance's ruby switcher. I'm using zsh myself, not bash: if this is your case, you'll find the relevant dotfiles in the spicy-code's repository. Good source of inspiration, but since I'm fairly happy with my configs, I just took over ruby_switcher.rb and ruby_installer.rb. Since I didn't want to reinstall versions i already had on my machine, I changed ruby_switcher.rb to use the paths of existing installations (look at the update_path function to see what to use) and then i added the following line to my .zshrc . source /.zsh/ruby_switcher.zsh

  • To run the activerecord test set, you need a few databases, and a user 'rails'.

      create user rails;
      create database activerecord_unittest;
      create database activerecord_unittest2;
      grant all on activerecord_unittest.* to rails@localhost;
      grant all on activerecord_unittest2.* to rails@localhost;
      

on postgres the grants of course are

      create user rails password 'password';
      grant all on database activerecord_unittest to rails;
      grant all on database activerecord_unittest2 to rails;
      

Strictly speaking, you need to test on as many dbs at possible - i've got mysql, posgres and (duh) sqlite3 - might add the jdbc's to that list.
You can change configs in activerecord/test/connections/native_/connection.rb . For mysql, I had to add my :socket in there, which defaulted to something strange. For postgres, i had to add user and password (though i suppose you could grant to PUBLIC). If you want to just test activerecord for one type of database, you go into the activerecord directory, and do

      rake test_mysql
      rake test_postgresql
      

and similar. In fact, it's adviseable to run ONLY the tests you need at first, because the test set is obviously sizeable, and takes a wee while to run (using env variable TEST=). Note: I must be missing a grant for postgresql, because i get a load of errors - I'll update if i fix this Update: i ended up using the superuser.

  • You also need to start memcached. 11211 is the default port.
      memcached -p 11211 -d
      
  • especially this week-end, i'd do git pull regularly, to avoid surprises.

Interesting, anyway.

blog comments powered by Disqus