【问题标题】:Heroku Rails 3 app crashing - Error H10 (App crashed)Heroku Rails 3 应用程序崩溃 - 错误 H10(应用程序崩溃)
【发布时间】:2011-12-01 19:58:37
【问题描述】:

我的网站在本地 mashine 上运行良好,但在 heroku 上崩溃。

这是我的 heroku 日志:http://pastie.org/private/ligfhv4tjqmodclkwxc21q

相关日志部分:

[36m2011-12-01T19:42:53+00:00 应用[web.1]:←[0m /app/.bundle/gems/ruby/1.8/gems/a ctivesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require': /app/app /helpers/kategoris_helper.rb:2: 语法错误, 意外的 kEND,期待 $end (S yntaxError)

我的堆栈是竹树 1.8.7

我认为这与这个助手有关,但不确定:

module KategorisHelper
  def sortkat(column, title = nil)
    title ||= column.titleize
    css_class = column == sort_column ? "current #{sort_direction}" : nil
    direction = column == sort_column && sort_direction == "ASC" ? "DESC" : "ASC"
    link_to title, params.merge(:sort => column, :direction => direction, :page => nil), {:class => css_class}
  end
end

【问题讨论】:

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


    【解决方案1】:

    好吧,错误消息基本上意味着end太多(syntax error, unexpected kEND, expecting $end,缺少的endsyntax error, unexpected $end, expecting kEND)。 ruby -c 没有抱怨你的助手,你复制了整个代码吗?

    【讨论】:

    • 原来是编码的问题,最后改写了,问题解决了
    猜你喜欢
    • 2016-08-20
    • 2012-06-18
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多