Ruby On Rails gem dependency conflict when install "google-api-client" - google-api-client

I added to Gemfile : gem 'google-api-client', "0.6.4"
1> execute “bundle install”, and got this error:
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies...
Bundler could not find compatible versions for gem "addressable":
In Gemfile:
google-api-client (= 0.6.4) ruby depends on
addressable (>= 2.3.2) ruby
koala (>= 0) ruby depends on
addressable (2.2.8)
2> execute “bundle update koala”, got this error:
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies...
Bundler could not find compatible versions for gem "launchy":
In snapshot (Gemfile.lock):
launchy (2.1.0)
In Gemfile:
google-api-client (= 0.6.4) ruby depends on
launchy (>= 2.1.1) ruby
Running bundle update will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.
What is the core issue of this error?
And how can I solve it?
Thank you.
[Update]
When I execute 'bundle update addressable', got this error:
Fetching gem metadata from https://rubygems.org/........
Fetching gem metadata from https://rubygems.org/..
Resolving dependencies...
Bundler could not find compatible versions for gem "launchy":
In snapshot (Gemfile.lock):
launchy (2.1.0)
In Gemfile:
google-api-client (= 0.6.4) ruby depends on
launchy (>= 2.1.1) ruby
Running bundle update will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.

The version of koala you are using required addressable-2.2.8, but google-api-client wants addressable-2.3.2 or higher. The latest version of koala does not specify a specific version of addressable, so try updating koala:
bundle update koala

Related

Error in installing mongodb plugin in logstash

I am using logstash 7.15.2. I need to connect mongodb in logstash so i am trying to install logstash-input-sqlite and logstash-input-mongodb. I have successfully installed logstash-input-sqlite. Facing error in mongodb plugin.
Error:
>logstash-plugin install logstash-input-mongodb
Using JAVA_HOME defined java: C:\Program Files\Java\jdk1.8.0_191
WARNING, using JAVA_HOME while Logstash distribution comes with a bundled JDK
Validating logstash-input-mongodb
Resolving mixin dependencies
Installing logstash-input-mongodb
Plugin version conflict, aborting
ERROR: Installation Aborted, message: Bundler could not find compatible versions for gem "jdbc-sqlite3":
In snapshot (Gemfile.lock):
jdbc-sqlite3 (= 3.28.0)
In Gemfile:
logstash-input-mongodb was resolved to 0.4.1, which depends on
jdbc-sqlite3 (= 3.8.10.1)
logstash-input-sqlite was resolved to 3.0.4, which depends on
jdbc-sqlite3
Running `bundle update` will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.
Bundler could not find compatible versions for gem "logstash":
In Gemfile:
logstash-input-mongodb was resolved to 0.1.1, which depends on
logstash (< 2.0.0, >= 1.4.0)
Could not find gem 'logstash (< 2.0.0, >= 1.4.0)', which is required by gem 'logstash-input-mongodb', in rubygems repository https://rubygems.org/ or installed locally.
Bundler could not find compatible versions for gem "logstash-input-mongodb":
In Gemfile:
logstash-input-mongodb

Two versions of the same gem required in Jekyll

I'm working through a gem problem with Jekyll. On adding the plugin amp-jekyll, I got this error:
Bundler could not find compatible versions for gem "fastimage":
In Gemfile:
amp-jekyll was resolved to 1.0.2, which depends on
fastimage (>= 1.8.0)
jekyll-picture-tag was resolved to 0.3.0, which depends on
fastimage (~> 1.6.4)
fastimage is tied to jekyll-picture-tag, which is on its more recent version. amp-jekyll won't go any lower than 1.8.0. I've tried rebuilding and updating this a few ways, but I'm stumped. any thoughts?
Figured it out - I thought I'd have to get a vendor folder set up, but all I needed to do was fork the gem, update the dependency (pessimistic to optimistic) and reference it in my gemfile, as in Forking a gem for a Rails project ; it's an older answer, but effective.

Mongify Ubuntu 14.04 installing error

I am trying to install mongify in my Ubuntu 14 box, but its throwing some error:
gem install mongify
ERROR: While executing gem ... (Gem::DependencyError)
Unable to resolve dependencies: mongify requires bson (>= 1.10.2); bson_ext requires bson (~> 1.12.5); mongo requires bson (~> 4.0)
I already have installed mongo db in my machine, which is working fine. Is there a seperate package needed to be installed for BSON?
Figured it out, So ubuntu 14 has an inbuilt ruby, which is a lower version. We need a higher version of that. So what we have to do is create an virenv with the higher version.
1.)Install ruby. Follow the steps in this link
https://gorails.com/setup/ubuntu/14.04 (Install using rvm method)
2.) Install Bundler.
gem install bundler
3.) Install mongify
gem install mongify

How map mongodb on ruby and rails

I am practice on ruby on rails 4 and using mongodb database,I am trying to work follow this site to connect database : http://mongoid.org/en/mongoid/docs/documents.html
However, when I worked this step this occur error:
rails g mongoid:config
error:
Bundler could not find compatible versions for gem "activemodel":
In snapshot (Gemfile.lock):
activemodel (4.1.1)
In Gemfile:
mongoid (~> 3.1.6) x86-mingw32 depends on
activemodel (~> 3.2) x86-mingw32
Running `bundle update` will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.
I am also try the command bundel update but it has that error:
sorry I am new bie on ruby and rails and mongodb, so I hope there is any easy guide to follow.
thankyou
Try skipping ActiveRecord when creating your app.
rails new my_app -O
I had this problem using the following:
gem 'rails', '4.1.1'
gem 'mongoid', '~> 4.0.0'
Skipping ActiveRecord solved that error.

heroku deployment error : bundler version

I have ruby 1.9.2 and rails 3.0.0 with bundler 1.0.22
when I push to heroku, I get
-----> Installing dependencies using Bundler version 1.1.rc.7
Running: bundle install --without development:test --path vendor/bundle -
-binstubs bin/
Fetching gem metadata from http://rubygems.org/.........
Bundler could not find compatible versions for gem "bundler":
In Gemfile:
rails (= 3.0.0) ruby depends on
bundler (~> 1.0.0) ruby
Current Bundler version:
bundler (1.1.rc.7)
This Gemfile requires a different version of Bundler.
Perhaps you need to update Bundler by running `gem install bundler`?
why does it use bundler version 1.1.rc.7 to install the dependencies and
why does it think the current bundler version is 1.1.rc.7?
No references in the .Gemfile or the Gemfile.lock to any version.
Any input appreciated.
-Thanks
If you have the following lines in your Gemfile.lock:
PLATFORMS
x86-mingw32
be sure to delete them. And don't forget to use:
git add Gemfile Gemfile.lock