acidtib/pace-rails

Generates Sass::SyntaxError on rake assets:precompile

Closed this issue · 4 comments

After upgrading from pace-rails 0.1.1 to 0.1.2,

I'm encountering Sass::SyntaxError when running rake assets:precompile.

Syntax errors are caught on every occurrence of 'backtick' syntax, like

background-color: `args.color || "#29d"`;

or

color: `Color(args.color || '#000').clearer(0.8).rgbString()`;

How can I avoid this error?

For your information, I'm attaching the error message from rake:

$ RAILS_ENV=production rake assets:precompile

rake aborted!
Sass::SyntaxError: Invalid CSS after "  background: ": expected expression (e.g. 1px, bold), was "`args.color || ..."
  (in /Users/meinside/srcs/someapp/app/assets/stylesheets/application.css.scss)
(sass):6822
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:1147:in `expected'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/script/lexer.rb:206:in `expected!'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/script/parser.rb:478:in `assert_expr'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/script/parser.rb:49:in `parse'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:1022:in `sass_script'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:882:in `value!'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:859:in `declaration'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:582:in `block in declaration_or_ruleset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:1123:in `call'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:1123:in `rethrow'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:592:in `declaration_or_ruleset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:554:in `block_child'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:543:in `block_contents'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:535:in `block'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:529:in `ruleset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:553:in `block_child'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:546:in `block_contents'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:82:in `stylesheet'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/scss/parser.rb:27:in `parse'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/engine.rb:342:in `_to_tree'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/engine.rb:315:in `_render'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sass-3.2.19/lib/sass/engine.rb:262:in `render'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/sass_compressor.rb:24:in `evaluate'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/tilt-1.4.1/lib/tilt/template.rb:103:in `render'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/context.rb:197:in `block in evaluate'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/context.rb:194:in `each'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/context.rb:194:in `evaluate'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/bundled_asset.rb:25:in `initialize'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/base.rb:377:in `new'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/base.rb:377:in `build_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/index.rb:94:in `block in build_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/caching.rb:58:in `cache_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/index.rb:93:in `build_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/base.rb:287:in `find_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/index.rb:61:in `find_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/manifest.rb:211:in `block in find_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/manifest.rb:257:in `benchmark'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/manifest.rb:210:in `find_asset'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/manifest.rb:119:in `block in compile'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/manifest.rb:118:in `each'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/sprockets/manifest.rb:118:in `compile'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-rails-2.2.4/lib/sprockets/rails/task.rb:70:in `block (3 levels) in define'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-2.12.3/lib/rake/sprocketstask.rb:146:in `with_logger'
/Users/meinside/.rvm/gems/ruby-2.2.0/gems/sprockets-rails-2.2.4/lib/sprockets/rails/task.rb:69:in `block (2 levels) in define'
Tasks: TOP => assets:precompile
(See full trace by running task with --trace)

$

Thank you!

Thank you, i did not realize i put the wrong files. An update will be pushed today

Hi, I'm waiting for your update.
How is it going?

Hey @meinside you can update now, also check out the readme.md the way you select the theme has changed, if theres anything else let me know.

Thank you @DrKyro !
It's working again like before.