2013-04-22 7 views
0

난 로컬로 작동 (bundle exec와 함께 테스트) 레일 애플 리케이션을 가지고 있지만 Heroku (시더 스택)에 추락했다. 이 구성은 원격지와 동일합니다 (둘 다 Postgres를 사용하고 있습니다). 스택 추적은 Rails/Thin 환경에서 발생하는 것처럼 보이기 때문에 실제로 충돌은 다소 혼란 스럽습니다. 내 vendor/plugins 디렉토리에는 아무 것도 없기 때문에, deprecation 경고는 똑같이 난처하게 만듭니다!원격 Heroku 응용 프로그램이 충돌합니다. 로컬 괜찮아요

Starting process with command `bundle exec thin start -R config.ru -e $RAILS_ENV -p 38427` 
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/ and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/config/environment.rb:5) 
DEPRECATION WARNING: You have Rails 2.3-style plugins in vendor/plugins! Support for these plugins will be removed in Rails 4.0. Move them out and bundle them in your Gemfile, or fold them in to your app as lib/myplugin/ and config/initializers/myplugin.rb. See the release notes for more on this: http://weblog.rubyonrails.org/2012/1/4/rails-3-2-0-rc2-has-been-released. (called from <top (required)> at /app/config/environment.rb:5) 
/app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/relation.rb:378:in `destroy': wrong number of arguments (0 for 1) (ArgumentError) 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/application/finisher.rb:53:in `block in <module:Finisher>' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/initializable.rb:30:in `run' 
from /app/app/models/transcript.rb:1:in `<top (required)>' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/engine.rb:439:in `block (2 levels) in eager_load!' 
from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:236:in `load_dependency' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/engine.rb:436:in `each' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/initializable.rb:55:in `block in run_initializers' 
from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:359:in `require_or_load' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/initializable.rb:54:in `each' 
from /app/vendor/bundle/ruby/1.9.1/gems/activerecord-3.2.13/lib/active_record/querying.rb:7:in `destroy' 
from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `block in require' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/initializable.rb:54:in `run_initializers' 
from /app/app/models/transcript.rb:4:in `<class:Transcript>' 
from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:225:in `require_dependency' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/application.rb:136:in `initialize!' 
from config.ru:1:in `new' 
from /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.1/lib/thin/controllers/controller.rb:181:in `load_rackup_config' 
from config.ru:3:in `require' 
from /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.1/bin/thin:6:in `<top (required)>' 
from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.5/lib/rack/builder.rb:51:in `initialize' 
from /app/vendor/bundle/ruby/1.9.1/bin/thin:19:in `load' 
from /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.1/lib/rack/adapter/loader.rb:33:in `load' 
from /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.1/lib/thin/controllers/controller.rb:71:in `start' 
from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require' 
from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/railtie/configurable.rb:30:in `method_missing' 
from /app/vendor/bundle/ruby/1.9.1/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:313:in `depend_on' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/engine.rb:436:in `eager_load!' 
from /app/config/environment.rb:5:in `<top (required)>' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/engine.rb:438:in `each' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/engine.rb:438:in `block in eager_load!' 
from config.ru:3:in `block in <main>' 
from /app/vendor/bundle/ruby/1.9.1/gems/railties-3.2.13/lib/rails/initializable.rb:30:in `instance_exec' 
from /app/vendor/bundle/ruby/1.9.1/gems/rack-1.4.5/lib/rack/builder.rb:51:in `instance_eval' 
from /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.1/lib/thin/runner.rb:187:in `run_command' 
from /app/vendor/bundle/ruby/1.9.1/bin/thin:19:in `<main>' 
from /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.1/lib/rack/adapter/loader.rb:33:in `eval' 
from config.ru:1:in `<main>' 
Process exited with status 1 
State changed from starting to crashed 

이미 rake db:resetrake db:migrate 그냥 확실하게 실행했는지 데이터베이스 시스템과의 문제점 아닙니다. 성적 증명서 파일의

내용 :

class Transcript < ActiveRecord::Base 
    attr_accessible :grade, :hours 

    belongs_to :student, class_name: 'User', dependent: destroy 
    belongs_to :course 
end 
+0

당신은'heroku pg : reset DATABASE_URL'을 원하셨습니까? – jason328

+0

http://stackoverflow.com/questions/9027403/rails-2-3-style-plugins-and-deprecation-warnings-running-task-in-heroku에서 비추천 경고를 참조하십시오. – matt

+1

성적표 모델 파일에 무엇이 있습니까? – jason328

답변

1

귀하의 모델은 다음과 같아야합니다. 무슨 일이 있었는지

class Transcript < ActiveRecord::Base 
    attr_accessible :grade, :hours 

    belongs_to :student, class_name: 'User', dependent: :destroy 
    belongs_to :course 
end 

는 문자열이나 해시로 destroy을 정의하지 않은 것이 었습니다. 따라서 당신은 왜 ...

`destroy': wrong number of arguments (0 for 1) (ArgumentError) 
+0

감사! 그것은 그것을 고쳤다. 왜 그것이 지역적으로 효과가 있었는지에 대한 아이디어는 있지만 리모컨에서 대단히 죽었습니까? –

+0

확실하지 않습니다. 아마 더 많은 지식을 가진 누군가가 우리를 계몽 할 수 있습니다. 이유를 아는 데 관심이 있습니다. – jason328

관련 문제