Ruby Rake - Error - ruby

I am using vmware and trying to run rake db:migrate for getting the database tables. I am getting this error.
ubuntu#ubuntu-VirtualBox:~/hw-acceptance-unit-test-cycle/rottenpotatoes$ bundle exec rake db:migrate
rake aborted!
Bundler::GemRequireError: There was an error while trying to load the gem 'coffee-rails'.
Gem Load Error is: Could not find a JavaScript runtime. See https://github.com/rails/execjs for a list of available runtimes.
Backtrace for gem load error is:
/var/lib/gems/2.3.0/gems/execjs-2.7.0/lib/execjs/runtimes.rb:58:in ` autodetect'
/var/lib/gems/2.3.0/gems/execjs-2.7.0/lib/execjs.rb:5:in `<module:ExecJS>'
/var/lib/gems/2.3.0/gems/execjs-2.7.0/lib/execjs.rb:4:in `<top (required)>'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee_script.rb:1:in `require'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee_script.rb:1:in `<top (required)>'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee-script.rb:1:in `require'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee-script.rb:1:in `<top (required)>'
/var/lib/gems/2.3.0/gems/coffee-rails-4.1.1/lib/coffee-rails.rb:1:in `require'
/var/lib/gems/2.3.0/gems/coffee-rails-4.1.1/lib/coffee-rails.rb:1:in `<top (required)>'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:91:in `require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:91:in `block (2 levels) in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in `each'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in `block in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:in `each'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:in `require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler.rb:106:in `require'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/config/application.rb:12:in `<top (required)>'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/Rakefile:5:in `require'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/Rakefile:5:in `<top (required)>'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/rake_module.rb:28:in `load'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/rake_module.rb:28:in `load_rakefile'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/application.rb:686:in `raw_load_rakefile'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/application.rb:96:in `block in load_rakefile'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/application.rb:178:in `standard_exception_handling'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/application.rb:95:in `load_rakefile'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/application.rb:79:in `block in run'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/application.rb:178:in `standard_exception_handling'
/var/lib/gems/2.3.0/gems/rake-11.2.2/lib/rake/application.rb:77:in `run'
/var/lib/gems/2.3.0/gems/rake-11.2.2/exe/rake:27:in `<top (required)>'
/usr/local/bin/rake:23:in `load'
/usr/local/bin/rake:23:in `<main>'
Bundler Error Backtrace:
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:94:in `rescue in block (2 levels) in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:90:in `block (2 levels) in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in `each'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in `block in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:in `each'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:in `require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler.rb:106:in `require'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/config/application.rb:12:in `<top (required)>'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/Rakefile:5:in `require'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/Rakefile:5:in `<top (required)>'
/var/lib/gems/2.3.0/gems/rake-11.2.2/exe/rake:27:in `<top (required)>'
ExecJS::RuntimeUnavailable: Could not find a JavaScript runtime. See https://github.com/rails/execjs for a list of available runtimes.
/var/lib/gems/2.3.0/gems/execjs-2.7.0/lib/execjs/runtimes.rb:58:in `autodetect'
/var/lib/gems/2.3.0/gems/execjs-2.7.0/lib/execjs.rb:5:in `<module:ExecJS>'
/var/lib/gems/2.3.0/gems/execjs-2.7.0/lib/execjs.rb:4:in `<top (required)>'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee_script.rb:1:in `require'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee_script.rb:1:in `<top (required)>'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee-script.rb:1:in `require'
/var/lib/gems/2.3.0/gems/coffee-script-2.4.1/lib/coffee-script.rb:1:in `<top (required)>'
/var/lib/gems/2.3.0/gems/coffee-rails-4.1.1/lib/coffee-rails.rb:1:in `require'
/var/lib/gems/2.3.0/gems/coffee-rails-4.1.1/lib/coffee-rails.rb:1:in `<top (required)>'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:91:in `require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:91:in `block (2 levels) in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in `each'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:86:in block in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:ineach'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler/runtime.rb:75:in require'
/var/lib/gems/2.3.0/gems/bundler-1.13.6/lib/bundler.rb:106:inrequire'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/config/application.rb:12:in <top (required)>'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/Rakefile:5:inrequire'
/home/ubuntu/hw-acceptance-unit-test-cycle/rottenpotatoes/Rakefile:5:in <top (required)>'
/var/lib/gems/2.3.0/gems/rake-11.2.2/exe/rake:27:in'
(See full trace by running task with --trace)
What is the problem?

If you are on Linux then run:
sudo apt-get install nodejs
On Mac:
brew install node
and then run bundle and try to migrate. Must work.
Also you shall be more attentive to the search on Stackoverflow for not to duplicate same topics.
Rails - Could not find a JavaScript runtime?

Related

I am trying to run a ruby sinatra app and I'm getting this error while running config.ru: cannot load such file -- matrix (LoadError)

This is the error I'm getting, please tell me what should I do?
C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/prawn-2.4.0/lib/prawn/transformation_stack.rb:10:in `require': cannot load such file -- matrix (LoadError)
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/prawn-2.4.0/lib/prawn/transformation_stack.rb:10:in `<top (required)>'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/prawn-2.4.0/lib/prawn.rb:67:in `require_relative'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/prawn-2.4.0/lib/prawn.rb:67:in `<top (required)>'
from C:/Users/Ayushman Bedi/diabetes_analyst-master/diabetes_analyst-master/config/environment.rb:12:in `require'
from C:/Users/Ayushman Bedi/diabetes_analyst-master/diabetes_analyst-master/config/environment.rb:12:in `<top (required)>'
from C:/Users/Ayushman Bedi/diabetes_analyst-master/diabetes_analyst-master/config.ru:2:in `require'
from C:/Users/Ayushman Bedi/diabetes_analyst-master/diabetes_analyst-master/config.ru:2:in `block in <main>'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/builder.rb:116:in `eval'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/builder.rb:116:in `new_from_string'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/builder.rb:105:in `load_file'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/builder.rb:66:in `parse_file'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/server.rb:349:in `build_app_and_options_from_config'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/server.rb:249:in `app'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/server.rb:422:in `wrapped_app'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/server.rb:312:in `block in start'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/server.rb:379:in `handle_profiling'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/server.rb:311:in `start'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/lib/rack/server.rb:168:in `start'
from C:/Ruby31-x64/lib/ruby/gems/3.1.0/gems/rack-2.2.4/bin/rackup:5:in `<top (required)>'
from C:/Ruby31-x64/bin/rackup:25:in `load'
from C:/Ruby31-x64/bin/rackup:25:in `<main>'
I installed all the gems required, matrix, rack, prawn... but still.

Error when installing pods on Apple Silicon (M1)

This is the error that I receive when entering "pod install" in AppCode
LoadError - dlopen(/Users/[user]/.gem/ruby/2.6.0/gems/ffi-1.14.2/lib/ffi_c.bundle, 0x0009): missing compatible arch in /Users/[user]/.gem/ruby/2.6.0/gems/ffi-1.14.2/lib/ffi_c.bundle - /Users/[user]/.gem/ruby/2.6.0/gems/ffi-1.14.2/lib/ffi_c.bundle
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Users/[user]/.gem/ruby/2.6.0/gems/ffi-1.14.2/lib/ffi.rb:6:in `rescue in <top (required)>'
/Users/[user]/.gem/ruby/2.6.0/gems/ffi-1.14.2/lib/ffi.rb:3:in `<top (required)>'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Users/[user]/.gem/ruby/2.6.0/gems/ethon-0.12.0/lib/ethon.rb:2:in `<top (required)>'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Users/[user]/.gem/ruby/2.6.0/gems/typhoeus-1.4.0/lib/typhoeus.rb:2:in `<top (required)>'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/sources_manager.rb:74:in `cdn_url?'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/sources_manager.rb:36:in `create_source_with_url'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/sources_manager.rb:21:in `find_or_create_source_with_url'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:178:in `block in sources'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:177:in `map'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:177:in `sources'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:1073:in `block in resolve_dependencies'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/user_interface.rb:64:in `section'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:1072:in `resolve_dependencies'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:124:in `analyze'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:414:in `analyze'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:239:in `block in resolve_dependencies'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/user_interface.rb:64:in `section'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:238:in `resolve_dependencies'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:160:in `install!'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/command/install.rb:52:in `run'
/Users/[user]/.gem/ruby/2.6.0/gems/claide-1.0.3/lib/claide/command.rb:334:in `run'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/command.rb:52:in `run'
/Users/[user]/.gem/ruby/2.6.0/gems/cocoapods-1.10.1/bin/pod:55:in `<top (required)>'
/Users/[user]/Library/Application Support/JetBrains/Toolbox/apps/AppCode-ARM/ch-0/203.7148.89/AppCode.app/Contents/bin/pod:6:in `load'
/Users/[user]/Library/Application Support/JetBrains/Toolbox/apps/AppCode-ARM/ch-0/203.7148.89/AppCode.app/Contents/bin/pod:6:in `<main>'
I tried this solution, but I still receive the same error.
I did notice that my cocoapods is installed under "Users", but not sure if that matters.

vagrant up command return errors

I am setting up a fast hadoop cluster development envirment with vagrant, but met error when "vagrant up".
I have tried "vagrant plugin install vagrant-centos7_fix", but no luck.
followings are these errors:
C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/response.rb:70:in `block in <class:Response>': undefined method `downcase' for nil:NilClass (NoMethodError)
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/response.rb:68:in `each'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/response.rb:68:in `inject'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/response.rb:68:in `<class:Response>'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/response.rb:16:in `<module:SFTP>'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/response.rb:3:in `<module:Net>'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/response.rb:3:in `<top (required)>'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/request.rb:2:in `<top (required)>'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp/session.rb:5:in `<top (required)>'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/net-sftp-2.1.2/lib/net/sftp.rb:2:in `<top (required)>'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/plugins/communicators/ssh/communicator.rb:12:in `<top (required)>'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/mingw64/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/plugins/communicators/ssh/plugin.rb:14:in `block in <class:Plugin>'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/registry.rb:27:in `get'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/machine.rb:259:in `communicate'
from C:/zjsw/HashiCorp/Vagrant/embedded/gems/2.2.4/gems/vagrant-2.2.4/lib/vagrant/action/builtin/wait_for_communicator.rb:16:in `block in call'

Why do I get error when trying to start rails console

$ rails c
Running via Spring preloader in process 3921
/Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require': dlopen(/Users/liangshihao/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/x86_64-darwin15/readline.bundle, 9): Library not loaded: /usr/local/opt/readline/lib/libreadline.6.dylib (LoadError)
Referenced from: /Users/liangshihao/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/x86_64-darwin15/readline.bundle
Reason: image not found - /Users/liangshihao/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/x86_64-darwin15/readline.bundle
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `block in require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:259:in `load_dependency'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require'
from /Users/liangshihao/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/irb/completion.rb:10:in `<top (required)>'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `block in require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:259:in `load_dependency'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0.1/lib/rails/commands/console.rb:3:in `<top (required)>'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `block in require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:259:in `load_dependency'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0.1/lib/rails/commands/commands_tasks.rb:138:in `require_command!'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0.1/lib/rails/commands/commands_tasks.rb:68:in `console'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0.1/lib/rails/commands/commands_tasks.rb:49:in `run_command!'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0.1/lib/rails/commands.rb:18:in `<top (required)>'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `block in require'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:259:in `load_dependency'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:293:in `require'
from /Users/liangshihao/railsbridge/suggestotron/bin/rails:9:in `<top (required)>'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:287:in `load'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:287:in `block in load'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:259:in `load_dependency'
from /Users/liangshihao/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0.1/lib/active_support/dependencies.rb:287:in `load'
from /Users/liangshihao/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /Users/liangshihao/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from -e:1:in `<main>'
thanks for any help you can provide
If you've updated readline, then you may need to recompile ruby. If you're using rbenv, try uninstalling this version of ruby and reinstalling it.

When I start the server in Ruby On Rails it exits as soon as it starts and sometimes doesn't even start, just gives an error

This is the error message in Windows:
C:\Users\USER\Sites\new_cms>rails s
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.6.2-x64-mingw32/lib/nokogir
.rb:29:in `require': cannot load such file -- nokogiri/nokogiri (LoadError)
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.6.2-x64-mingw3
/lib/nokogiri.rb:29:in `rescue in <top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/nokogiri-1.6.6.2-x64-mingw3
/lib/nokogiri.rb:25:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/loofah-2.0.1/lib/loofah.rb:
:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/loofah-2.0.1/lib/loofah.rb:
:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rails-html-sanitizer-1.0.2/
ib/rails-html-sanitizer.rb:2:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rails-html-sanitizer-1.0.2/
ib/rails-html-sanitizer.rb:2:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/sanitize_helper.rb:3:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/sanitize_helper.rb:3:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/text_helper.rb:32:in `<module:TextHelper>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/text_helper.rb:29:in `<module:Helpers>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/text_helper.rb:6:in `<module:ActionView>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/text_helper.rb:4:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/form_tag_helper.rb:18:in `<module:FormTagHelper>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/form_tag_helper.rb:14:in `<module:Helpers>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/form_tag_helper.rb:8:in `<module:ActionView>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/form_tag_helper.rb:6:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/form_helper.rb:4:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers/form_helper.rb:4:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers.rb:50:in `<module:Helpers>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers.rb:4:in `<module:ActionView>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/actionview-4.2.0/lib/action
view/helpers.rb:3:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/legacy_asset_tag_helper.rb:7:in `<module:LegacyAssetTagHelper>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/legacy_asset_tag_helper.rb:6:in `<module:Rails>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/legacy_asset_tag_helper.rb:4:in `<module:Sprockets>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/legacy_asset_tag_helper.rb:3:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/helper.rb:45:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/helper.rb:45:in `<module:Helper>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/helper.rb:7:in `<module:Rails>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/helper.rb:6:in `<module:Sprockets>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/rails/helper.rb:5:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/railtie.rb:6:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sprockets-rails-2.2.4/lib/s
rockets/railtie.rb:6:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sass-rails-5.0.1/lib/sass/r
ils/railtie.rb:2:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sass-rails-5.0.1/lib/sass/r
ils/railtie.rb:2:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sass-rails-5.0.1/lib/sass/r
ils.rb:11:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sass-rails-5.0.1/lib/sass/r
ils.rb:11:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sass-rails-5.0.1/lib/sass-r
ils.rb:1:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/sass-rails-5.0.1/lib/sass-r
ils.rb:1:in `<top (required)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.8.5/lib/bundler/r
ntime.rb:76:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.8.5/lib/bundler/r
ntime.rb:76:in `block (2 levels) in require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.8.5/lib/bundler/r
ntime.rb:72:in `each'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.8.5/lib/bundler/r
ntime.rb:72:in `block in require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.8.5/lib/bundler/r
ntime.rb:61:in `each'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.8.5/lib/bundler/r
ntime.rb:61:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.8.5/lib/bundler.r
:134:in `require'
from C:/Users/USER/Sites/new_cms/config/application.rb:7:in `<top (requ
red)>'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.0/lib/rails/co
mands/commands_tasks.rb:78:in `require'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.0/lib/rails/co
mands/commands_tasks.rb:78:in `block in server'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.0/lib/rails/co
mands/commands_tasks.rb:75:in `tap'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.0/lib/rails/co
mands/commands_tasks.rb:75:in `server'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.0/lib/rails/co
mands/commands_tasks.rb:39:in `run_command!'
from C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/railties-4.2.0/lib/rails/co
mands.rb:17:in `<top (required)>'
from bin/rails:4:in `require'
from bin/rails:4:in `<main>'
C:\Users\USER\Sites\new_cms>
Nokogiri doesn't have binaries for Ruby 2.2.1 available for the mingw32 platform due to some problems with cross compiling Ruby 2.2.1 for the rake-compiler-dev-box.
Since Nokogiri doesn't natively compile on Windows, the only fix is to downgrade to Ruby 2.1.5. Once the next patch level of Ruby 2.2 is released hopefully the problem will be solved.
try to
rvm ruby-2.2.0 gem update --system
Looks like ur nokogiri path broken
ps edited on ur rvm version

Resources