随机ActionView :: Template :: Error(未预编译):

时间:2013-11-19 04:36:47

标签: ruby-on-rails ruby-on-rails-3 heroku

随机我的应用程序在我的一个控制器操作上发出错误:ActionView::Template::Error ( isn't precompiled):

之前工作正常,然后才停止工作。我没有推到heroku或任何东西..

关于如何修复它的任何想法?

我试过运行heroku run rake assets:precompile没有运气。

前几天我确实有this issue,可能有关系吗?

完全错误:

2013-11-19T04:44:35.306982+00:00 app[web.1]:     18: <tr>
2013-11-19T04:44:35.306982+00:00 app[web.1]:     19: <% @accounts.each do |a| %>
2013-11-19T04:44:35.306982+00:00 app[web.1]:     20:    <tr>
2013-11-19T04:44:35.306982+00:00 app[web.1]:     21:        <td style="text-align:left;" class="list"><%= image_tag a.image %> <%= a.name %> <% if a.verified == true %> <img src="/images/verified.png" title ="Verified account" alt="Verified account" style="height:18px;"><% end %>
2013-11-19T04:44:35.306982+00:00 app[web.1]:     22:            <br> <%= link_to "Purchase", "/#{a.permalink}" %> | <%= link_to "Visit twitter", a.url, :rel => 'nofollow', :target => "new" %></td> 
2013-11-19T04:44:35.306982+00:00 app[web.1]:     23:        <td class="list">$<%= number_with_delimiter(a.price, :delimiter => ',') %></td>
2013-11-19T04:44:35.306982+00:00 app[web.1]: 
2013-11-19T04:44:35.306982+00:00 app[web.1]: ActionView::Template::Error ( isn't precompiled):
2013-11-19T04:44:35.306982+00:00 app[web.1]:     24:        <% if a.retweets %>
2013-11-19T04:44:35.307215+00:00 app[web.1]:   app/views/market/_list.html.erb:19:in `_app_views_market__list_html_erb___3570010844875364888_70106042012700'
2013-11-19T04:44:35.307215+00:00 app[web.1]: 
2013-11-19T04:44:35.307215+00:00 app[web.1]:   app/views/market/index.html.erb:1:in `_app_views_market_index_html_erb___4051548369069171146_70106041975580'

1 个答案:

答案 0 :(得分:1)

看起来a.image回来nil或空白,所以它试图找到资产“”并失败。