I upgraded from Rails 3.0.11 to 3.1.3. When I start the server, it's giving the error:
>> Using rack adapter
rake aborted!
libffi.so.5: cannot open shared object file: No such file or directory - /home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/ffi-1.0.11/lib/ffi_c.so
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `block in require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:223:in `block in load_dependency'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:640:in `new_constants_in'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:223:in `load_dependency'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/ffi-1.0.11/lib/ffi.rb:11:in `rescue in <top (required)>'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/ffi-1.0.11/lib/ffi.rb:2:in `<top (required)>'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `block in require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:223:in `block in load_dependency'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:640:in `new_constants_in'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:223:in `load_dependency'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/ethon-0.5.3/lib/ethon.rb:2:in `<top (required)>'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `block in require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:223:in `block in load_dependency'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:640:in `new_constants_in'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:223:in `load_dependency'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/activesupport-3.1.4/lib/active_support/dependencies.rb:240:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/typhoeus-0.5.3/lib/typhoeus.rb:2:in `<top (required)>'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/bundler-1.2.1/lib/bundler/runtime.rb:68:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/bundler-1.2.1/lib/bundler/runtime.rb:68:in `block (2 levels) in require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/bundler-1.2.1/lib/bundler/runtime.rb:66:in `each'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/bundler-1.2.1/lib/bundler/runtime.rb:66:in `block in require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/bundler-1.2.1/lib/bundler/runtime.rb:55:in `each'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/bundler-1.2.1/lib/bundler/runtime.rb:55:in `require'
/home/srikanth/.rvm/gems/ruby-1.9.3-p125/gems/bundler-1.2.1/lib/bundler.rb:128:in `require'
/home/srikanth/projects/tango/config/application.rb:19:in `<top (required)>'
/home/srikanth/projects/tango/Rakefile:8:in `require'
/home/srikanth/projects/tango/Rakefile:8:in `<top (required)>'
(See full trace by running task with --trace)
Any idea how to fix this?
Maybe the ffi gem was not installed properly?
gem uninstall ffi
Assuming you are using Ubuntu:
sudo apt-get install libffi libffi-dev
gem install ffi -v 1.0.11
As I already have 'ffi' installed. I have to find another solution, try below(Which helped me):
Locate the file "libffi.so.5", if it is not present check for "libffi.so." (in my case it was 6, that is libffi.so.6).
Now unlink the file associated with the "/usr/lib64/libffi.so.6". (In my case it was pointed to "libffi.so.6.0.1")
Now create a new symlink for "libffi.so.5", such that "/usr/lib64/libffi.so.5" should point to the new one, "libffi.so.6.0.1".
ie,the final set up should look like:- "/usr/lib64/libffi.so.5 -> libffi.so.6.0.1"
Hope this helps.(I use Amazon Linux AMI based instances.)
This worked for me.
ln -s /usr/lib64/libffi.so.6 /usr/lib64/libffi.so.5
Related
I am trying to convert ?locale=en in routes to /en/ I found routing-filter gem
but if I try to run rails, I get this error:
samir#samir-VirtualBox:~/RubymineProjects/dcaclab$ rails s
/home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `require': cannot load such file -- routing_filter/adapters/rails_4 (LoadError)
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `block in require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:214:in `load_dependency'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/routing-filter-0.3.1/lib/routing_filter.rb:27:in `<top (required)>'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `block in require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:214:in `load_dependency'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/activesupport-4.0.3/lib/active_support/dependencies.rb:229:in `require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/routing-filter-0.3.1/lib/routing-filter.rb:1:in `<top (required)>'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/bundler-1.5.3/lib/bundler/runtime.rb:76:in `require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/bundler-1.5.3/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/bundler-1.5.3/lib/bundler/runtime.rb:72:in `each'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/bundler-1.5.3/lib/bundler/runtime.rb:72:in `block in require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/bundler-1.5.3/lib/bundler/runtime.rb:61:in `each'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/bundler-1.5.3/lib/bundler/runtime.rb:61:in `require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/bundler-1.5.3/lib/bundler.rb:131:in `require'
from /home/samir/RubymineProjects/dcaclab/config/application.rb:8:in `<top (required)>'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/railties-4.0.3/lib/rails/commands.rb:74:in `require'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/railties-4.0.3/lib/rails/commands.rb:74:in `block in <top (required)>'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/railties-4.0.3/lib/rails/commands.rb:71:in `tap'
from /home/samir/.rvm/gems/ruby-2.1.0#dcaclab/gems/railties-4.0.3/lib/rails/commands.rb:71:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
Any idea how to solve this?
The version of the gem you are currently using is probably not compatible with Rails 4. You need to have version 0.4.0.pre, which can be installed through gem install routing-filter --pre or by editing your gemfile. I have found this issue, which relates to your problem: https://github.com/svenfuchs/routing-filter/issues/48
I'm working on a Rails app and testing using Rspec. Unfortunately when I try to run bundle exec rspec I'm met with a giant wall of error text (below).
The first line I see is a warning about Nokogiri, but I suspect that is unrelated to the main issue at hand.
WARNING: Nokogiri was built against LibXML version 2.8.0, but has dynamically loaded 2.7.8
Could not open library 'kernel32': dlopen(kernel32, 5): image not found.
Could not open library 'libkernel32.dylib': dlopen(libkernel32.dylib, 5): image not found (LoadError)
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/ffi-1.9.0/lib/ffi/library.rb:123:in `block in ffi_lib'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/ffi-1.9.0/lib/ffi/library.rb:90:in `map'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/ffi-1.9.0/lib/ffi/library.rb:90:in `ffi_lib'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/rb-fchange-0.0.5/lib/rb-fchange/native.rb:10:in `<module:Native>'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/rb-fchange-0.0.5/lib/rb-fchange/native.rb:8:in `<module:FChange>'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/rb-fchange-0.0.5/lib/rb-fchange/native.rb:3:in `<top (required)>'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `block in require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:236:in `load_dependency'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/rb-fchange-0.0.5/lib/rb-fchange.rb:1:in `<top (required)>'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `block (2 levels) in require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `each'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `block in require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `each'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/bundler-1.3.5/lib/bundler.rb:132:in `require'
/Users/varunrau/Documents/curr/BPSF/config/application.rb:7:in `<top (required)>'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/core_ext/kernel_require.rb:45:in `require'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/app_framework/rails.rb:48:in `preload_rails'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/app_framework/rails.rb:7:in `preload'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/test_framework.rb:134:in `block in preload'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork.rb:62:in `exec_prefork'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/test_framework.rb:120:in `preload'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/run_strategy/forking.rb:25:in `preload'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/runner.rb:74:in `run'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/runner.rb:10:in `run'
/usr/local/Cellar/ruby/1.9.3-p194/lib/ruby/gems/1.9.1/gems/spork-0.9.2/bin/spork:10:in `<top (required)>'
/usr/local/Cellar/ruby/1.9.3-p194/bin/spork:23:in `load'
/usr/local/Cellar/ruby/1.9.3-p194/bin/spork:23:in `<main>'
My system details are: OS X 10.8, Rails 3.2.13, Ruby 1.9.3p194. I tried reinstalling Ruby and the rb-fchange gem as per some advice on this site, but nothing has worked.
Thanks so much for the help!
When I run my code on osx, I get following error. Same code works fine on Linux. What could be wrong?
Exiting
/Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/polyglot-0.3.3/lib/polyglot.rb:63:in `require': no such file to load -- psych (LoadError)
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/polyglot-0.3.3/lib/polyglot.rb:63:in `require'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:240:in `block in require'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:223:in `block in load_dependency'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:640:in `new_constants_in'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:223:in `load_dependency'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:240:in `require'
from /Users/jagratishringi/.rvm/rubies/ruby-1.9.2-p320/lib/ruby/1.9.1/yaml.rb:16:in `yamler='
from /Users/jagratishringi/work/voylla_website/config/environment.rb:12:in `<top (required)>'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/polyglot-0.3.3/lib/polyglot.rb:63:in `require'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/polyglot-0.3.3/lib/polyglot.rb:63:in `require'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:240:in `block in require'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:223:in `block in load_dependency'
from /Users/jagratishringi/.rvm/gems/ruby-1.9.2-p320#voylla/gems/activesupport-3.1.10/lib/active_support/dependencies.rb:640:i
In Gemfile
Please add
gem "psych", "~> 2.0.0"
bundle install
rails s
Thanks
using ruby1.9.2 rails3.1.0
I am working from my netbook, so it is not my usual dev environment. I cloned a repo that I was working with on my desktop early this week. Now when I run rake test I get this error in the terminal.
^[[1;5C/home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/turn-0.8.3/lib/turn/autorun/minitest.rb:14:in `<top (required)>': MiniTest v1.6.0 is out of date. (RuntimeError)
`gem install minitest` and add `gem 'minitest' to you test helper.
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/turn-0.8.3/lib/turn.rb:13:in `<top (required)>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/test_help.rb:19:in `<top (required)>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/Desktop/sa_clubbing/test/test_helper.rb:3:in `<top (required)>'
from /home/work/Desktop/sa_clubbing/test/unit/blog_post_test.rb:1:in `require'
from /home/work/Desktop/sa_clubbing/test/unit/blog_post_test.rb:1:in `<top (required)>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `require'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `block (2 levels) in <main>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `each'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `block in <main>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:5:in `each'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:5:in `<main>'
/home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/turn-0.8.3/lib/turn/autorun/minitest.rb:14:in `<top (required)>': MiniTest v1.6.0 is out of date. (RuntimeError)
`gem install minitest` and add `gem 'minitest' to you test helper.
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/turn-0.8.3/lib/turn.rb:13:in `<top (required)>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/railties-3.1.0/lib/rails/test_help.rb:19:in `<top (required)>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/.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/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/work/.rvm/gems/ruby-1.9.2-p290#rails310/gems/activesupport-3.1.0/lib/active_support/dependencies.rb:240:in `require'
from /home/work/Desktop/sa_clubbing/test/test_helper.rb:3:in `<top (required)>'
from /home/work/Desktop/sa_clubbing/test/functional/landing_page_controller_test.rb:1:in `require'
from /home/work/Desktop/sa_clubbing/test/functional/landing_page_controller_test.rb:1:in `<top (required)>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `require'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `block (2 levels) in <main>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `each'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:9:in `block in <main>'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:5:in `each'
from /home/work/.rvm/gems/ruby-1.9.2-p290#global/gems/rake-0.9.2/lib/rake/rake_test_loader.rb:5:in `<main>'
Errors running test:units, test:functionals!
I followed the instruction and did gem install minitest , but still get the same result. Anyone know what to do here?
I just checked my gem list and it says minitest version 2.6.2 is installed. I don't know why the error is saying MiniTest v1.6.0 is out of date I am not using that version
I fixed it in the following way:
add in your Gemfile following gem, Then run bundle install
group :test do
gem 'turn', '< 0.8.3'
end
bundle exec rake test
Having a .rvmrc file in the project's root directory is handy for automatically setting the correct ruby/gemset. Also make sure your Gemfile/Gemfile.lock are using the correct version.
Here is how to fix it...
go to the root of your aplication and type:
gem install minitest
Then go to your gemfile located in the root of your app and add
gem 'minitest' at the bottom of the file.
I have some code that is using SyncEnumerator. As you can see here, SyncEnumerator requires generator.rb. To include this, the developer of this plugin has require 'generator'. This worked on my previous Rails installation but is not working since I upgraded OS X and reinstalled Rails. Now when I try to install my gems, I get:
Macintosh:mls TAmoyal$ sudo rake gems:install
(in /Users/TAmoyal/Desktop/RoR_Projects/mls)
rake aborted!
no such file to load -- generator
(See full trace by running task with --trace)
Stack Trace:
/usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require': no such file to load -- generator (MissingSourceFile)
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `block in require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /Users/TAmoyal/Desktop/RoR_Projects/mls/vendor/plugins/blackbook/lib/blackbook/importer/page_scraper.rb:4:in `<top (required)>'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `block in require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /Users/TAmoyal/Desktop/RoR_Projects/mls/vendor/plugins/blackbook/lib/blackbook/importer/aol.rb:1:in `<top (required)>'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `block in require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /Users/TAmoyal/Desktop/RoR_Projects/mls/vendor/plugins/blackbook/lib/blackbook.rb:68:in `block in <top (required)>'
from /Users/TAmoyal/Desktop/RoR_Projects/mls/vendor/plugins/blackbook/lib/blackbook.rb:68:in `each'
from /Users/TAmoyal/Desktop/RoR_Projects/mls/vendor/plugins/blackbook/lib/blackbook.rb:68:in `<top (required)>'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `block in require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /Users/TAmoyal/Desktop/RoR_Projects/mls/vendor/plugins/blackbook/init.rb:1:in `block in evaluate_init_rb'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/rails/plugin.rb:146:in `eval'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/rails/plugin.rb:146:in `block in evaluate_init_rb'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/core_ext/kernel/reporting.rb:11:in `silence_warnings'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/rails/plugin.rb:142:in `evaluate_init_rb'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/rails/plugin.rb:48:in `load'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/rails/plugin/loader.rb:38:in `block in load_plugins'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/rails/plugin/loader.rb:37:in `each'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/rails/plugin/loader.rb:37:in `load_plugins'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/initializer.rb:348:in `load_plugins'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/initializer.rb:163:in `process'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/initializer.rb:113:in `run'
from /Users/TAmoyal/Desktop/RoR_Projects/mls/config/environment.rb:13:in `<top (required)>'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `block in require'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/dependencies.rb:156:in `require'
from /usr/local/lib/ruby/gems/1.9.1/gems/rails-2.3.2/lib/commands/server.rb:84:in `<top (required)>'
from script/server:3:in `require'
from script/server:3:in `<main>'
Anyone know how to solve this?
Thanks!
The problem has nothing to do with Rails. Both SyncEnumerator and Generator are part of the Ruby Core Library. You should have both in Ruby 1.8.x.
Could you post the full exception trace?
EDIT:
In Ruby 1.9 the Generator library has been removed in favor of Fibers.
See here and here.
The library you are using is not compatible with Ruby 1.9. You can try to copy the Generator and SyncEnumerator files from Ruby 1.8.x, but I don't know whether this solution will work.
in 1.9 there's Enumerator::Generator
or you might be able to get away with creating your own file
'generator'
that just does
Generator = Enumerator
GL.
-r
I had this problem with ruby 1.8 and found that my problem was that i was requiring 'generator' and that changing it to require 'generator.rb' fixed it. I believe this was because of a conflict in rails with its own Generator class
SyncEnumerator has moved to rexml/syncenumerator in Ruby 1.9.x you can use it by doing require 'rexml/syncenumerator'