2011-02-17 40 views
0

我不斷收到這個錯誤,我很難過。所以應用在鐵軌2.3.8,這裏是我的寶石名單拋出異常:RubyGem版本錯誤:activerecord(2.3.8 not> = 3.0.3)

*** LOCAL GEMS *** 

aaronh-chronic (0.3.9) 
abstract (1.0.0) 
actionmailer (2.3.8) 
actionpack (2.3.8) 
activerecord (2.3.8) 
activeresource (2.3.8) 
activesupport (2.3.8) 
arel (2.0.8) 
builder (2.1.2) 
bundler (1.0.10) 
daemon_controller (0.2.6) 
erubis (2.6.6) 
fastthread (1.0.7) 
file-tail (1.0.5) 
i18n (0.5.0) 
mail (2.2.15) 
mime-types (1.16) 
passenger (3.0.2) 
polyglot (0.3.1) 
rack (1.1.0) 
rack-mount (0.6.13) 
rack-test (0.5.7) 
rails (2.3.8) 
railties (3.0.4) 
rake (0.8.7) 
riddle (1.2.2) 
rubygems-update (1.5.2) 
spruz (0.2.5) 
thinking-sphinx (2.0.2) 
thor (0.14.6) 
treetop (1.4.9) 
tzinfo (0.3.24) 
whenever (0.6.2) 

我有RubyGems的1.3.7和我降級到1.3.5和錯誤仍然存​​在......

寶石ENV

RubyGems Environment: 
    - RUBYGEMS VERSION: 1.3.5 
    - RUBY VERSION: 1.8.7 (2010-01-10 patchlevel 249) [x86_64-linux] 
    - INSTALLATION DIRECTORY: /usr/lib/ruby/gems/1.8 
    - RUBY EXECUTABLE: /usr/bin/ruby1.8 
    - EXECUTABLE DIRECTORY: /usr/bin 
    - RUBYGEMS PLATFORMS: 
    - ruby 
    - x86_64-linux 
    - GEM PATHS: 
    - /usr/lib/ruby/gems/1.8 
    - /root/.gem/ruby/1.8 
    - GEM CONFIGURATION: 
    - :update_sources => true 
    - :verbose => true 
    - :benchmark => false 
    - :backtrace => false 
    - :bulk_threshold => 1000 
    - REMOTE SOURCES: 
    - http://gems.rubyforge.org/ 

我可以做些什麼來解決

+0

是否有原因你不能使用rubygems最新的1.5.2?我有很多運行1.5.2的rails 2.x應用程序。我不認爲RubyGems是你的問題,看起來你的應用程序寶石之一想要使用rails 3 activerecord – 2011-02-17 05:10:06

回答

0

可能是你 「遠程源」,嘗試做:

gem sources -r http://gems.rubyonrails.org 

然後加入:

gem sources -a http://rubygems.org/ 

而且......您可以發佈它的寶石做你在environment.rb文件(ROR 2.X)或Gemfile(ROR 3.X)要求

0

只需編輯軌道版本config/environment.rb文件到2.3.8