LoadError: impossible de charger le fichier — rspec/core/rake_task

Mise à jour: ce problème n'est toujours pas résolu! Toute aide est appréciée! 05/07/2015
Mise à jour: une solution est trouvée. Veuillez voir ma propre réponse 05/09/2015

Quand je râteau, j'ai eu cette erreur.

AllenLins-MacBook-Pro:geoblacklight allenlin$ rake -t
Resolving dependencies...
You must `gem install bundler` and `bundle install` to run rake tasks
rake aborted!
LoadError: cannot load such file -- rspec/core/rake_task
/Users/allenlin/Documents/USpatial/geoblacklight/Rakefile:12:in `require'
/Users/allenlin/Documents/USpatial/geoblacklight/Rakefile:12:in `<top (required)>'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/rake_module.rb:28:in `load'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/rake_module.rb:28:in `load_rakefile'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb:689:in `raw_load_rakefile'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb:94:in `block in load_rakefile'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb:176:in `standard_exception_handling'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb:93:in `load_rakefile'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb:77:in `block in run'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb:176:in `standard_exception_handling'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/2.2.0/rake/application.rb:75:in `run'
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/rake-10.4.2/bin/rake:33:in `<top (required)>'
/Users/allenlin/.rbenv/versions/2.2.2/bin/rake:23:in `load'
/Users/allenlin/.rbenv/versions/2.2.2/bin/rake:23:in `<main>'

Cependant, j'ai couru le "gem install bundler" et "bundle install' rspec/core/rake_task existe réellement, illustré par

AllenLins-MacBook-Pro:geoblacklight allenlin$ gem which rspec/core/rake_task
/Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/rspec-core-3.0.4/lib/rspec/core/rake_task.rb

Je suis perdu ici. Merci beaucoup pour toute aide sur ce! J'ai attaché le Gemfile:

source 'https://rubygems.org'

# Specify your gem's dependencies in geoblacklight.gemspec
gemspec

# If we don't specify 2.11.0 we'll end up with sprockets 2.12.0 in the main
# Gemfile.lock but since sass-rails gets generated (rails new) into the test app
# it'll want sprockets 2.11.0 and we'll have a conflict
gem 'sprockets', '2.11.0'

# If we don't specify 3.2.15 we'll end up with sass 3.3.2 in the main
# Gemfile.lock but since sass-rails gets generated (rails new) into the test app
# it'll want sass 3.2.0 and we'll have a conflict
gem 'sass', '~> 3.2.0'
gem 'bootstrap-sass', ">= 3.2"

group :test do
  # Peg simplecov to < 0.8 until this is resolved:
  # https://github.com/colszowka/simplecov/issues/281
  gem 'simplecov', '~> 0.7.1', require: false
  gem 'coveralls', require: false
end

Mise à jour

Ajouter ma perle rare env si c'est utile

RubyGems Environment:
- RUBYGEMS VERSION: 2.4.5
- RUBY VERSION: 2.2.2 (2015-04-13 patchlevel 95) [x86_64-darwin14]
- INSTALLATION DIRECTORY: /Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0
- RUBY EXECUTABLE: /Users/allenlin/.rbenv/versions/2.2.2/bin/ruby
- EXECUTABLE DIRECTORY: /Users/allenlin/.rbenv/versions/2.2.2/bin
- SPEC CACHE DIRECTORY: /Users/allenlin/.gem/specs
- SYSTEM CONFIGURATION DIRECTORY: /Users/allenlin/.rbenv/versions/2.2.2/etc
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-darwin-14
- GEM PATHS:
- /Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0
- /Users/allenlin/.gem/ruby/2.2.0
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- https://rubygems.org/
- SHELL PATH:
- /Users/allenlin/.rbenv/versions/2.2.2/bin
- /usr/local/Cellar/rbenv/0.4.0/libexec
- /Users/allenlin/.rbenv/shims
- /Applications/Postgres.app/Contents/Versions/9.3/bin
- /Library/Frameworks/Python.framework/Versions/2.7/bin
- /Users/allenlin/Library/Enthought/Canopy_64bit/User/bin
- /Users/allenlin/.rbenv/versions/2.2.2/lib/ruby/gems/2.2.0/gems/bundler-1.9.6/bin
- /Users/allenlin/gradle-1.12/bin
- /usr/local/bin
- /Users/allenlin/apache-maven/apache-maven-3.1.1/bin
- /usr/local/bin
- /usr/bin
- /bin
- /usr/sbin
- /sbin
- /opt/X11/bin
- /usr/local/git/bin
- /usr/texbin
(1)cette Gemfile contient de multiples sources primaires. (2)Votre Gemfile listes de la gemme geoblacklight (>= 0) plus d'une fois.(3)Vous devez gem install bundler et bundle install
Merci pour votre réponse! J'ai mis à jour le post! Essentiellement, je ne comprends pas pourquoi le message d'erreur et messages d'avertissement dire que j'ai plusieurs "source" et geoblacklight. Est-il d'autres fichiers que je devrais regarder?
Ce qui s'est passé lorsque vous avez suivi cette instruction: "(Voir texte intégral de la trace en cours d'exécution de la tâche avec --trace)" ? 🙂
Aussi, l'ensemble du fichier-expansion-chemin peu au fond. n'est-ce pas juste de charger le même Gemfile une deuxième fois? Qui pourrait être pourquoi vous êtes obtenir des "deux sources", et deux de tout le reste aussi
Merci de me le rappeler! 🙂 S'il vous plaît voir la trace complète!

OriginalL'auteur Allen Lin | 2015-05-08