我的Rails应用程序在我的本地Ubuntu机器上运行良好,但是当我将其推送到heroku并访问网站时,该应用程序崩溃并出现以下错误。Heroku崩溃在.sass文件上的应用程序
2011-09-26T03:45:52+00:00 heroku[web.1]: State changed from created to starting
2011-09-26T03:45:54+00:00 heroku[web.1]: Starting process with command `thin -p 7208 -e production -R /home/heroku_rack/heroku.ru start`
2011-09-26T03:46:00+00:00 app[web.1]: WARNING on line 640 of /app/app/stylesheets/simpla/style.sass:
2011-09-26T03:46:00+00:00 app[web.1]: This selector doesn't have any properties and will not be rendered.
2011-09-26T03:46:03+00:00 app[web.1]: WARNING: 'ui-ui-bg_flat_0_000000_40x100.png' was not found (or cannot be read) in /app/public/images
2011-09-26T03:46:03+00:00 app[web.1]: WARNING on line 122 of /app/app/stylesheets/calendar/jquery.weekcalendar.sass:
2011-09-26T03:46:03+00:00 app[web.1]: This selector doesn't have any properties and will not be rendered.
2011-09-26T03:46:03+00:00 app[web.1]: WARNING on line 214 of /app/app/stylesheets/calendar/jquery.weekcalendar.sass:
2011-09-26T03:46:03+00:00 app[web.1]: This selector doesn't have any properties and will not be rendered.
2011-09-26T03:46:03+00:00 app[web.1]: WARNING on line 122 of /app/app/stylesheets/calendar/jquery.weekcalendar.sass:
2011-09-26T03:46:03+00:00 app[web.1]: This selector doesn't have any properties and will not be rendered.
2011-09-26T03:46:03+00:00 app[web.1]: WARNING on line 214 of /app/app/stylesheets/calendar/jquery.weekcalendar.sass:
2011-09-26T03:46:03+00:00 app[web.1]: This selector doesn't have any properties and will not be rendered.
2011-09-26T03:46:03+00:00 app[web.1]: /app/app/stylesheets/calendar/jquery.weekcalendar.sass:6:in `linear-gradient': Undefined mixin 'linear-gradient'. (Sass::SyntaxError)
2011-09-26T03:46:03+00:00 app[web.1]: from /app/app/stylesheets/calendar/jquery.weekcalendar.sass:6
2011-09-26T03:46:03+00:00 app[web.1]: from /app/.bundle/gems/ruby/1.8/gems/sass-3.1.7/lib/sass/../sass/tree/visitors/perform.rb:169:in `visit_mixin'
2011-09-26T03:46:03+00:00 app[web.1]: from /app/.bundle/gems/ruby/1.8/gems/sass-3.1.7/lib/sass/../sass/tree/visitors/base.rb:37:in `send'
2011-09-26T03:46:03+00:00 app[web.1]: from /app/.bundle/gems/ruby/1.8/gems/sass-3.1.7/lib/sass/../sass/tree/visitors/base.rb:37:in `visit'
2011-09-26T03:46:03+00:00 app[web.1]: from /app/.bundle/gems/ruby/1.8/gems/sass-3.1.7/lib/sass/../sass/tree/visitors/perform.rb:18:in `visit'
2011-09-26T03:46:03+00:00 app[web.1]: from /app/.bundle/gems/ruby/1.8/gems/sass-3.1.7/lib/sass/../sass/tree/visitors/base.rb:53:in `visit_children'
2011-09-26T03:46:03+00:00 app[web.1]: from /app/.bundle/gems/ruby/1.8/gems/sass-3.1.7/lib/sass/../sass/tree/visitors/base.rb:53:in `map'
.
.
2011-09-26T03:46:04+00:00 heroku[web.1]: Process exited
2011-09-26T03:46:04+00:00 heroku[web.1]: State changed from starting to crashed
2011-09-26T03:47:27+00:00 heroku[slugc]: Slug compilation started
我的应用程序/样式表/日历/ jquery.weekcalendar.sass在开头以下:
.wc-container
font-size: 14px
font-family: arial, helvetica
.wc-toolbar
+linear-gradient(color-stops(#EFEFEF, #D5D5D5))
border: 1px solid #DADADA
padding: 1em
font-size: 0.8em
.wc-nav
float: left
.wc-display
float: right
button
margin-top: 0
margin-bottom: 0
.wc-title
text-align: center
padding: 0
margin: 0
6行是一个与“+线性梯度(彩色停止(# EFEFEF,#D5D5D5))“。我的本地机器不会抱怨这一行,我想知道为什么heroku在抱怨。
在推送到heroku之前,您是否尝试过编译它们? – thomasfedb
是的,我跑了捆绑,测试了一下,然后推到了heroku。仅供参考,我做了一些研究,认为有一些复杂的b/w heroku和sass。在我的Gemfile中,我有: gem'hassle',:git =>'git://github.com/Papipo/hassle.git', :ref =>“3a12feb7ae8c94acde7b” – rapidror
经过更多研究,我发现线性渐变定义在我的本地机器上的./vendor/bundle/ruby/1.8/gems/compass-0.10.6/frameworks/compass/stylesheets/compass/css3/_gradient.scss,我使用rails 3.0.3。仍然没有解决方案... – rapidror