In Rubymine, Rails fails to load 'uglifier' gem - ruby-on-rails

I have an issue while running Rails from Rubymine where it fails to load the uglifier gem with the stack below. Note that Node.js is installed on my Windows 7 computer.
From cmd.exe, 'rails s' works well : the web application starts.
From RubyMine run button, default configuration, I get the error :
"C:\Program Files (x86)\JetBrains\RubyMine 8.0.2\bin\runnerw.exe" C:\tools\languages\RailsInstaller\Ruby2.2.0\bin\ruby.exe -e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) C:/projects/perso/exercises/bin/rails server -b 127.0.0.1 -p 3000 -e development
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:80:in `rescue in block (2 levels) in require': There was an error while trying to load the gem 'uglifier'. (Bundler::GemRequireError)
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `each'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `block in require'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `each'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `require'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler.rb:99:in `require'
from C:/projects/perso/exercises/config/application.rb:7:in `<top (required)>'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:78:in `require'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:78:in `block in server'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:75:in `tap'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:75:in `server'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
from C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/railties-4.2.6/lib/rails/commands.rb:17:in `<top (required)>'
from C:/projects/perso/exercises/bin/rails:4:in `require'
from C:/projects/perso/exercises/bin/rails:4:in `<top (required)>'
from -e:1:in `load'
from -e:1:in `<main>'
Process finished with exit code 1
I get the same error from RubyMine terminal.
Here's some information on my environment from (same output from cmd.exe and RubyMine) :
>rails --version
Rails 4.2.6
>node --version
v0.10.22
>ruby --version
ruby 2.2.4p230 (2015-12-16 revision 53155) [i386-mingw32]
Ruby was installed using Rails Installer on a Windows 7 computer.
Node.js is installed too, using official installer.
RubyMine 8.0.4 (ultimate, not sure if there's a community version too)
I suspect an environment problem inside RubyMine in which rails/bundler/gem/? can't "see" Node.js, where cmd.exe can.
I think the error started when I tryed to start RubyMine debug mode.
Any idea on how to solve the issue ?
Thanks
Edit : some more information
My Gemfile :
source 'https://rubygems.org'
gem 'rails', '4.2.6'
gem 'sqlite3'
gem 'sass-rails', '~> 5.0'
gem 'uglifier', '>= 1.3.0'
gem 'coffee-rails', '~> 4.1.0'
gem 'jquery-rails'
gem 'turbolinks'
gem 'jbuilder', '~> 2.0'
gem 'sdoc', '~> 0.4.0', group: :doc
gem 'bcrypt', '~> 3.1.7'
group :development, :test do
gem 'byebug'
end
group :development do
gem 'web-console', '~> 2.0'
end
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
rake tasks (for example to get the full error stack, note the ExecJS::RuntimeUnavailable: Could not find a JavaScript runtime. )
>rake tasks --trace
rake aborted!
Bundler::GemRequireError: There was an error while trying to load the gem 'uglifier'.
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:80:in `rescue in block (2 levels) in require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `each'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `block in require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `each'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler.rb:99:in `require'
C:/projects/perso/exercises/config/application.rb:7:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require'
C:/projects/perso/exercises/Rakefile:4:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/rake_module.rb:28:in `load'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/rake_module.rb:28:in `load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:689:in `raw_load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:94:in `block in load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:176:in `standard_exception_handling'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:93:in `load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:77:in `block in run'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:176:in `standard_exception_handling'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:75:in `run'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/bin/rake:33:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/bin/rake:23:in `load'
C:/tools/languages/RailsInstaller/Ruby2.2.0/bin/rake:23:in `<main>'
ExecJS::RuntimeUnavailable: Could not find a JavaScript runtime. See https://github.com/rails/execjs for a list of available runtimes.
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/execjs-2.6.0/lib/execjs/runtimes.rb:48:in `autodetect'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/execjs-2.6.0/lib/execjs.rb:5:in `<module:ExecJS>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/execjs-2.6.0/lib/execjs.rb:4:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/uglifier-3.0.0/lib/uglifier.rb:5:in `require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/uglifier-3.0.0/lib/uglifier.rb:5:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:77:in `require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:77:in `block (2 levels) in require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `each'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:72:in `block in require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `each'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler/runtime.rb:61:in `require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/bundler-1.11.2/lib/bundler.rb:99:in `require'
C:/projects/perso/exercises/config/application.rb:7:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/2.2.0/rubygems/core_ext/kernel_require.rb:54:in `require'
C:/projects/perso/exercises/Rakefile:4:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/rake_module.rb:28:in `load'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/rake_module.rb:28:in `load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:689:in `raw_load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:94:in `block in load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:176:in `standard_exception_handling'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:93:in `load_rakefile'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:77:in `block in run'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:176:in `standard_exception_handling'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:75:in `run'
C:/tools/languages/RailsInstaller/Ruby2.2.0/lib/ruby/gems/2.2.0/gems/rake-11.1.2/bin/rake:33:in `<top (required)>'
C:/tools/languages/RailsInstaller/Ruby2.2.0/bin/rake:23:in `load'
C:/tools/languages/RailsInstaller/Ruby2.2.0/bin/rake:23:in `<main>'

I had the same problem, though my solution isn't that simple!
I have a run configuration that has field "Environment variables" set with PATH=d:\opt\curl-7.40.0-devel-mingw64\bin\;%PATH%;=. But when I click on "..." right to this field, in value column it says d:\opt\curl-7.40.0-devel-mingw64\bin\;%PATH%" (without the "=" at the end).
I changed it so that it includes the path to node.exe
PATH=d:\opt\curl-7.40.0-devel-mingw64\bin\;d:\opt\nodejs\;%PATH%;
Now it works fine.
I run ruby 2.2.3-x64 with Rails 4.2.5 on a Windows 10 machine.

Check if your Gemfile has the following gem
gem 'uglifier'
If you already have the gem in Gemfile, then run bundle install and check if the bundle in installing the uglifier gem.

I finally got it working, here's the context and solution if someone else has the same issue.
I have defined a user scoped Path variable which was refering to my system Path as :
%Path%;C:\tools\…
In RedMine, this %Path% was not interpreted anymore (don't know why). I saw it by typing in RubyMine Terminal :
echo %Path%
The result was displaying "%Path%", not its content.
I solved the problem by simply rebooting the computer.

Related

cannot load such file -- bcrypt_ext (LoadError) on windows

I have ruby 2.3.3p222 (2016-11-21 revision 56859) [x64-mingw32] and rails 5.1.4. I am getting following error when i run rails s command.
rails s
C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `require': cannot load such file -- bcrypt_ext (LoadError)
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `block in require'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:258:in `load_dependency'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/activesupport-5.1.4/lib/active_support/dependencies.rb:292:in `require'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bcrypt-3.1.11-x64-mingw32/lib/bcrypt.rb:16:in `rescue in <top (required)>'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bcrypt-3.1.11-x64-mingw32/lib/bcrypt.rb:12:in `<top (required)>'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bundler-1.16.0.pre.2/lib/bundler/runtime.rb:83:in `require'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bundler-1.16.0.pre.2/lib/bundler/runtime.rb:83:in `block (2 levels) in require'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bundler-1.16.0.pre.2/lib/bundler/runtime.rb:78:in `each'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bundler-1.16.0.pre.2/lib/bundler/runtime.rb:78:in `block in require'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bundler-1.16.0.pre.2/lib/bundler/runtime.rb:67:in `each'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bundler-1.16.0.pre.2/lib/bundler/runtime.rb:67:in `require'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/bundler-1.16.0.pre.2/lib/bundler.rb:114:in `require'
from E:/Rauf Personal Data/work/rails/shine/config/application.rb:7:in `<top (required)>'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/railties-5.1.4/lib/rails/commands/server/server_command.rb:133:in `require'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/railties-5.1.4/lib/rails/commands/server/server_command.rb:133:in `block in perform'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/railties-5.1.4/lib/rails/commands/server/server_command.rb:130:in `tap'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/railties-5.1.4/lib/rails/commands/server/server_command.rb:130:in `perform'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/thor-0.20.0/lib/thor/command.rb:27:in `run'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/thor-0.20.0/lib/thor/invocation.rb:126:in `invoke_command'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/thor-0.20.0/lib/thor.rb:387:in `dispatch'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/railties-5.1.4/lib/rails/command/base.rb:63:in `perform'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/railties-5.1.4/lib/rails/command.rb:44:in `invoke'
from C:/Ruby23-x64/lib/ruby/gems/2.3.0/gems/railties-5.1.4/lib/rails/commands.rb:16:in `<top (required)>'
from bin/rails:4:in `require'
from bin/rails:4:in `<main>'
I have almost tried every solution but i am unable to resolve this issue. Can any body please help me to sort out this issue. I already tried following:
Firstly uninstall bcrypt and bcrypt-ruby by running these two commands:
gem uninstall bcrypt and gem uninstall bcrypt-ruby
Install it again with gem install bcrypt --platform=ruby
In your Gemfile write gem 'bcrypt-ruby', '3.1.5', :require => 'bcrypt'
Run bundle install
I have managed to solve this issue by adding following line in the Gemfile....
gem 'bcrypt', git: 'https://github.com/codahale/bcrypt-ruby.git', :require => 'bcrypt'
After trying several methods, the above worked for me:
1) Stop all rails servers.
2) Add : gem 'bcrypt', git: 'https://github.com/codahale/bcrypt-ruby.git', :require => 'bcrypt' to the gemfile.
3) bundle install.

Error with Ruby gems (Ruby on Rails)

I'm still getting an error with my gemfile, I can Download all the gems, but at the moment of 'rails server' I'm getting this error:
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:94:in `rescue in block (2 levels) in require': There was an error while trying to load the gem 'will_paginate'. (Bundler::GemRequireError)
Gem Load Error is: uninitialized constant ActiveSupport::LogSubscriber
Backtrace for gem load error is:
/home/administrador/.rvm/gems/ruby-2.4.0/gems/activerecord-3.0.5/lib/active_record/log_subscriber.rb:2:in `<module:ActiveRecord>'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/activerecord-3.0.5/lib/active_record/log_subscriber.rb:1:in `<top (required)>'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/activerecord-3.0.5/lib/active_record/base.rb:24:in `<top (required)>'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/will_paginate-2.3.15/lib/will_paginate.rb:33:in `require'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/will_paginate-2.3.15/lib/will_paginate.rb:33:in `enable_activerecord'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/will_paginate-2.3.15/lib/will_paginate.rb:88:in `<top (required)>'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:91:in `require'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:91:in `block (2 levels) in require'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in `each'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in `block in require'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in `each'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in `require'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler.rb:106:in `require'
/home/administrador/Documents/forminst4/config/application.rb:7:in `<top (required)>'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:28:in `require'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:28:in `block in <top (required)>'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:27:in `tap'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:27:in `<top (required)>'
script/rails:6:in `require'
script/rails:6:in `<main>'
Bundler Error Backtrace:
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:90:in `block (2 levels) in require'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in `each'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:86:in `block in require'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in `each'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:75:in `require'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler.rb:106:in `require'
from /home/administrador/Documents/forminst4/config/application.rb:7:in `<top (required)>'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:28:in `require'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:28:in `block in <top (required)>'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:27:in `tap'
from /home/administrador/.rvm/gems/ruby-2.4.0/gems/railties-3.0.5/lib/rails/commands.rb:27:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
This is my gemfile:
source 'http://rubygems.org'
gem 'rails', '3.0.5'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
gem 'mysql2', '~> 0.2.6'
gem 'prawn', '0.8.4'
gem 'jquery-rails'
gem 'carrierwave'
gem 'will_paginate', '2.3.15'
gem 'net-ldap', '0.3.1'
gem 'cancan', '1.6.10'
gem 'therubyracer'
I'll really appreciate it if you can help me with this! Thanks a lot
Edit: I've tried adding "gem 'will_paginate', '~> 3.1.0'" to my gemfile.. and when I run rails server I get this error
/home/administrador/.rvm/gems/ruby-2.4.0/gems/bundler-1.13.7/lib/bundler/runtime.rb:94:in `rescue in block (2 levels) in require': There was an error while trying to load the gem 'cancan'. (Bundler::GemRequireError)
Gem Load Error is: uninitialized constant AbstractController::ViewPaths
Backtrace for gem load error is:
/home/administrador/.rvm/gems/ruby-2.4.0/gems/actionpack-3.0.5/lib/abstract_controller/rendering.rb:36:in `<module:Rendering>'
/home/administrador/.rvm/gems/ruby-2.4.0/gems/actionpack-3.0.5/lib/abstract_controller/rendering.rb:33:in `<module:AbstractController>'....(same as above)
just update your gemfile with
gem 'will_paginate', '~> 3.1.0'
rails 3 or 3+ version need above version for will paginate
refer this https://github.com/mislav/will_paginate

cannot load such file -- activerecord (LoadError)

I'm trying to upgrade a very old app from Rails 2.3.12 to Rails 3.0.0 (as a starting point to getting it to Rails 4). I've been slowly going through and fixing anything that has broken since the upgrade by removing old gems etc.
I've got stuck on a problem that I can't seem to pin point or fix.
I'm running Rails3, Ruby1.9.3
When I try to run the rails server I get the following error:
=> Booting WEBrick
=> Rails 3.0.0 application starting in development on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
/home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require': cannot load such file -- activerecord (LoadError)
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `block in require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
from /home/camillavk/Documents/Work/Saild/saild/vendor/plugins/acts_as_commentable/lib/commentable_methods.rb:1:in `<top (required)>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `block in require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
from /home/camillavk/Documents/Work/Saild/saild/vendor/plugins/acts_as_commentable/lib/acts_as_commentable.rb:1:in `<top (required)>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `block in require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
from /home/camillavk/Documents/Work/Saild/saild/vendor/plugins/acts_as_commentable/rails/init.rb:1:in `block in <class:Plugin>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/plugin.rb:81:in `eval'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/plugin.rb:81:in `block in <class:Plugin>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/initializable.rb:25:in `instance_exec'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/initializable.rb:25:in `run'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/initializable.rb:50:in `block in run_initializers'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/initializable.rb:49:in `each'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/initializable.rb:49:in `run_initializers'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/application.rb:134:in `initialize!'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/application.rb:77:in `method_missing'
from /home/camillavk/Documents/Work/Saild/saild/config/environment.rb:7:in `<top (required)>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `block in require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
from /home/camillavk/Documents/Work/Saild/saild/config.ru:3:in `block in <main>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/rack-1.2.8/lib/rack/builder.rb:46:in `instance_eval'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/rack-1.2.8/lib/rack/builder.rb:46:in `initialize'
from /home/camillavk/Documents/Work/Saild/saild/config.ru:1:in `new'
from /home/camillavk/Documents/Work/Saild/saild/config.ru:1:in `<main>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/rack-1.2.8/lib/rack/builder.rb:35:in `eval'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/rack-1.2.8/lib/rack/builder.rb:35:in `parse_file'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/rack-1.2.8/lib/rack/server.rb:162:in `app'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/rack-1.2.8/lib/rack/server.rb:253:in `wrapped_app'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/rack-1.2.8/lib/rack/server.rb:204:in `start'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/commands/server.rb:65:in `start'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/commands.rb:30:in `block in <top (required)>'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/commands.rb:27:in `tap'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/railties-3.0.0/lib/rails/commands.rb:27:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
My Gemfile looks like this:
source 'https://rubygems.org'
gem "rails", "3.0.0"
gem "airbrake"
gem "aws-s3"
gem "bj"
gem "bundler", "~> 1.0.0"
gem "calendar_date_select", "1.15"
gem "cancan", "1.2.0"
gem "carmen"
gem 'comma', '0.4.1'
gem 'exifr'
# factory_girl 1.2.4 wasn't working with Rails 3 - consider an upgrade to factory_girl_rails?
# gem "factory_girl", "1.2.4"
gem 'fastercsv'
gem "geokit"
gem "haml"
gem "hpricot"
gem 'hoptoad_notifier'
gem "jrails"
gem "libxml-ruby", "2.4.0"
gem "memcached", "~> 1.8.0"
#memcached no longer works?
gem 'dalli'
# Not sure why we have this if we're using SQLite3
gem "mysql2", "~> 0.2.6"
#TODO: changed by almazom
gem "rake", "0.8.4"
gem 'recurly'
gem "rdoc"
gem "rmagick"
gem "rspreedly"
gem "rubyzip"
gem 'sass'
#need to use simplecov when upgrading to ruby 2 as rcov doesn't work
gem "simplecov"
gem 'sqlite3'
# tmail no longer included in rails 3?
gem 'tmail'
gem "will_paginate", "2.3.16"
gem 'yaml_db'
group :development, :test do
gem 'test-unit', '1.2.3'
gem 'rspec', '1.3.2'
gem 'rspec-rails', '~> 1.3.4'
end
group :test do
gem 'capybara', '0.3.5'
gem 'cucumber', '1.1.2'
gem 'cucumber-rails', :git => "git://github.com/RKelln/cucumber-rails.git", :branch => "0.3.2-capybara-fix"
gem 'database_cleaner'
end
Has anyone else encountered this problem before when upgrading to Rails 3? I can't find anything on Google about it....
Or does anyone have a suggestion on how I can find/fix the issue?
Many thanks in advance!
Let's take a look at your stack trace. Stack traces are read top to bottom. If you have function A calling function B calling function C, where an error happens, the stack trace shows
C
B
A
We can see that the first lines all come from Rails itself:
/home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require': cannot load such file -- activerecord (LoadError)
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `block in require'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/camillavk/.rvm/gems/ruby-1.9.3-p551#rails3/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
Since it's usually unlikely that Rails itself is the culprit, we look for the first line that comes from some place else — either your own code, or a third-party library.
The next line is just that:
from /home/camillavk/Documents/Work/Saild/saild/vendor/plugins/acts_as_commentable/lib/commentable_methods.rb:1:in `<top (required)>'
We see that it's code at vendor/plugins, making it an old, Rails 2.3-style plugin. They were deprecated in Rails 3, and completely stopped working in Rails 4. They were replaced by "Gem plugins" that are added through your Gemfile and Bundler, instead of vendor/plugins.
So acts_as_commentable is a good candidate as the culprit. The Github project page shows a version especially for Rails 3, so removing the old plugin and replacing it with that Gem gives you a good shot at fixing this issue.

Rspec 3.0.0 Ruby on rails

I used
gem 'rspec-rails', "~> 2.14.2" and all my tests works. Now i installed
gem 'rspec', '~> 3.0.0.beta' and I get this:
henio#henio-Toshiba:~/git/EduWords$ bundle exec rspec
/home/henio/.rvm/gems/ruby-2.1.1/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `require': cannot load such file -- rspec/rails (LoadError)
from /home/henio/.rvm/gems/ruby-2.1.1/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `block in require'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:214:in `load_dependency'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `require'
from /home/henio/git/EduWords/spec/spec_helper.rb:4:in `<top (required)>'
from /home/henio/git/EduWords/spec/features/languages_pages_spec.rb:1:in `require'
from /home/henio/git/EduWords/spec/features/languages_pages_spec.rb:1:in `<top (required)>'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/configuration.rb:1051:in `load'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/configuration.rb:1051:in `block in load_spec_files'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/configuration.rb:1051:in `each'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/configuration.rb:1051:in `load_spec_files'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/runner.rb:97:in `setup'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/runner.rb:85:in `run'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/runner.rb:70:in `run'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/lib/rspec/core/runner.rb:38:in `invoke'
from /home/henio/.rvm/gems/ruby-2.1.1/gems/rspec-core-3.0.0.rc1/exe/rspec:4:in `<top (required)>'
from /home/henio/.rvm/gems/ruby-2.1.1/bin/rspec:23:in `load'
from /home/henio/.rvm/gems/ruby-2.1.1/bin/rspec:23:in `<main>'
from /home/henio/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `eval'
from /home/henio/.rvm/gems/ruby-2.1.1/bin/ruby_executable_hooks:15:in `<main>'
I'm using Rails 4.0.3 and Ruby 2.1.1p76. I did bundle install. What I'm doing in wrong way?
If you’re using Rails, you should use rspec-rails to integrate Rails with RSpec. Change your gem requirement to this:
gem 'rspec-rails', '~> 3.0.0.beta'
RSpec 3 introduces significant changes, so you’ll have to update some specs.

Bitly Gem/ Oauth Gem issues when starting app in production

I'm trying to deploy my rails application to production however I've hit a bit of a problem. I'm using Nginx and Unicorn and the application has been running fine in production for a while now but a hardware error with my hosting provider earlier today has brought the site down and while trying to revive it the following errors appeared in the unicorn error log:
E, [2012-11-23T21:30:03.291386 #4370] ERROR -- : reaped #<Process::Status: pid 7795 exit 1> worker=0
I, [2012-11-23T21:30:03.291819 #4370] INFO -- : worker=0 spawning...
I, [2012-11-23T21:30:03.310884 #7801] INFO -- : worker=0 spawned pid=7801
I, [2012-11-23T21:30:03.311488 #7801] INFO -- : Refreshing Gem list
/home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/faraday-0.7.6/lib/faraday/connection.rb:1:in `require': no such file to load -- addressable/uri (LoadError)
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/faraday-0.7.6/lib/faraday/connection.rb:1:in `<top (required)>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/faraday-0.7.6/lib/faraday.rb:68:in `require'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/faraday-0.7.6/lib/faraday.rb:68:in `<top (required)>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/oauth2-0.5.2/lib/oauth2/client.rb:1:in `require'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/oauth2-0.5.2/lib/oauth2/client.rb:1:in `<top (required)>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/oauth2-0.5.2/lib/oauth2.rb:2:in `require'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/oauth2-0.5.2/lib/oauth2.rb:2:in `<top (required)>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/bitly-0.7.0/lib/bitly/v3.rb:5:in `require'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/bitly-0.7.0/lib/bitly/v3.rb:5:in `<top (required)>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/bitly-0.7.0/lib/bitly.rb:9:in `require'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/bitly-0.7.0/lib/bitly.rb:9:in `<top (required)>'
from /home/deployer/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.5/lib/bundler/runtime.rb:68:in `require'
from /home/deployer/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.5/lib/bundler/runtime.rb:68:in `block (2 levels) in require'
from /home/deployer/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.5/lib/bundler/runtime.rb:66:in `each'
from /home/deployer/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.5/lib/bundler/runtime.rb:66:in `block in require'
from /home/deployer/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.5/lib/bundler/runtime.rb:55:in `each'
from /home/deployer/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.5/lib/bundler/runtime.rb:55:in `require'
from /home/deployer/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.5/lib/bundler.rb:119:in `require'
from /home/deployer/apps/stealthygecko/releases/20121123212740/config/application.rb:7:in `<top (required)>'
from /home/deployer/apps/stealthygecko/releases/20121123212740/config/environment.rb:2:in `require'
from /home/deployer/apps/stealthygecko/releases/20121123212740/config/environment.rb:2:in `<top (required)>'
from config.ru:4:in `require'
from config.ru:4:in `block in <main>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:51:in `instance_eval'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/rack-1.4.1/lib/rack/builder.rb:51:in `initialize'
from config.ru:1:in `new'
from config.ru:1:in `<main>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn.rb:44:in `eval'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn.rb:44:in `block in builder'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn/http_server.rb:694:in `call'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn/http_server.rb:694:in `build_app!'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn/http_server.rb:567:in `init_worker_process'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn/http_server.rb:587:in `worker_loop'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn/http_server.rb:487:in `spawn_missing_workers'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn/http_server.rb:498:in `maintain_worker_count'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/lib/unicorn/http_server.rb:272:in `join'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/gems/unicorn-4.2.1/bin/unicorn:121:in `<top (required)>'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/bin/unicorn:23:in `load'
from /home/deployer/apps/stealthygecko/shared/bundle/ruby/1.9.1/bin/unicorn:23:in `<main>'
Here's my Gemfile:
gem 'rake'
gem 'rails', '3.2.6'
gem 'mysql2'
gem 'bcrypt-ruby', '~> 3.0.0'
gem 'gravtastic'
gem "friendly_id"
gem "videawesome"
gem "will_paginate", "~>3.0.3"
gem "bitly"
gem "sanitize"
gem "newrelic_rpm"
gem 'capistrano'
gem 'rvm-capistrano'
gem "unicorn", "~> 4.2.1"
gem "wysihtml5-rails", "~> 0.0.2"
gem 'airbrake'
group :assets do
gem 'less-rails'
gem 'jquery-rails'
gem 'therubyracer'
gem 'uglifier'
gem 'twitter-bootstrap-rails'
end
From what I can see its the Bitly gem requiring oauth thats the problem, however I'm not sure how to fix this. if anyone can help I'd really appreciate it.
Thanks in advance.
Looks like the faraday gem is trying to require addressable/uri but that's not in your Gemfile.
after several hours or deploying and supposedly getting nowhere, it turned out that all I had to do was stop Unicorn completely and start it up again rather than just restart it. its now finding all the necessary dependencies.
The thing that confused me in all this was that I read that Faradays dependency on Addressable had been removed back in August, so naturally I was stumped as to why it was still being referenced.
Thanks for your help Ipwnstuff it was much appreciated.

Resources