【问题标题】:bundle install circular dependencies捆绑安装循环依赖项
【发布时间】:2012-03-22 22:42:22
【问题描述】:

以下控制台日志应描述问题

bundle install
Could not find multi_json-1.1.0 in any of the sources
Run `bundle install` to install missing gems.

捆绑安装要求我捆绑安装。

试过了:https://github.com/mpapis/rubygems-bundler/issues/4
看了看:https://github.com/carlhuda/bundler/issues/865

不知道下一步该去哪里。

同样有趣的是,如果我们评论 vendor/gems 中的所有 gem,则捆绑包可以正常工作。

来源“http://rubygems.org”

gem 'rails', '~> 3.2.2'

gem 'mysql2'
gem 'thin'

# Asset template engines
gem 'coffee-script'
gem 'uglifier'
gem 'sprockets'
gem 'less-js'
gem 'execjs'
gem 'nokogiri'
gem 'lucy'
gem 'babilu'
gem 'simple_form'
gem 'mechanize'
gem 'geoip'
gem 'less'
gem 'bb-ruby'
gem 'client_side_validations', "~> 3.2.0.beta.2"
gem 'client_side_validations-simple_form'
gem 'require_all'

#for avatars
gem 'paperclip'

gem 'rmagick'
gem "multipart-post"
gem 'gibberish'
# Memcached client
gem 'dalli'

#to support tables without auto-incrementing primary keys
gem 'composite_primary_keys', "~> 5.0.1"

gem 'calendar_helper', :require => 'calendar_helper'

gem 'jquery-rails'

gem 'capistrano'
gem 'capistrano-ext'

gem 'simple_form'
gem 'htmlentities'
gem 'will_paginate'

gem 'airbrake', :path => "vendor/gems/airbrake"

gem "uservoice", :path => "vendor/gems/uservoice"

# For spambots
gem "honeypot-captcha"

# Internationalization GUI
gem "tolk", :git => "http://github.com/miloops/tolk.git", :branch => "rails31"
gem "will-paginate-i18n"

gem "omniauth"
gem "omniauth-facebook"
gem "omniauth-justintv", :git => 'http://github.com/themindoverall/omniauth-justintv.git'
gem 'oauth'

gem 'rails-i18n'

# For rate limiting
gem "rack-throttle", :path => "vendor/gems/rack-throttle"

gem "xfire-api", :path => "vendor/gems/xfire-api"
gem "anametrix", :path => "vendor/gems/anametrix"

#To make ruby debug work see: http://stackoverflow.com/questions/6438116/rails-with-ruby-debugger-throw-symbol-not-found-ruby-current-thread-loaderro
group :development, :test do
  #gem 'ruby-debug-base19', '0.11.26', :path => "~/.rvm/gems/ruby-1.9.3-p#{RUBY_PATCHLEVEL}/gems/ruby-debug-base19-0.11.26/"
  #gem 'linecache19', '0.5.13', :path => "~/.rvm/gems/ruby-1.9.3-p#{RUBY_PATCHLEVEL}/gems/linecache19-0.5.13/"
  #gem 'ruby-debug19', :require => 'ruby-debug'
  gem 'ruby_parser'
end

group :test do
  gem 'ruby-prof'
  gem 'test-unit' # For performance testing

  gem 'turn', :require => false
  gem 'factory_girl_rails', "~> 1.0.1"
  gem 'capybara', "~> 1.0.0"
  gem 'database_cleaner', '~> 0.6.7'

  gem 'rspec-rails', "~> 2.6.1"
  gem 'cucumber-rails', "~> 1.0.0"
  gem 'webrat', "~> 0.7.3"
  gem 'autotest'
  gem 'simplecov'
  gem 'autotest-rails-pure'

    gem 'simplecov', :require => false, :group => :test
  gem 'spork'
end

group :production do
    gem 'rack-google_analytics', :require => "rack/google_analytics"
end

【问题讨论】:

  • 请将 gem 放入您的 gemfile 并执行bundle update 并尝试
  • 一直走这条路。不去。它失败的 gem 是它仍然需要安装的下一个 gem。

标签: ruby-on-rails bundler bundle


【解决方案1】:

您是否在 Gemfile 中声明了该宝石?有时指定一个特定的版本会有所帮助,就像您对某些人所做的那样:

gem 'multi-json', '1.1.0'

【讨论】:

  • 玩过。不去。并不是特别是那个宝石,那只是碰巧需要更新的第一个宝石。吹走服务器上的 vendored bundle 然后要求 rake 而不是 multi-json。这只是需要安装的第一个 gem。
【解决方案2】:

如果有人被困在这个问题上,那么答案就是我们的本土宝石之一:

gem "xfire-api", :path => "vendor/gems/xfire-api"

gemspec 中没有指定的 gem 提供了一个 require。如果您对此感到困惑并且拥有本地 gem,请查看您的所有需求,并确保所有文件都由您在 Gemspec 中指定的 gem 提供。

【讨论】:

  • 只是想知道你用 anametrix 做什么
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2015-12-03
  • 2015-10-04
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多