I've tried to implode the rvm and install everything from scratch, strangely it worked until I restarted my shell (I use zsh, but the same happens on bash).
The console output:
➜ ~backend_folder git:(master) ✗ which rails
/Users/shaioz/.rvm/gems/ruby-1.9.3-p429/bin/rails
➜ ~backend_folder git:(master) ✗ rails server
ruby(10188,0x7fff7176c180) malloc: *** mmap(size=1125878379425792) failed (error code=12)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug
ruby(10188,0x7fff7176c180) malloc: *** mmap(size=1125878379425792) failed (error code=12)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug
/Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `require': failed to allocate memory (NoMemoryError)
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `block in require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:223:in `block in load_dependency'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:640:in `new_constants_in'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:223:in `load_dependency'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/debugger-1.6.0/lib/ruby-debug-base.rb:1:in `<top (required)>'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `block in require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:223:in `block in load_dependency'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:640:in `new_constants_in'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:223:in `load_dependency'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/debugger-1.6.0/lib/ruby-debug.rb:5:in `<top (required)>'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `block in require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:223:in `block in load_dependency'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:640:in `new_constants_in'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:223:in `load_dependency'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/activesupport-3.1.1/lib/active_support/dependencies.rb:240:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/debugger-1.6.0/lib/debugger.rb:4:in `<top (required)>'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `block (2 levels) in require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `each'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `block in require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `each'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429#global/gems/bundler-1.3.5/lib/bundler.rb:132:in `require'
from /Users/shaioz/projects/flayvr-backend/config/application.rb:7:in `<top (required)>'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/railties-3.1.1/lib/rails/commands.rb:52:in `require'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/railties-3.1.1/lib/rails/commands.rb:52:in `block in <top (required)>'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/railties-3.1.1/lib/rails/commands.rb:49:in `tap'
from /Users/shaioz/.rvm/gems/ruby-1.9.3-p429/gems/railties-3.1.1/lib/rails/commands.rb:49:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
(This also happens when I use irb, I have at least 2 GB of RAM available)
When I try to 'rvm get', I get this:
cat: /Users/shaioz/.rvm/help/get: No such file or directory
Could not update RVM, get some help at #rvm IRC channel at freenode servers.
But strangely the rvm wasn't installed on sudo user, and .rvm sits on my user's homedir.
I'm running on OSX 10.8.3
I figured it out.
In $PATH, I had the local ruby take precedent over the ruby installed by rvm, but the rails was the one installed by rvm to match the ruby version.
(the incorrect $PATH was due to an unneeded entry in my zshrc)
in short, if you're having a similar problem try to
$ which ruby; which rails
and see if they are the correct versions.
Related
when i tried to start my rails server i got an error related to mecab
So i followed below given instruction to install mecab and it was installed successfully
i checked the version of mecab
while installing mecab followed steps are
1. gem install natto
2. sudo apt-get install mecab libmecab-dev
3. sudo apt-get install mecab-ipadic-utf8
4. mecab --version
5. sudo find / -name libmecab.so*
this gives an error of permission denied
6. echo 'export MECAB_PATH=/usr/lib/libmecab.so.2' >> ~/.bash_profile
7. source ~/.bash_profile
After all, this when I tried to start rails server I got below given error
/home/admin123/.rvm/gems/ruby-2.3.1/gems/ffi-1.9.14/lib/ffi/library.rb:147:in `block in ffi_lib': Could not open library '/usr/lib/libmecab.so.2': /usr/lib/libmecab.so.2: cannot open shared object file: No such file or directory (LoadError)
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/ffi-1.9.14/lib/ffi/library.rb:100:in `map'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/ffi-1.9.14/lib/ffi/library.rb:100:in `ffi_lib'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/natto-1.1.1/lib/natto/binding.rb:64:in `<module:Binding>'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/natto-1.1.1/lib/natto/binding.rb:6:in `<module:Natto>'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/natto-1.1.1/lib/natto/binding.rb:2:in `<top (required)>'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `block in require'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:240:in `load_dependency'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/natto-1.1.1/lib/natto/natto.rb:2:in `<top (required)>'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `block in require'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:240:in `load_dependency'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/natto-1.1.1/lib/natto.rb:2:in `<top (required)>'
from /usr/share/rvm/rubies/ruby-2.3.1/lib/ruby/site_ruby/2.3.0/bundler/runtime.rb:81:in `require'
from /usr/share/rvm/rubies/ruby-2.3.1/lib/ruby/site_ruby/2.3.0/bundler/runtime.rb:81:in `block (2 levels) in require'
from /usr/share/rvm/rubies/ruby-2.3.1/lib/ruby/site_ruby/2.3.0/bundler/runtime.rb:76:in `each'
from /usr/share/rvm/rubies/ruby-2.3.1/lib/ruby/site_ruby/2.3.0/bundler/runtime.rb:76:in `block in require'
from /usr/share/rvm/rubies/ruby-2.3.1/lib/ruby/site_ruby/2.3.0/bundler/runtime.rb:65:in `each'
from /usr/share/rvm/rubies/ruby-2.3.1/lib/ruby/site_ruby/2.3.0/bundler/runtime.rb:65:in `require'
from /usr/share/rvm/rubies/ruby-2.3.1/lib/ruby/site_ruby/2.3.0/bundler.rb:114:in `require'
from /home/admin123/WFSGo/myproject/config/application.rb:16:in `<top (required)>'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:78:in `require'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:78:in `block in server'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:75:in `tap'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:75:in `server'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/railties-4.2.4/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
from /home/admin123/.rvm/gems/ruby-2.3.1/gems/railties-4.2.4/lib/rails/commands.rb:17:in `<top (required)>'
from bin/rails:4:in `require'
from bin/rails:4:in `<main>'
On Ununtu the mecab lib is in /usr/lib/x86_64-linux-gnu/libmecab.so. So this should work:
export MECAB_PATH=/usr/lib/x86_64-linux-gnu/libmecab.so
rails server
while generating controllers, I am getting this error message:
Leticias-MacBook-Pro:portfolio Tish$ rails g controller welcome index about music loops projects
/Users/Tish/.rvm/gems/ruby-2.3.1/gems/sqlite3-1.3.12/lib/sqlite3.rb:6:in `require': incompatible library version - /Users/Tish/.rvm/gems/ruby-2.3.1/gems/sqlite3-1.3.12/lib/sqlite3/sqlite3_native.bundle (fatal)
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/sqlite3-1.3.12/lib/sqlite3.rb:6:in `rescue in <top (required)>'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/sqlite3-1.3.12/lib/sqlite3.rb:2:in `<top (required)>'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/bundler-1.13.6/lib/bundler/runtime.rb:91:in `require'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/bundler-1.13.6/lib/bundler/runtime.rb:91:in `block (2 levels) in require'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in `each'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in `block in require'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:in `each'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:in `require'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/bundler-1.13.6/lib/bundler.rb:106:in `require'
from /Users/Tish/Projects/portfolio/config/application.rb:7:in `<top (required)>'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/spring-2.0.0/lib/spring/application.rb:82:in `require'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/spring-2.0.0/lib/spring/application.rb:82:in `preload'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/spring-2.0.0/lib/spring/application.rb:143:in `serve'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/spring-2.0.0/lib/spring/application.rb:131:in `block in run'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/spring-2.0.0/lib/spring/application.rb:125:in `loop'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/spring-2.0.0/lib/spring/application.rb:125:in `run'
from /Users/Tish/.rvm/gems/ruby-2.3.1/gems/spring-2.0.0/lib/spring/application/boot.rb:19:in `<top (required)>'
from /usr/local/lib/ruby/site_ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /usr/local/lib/ruby/site_ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from -e:1:in `<main>'
Nothing I have tried makes it stop. I have reinstalled every gem it complains about, but the changes do not persist. I've followed every fix I can find/understand but I am chasing my tail on this one.
Working on OSX...
Your rails is not linked with the right ruby version. Use the following code:
rvm use ruby-<version number> like: (rvm use ruby-2.1.4)
then reinstall the bundler:
gem uninstall bundler
gem install bundler
bundle install once again with the new version.
bundle install
Then proceed with your rails g command.
I'm learning Ruby from Michael Hartl's tutorial. I'm following the steps one by one, but I can't get passed this one. When I input "bundle exec rspec spec/requests/static_pages_spec.rb" I get a very long error response as opposed to a simple "1 example, 0 failures". I changed the necessary code in the static pages directories and I'm fairly confident the code is correct as I simply copied and pasted. The error message is this:
/Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/nokogiri-1.6.0/lib/nokogiri.rb:28:in `require': dlopen(/Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/nokogiri-1.6.0/lib/nokogiri/nokogiri.bundle, 9): Library not loaded: /Users/marlon/.bundler/tmp/1219/gems/nokogiri-1.6.0/ports/i686-apple-darwin11/libxml2/2.8.0/lib/libxml2.2.dylib (LoadError)
Referenced from: /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/nokogiri-1.6.0/lib/nokogiri/nokogiri.bundle
Reason: Incompatible library version: nokogiri.bundle requires version 11.0.0 or later, but libxml2.2.dylib provides version 10.0.0 - /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/nokogiri-1.6.0/lib/nokogiri/nokogiri.bundle
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/nokogiri-1.6.0/lib/nokogiri.rb:28:in `<top (required)>'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/capybara-1.1.2/lib/capybara.rb:2:in `require'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/capybara-1.1.2/lib/capybara.rb:2:in `<top (required)>'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `require'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `block (2 levels) in require'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `each'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `block in require'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `each'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `require'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320#global/gems/bundler-1.3.5/lib/bundler.rb:132:in `require'
from /Users/marlon/rails_projects/sample_app/config/application.rb:7:in `<top (required)>'
from /Users/marlon/rails_projects/sample_app/config/environment.rb:2:in `require'
from /Users/marlon/rails_projects/sample_app/config/environment.rb:2:in `<top (required)>'
from /Users/marlon/rails_projects/sample_app/spec/spec_helper.rb:3:in `require'
from /Users/marlon/rails_projects/sample_app/spec/spec_helper.rb:3:in `<top (required)>'
from /Users/marlon/rails_projects/sample_app/spec/requests/static_pages_spec.rb:1:in `require'
from /Users/marlon/rails_projects/sample_app/spec/requests/static_pages_spec.rb:1:in `<top (required)>'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/rspec-core-2.11.1/lib/rspec/core/configuration.rb:780:in `load'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/rspec-core-2.11.1/lib/rspec/core/configuration.rb:780:in `block in load_spec_files'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/rspec-core-2.11.1/lib/rspec/core/configuration.rb:780:in `map'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/rspec-core-2.11.1/lib/rspec/core/configuration.rb:780:in `load_spec_files'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/rspec-core-2.11.1/lib/rspec/core/command_line.rb:22:in `run'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/rspec-core-2.11.1/lib/rspec/core/runner.rb:69:in `run'
from /Users/marlon/.rvm/gems/ruby-1.9.2-p320/gems/rspec-core-2.11.1/lib/rspec/core/runner.rb:8:in `block in autorun'
dyn172-30-28-254:sample_app marlon$
Please let me know what I can do to fix this. I appreciate all the help, thanks in advance!
You should install nokogiri dependencies:
brew install libxml2 --with-xml2-config
brew install libxslt
Basically, When I try to generate a scaffold I am getting this error
no such file to load -- openssl (LoadError) .
The error is coming from
.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `block in require'
Not sure why this is happening. Here is the full error:
/home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/rack-1.3.4/lib/rack/backports/uri/common_192.rb:53: warning: already initialized constant WFKV_
/home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require': no such file to load -- openssl (LoadError)
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `block in require'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:223:in `block in load_dependency'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:640:in `new_constants_in'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:223:in `load_dependency'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/rack-1.3.4/lib/rack/session/cookie.rb:1:in `<top (required)>'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `block in require'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:223:in `block in load_dependency'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:640:in `new_constants_in'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:223:in `load_dependency'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/actionpack-3.1.0/lib/action_dispatch/middleware/session/cookie_store.rb:4:in `<top (required)>'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application/configuration.rb:125:in `const_get'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application/configuration.rb:125:in `session_store'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application.rb:168:in `block in default_middleware_stack'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application.rb:142:in `tap'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application.rb:142:in `default_middleware_stack'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/engine.rb:445:in `app'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application/finisher.rb:37:in `block in <module:Finisher>'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/initializable.rb:25:in `instance_exec'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/initializable.rb:25:in `run'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/initializable.rb:50:in `block in run_initializers'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/initializable.rb:49:in `each'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/initializable.rb:49:in `run_initializers'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application.rb:92:in `initialize!'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/railtie/configurable.rb:30:in `method_missing'
from /home/spencer/Desktop/blog/config/environment.rb:5:in `<top (required)>'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application.rb:78:in `require'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/application.rb:78:in `require_environment!'
from /home/spencer/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/commands.rb:22:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
OK so what I ended up doing is this.
uninstalled all version of ruby from rvm
deleted all of the gemsets from rvm
$ rvm pkg install openssl
$ rvm pkg install zlib
$ rvm install 1.9.2 --with-openssl-dir=$HOME/.rvm/usr --with-zlib-dir=$rvm_path/usr
reinstalled rails in a gemset
Everything works fine after that.
You should be able to do something like this: (forgive the fact that there may be errors in my paths and I'm not on my linux box)
cd to ~.rvm/src/ruby-1.9.2-p290/ext/openssl
ruby extconf.rb
make
make install
Basically, just cd to the gem's source directory for your particular ruby version and rebuild/install this.
You will not need to rebuild ruby, this has been a common problem.
If your in linux you could try these
apt-get install openssl
apt-get install libopenssl-ruby
Cucumber is somehow not working on my machine. Now on running
bundle show cucumber
I am getting
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6
but when I now try to run the features on my application I am getting the following error
bundle exec cucumber features
Using the default profile...
no such file to load -- crack/core_extensions (LoadError)
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:225:in `load_dependency'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:596:in `new_constants_in'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:225:in `load_dependency'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require'
/opt/local/lib/ruby/gems/1.8/gems/pusher-0.6.0/lib/pusher/channel.rb:1
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:225:in `load_dependency'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:596:in `new_constants_in'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:225:in `load_dependency'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require'
/opt/local/lib/ruby/gems/1.8/gems/pusher-0.6.0/lib/pusher.rb:67
/opt/local/lib/ruby/gems/1.8/gems/bundler-1.0.15/lib/bundler/runtime.rb:68:in `require'
/opt/local/lib/ruby/gems/1.8/gems/bundler-1.0.15/lib/bundler/runtime.rb:68:in `require'
/opt/local/lib/ruby/gems/1.8/gems/bundler-1.0.15/lib/bundler/runtime.rb:66:in `each'
/opt/local/lib/ruby/gems/1.8/gems/bundler-1.0.15/lib/bundler/runtime.rb:66:in `require'
/opt/local/lib/ruby/gems/1.8/gems/bundler-1.0.15/lib/bundler/runtime.rb:55:in `each'
/opt/local/lib/ruby/gems/1.8/gems/bundler-1.0.15/lib/bundler/runtime.rb:55:in `require'
/opt/local/lib/ruby/gems/1.8/gems/bundler-1.0.15/lib/bundler.rb:120:in `require'
/Users/gauravsingharoy/work/tiatros/config/application.rb:7
/Users/gauravsingharoy/work/tiatros/config/environment.rb:2:in `require'
/Users/gauravsingharoy/work/tiatros/config/environment.rb:2
/opt/local/lib/ruby/gems/1.8/gems/cucumber-rails-1.0.2/lib/cucumber/rails.rb:5:in `require'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-rails-1.0.2/lib/cucumber/rails.rb:5
/Users/gauravsingharoy/work/tiatros/features/support/env.rb:7:in `require'
/Users/gauravsingharoy/work/tiatros/features/support/env.rb:7
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/rb_support/rb_language.rb:143:in `load'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/rb_support/rb_language.rb:143:in `load_code_file'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/runtime/support_code.rb:171:in `load_file'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/runtime/support_code.rb:83:in `load_files!'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/runtime/support_code.rb:82:in `each'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/runtime/support_code.rb:82:in `load_files!'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/runtime.rb:137:in `load_step_definitions'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/runtime.rb:39:in `run!'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/cli/main.rb:43:in `execute!'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/../lib/cucumber/cli/main.rb:20:in `execute'
/opt/local/lib/ruby/gems/1.8/gems/cucumber-1.0.6/bin/cucumber:14
/opt/local/lib/ruby/gems/1.8/bin/cucumber:19:in `load'
/opt/local/lib/ruby/gems/1.8/bin/cucumber:19
REF FOR INSTALLING RVM:
http://seanbehan.com/mac-os-x/installing-and-using-rvm-on-mac-os-x-creating-gemsets-and-reverting-to-original-environment/
Looks like bundler can't find your dependencies. You appear to be using a System-wide ruby installation which is unrecommended.
I recommend you install rvm and reinstall ruby using rvm's method then running bundle again once everything is configured and working correctly.