gem and/or Ruby on Rails broke all of a sudden, anyone know what happened?
I'd try cleaning out all your installed gems by running
rm -rf ~/.gems
sudo rm -rf /Library/Ruby/Gems/*
After this gem list
should list no gems. Then run
sudo gem update --system
to ensure Ruby Gems is at the latest version. You'll then have to reinstall all your gems. (Probably gem install bundler
followed by bundle install
).
By the way, you should check out rbenv or rvm for managing Ruby versions and keeping all your development gems separate from the system Ruby.
Rails / Gem command suddenly throwing errors
My hunch was correct - RubyMine was to blame... and the user too, of course !
Far too used to using refactoring tools in Intellij for Java, I refactored some fairly common methods names in my controllers (such as changing "show" to "index") and ended up refactoring into the Ruby 1.8 standard library files too !
Need to double-check what refactoring is doing, going forward, and try to limit it just to my project and not the whole SDK :)
Gem not working after update to OS X 10.10 Yosemite Beta
I had the same issue, and solved it by deleting my Gems, and reinstalling:
sudo rm -rf /Library/Ruby/Gems/*;
sudo gem update --system
(as described
here)
twitter bootstrap drop down suddenly not working
had to move
//= require jquery
below
//= require bootstrap
within
application.js
When installing Hobo it installed a previous version of rails in my system, is it going to mess up things?
As ruralocity indicated, it's your gemfile and gemfile.lock that indicate what gems are loaded. Rvm gemsets were a godsend with rails 2, but they are not worth the hassle for rails 3.
You will have to downgrade your app to rails 3.0 if you ant to use hobo 1.3. Alternatively you can use the version of hobo from github, which works with rails 3.2. I recommend the latter. Hobo 1.4 is very stable and very close to release.
The other caveat is that while rails automatically uses gemfile.lock, other command line apps may not. Get into the habit of typing ‛bundle exec rake‛ instead of just rake.
Rails link_to syntax error: unexpected ',', expecting ')'
There is an extra-space after image_tag.
image_tag ("right_arrow.png", :size => '20x20')
It should be
image_tag("right_arrow.png", :size => '20x20')
Rails app throwing error after migrations that should not affect it
I'm a coworker of Jon's, going to answer this for posterity.
The problem was a consequence of the caching in https://github.com/rails/rails/blob/v3.0.9/activerecord/lib/active_record/base.rb; essentially @columns and @arel_table for certain model classes were out of sync because the latter was cached during app initialization and thus inherited from the master Unicorn by any new worker.
We fixed it by preventing calls to any model's ::scoped or ::unscoped during initialization where we could, and calling ::reset_column_information afterwards where we couldn't.
Related Topics
After Ruby 2.4 Upgrade - Error While Trying to Load The Gem 'Uglifier' (Bundler::Gemrequireerror)
What's The Impact of Eager_Load=True
More Efficient Ruby Way to Map Attribute in Array of Objects to Another Array
Ruby Group Hashes by Value of Key
Factory_Girl + Rspec Doesn't Seem to Roll Back Changes After Each Example
Stub Method Only on The First Call with Rspec
Package Configuration for Libffi Is Not Found in MACos While Installing Travis-Cli
What's The Most Efficient Way Get The First Day of The Current Month
Nokogiri Recursively Get All Children
Ruby Inserting Key, Value Elements in Hash
How to Add Attribute to Nokogiri Node
Can't Install Therubyracer in Jruby
Rspec Load Time Incredible Long on Os X
Failing to Bundle Install Tiny_Tds on MAC Os X 10.8 with Homebrew Freetds
How Can a Nested Class Access a Method in The Outer Class in Ruby