Getting error while running rake routes. Please suggest.
$ rake routes
rake aborted!
LoadError: incompatible library version -
/home/latei/.rvm/gems/ruby-2.4.1/gems/sqlite3-1.3.13/lib/sqlite3/sqlite3_native.so
/home/latei/.rvm/gems/ruby-2.4.1/gems/sqlite3-1.3.13/lib/sqlite3.rb:6:in
`require'
/home/latei/.rvm/gems/ruby-2.4.1/gems/sqlite3-1.3.13/lib/sqlite3.rb:6:in
`rescue in <top (required)>'
/home/latei/.rvm/gems/ruby-2.4.1/gems/sqlite3-1.3.13/lib/sqlite3.rb:2:in
`<top (required)>'
/home/latei/Desktop/rails/alpha-blog/config/application.rb:7:in `<top
(required)>' /home/latei/Desktop/rails/alpha-blog/Rakefile:4:in
`require_relative' /home/latei/Desktop/rails/alpha-blog/Rakefile:4:in
`<top (required)>'
/home/latei/.rvm/gems/ruby-2.4.1#global/gems/rake-12.0.0/exe/rake:27:in
`<top (required)>' LoadError: cannot load such file --
sqlite3/2.3/sqlite3_native
/home/latei/.rvm/gems/ruby-2.4.1/gems/sqlite3-1.3.13/lib/sqlite3.rb:4:in
`require'
/home/latei/.rvm/gems/ruby-2.4.1/gems/sqlite3-1.3.13/lib/sqlite3.rb:4:in
`<top (required)>'
/home/latei/Desktop/rails/alpha-blog/config/application.rb:7:in `<top
(required)>' /home/latei/Desktop/rails/alpha-blog/Rakefile:4:in
`require_relative' /home/latei/Desktop/rails/alpha-blog/Rakefile:4:in
`<top (required)>'
/home/latei/.rvm/gems/ruby-2.4.1#global/gems/rake-12.0.0/exe/rake:27:in
`<top (required)>' (See full trace by running task with --trace)
It appears that you may be lacking the necessary development library required to use the sqlite gem.
In debian this can be installed using the following command:
sudo apt-get install libsqlite-3
I am not sure, but I think the problem is in your gem version, Try this one:
gem 'sqlite3', '~> 1.3', '>= 1.3.10'
and then $ bundle install
Related
I have this versions, and I cannot change the ruby and rail versions
ruby version - 1.9.2-p290
rail version - 3.0.9
mysql2 version - 0.2.9
when I try to run rails server command on Ubuntu, I am getting this error
rake aborted!
Bundler::GemRequireError: There was an error while trying to load the gem 'mysql2'.
Gem Load Error is: uninitialized constant Mysql2::Client::SECURE_CONNECTION
Backtrace for gem load error is:
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/mysql2-0.2.9/lib/mysql2/client.rb:12:in `<class:Client>'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/mysql2-0.2.9/lib/mysql2/client.rb:2:in `<module:Mysql2>'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/mysql2-0.2.9/lib/mysql2/client.rb:1:in `<top (required)>'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/mysql2-0.2.9/lib/mysql2.rb:9:in `<top (required)>'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/bundler-1.15.4/lib/bundler/runtime.rb:82:in `require'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/bundler-1.15.4/lib/bundler/runtime.rb:82:in `block (2 levels) in require'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/bundler-1.15.4/lib/bundler/runtime.rb:77:in `each'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/bundler-1.15.4/lib/bundler/runtime.rb:77:in `block in require'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/bundler-1.15.4/lib/bundler/runtime.rb:66:in `each'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/bundler-1.15.4/lib/bundler/runtime.rb:66:in `require'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/bundler-1.15.4/lib/bundler.rb:108:in `require'
/home/xyz/Documents/trailtap-api/config/application.rb:9:in `<top (required)>'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/home/xyz/Documents/trailtap-api/Rakefile:4:in `<top (required)>'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/rake_module.rb:28:in `load'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/rake_module.rb:28:in `load_rakefile'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/application.rb:689:in `raw_load_rakefile'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/application.rb:94:in `block in load_rakefile'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/application.rb:176:in `standard_exception_handling'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/application.rb:93:in `load_rakefile'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/application.rb:77:in `block in run'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/application.rb:176:in `standard_exception_handling'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/lib/rake/application.rb:75:in `run'
/home/xyz/.rbenv/versions/1.9.2-p290/lib/ruby/gems/1.9.1/gems/rake-10.5.0/bin/rake:33:in `<top (required)>'
/home/xyz/.rbenv/versions/1.9.2-p290/bin/rake:23:in `load'
/home/xyz/.rbenv/versions/1.9.2-p290/bin/rake:23:in `<main>'
Bundler Error Backtrace:
/home/xyz/Documents/trailtap-api/config/application.rb:9:in `<top (required)>'
/home/xyz/Documents/trailtap-api/Rakefile:4:in `<top (required)>'
(See full trace by running task with --trace)
I thought gem file needed to be update so I updated it but then mysql2 doesnot support rail version and doesnot ship active record adapter, even after installing adapter gem it fails.
Thanks in advance.
Check this article: uninitialized constant Mysql2::Client::SECURE_CONNECTION
Solution was to upgrade mysql2. In your case, might be worth trying downgrading the that version and see if it fixes your issue.
Also, make sure that libmysqlclient-dev and ruby-mysql are installed and up-to-date
Try
gem 'rails', '3.0.9'
gem 'mysql2', "0.2.24"
I'm learning ruby on rails on windows platform in windows 8. Now I'm in the database part where rake db:schema:dump command should create a file in config folder named schema.rb, but that's not happening. When I'm typing rake db:schema:dump it shows rake aborted and a long list. Please help.
Here is what shows up in console:
C:\Users\New User\sites2\learning_rails>rake db:schema;dump
rake aborted!
Bundler::GemRequireError: There was an error while trying to load the gem 'uglif
ier'.
Gem Load Error is: Could not find a JavaScript runtime. See https://github.com/r
ails/execjs for a list of available runtimes.
Backtrace for gem load error is:
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/execjs-2.7.0/lib/execjs/runtimes.rb:58:in
`autodetect'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/execjs-2.7.0/lib/execjs.rb:5:in `<module:
ExecJS>'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/execjs-2.7.0/lib/execjs.rb:4:in `<top (re
quired)>'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/uglifier-3.0.0/lib/uglifier.rb:5:in `requ
ire'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/uglifier-3.0.0/lib/uglifier.rb:5:in `<top
(required)>'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:86:
in `require'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:86:
in `block (2 levels) in require'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:81:
in `each'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:81:
in `block in require'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:70:
in `each'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler/runtime.rb:70:
in `require'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/bundler-1.12.5/lib/bundler.rb:102:in `req
uire'
C:/Users/New User/sites2/learning_rails/config/application.rb:7:in `<top (requir
ed)>'
C:/Ruby22-x64/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:55:in
`require'
C:/Ruby22-x64/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:55:in
`require'
C:/Users/New User/sites2/learning_rails/Rakefile:4:in `<top (required)>'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/rake_module.rb:28:in
`load'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/rake_module.rb:28:in
`load_rakefile'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:689:i
n `raw_load_rakefile'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:94:in
`block in load_rakefile'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:176:i
n `standard_exception_handling'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:93:in
`load_rakefile'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:77:in
`block in run'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:176:i
n `standard_exception_handling'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/lib/rake/application.rb:75:in
`run'
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/rake-11.1.2/bin/rake:33:in `<top (require
d)>'
C:/Ruby22-x64/bin/rake:22:in `load'
C:/Ruby22-x64/bin/rake:22:in `<main>'
Bundler Error Backtrace:
C:/Users/New User/sites2/learning_rails/config/application.rb:7:in `<top (requir
ed)>'
C:/Users/New User/sites2/learning_rails/Rakefile:4:in `<top (required)>'
ExecJS::RuntimeUnavailable: Could not find a JavaScript runtime. See https://git
hub.com/rails/execjs for a list of available runtimes.
C:/Users/New User/sites2/learning_rails/config/application.rb:7:in `<top (requir
ed)>'
C:/Users/New User/sites2/learning_rails/Rakefile:4:in `<top (required)>'
(See full trace by running task with --trace)
install nodejs
Uglifier is JavaScript compressor, so it need javascript runtime try installing nodejs
apt-get install nodejs
or
brew install nodejs
if you are on a OSX.
I get this error when ever I run this command rails g mongoid:config. Does anybody have any idea
/home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug/history.rb:1:in `require': cannot load such file -- readline (LoadError)
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug/history.rb:1:in `<top (required)>'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug/interface.rb:1:in `require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug/interface.rb:1:in `<top (required)>'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug/core.rb:5:in `require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug/core.rb:5:in `<top (required)>'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug.rb:1:in `require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/byebug-3.5.1/lib/byebug.rb:1:in `<top (required)>'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/bundler-1.8.3/lib/bundler/runtime.rb:76:in `require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/bundler-1.8.3/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/bundler-1.8.3/lib/bundler/runtime.rb:72:in `each'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/bundler-1.8.3/lib/bundler/runtime.rb:72:in `block in require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/bundler-1.8.3/lib/bundler/runtime.rb:61:in `each'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/bundler-1.8.3/lib/bundler/runtime.rb:61:in `require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/bundler-1.8.3/lib/bundler.rb:134:in `require'
from /home/gardezi/blog/config/application.rb:7:in `<top (required)>'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/spring-1.3.3/lib/spring/application.rb:82:in `require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/spring-1.3.3/lib/spring/application.rb:82:in `preload'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/spring-1.3.3/lib/spring/application.rb:143:in `serve'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/spring-1.3.3/lib/spring/application.rb:131:in `block in run'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/spring-1.3.3/lib/spring/application.rb:125:in `loop'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/spring-1.3.3/lib/spring/application.rb:125:in `run'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/gems/2.1.0/gems/spring-1.3.3/lib/spring/application/boot.rb:18:in `<top (required)>'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /home/gardezi/.rbenv/versions/2.1.5/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from -e:1:in `<main>'
The commands that I ran are as followed below:
gem install mongoid
rails new blog
gedit /blog/Gemfile
in which I wrote
gem 'mongoid', '4.0.2'
gem 'bson_ext'
and then I ran bundle
and then rails g mongoid:config
Thanks to Shweta the rails g command is not giving an error now but now I am encountering another problem and that is when ever I run this command it's running in infinite loop. It's been seven hours and still running so please tell me what should I do.
THANKS IN ADVANCE
I solved the problem. I just needed to stop the spring.
Follow following steps:
1] Skip active-record while creating new project
rails new blog -O
2] open Gemfile add gem 'mongoid'. No need to add gem 'bson_ext'
gem 'mongoid'
3] Install bundle
bundle install
4] Generate mongoid config file
rails g mongoid:config
Hope this helps.
>: rails generate rspec:install
/Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481/gems/rspec-core-3.1.7/lib/rspec/core/formatters/base_formatter.rb:1:in `<top (required)>': uninitialized constant RSpec (NameError)
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481/gems/allure-rspec-0.6.7/lib/allure-rspec/formatter.rb:1:in `require'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481/gems/allure-rspec-0.6.7/lib/allure-rspec/formatter.rb:1:in `<top (required)>'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481/gems/allure-rspec-0.6.7/lib/allure-rspec.rb:3:in `require'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481/gems/allure-rspec-0.6.7/lib/allure-rspec.rb:3:in `<top (required)>'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481#global/gems/bundler-1.6.2/lib/bundler/runtime.rb:76:in `require'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481#global/gems/bundler-1.6.2/lib/bundler/runtime.rb:76:in `block (2 levels) in require'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481#global/gems/bundler-1.6.2/lib/bundler/runtime.rb:72:in `each'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481#global/gems/bundler-1.6.2/lib/bundler/runtime.rb:72:in `block in require'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481#global/gems/bundler-1.6.2/lib/bundler/runtime.rb:61:in `each'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481#global/gems/bundler-1.6.2/lib/bundler/runtime.rb:61:in `require'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481#global/gems/bundler-1.6.2/lib/bundler.rb:132:in `require'
from /Users/prashanth_sams/Desktop/MAC/blog/config/application.rb:7:in `<top (required)>'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481/gems/railties-3.2.16/lib/rails/commands.rb:24:in `require'
from /Users/prashanth_sams/.rvm/gems/ruby-2.0.0-p481/gems/railties-3.2.16/lib/rails/commands.rb:24:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
I tried the below cmd in Terminal
bundle exec rails generate rspec:install
but no luck :(
Placed the below in my Gemfile
group :test, :development do
gem 'rspec-rails', '~> 3.1.0'
end
May be the version of Rspec is incompatible: downgrade the version of rspec or just write:
gem 'rspec-rails'
then you can update it:
bundle update rspec-rails
I am able to create the spec folder and spec_helper.rb using
rspec --init
This is the error log that the command line shows when I run the bundler and Rails commands:
Users/MeksProper1/Desktop/kickthelistmaster/config/application.rb:7:in `<top (required)>': uninitialized constant Bundler (NameError)
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:126:in `require'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:126:in `require'
from /usr/local/rvm/gems/ruby-2.0.0-p247#global/gems/railties-4.0.0/lib/rails/commands.rb:76:in `block in <top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247#global/gems/railties-4.0.0/lib/rails/commands.rb:73:in `tap'
from /usr/local/rvm/gems/ruby-2.0.0-p247#global/gems/railties-4.0.0/lib/rails/commands.rb:73:in `<top (required)>'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:135:in `require'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:135:in `rescue in require'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:144:in `require'
from bin/rails:4:in `<main>'
Mekatron:kickthelistmaster MeksProper1$ rails server
/Users/MeksProper1/Desktop/kickthelistmaster/config/application.rb:7:in `<top (required)>': uninitialized constant Bundler (NameError)
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:126:in `require'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:126:in `require'
from /usr/local/rvm/gems/ruby-2.0.0-p247#global/gems/railties-4.0.0/lib/rails/commands.rb:76:in `block in <top (required)>'
from /usr/local/rvm/gems/ruby-2.0.0-p247#global/gems/railties-4.0.0/lib/rails/commands.rb:73:in `tap'
from /usr/local/rvm/gems/ruby-2.0.0-p247#global/gems/railties-4.0.0/lib/rails/commands.rb:73:in `<top (required)>'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:135:in `require'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:135:in `rescue in require'
from /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_require.rb:144:in `require'
from bin/rails:4:in `<main>'
It seems like you might not have Bundler installed correctly or if you do, maybe an earlier version. I would try
gem install bundler
Looks like you haven't install bundler. Try this:
gem install bundler