Getting a RubyGem version error: haml(2.3.0 not ~> 2.0.4) #7

omarvelous opened this Issue Sep 21, 2009 · 7 comments


None yet

2 participants


Was updating my version of Compass to the latest, which also uses Haml 2.2.0+. Long story short, I've uninstalled HAML 2.0.9, which Hanna seemed to have liked, and now all my gems seem to have broke. I get the following errors in whatever I run:

rails -v
/Library/Ruby/Site/1.8/rubygems.rb:827:in report_activate_error': RubyGem version error: haml(2.3.0 not ~> 2.0.4) (Gem::LoadError)
from /Library/Ruby/Site/1.8/rubygems.rb:261:in
from /Library/Ruby/Site/1.8/rubygems.rb:296:in activate'
from /Library/Ruby/Site/1.8/rubygems.rb:295:in
from /Library/Ruby/Site/1.8/rubygems.rb:295:in activate'
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:35:in
from /Library/Ruby/Gems/1.8/gems/mislav-hanna-0.1.10/lib/rubygems_plugin.rb:4
from /Library/Ruby/Site/1.8/rubygems.rb:1136:in load'
from /Library/Ruby/Site/1.8/rubygems.rb:1136
from /Library/Ruby/Site/1.8/rubygems.rb:1134:in
from /Library/Ruby/Site/1.8/rubygems.rb:1134
from /usr/bin/rails:9:in `require'
from /usr/bin/rails:9

This is with Rails, Hanna, Compass, Gem, and etc... Any help?


You broke gem dependencies and now Hanna can never be activated. Because Hanna also has a rubygems plugin in it, this means you'll always be getting these errors whenever you try to use rubygems.

Solution? Don't break dependencies. You shouldn't have uninstalled old Haml.

gem install haml -v'~> 2.0.4'

You'll still have Haml 2.2.0+, which libraries like Compass will use.


Thanks for the fast response. I wish it was that easy. I can not run any gem commands, even to install haml 2.0.4... I just thought of something, I'll dl 2.0.4 and install manually.


Wow, that really sucks. Easier solution would be to go where Hanna 0.1.10 is installed and comment out stuff in its "lib/rubygems_plugin.rb".


Ok, rake doesn't even work for me to rake install Haml. The problem is, before I uninstalled Haml 2.0.9 actually (never had 2.0.4 nor did I have mislav-hanna according to my gem list --local), I was getting complaints about mislav-hanna already activating Haml 2.0.9, which wouldn't allow my newly updated compass (0.8.13) to utilize the newly updated Haml (2.2.0+)...

Not sure where the issue really is... Im assuming I'll have to blow away all my gems and re-install? Have no problem doing that, just would like to make sure that is the case? And would it be as easy as "deleting" the folders... I'm on a Mac btw.


Oh wow.

Don't blow away your gems. Do what I suggested: edit or trash the "lib/rubygems_plugin.rb" where Hanna gem is installed (could be "/Library/Ruby/Gems/1.8" for you). Stuff will work after that.


Thanks for reporting this. I made necessary changes to v0.1.11 to avoid activating the Hanna gem and that should end your troubles with Haml versions.


That seems to have done the trick... moved the rubygems_plugin.rb and I've regained controll! Thanks for you help! WillPaginate is the greatest btw...

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment