Hi I am planing to switch my development machine from windows to ubuntu. But i am hitting this error
i have ruby -v of 2.0.0p0
on rails s
/home/rigel/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:in `require': cannot load such file -- hitimes/hitimes (LoadError)
from /home/rigel/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:247:in `block in require'
from /home/rigel/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/activesupport-4.1.6/lib/active_support/dependencies.rb:232:in `load_dependency'
updating gem -v did not work for me as intended https://github.com/copiousfreetime/hitimes/issues/17
gem -v 2.4.1
hitimes (1.2.2)
Updates
as suggested by art reinstall gem for me worked
I don't use that at all, but I think it is covered here:
https://github.com/copiousfreetime/hitimes/issues/17
And, according to it, you probably just need to run gem install hitimes to get a version that is works with Ruby 2.0.
Related
Bundler::RubyVersionMismatch: Your Ruby version is 2.3.1, but your Gemfile specified 2.1.8
/opt/chef/embedded/lib/ruby/gems/2.3.0/gems/bundler-1.12.5/lib/bundler/definition.rb:417:in `validate_ruby!'
/opt/chef/embedded/lib/ruby/gems/2.3.0/gems/bundler-1.12.5/lib/bundler.rb:91:in `setup'
/opt/chef/embedded/lib/ruby/gems/2.3.0/gems/bundler-1.12.5/lib/bundler/setup.rb:19:in `<top (required)>'
/opt/chef/embedded/lib/ruby/site_ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
/opt/chef/embedded/lib/ruby/site_ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
bundler: failed to load command: rake (/home/deploy/.bundler/app_name/ruby/2.1.0/bin/rake)
All the places it is showing: 2.1.8
ruby -v ==> 2.1.8
Gemfile has ==> 2.1.8
No idea about where it is taking version 2.3.1 from.
I want to remove 2.3.1 from wherever it is taking it.
Not sure, its an error related to chef setup or ruby installation on server.
Any help would be greatly appreciated.
Your bundle executable apparently is linked to the Ruby shipped with your local Chef installation (which uses Ruby 2.3.1 in this case).
This can happen when chef's executables are in your PATH and you don't have a different version of bundler installed elsewhere.
Assuming that you have a sane PATH, it might be enough to run
gem install bundler
to install the current version of bundler with your own Ruby (that is, the one install in /usr/local rather than in /opt/chef/embedded).
When I run foreman start, I get this error:
~/.rvm/gems/ruby-2.2.3/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require': incompatible library version - ~/.rvm/gems/ruby-2.2.3/gems/rgeo-0.4.0/lib/rgeo/coord_sys/proj4_c_impl.bundle (fatal)
from ~/.rvm/gems/ruby-2.2.3/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `block in require'
from ~/.rvm/gems/ruby-2.2.3/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:240:in `load_dependency'
from ~/.rvm/gems/ruby-2.2.3/gems/activesupport-4.2.4/lib/active_support/dependencies.rb:274:in `require'
from ~/.rvm/gems/ruby-2.2.3/gems/rgeo-0.4.0/lib/rgeo/coord_sys.rb:39:in `<top (required)>'
I've tried rvm gemset empty && bundle install, gem uninstall rgeo && gem install rgeo, other people working on this same project don't have this issue.
Ruby 2.2.3p173 Rails 4.2.4 Gem 2.4.8
What am I doing wrong?
I was running into this issue as well. I would need to know more about your environment, but it might be related to this issue I reported to the RGeo project today: https://github.com/rgeo/rgeo/issues/114
If you're using Homebrew's version of Ruby, you might need to uninstall it and use RVM. There seems to be a conflict when you have both running.
I also committed a patch that might work for you. It basically ensures that if you're using a Ruby Manager, RGeo tries to build with those libraries first. You can see that code here: https://github.com/eddietejeda/rgeo/tree/prioritize_ruby_manager_lib
You can add this to your Gemfile to test it out:
gem 'rgeo', :git => 'git#github.com:eddietejeda/rgeo.git', :branch => 'prioritize_ruby_manager_lib'
Hope this helps!
I'm trying to get up and running following a tutorial but I had tried using the Hartl book about 2 years ago unsuccessfully so now I have all these different things installed that I have no idea where they are, what they are, or how to get rid of them. I don't even remember everything I've installed. I'm on OSX 10.6.8
The tutorial said to do rails new issues so I did that and it said I should see a bunch of things created and then a bundler. I didn't see the bundler. I found some instructions on another SO post and followed them to get this error:
xxxx-xxxx-macbook-pro:issues Ryan$ bundle install
Fetching gem metadata from http://rubygems.org/...........
Fetching gem metadata from http://rubygems.org/..
Resolving dependencies...
Bundler could not find compatible versions for gem "bundler":
In Gemfile:
rails (= 3.0.1) ruby depends on
bundler (~> 1.0.0) ruby
Current Bundler version:
bundler (1.3.5)
This Gemfile requires a different version of Bundler.
Perhaps you need to update Bundler by running `gem install bundler`?
Now if I do rails -v I get this:
/Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/resolver.rb:130:in `block in resolve': Bundler could not find compatible versions for gem "bundler": (Bundler::VersionConflict)
In Gemfile:
rails (= 3.0.1) ruby depends on
bundler (~> 1.0.0) ruby
Current Bundler version:
bundler (1.3.5)
This Gemfile requires a different version of Bundler.
Perhaps you need to update Bundler by running `gem install bundler`?
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/resolver.rb:128:in `catch'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/resolver.rb:128:in `resolve'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/definition.rb:179:in `resolve'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/definition.rb:114:in `specs'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/definition.rb:159:in `specs_for'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/definition.rb:148:in `requested_specs'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/environment.rb:18:in `requested_specs'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler/runtime.rb:13:in `setup'
from /Users/Ryan/.rvm/gems/ruby-1.9.2-p318#rails3tutorial/gems/bundler-1.3.5/lib/bundler.rb:120:in `setup'
from /Library/firstapp/issues/config/boot.rb:8:in `<top (required)>'
from <internal:lib/rubygems/custom_require>:29:in `require'
from <internal:lib/rubygems/custom_require>:29:in `require'
from script/rails:5:in `<main>'
Another SO topic said to see if I have to bundlers installed:
xxxxx-xxxx-macbook-pro:issues Ryan$ gem list bundler
*** LOCAL GEMS ***
bundler (1.3.5, 1.0.22)
So then since 1.0.22 said its being used I removed the 1.3.5
xxxx-xxxx-macbook-pro:issues Ryan$ gem uninstall bundler -v 1.3.5
Successfully uninstalled bundler-1.3.5
Regardless of whether or not I update this I'm getting errors.
I'm so lost. I think rails3tutorial is from over a year ago when I tried that Hartl book and firstapp is where I was trying to put the tutorial I'm now trying. If anyone has any clues I would really love to figure this out. Maybe one day I'll even be able to get past the setup and do something productive on Ruby On Rails.
The problem i propably your outdated rails version (you are using 3.0, with 3.2 being the current version). As a general advice: Try to use the latest version of every gem.
To update your gems/ruby, do a
rvm get stable # see the note at the bottom, if that does not work
rvm install 1.9.3 # may take some time
rvm use 1.9.3 --default
gem install bundler
gem install rails
rails new issues
Note: If rvm get stable does not work, have a look at this SO answer.
Lucky for you, you're using RVM! You can start with a clean slate and not worry about resolving old dependencies. You can install 1.9.3 (you're on 1.9.2), create a clean gemset, and follow the updated tutorial for 3.2 or 4.0. Let me know if you need help with any of this.
You will do something productive with Rails. Persistence is important.
rake aborted!
no such file to load -- sqlite3/sqlite3_native
:33:in require'
<internal:lib/rubygems/custom_require>:33:inrescue in require'
:29:in `require'
i jus keep gettin this error .
info on my system
Ubuntu server 10.04
rails 2.3.8
ruby 1.9.2
sqlite3-ruby 1.3.2 (even installed libsqlite3-ruby1.9.1)
Any solutions on how to deal with this problem .........
have you tried to use a lower version of sqlite3?
do sudo gem uninstall sqlite3-rubyand then do a gem install sqlite3-ruby --version=1.2.5.
I've just upgraded to Rails 3, using the instructions from this railscast. When I try to start the server, this is what happens:
$ rails s
script/rails:6:in `require': no such file to load -- rails/commands (LoadError)
from script/rails:6:in `<main>'
I can't find this exact error using Google. Anyone know what is causing this? Thanks for reading
EDIT:
Here's the console output:
$ rvm 1.9.2
$ rails -v
Rails 3.0.1
$ ruby -v
ruby 1.9.2p0 (2010-08-18 revision 29036) [x86_64-darwin10.4.0]
$ rails new . -d sqlite3
(all the overwrite checking stuff happens here)
$ bundle install
...
Your bundle is complete! It was installed into /Users/ben/.rvm/gems/ruby-1.9.2-p0
$ rails s
script/rails:6:in `require': no such file to load -- rails/commands (LoadError)
from script/rails:6:in `<main>'
$ rvm list
rvm rubies
=> ruby-1.9.2-p0 [ x86_64 ]
$ ruby -v
ruby 1.9.2p0 (2010-08-18 revision 29036) [x86_64-darwin10.4.0]
$ rails -v
script/rails:6:in `require': no such file to load -- rails/commands (LoadError)
from script/rails:6:in `<main>'
Have you actually installed the rails 3.0.x gem? Maybe you missed this step :).
It looks like your script/rails script cannot find the included file from rails gem. You need to install all needed gems separately for each version of Ruby you're using (e.g. 1.8.7 and 1.9.2).
Maybe you can just reinstall your rubygem, or update it.
Rubygem versions should fit to your Ruby versions. For every Ruby version you installed separated Gems needed.
May I ask did you use any 'sudo' with RVM installations? Better to avoid, see here:
http://rvm.beginrescueend.com/rubies/rubygems/
Can you list here please your "gem list" after switched to default Ruby version you want to use? Also "rvm list" "ruby -v" "gem -v" and your OS please.
Also wise to write to forum at the section you downloaded Railscasts' video, because maybe others will have the same problem.