开发者

Cloned Heroku app not working remotely

I wanted to create a开发者_如何学运维nother cloned version of my existing heroku app on heroku. For that i cloned it to my local machine then create a new heroku app and push the code to the newly created app.

I also pulled the db from the prev similar app and pushed it to my new app db. But when i ran my rake db:migrate command i got this error

** Invoke db:migrate (first_time) ** Invoke environment (first_time) ** Execute environment

rake aborted! can't convert Symbol into Integer

/app/.gems/gems/rails-2.3.8/lib/rails/gem_dependency.rb:51:in `[]'
/app/.gems/gems/rails-2.3.8/lib/rails/gem_dependency.rb:51:in `initialize'
/app/.gems/gems/rails-2.3.8/lib/initializer.rb:812:in `new'
/app/.gems/gems/rails-2.3.8/lib/initializer.rb:812:in `gem'
/app/config/environment.rb:20:in `block in <top (required)>'
/app/.gems/gems/rails-2.3.8/lib/initializer.rb:111:in `run'
/app/config/environment.rb:9:in `<top (required)>'
<internal:lib/rubygems/custom_require>:29:in `require'
<internal:lib/rubygems/custom_require>:29:in `require'
/app/.gems/gems/activesupport-2.3.8/lib/active_support/dependencies.rb:156:in `block in require'
/app/.gems/gems/activesupport-2.3.8/lib/active_support/dependencies.rb:521:in `new_constants_in'
/app/.gems/gems/activesupport-2.3.8/lib/active_support/dependencies.rb:156:in `require'
/app/.gems/gems/rails-2.3.8/lib/tasks/misc.rake:4:in `block in <top (required)>'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:634:in `call'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:634:in `block in execute'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:629:in `each'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:629:in `execute'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:595:in `block in invoke_with_call_chain'
/usr/ruby1.9.2/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:605:in `block in invoke_prerequisites'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:602:in `each'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:602:in `invoke_prerequisites'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:594:in `block in invoke_with_call_chain'
/usr/ruby1.9.2/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:581:in `invoke'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:2041:in `invoke_task'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:2019:in `block (2 levels) in top_level'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:2019:in `each'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:2019:in `block in top_level'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:2058:in `standard_exception_handling'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:2013:in `top_level'
/usr/ruby1.9.2/lib/ruby/1.9.1/rake.rb:1992:in `run'
/usr/ruby1.9.2/bin/rake:31:in `<main>'

Also when i run the application it crashes and the following error is shown in the heroku logs

2011-06-22T08:47:39+00:00 heroku[router]: Error H10 (App crashed) -> GET glowing-flower-236.heroku.com/ dyno= queue= wait= service= status=503 bytes=
2011-06-22T08:47:40+00:00 heroku[router]: Error H10 (App crashed) -> GET glowing-flower-236.heroku.com/favicon.ico dyno= queue= wait= service= status=503 bytes=
2011-06-22T08:47:40+00:00 heroku[nginx]: GET / HTTP/1.1 | 2.91.6.132 | 796 | http | 503

Do let me know where i am doing the things wrong.


You misspelled the field type on your column name. Go through your schema and look at all of your tables. Make sure all have been dumped into db/schema.rb. Then look at each column type.

For example:

t.intgre
#should be 
t.integer 

I have got the error you are getting for this exact reason many times over. It's a pain in the ass to fix. You will have to drop that table, fix the spelling, and then start over.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜