2013-04-12 46 views
1

,因爲今天我的資產中獲得了超時異常編譯:Heroku的編譯資產超時

git push heroku 
... 
-----> Writing config/database.yml to read from DATABASE_URL 
-----> Preparing app for Rails asset pipeline 
     Running: rake assets:precompile 
/app/slug-compiler/lib/utils.rb:67:in `block (2 levels) in spawn': command='/app/slug-compiler/lib/../../tmp/buildpacks/ruby/bin/compile /tmp/build_nnx3b7xhbc6j /app/tmp/repo.git/.cache' exit_status=0 out='' at=timeout elapsed=900.1050653457642 (Utils::TimeoutError) 
     from /app/slug-compiler/lib/utils.rb:53:in `loop' 
     from /app/slug-compiler/lib/utils.rb:53:in `block in spawn' 
     from /app/slug-compiler/lib/utils.rb:48:in `popen' 
     from /app/slug-compiler/lib/utils.rb:48:in `spawn' 
.. 

更新:

heroku[api]: Starting process with command `bundle exec rake assets:precompile` by 
heroku[api]: Starting process with command `bundle exec rake assets:precompile` 
heroku[run.7870]: Awaiting client 
heroku[run.7870]: Error R13 (Attach error) -> Failed to attach to process 
heroku[run.7870]: State changed from starting to complete 
heroku[run.7870]: Process exited with status 128 
heroku[slugc]: Slug compilation started 
heroku[slugc]: Slug compilation failed: failed to compile Ruby/rails app 

任何想法?

謝謝

回答

0

我的回答:問題出在屬性中的非ASCII字符,本地編譯進行的很好,但不在heroku上。 底線 - 僅使用ascii

+0

你能發表嗎? –

2

嘗試在本地預編譯資產。

bundle exec rake assets:precompile 

另外config.assets.initialize_on_precompile必須在Heroku上設置爲false。

有關更多信息,請參見Rails Guides

+0

這可以作爲快速修復,但不是所有的永久解決方案 –

+0

因此它成功了嗎? – iltempo

0

是不是命令git push heroku master?