I am a newbie to the Ruby and the Ruby on Rails world and recently started working on my first Ruby on Rails project. This project was started by my manager and a couple co-workers a couple months ago and now I have got an opportunity to learn RoR while contributing to this project.
The first step: Setting up my Ubuntu box with all the required software, and gems, and what not…
Well we installed all the necessary items (Ruby 1.8.6, Rails 2.0.2 etc) on my box and started the backgroundrb, got a few errors, read a few blogs, corrected those errors and this cycle continued for about two days. Finally when everything seemed ok, as suspected, got another error, the error text as follows:
/usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require': no such file to load -- log_worker (LoadError) from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:27:in `require' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:35:in `load_worker' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:26:in `initialize' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:47:in `new' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:47 from /usr/bin/packet_worker_runner:19:in `load' from /usr/bin/packet_worker_runner:19 /home/mjain/work/code/leadserver/trunk/nqc-engine/lib/workers/cache_refresh_worker.rb:9: uninitialized constant BackgrounDRb (NameError) from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:27:in `require' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:31:in `load_worker' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:26:in `initialize' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:47:in `new' from /usr/lib/ruby/gems/1.8/gems/packet-0.1.10/bin/packet_worker_runner:47 from /usr/bin/packet_worker_runner:19:in `load' from /usr/bin/packet_worker_runner:19
What the what?? everything works perfectly fine on others’ machines why it wont work on mine???
so I googled it and sure enough not enough info about what this error meant and how to correct it. Late on the second day my seniors and I tried everything (almost) possible to try to get rid of this error. Nothing seemed to work and we finally went home…Next day I found a note on my desk:
uninstall Packet 0.1.10 and install Packet 0.1.5
and it worked…thanks to Aaron Hawkins who compared his gem versions with mine and figured it out.