Почему зависимость Фарадея не разрешается компоновщиком? - PullRequest
0 голосов
/ 26 июня 2018

Я добавил gem 'bitfinex-rb' в файл geils rails. Когда я выполняю установку комплекта, я получил указанную ниже ошибку:

Bundler could not find compatible versions for gem "faraday":
In snapshot (Gemfile.lock):
  faraday (= 0.14.0)

In Gemfile:
  bitfinex-rb was resolved to 0.1.0, which depends on
  faraday (>= 0.9.2, ~> 0.9.2)

kucoin was resolved to 0.1.1, which depends on
  faraday (>= 0.13)

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 "actionpack":
      In Gemfile:
        lograge (~> 0.3.1) was resolved to 0.3.6, which depends on
          actionpack (>= 3)

        pretender was resolved to 0.3.2, which depends on
          actionpack

        rails (~> 5.1.5) was resolved to 5.1.6, which depends on
          actionpack (= 5.1.6)

        rspec-rails (~> 3.6) was resolved to 3.7.2, which depends on
          actionpack (>= 3.0)

        simple_form was resolved to 4.0.1, which depends on
          actionpack (>= 5.0)

    Bundler could not find compatible versions for gem "actionview":
      In Gemfile:
        rails (~> 5.1.5) was resolved to 5.1.6, which depends on
          actionview (= 5.1.6)

        web-console was resolved to 3.6.2, which depends on
          actionview (>= 5.0)

    Bundler could not find compatible versions for gem "activemodel":
      In Gemfile:
        dynamoid (~> 2) was resolved to 2.2.0, which depends on
          activemodel (>= 4)

        paperclip (~> 5.3.0) was resolved to 5.3.0, which depends on
          activemodel (>= 4.2.0)

        rails (~> 5.1.5) was resolved to 5.1.6, which depends on
          activemodel (= 5.1.6)

        simple_form was resolved to 4.0.1, which depends on
          activemodel (>= 5.0)

    Bundler could not find compatible versions for gem "activerecord":
      In Gemfile:
        annotate was resolved to 2.7.4, which depends on
          activerecord (< 6.0, >= 3.2)

        rails (~> 5.1.5) was resolved to 5.1.6, which depends on
          activerecord (= 5.1.6)

        rails-erd was resolved to 1.5.2, which depends on
          activerecord (>= 3.2)

    Bundler could not find compatible versions for gem "activesupport":
      In Gemfile:
        bullet was resolved to 5.7.5, which depends on
          activesupport (>= 3.0.0)

        formulaic was resolved to 0.4.0, which depends on
          activesupport

        lograge (~> 0.3.1) was resolved to 0.3.6, which depends on
          activesupport (>= 3)

        paperclip (~> 5.3.0) was resolved to 5.3.0, which depends on
          activesupport (>= 4.2.0)

        rails (~> 5.1.5) was resolved to 5.1.6, which depends on
          activesupport (= 5.1.6)

        rails-erd was resolved to 1.5.2, which depends on
          activesupport (>= 3.2)

        rspec-rails (~> 3.6) was resolved to 3.7.2, which depends on
          activesupport (>= 3.0)

        shoulda-matchers was resolved to 3.1.2, which depends on
          activesupport (>= 4.0.0)

        spring was resolved to 2.0.2, which depends on
          activesupport (>= 4.2)

        time_difference was resolved to 0.7.0, which depends on
          activesupport (~> 5.1)

    Bundler could not find compatible versions for gem "aws-sdk-resources":
      In Gemfile:
        aws-sdk (= 2.10.47) was resolved to 2.10.47, which depends on
          aws-sdk-resources (= 2.10.47)

        dynamoid (~> 2) was resolved to 2.2.0, which depends on
          aws-sdk-resources (~> 2)

    Bundler could not find compatible versions for gem "faraday":
      In Gemfile:
        bitfinex-rb was resolved to 0.1.0, which depends on
          faraday (>= 0.9.2, ~> 0.9.2)

        kucoin was resolved to 0.1.1, which depends on
          faraday (>= 0.13)

    Bundler could not find compatible versions for gem "json":
      In Gemfile:
        bitfinex-rb was resolved to 0.1.0, which depends on
          json (>= 1.8.3, ~> 1.8.3)

        cryptocompare was resolved to 0.14.0, which depends on
          json

        simplecov was resolved to 0.16.1, which depends on
          json (< 3, >= 1.8)

    Bundler could not find compatible versions for gem "rails":
      In Gemfile:
        rails (~> 5.1.5)

        devise_token_auth was resolved to 0.1.43, which depends on
          rails (< 6)

        sparkpost_rails was resolved to 1.5.1, which depends on
          rails (< 5.3, >= 4.0)

        suspenders was resolved to 1.45.0, which depends on
          rails (~> 5.1.3)

        title was resolved to 0.0.7, which depends on
          rails (>= 3.1)

    Bundler could not find compatible versions for gem "railties":
      In Gemfile:
        devise_token_auth was resolved to 0.1.43, which depends on
          devise (< 4.5, > 3.5.2) was resolved to 4.4.3, which depends on
            railties (< 6.0, >= 4.1.0)

        dotenv-rails was resolved to 2.5.0, which depends on
          railties (< 6.0, >= 3.2)

        factory_bot_rails was resolved to 4.10.0, which depends on
          railties (>= 3.0.0)

        jquery-rails was resolved to 4.3.3, which depends on
          railties (>= 4.2.0)

        lograge (~> 0.3.1) was resolved to 0.3.6, which depends on
          railties (>= 3)

        rails (~> 5.1.5) was resolved to 5.1.6, which depends on
          railties (= 5.1.6)

        rspec-rails (~> 3.6) was resolved to 3.7.2, which depends on
          railties (>= 3.0)

        sass-rails (~> 5.0) was resolved to 5.0.7, which depends on
          railties (< 6, >= 4.0.0)

        web-console was resolved to 3.6.2, which depends on
          railties (>= 5.0)

    Bundler could not find compatible versions for gem "ruby":
      In Gemfile:
        ruby

    suspenders was resolved to 1.46.0, which depends on
          ruby (>= 2.5.0)  

Я попытался удалить Gemfile.lock и установленный пакет, но получил выше перечисленную ошибку.Что может быть решением для этого типа сценария.Спасибо всем.

1 Ответ

0 голосов
/ 29 июня 2018

Это потому, что kucoin 0.1.1 требует фарадея> = 0.13, а bitfinex-rb 0.1.0 требует фарадея ~> 0.9.2 (поэтому> = 0.9.2 и <= 0.10).По крайней мере, в Ruby Gems нет более высокой версии bitfinex-rb, чтобы вы могли ее обновить.А другая версия kucoin (0.1.0) также требует фарадея> = 0.13.Поэтому вы не можете установить оба гема (kucoin и bitfinex-rb) одновременно из-за зависимости.Bundle пытается разрешить зависимости, но он может сделать это только если это возможно.

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...