Getting error while installing lincache19 in rails project - ruby-on-rails

i am using ruby 1.8.7 and rails 3.0.12 for my project.
when i run "bundle install", i get the following error.
Gem::InstallError: linecache19 requires Ruby version >= 1.9.2.
An error occurred while installing linecache19 (0.5.12), and Bundler cannot continue.
i don't want to change my ruby version.

You can try using the debugger gem instead of ruby-debug. Check out your gemfile and replace gem "ruby-debug" with gem "debugger". From memory that's how I did it.

Replacing gem 'ruby-debug19' with gem 'ruby-debug' worked for me.

Related

Globalid and pg not existing when in gemfile

I am trying to rails server from a cloned repo, I have updated ruby, and rails, followed the rvm process, updated all my gem files, and when I go to serve I receive the message
Could not find globalid-0.3.7 in any of the sources Run bundle
install to install missing gems.
So I do bundle install, then get the error
An error occurred while installing pg (0.20.0), and Bundler cannot
continue. Make sure that gem install pg -v '0.20.0' succeeds before
bundling.
Try to insall that and then get
ERROR: Could not find a valid gem 'globalid-0.3.7' (>= 0) in any
repository ERROR: Possible alternatives: globalid, globalize3
I have googled everything and asked many.
globalid is a dependency of the Rails core gem ActiveJob so it is a required gem to have in your Gemfile.lock. See if it is listed in your Gemfile.lock file. If not you could add it to the top of your gemfile including the version
# gemfile
gem 'globalid', '0.3.7'
Then bundle install. If it works, then you can delete it from your gemfile since it should load automatically when Rails loads (since it is a dependency of Rails' ActiveJob). I've run into a similar issue with another gem and this process worked for me.
It could be a version error. Try using gem 'globalid', '~> 0.4.0' in your gemfile and bundling.

Error While installing rails, i18n requires Ruby version >= 1.9.3 [duplicate]

How can I correct this "i18n requires Ruby version >= 1.9.3" I get when I run "bundler install"?
Background: Need to use ruby 1.8.7 on dreamhost, so have targeted Rails v3.2 for this.
Command Line
Gregs-MacBook-Pro:weekends Greg$ ruby -v
ruby 1.8.7 (2013-12-22 patchlevel 375) [i686-darwin14.1.0]
Gregs-MacBook-Pro:weekends Greg$ bundler -v
Bundler version 1.9.2
Gregs-MacBook-Pro:weekends Greg$ bundler install
Fetching gem metadata from https://rubygems.org/..........
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Resolving dependencies............
Using rake 10.4.2
Gem::InstallError: i18n requires Ruby version >= 1.9.3.
An error occurred while installing i18n (0.7.0), and Bundler cannot continue.
Make sure that `gem install i18n -v '0.7.0'` succeeds before bundling.
Gregs-MacBook-Pro:weekends Greg$
Gregs-MacBook-Pro:weekends Greg$ gem install i18n -v '0.7.0'
ERROR: Error installing i18n:
i18n requires Ruby version >= 1.9.3.
Gem File
gem 'rails', '3.2' # Dreamhost is Ruby 1.8.7. Rails 3.2 requires at least Ruby 1.8.7
gem 'sqlite3'
gem 'haml'
gem 'haml-rails'
gem 'omniauth-google-oauth2'
gem 'google-api-client', :require => 'google/api_client'
gem 'jquery-rails'
gem 'figaro'
gem 'rest-client'
You could try to downgrade I18n's version to 0.6.11, because that seems to be the latest version that does not require Ruby 1.9.3. To do so add this to your Gemfile
gem 'i18n', '0.6.11'
and try to run bundle install again.
Furthermore, I suggest upgrading your Ruby and Rails versions. They are both outdated. At least you could try to run Rails 3.2 with a version of Ruby that allows the new syntax. Otherwise, you will face this kind of problems with many other gems too and - more important - you will not be able to install all the security fixes there were released during the last years.

An error occurred while installing refile (0.6.2)

I can't install refile gem from cloned repo on my local.
in my Gemfile:
gem "refile", require: "refile/rails"
gem "refile-mini_magick"
and after running bundle install --without production
i got this error:
Any help?
Check ruby current and default version. rvm list
Make default your ruby 2.2.3 version rvm use 2.2.3 --default
Close terminal and go back to your project directory.

bundler install getting "i18n requires Ruby version >= 1.9.3"

How can I correct this "i18n requires Ruby version >= 1.9.3" I get when I run "bundler install"?
Background: Need to use ruby 1.8.7 on dreamhost, so have targeted Rails v3.2 for this.
Command Line
Gregs-MacBook-Pro:weekends Greg$ ruby -v
ruby 1.8.7 (2013-12-22 patchlevel 375) [i686-darwin14.1.0]
Gregs-MacBook-Pro:weekends Greg$ bundler -v
Bundler version 1.9.2
Gregs-MacBook-Pro:weekends Greg$ bundler install
Fetching gem metadata from https://rubygems.org/..........
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Resolving dependencies............
Using rake 10.4.2
Gem::InstallError: i18n requires Ruby version >= 1.9.3.
An error occurred while installing i18n (0.7.0), and Bundler cannot continue.
Make sure that `gem install i18n -v '0.7.0'` succeeds before bundling.
Gregs-MacBook-Pro:weekends Greg$
Gregs-MacBook-Pro:weekends Greg$ gem install i18n -v '0.7.0'
ERROR: Error installing i18n:
i18n requires Ruby version >= 1.9.3.
Gem File
gem 'rails', '3.2' # Dreamhost is Ruby 1.8.7. Rails 3.2 requires at least Ruby 1.8.7
gem 'sqlite3'
gem 'haml'
gem 'haml-rails'
gem 'omniauth-google-oauth2'
gem 'google-api-client', :require => 'google/api_client'
gem 'jquery-rails'
gem 'figaro'
gem 'rest-client'
You could try to downgrade I18n's version to 0.6.11, because that seems to be the latest version that does not require Ruby 1.9.3. To do so add this to your Gemfile
gem 'i18n', '0.6.11'
and try to run bundle install again.
Furthermore, I suggest upgrading your Ruby and Rails versions. They are both outdated. At least you could try to run Rails 3.2 with a version of Ruby that allows the new syntax. Otherwise, you will face this kind of problems with many other gems too and - more important - you will not be able to install all the security fixes there were released during the last years.

"Bundle install" fails with "thin", and cannot point a different "eventmachine"

I work with Ruby 1.9.3 on Windows.
**I have a trouble to do "bundle install" due to a "thin" gem, for my app.
My original GEMFILE looks like this:
gem "sinatra"
gem "mogli"
gem "json"
gem "httparty"
gem "thin"
Running "bundle install" causes Installing eventmachine (0.12.10) with native extensions which fails. Error is described here: Cannot install thin on windows
Just to mention that "gem install thin" is successful!
Some people on the net, facing this issue, suggested to install
"eventmachine" version 1.0.0.beta.4.1 which I did:
gem list --local shows eventmachine (1.0.0.beta.4.1 x86-mingw32, 1.0.0.beta.2 x86-mingw32)
Yet "bundle install" fails.
In another post: ROR 3.1: Bundle update fails (eventmachine gem)
I followed the advise to specify the exact version of "eventmachine" in GEMFILE, so I edited it like (hopefully I did it right)
gem "sinatra"
gem "mogli"
gem "json"
gem "httparty"
gem "eventmachine" "1.0.0.beta.4.1"
gem "thin"
Now, "bundle install" fails with a different error:
Could not find gem 'eventmachine1.0.0.beta.4.1 (>= 0) ruby' in any of the gem sources listed in your Gemfile.
As I mentioned, this version was successfully installed, and it appears in the local repository.
Please help to make "bundle" "happy" with the right 'eventmachine' version.
Sorry if I missed something basic, or failed to find answer already published.
I think you are missing a comma in this line of the last Gemfile:
gem "eventmachine", "1.0.0.beta.4.1"

Resources