Ruby on rails ActionView::Template::Error(highcharts.js未预编译):
heroku上的我的应用程序显示此错误:Ruby on rails ActionView::Template::Error(highcharts.js未预编译):,ruby-on-rails,heroku,actionview,Ruby On Rails,Heroku,Actionview,heroku上的我的应用程序显示此错误: ActionView::Template::Error (highcharts.js isn't precompiled): 我尝试了两种在互联网上找到的解决方案 config.assets.initialize_on_precompile = false 及 我读了一篇我不记得是哪一篇的帖子,并用以下命令创建了de heroku: heroku create --stack cedar 另外,当我运行heroku open时,我遇到了以下错误:
ActionView::Template::Error (highcharts.js isn't precompiled):
我尝试了两种在互联网上找到的解决方案
config.assets.initialize_on_precompile = false
及
我读了一篇我不记得是哪一篇的帖子,并用以下命令创建了de heroku:
heroku create --stack cedar
另外,当我运行heroku open时,我遇到了以下错误:
ActionView::Template::Error (highcharts.js isn't precompiled):
这是我的heroku日志
....
2012-08-08T21:03:41+00:00 app[web.1]: ActionView::Template::Error (highcharts.js isn't precompiled):
2012-08-08T21:03:41+00:00 app[web.1]:
2012-08-08T21:03:41+00:00 app[web.1]: 5: <%= stylesheet_link_tag "application", :media => "all" %>
2012-08-08T21:03:41+00:00 app[web.1]: 6: <%= javascript_include_tag "application" %>
2012-08-08T21:03:41+00:00 app[web.1]: 7: <%= javascript_include_tag "http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" %>
2012-08-08T21:03:41+00:00 app[web.1]: 8: <%= javascript_include_tag :highcharts %>
2012-08-08T21:03:41+00:00 app[web.1]: 10: </head>
2012-08-08T21:03:41+00:00 app[web.1]: 11: <body>
2012-08-08T21:03:41+00:00 app[web.1]: 9: <%= csrf_meta_tags %>
2012-08-08T21:03:41+00:00 app[web.1]: app/views/layouts/application.html.erb:8:in `_app_views_layouts_application_html_erb___4426161850966429466_47229900'
2012-08-08T21:03:41+00:00 heroku[router]: GET floating-forest-7331.herokuapp.com/favicon.ico dyno=web.1 queue=0 wait=0ms service=4010ms status=304 bytes=0
....
编辑如果您想查看我的应用程序,我将非常感谢您在这里查看我的应用程序。请尝试:
RAILS_ENV=production bundle exec rake assets:precompile
然后将创建的文件夹./public/assets/添加到Git存储库并推送到Heroku
如果rake将尝试连接到您的数据库,请添加您的./config/application.rb:
请尝试:
RAILS_ENV=production bundle exec rake assets:precompile
然后将创建的文件夹./public/assets/添加到Git存储库并推送到Heroku
如果rake将尝试连接到您的数据库,请添加您的./config/application.rb:
我得到了这个错误:rake中止!致命:数据库数据库/estation\u测试\u生产不可用exist@Asantoya17我在回答中添加了您当前问题的可能解决方案。谢谢您的回答,但我发布了该解决方案,我已经尝试过该命令line@Asantoya17应用此配置设置后,您是否尝试过assets:precompile?我遇到了一个错误:rake中止!致命:数据库数据库/estation\u测试\u生产不可用exist@Asantoya17我在回答中添加了您当前问题的可能解决方案。谢谢您的回答,但我发布了该解决方案,我已经尝试过该命令line@Asantoya17应用此配置设置后,您是否尝试过assets:precompile?我发现了这个,但实际上我没有我很明白muchI发现了这个但我真的不太明白