2009-08-10 2 views
0

이 문제를 해결하는 방법을 설명해 주시겠습니까? 나는 레일 2.3.3 응용 프로그램과 완벽하게 작업에 가장자리 설치 한 서버를 실행하는 시도에서 내가 가지고 1.8.7로 업그레이드 한 후 (루비 1.8.6)osx 및 gem 문제의 가장자리 레일

$ ruby script/server 
=> Booting Mongrel 
=> Rails 3.0.pre application starting on http://0.0.0.0:3000 
/Library/Ruby/Site/1.8/rubygems.rb:270:in `activate': You have a nil 
object when you didn't expect it! (NoMethodError) 
You might have expected an instance of Array. 
The error occurred while evaluating nil.map 
     from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:35:in 
`require' 
.......................... 

있어

$ ruby script/server 
./script/../config/../vendor/rails/railties/lib/rails/ 
vendor_gem_source_index.rb:1:in `require': no such file to load -- 
rubygems (LoadError) 
     from ./script/../config/../vendor/rails/railties/lib/rails/ 
vendor_gem_source_index.rb:1 
     from ./script/../config/../vendor/rails/railties/lib/rails/ 
gem_dependency.rb:1:in `require' 
     from ./script/../config/../vendor/rails/railties/lib/rails/ 
gem_dependency.rb:1 
     from ./script/../config/../vendor/rails/railties/lib/initializer.rb: 
6:in `require' 
     from ./script/../config/../vendor/rails/railties/lib/initializer.rb:6 
     from ./script/../config/boot.rb:45:in `require' 
     from ./script/../config/boot.rb:45:in `load_initializer' 
     from ./script/../config/boot.rb:38:in `run' 
     from ./script/../config/boot.rb:11:in `boot!' 
     from ./script/../config/boot.rb:110 
     from script/server:2:in `require' 
     from script/server:2 

어떤 아이디어가 있습니까?

답변

0

RubyGems 버전이 1.3.1 이상인지 확인 했습니까?

예인 경우 다시 설치하십시오.

많은 사람들이 최근에 같은 문제를 겪고있는 것 같습니다. 루비를 다시 설치 한 사람들, MacPorts를 사용하여 루비 젬 설치를 한 것 같았습니다.

+0

안녕하세요, 보석 1.3.5, 다시 설치 - 동일한 결과 : (보석 업데이트에 의한 업데이트가있는 루비 보석에서 - 시스템 –

0

보석이 새 버전의 Ruby 용으로 설치되지 않았거나 경로 설정을 업데이트해야하는 것처럼 들립니다. http://rubygems.org/read/chapter/19#page98에서

: 실행 루비의 설치가 설치 젬을 가지고 동일 하나라고

  • 확인합니다. 유닉스 시스템에서는 which 명령 (또는 type 명령)이 이것을 알아내는 데 도움이됩니다.

  • 현재 실행중인 Ruby 설치에 실제로 RubyGems 라이브러리가 설치되어 있는지 확인하십시오. Ruby 설치의 site_ruby/1.8 디렉토리에 "rubygems.rb"파일이 있어야합니다.

이러한 혼합은 Ruby의 새 인스턴스를 설치 한 후에 쉽게 발생할 수 있지만 이전 인스턴스는 PATH 목록의 새 인스턴스보다 우선합니다.

Ruby의 새로운 버전을 어떻게 설치했으며 PATH 환경 변수가 올바르게 조정 되었습니까 (echo $PATH)?

아마도 which gemwhich ruby을 실행할 때 새로운 1.8.7 위치를 가리키고 있을까요? ruby -vgem -v이이를 확인합니다.

관련 문제