Rails Console не може да намери activesupport-4.1.2, въпреки че е инсталиран

Когато стартирам сървъра Rails 4.1.2, не получавам грешки.

Въпреки това, ако стартирам „rails c“, получавам следната грешка:

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

Странното е, че activesupport-4.1.2 е инсталиран и е посочен в Gemfile.lock. Опитах „актуализация на пакет“, както и изтриване на Gemfile.lock и стартиране на „инсталиране на пакет“. Също така се опитах да посоча тази конкретна версия на ActiveSupport в моя Rails gemfile, но това не ме доведе до никъде.

Наистина бих искал да използвам най-новите Rails, но изглежда доста гадно, че не мога да използвам конзолата.

FIY: Използвам Ruby 2.1.2p95 в Linux с RVM.

РЕДАКТИРАНЕ: Деинсталирах всички скъпоценни камъни за активна поддръжка и преинсталирах 4.1.2. Ето какво казва „gem list activesupport“:

*** LOCAL GEMS ***

activesupport (4.1.2)

Същия проблем.

EDIT2: Ето моя Gemfile.lock:

GEM
  remote: https://rubygems.org/
  specs:
    actionmailer (4.1.2)
      actionpack (= 4.1.2)
      actionview (= 4.1.2)
      mail (~> 2.5.4)
    actionpack (4.1.2)
      actionview (= 4.1.2)
      activesupport (= 4.1.2)
      rack (~> 1.5.2)
      rack-test (~> 0.6.2)
    actionview (4.1.2)
      activesupport (= 4.1.2)
      builder (~> 3.1)
      erubis (~> 2.7.0)
    activemodel (4.1.2)
      activesupport (= 4.1.2)
      builder (~> 3.1)
    activerecord (4.1.2)
      activemodel (= 4.1.2)
      activesupport (= 4.1.2)
      arel (~> 5.0.0)
    activesupport (4.1.2)
      i18n (~> 0.6, >= 0.6.9)
      json (~> 1.7, >= 1.7.7)
      minitest (~> 5.1)
      thread_safe (~> 0.1)
      tzinfo (~> 1.1)
    akami (1.2.2)
      gyoku (>= 0.4.0)
      nokogiri
    arel (5.0.1.20140414130214)
    builder (3.2.2)
    capybara (2.3.0)
      mime-types (>= 1.16)
      nokogiri (>= 1.3.3)
      rack (>= 1.0.0)
      rack-test (>= 0.5.4)
      xpath (~> 2.0)
    coffee-rails (4.0.1)
      coffee-script (>= 2.2.0)
      railties (>= 4.0.0, < 5.0)
    coffee-script (2.2.0)
      coffee-script-source
      execjs
    coffee-script-source (1.7.0)
    database_cleaner (1.3.0)
    diff-lcs (1.2.5)
    erubis (2.7.0)
    execjs (2.2.1)
    gyoku (1.1.1)
      builder (>= 2.1.2)
    hike (1.2.3)
    httpi (2.1.0)
      rack
      rubyntlm (~> 0.3.2)
    i18n (0.6.9)
    jbuilder (2.1.1)
      activesupport (>= 3.0.0, < 5)
      multi_json (~> 1.2)
    jquery-rails (3.1.1)
      railties (>= 3.0, < 5.0)
      thor (>= 0.14, < 2.0)
    json (1.8.1)
    kgio (2.9.2)
    libv8 (3.16.14.3)
    macaddr (1.7.1)
      systemu (~> 2.6.2)
    mail (2.5.4)
      mime-types (~> 1.16)
      treetop (~> 1.4.8)
    mime-types (1.25.1)
    mini_portile (0.6.0)
    minitest (5.3.5)
    multi_json (1.10.1)
    mysql2 (0.3.16)
    nokogiri (1.6.2.1)
      mini_portile (= 0.6.0)
    nori (2.4.0)
    polyglot (0.3.5)
    rack (1.5.2)
    rack-test (0.6.2)
      rack (>= 1.0)
    rails (4.1.2)
      actionmailer (= 4.1.2)
      actionpack (= 4.1.2)
      actionview (= 4.1.2)
      activemodel (= 4.1.2)
      activerecord (= 4.1.2)
      activesupport (= 4.1.2)
      bundler (>= 1.3.0, < 2.0)
      railties (= 4.1.2)
      sprockets-rails (~> 2.0)
    railties (4.1.2)
      actionpack (= 4.1.2)
      activesupport (= 4.1.2)
      rake (>= 0.8.7)
      thor (>= 0.18.1, < 2.0)
    raindrops (0.13.0)
    rake (10.3.2)
    rdoc (4.1.1)
      json (~> 1.4)
    ref (1.0.5)
    rspec-core (3.0.2)
      rspec-support (~> 3.0.0)
    rspec-expectations (3.0.2)
      diff-lcs (>= 1.2.0, < 2.0)
      rspec-support (~> 3.0.0)
    rspec-mocks (3.0.2)
      rspec-support (~> 3.0.0)
    rspec-rails (3.0.1)
      actionpack (>= 3.0)
      activesupport (>= 3.0)
      railties (>= 3.0)
      rspec-core (~> 3.0.0)
      rspec-expectations (~> 3.0.0)
      rspec-mocks (~> 3.0.0)
      rspec-support (~> 3.0.0)
    rspec-support (3.0.2)
    rubyntlm (0.3.4)
    sass (3.2.19)
    sass-rails (4.0.3)
      railties (>= 4.0.0, < 5.0)
      sass (~> 3.2.0)
      sprockets (~> 2.8, <= 2.11.0)
      sprockets-rails (~> 2.0)
    savon (2.5.1)
      akami (~> 1.2.0)
      builder (>= 2.1.2)
      gyoku (~> 1.1.0)
      httpi (~> 2.1.0)
      nokogiri (>= 1.4.0)
      nori (~> 2.4.0)
      uuid (~> 2.3.7)
      wasabi (~> 3.3.0)
    sdoc (0.4.0)
      json (~> 1.8)
      rdoc (~> 4.0, < 5.0)
    simplecov (0.7.1)
      multi_json (~> 1.0)
      simplecov-html (~> 0.7.1)
    simplecov-html (0.7.1)
    spring (1.1.3)
    sprockets (2.11.0)
      hike (~> 1.2)
      multi_json (~> 1.0)
      rack (~> 1.0)
      tilt (~> 1.1, != 1.3.0)
    sprockets-rails (2.1.3)
      actionpack (>= 3.0)
      activesupport (>= 3.0)
      sprockets (~> 2.8)
    sqlite3 (1.3.9)
    subactions (1.0.1)
    systemu (2.6.4)
    therubyracer (0.12.1)
      libv8 (~> 3.16.14.0)
      ref
    thor (0.19.1)
    thread_safe (0.3.4)
    tilt (1.4.1)
    treetop (1.4.15)
      polyglot
      polyglot (>= 0.3.1)
    turbolinks (2.2.2)
      coffee-rails
    tzinfo (1.2.1)
      thread_safe (~> 0.1)
    uglifier (2.5.1)
      execjs (>= 0.3.0)
      json (>= 1.8.0)
    unicorn (4.8.3)
      kgio (~> 2.6)
      rack
      raindrops (~> 0.7)
    unicorn-rails (2.1.1)
      rack
      unicorn
    uuid (2.3.7)
      macaddr (~> 1.0)
    version (1.0.0)
    wasabi (3.3.0)
      httpi (~> 2.0)
      mime-types (< 2.0.0)
      nokogiri (>= 1.4.0)
    xpath (2.0.0)
      nokogiri (~> 1.3)

PLATFORMS
  ruby

DEPENDENCIES
  capybara
  coffee-rails (~> 4.0.0)
  database_cleaner
  jbuilder (~> 2.0)
  jquery-rails
  mysql2
  rails (= 4.1.2)
  rspec-rails (~> 3.0.0)
  sass-rails (~> 4.0.3)
  sdoc (~> 0.4.0)
  simplecov (~> 0.7.1)
  simplecov-html
  spring
  sqlite3
  subactions
  therubyracer
  turbolinks
  uglifier (>= 1.3.0)
  unicorn
  unicorn-rails
  version

EDIT3: Ето моя .irbrc файл:

# This loads some niceties for irb, courtesy of rvm.
# It also loads your custom ~/.irbrc if it exists.
# If you want to customize the irbrc for ONLY this version of
# ruby then edit this file. It will only be deleted if you do
# an "rvm install" over this ruby version.

if ENV["rvm_path"].nil?
  require File.join(ENV["HOME"], "irbrc")
else
  require File.join(ENV["rvm_path"], "scripts", "irbrc")
end

person Ravenstine    schedule 30.06.2014    source източник
comment
Ами ако стартирате: bundle exec rails c? или ./script/rails c?   -  person Bill Turner    schedule 30.06.2014
comment
Вижте своя Gemfile.lock файл, моля, публикувайте го   -  person Xiao Liang    schedule 30.06.2014
comment
Премахнете Gemfile.lock и след това направете пакетна инсталация   -  person SSR    schedule 30.06.2014
comment
bundle exec rails c няма значение. Вече премахнах Gemfile.lock и инсталирах пакет (моля, прочетете въпроса ми). Ще добавя моя Gemfile.lock към моя въпрос.   -  person Ravenstine    schedule 30.06.2014
comment
Може би има нещо странно във вашия .irbrc?   -  person Frederick Cheung    schedule 30.06.2014
comment
Сега включих моя .irbrc файл за ruby ​​2.1.2 във въпроса си.   -  person Ravenstine    schedule 30.06.2014
comment
За да изключа възможността spring да се намеси, с което се сблъсквам от време на време. Стартирайте spring status, за да проверите състоянието му. Опитайте да го спрете, като използвате spring stop след това bundle и след това rails c.   -  person vee    schedule 30.06.2014
comment
Това свърши работа! Благодаря, vee!   -  person Ravenstine    schedule 01.07.2014


Отговори (1)


Пролетта все още тичаше и се намесваше. Изпълнението на следното в обвивката свърши работа:

spring stop

Сега Rails конзолата работи както трябва.

person Ravenstine    schedule 30.06.2014
comment
поправи този точно същия проблем за мен. Благодаря! - person Jtgrenz; 08.07.2014
comment
Благодаря! Ти току-що ме спаси от часове на объркване и болка :) - person Uzzar; 09.12.2014