Open tamarmot opened 9 years ago
I'm having the same problem.
From https://github.com/vbabiy/django-pipeline-compass/blob/master/pipeline_compass/compiler.py it looks like it calls the Python Sass compiler (import sass
and scss.Scss(scss_opts={'compress': False,'debug_info': settings.DEBUG,}).compile(None, content)
), after adding the compass directory (included in the django-pipeline-package app) to the path.
This leads me to believe that it never calls the command line compass
tool, so will not read the config.rb file.
My theory about fixing this is to adjust the @import
for modular-scale in gumby.scss to @import "extensions/modular-scale/stylesheets/modular-scale";
I'm now stuck at the error:
Error evaluating expression:
$golden
on line 7 of /path/static/gumby/sass/var/_settings.scss
imported from line 1 of /path/static/gumby/sass/gumby.scss
Traceback:
File "/path/.virtualenvs/project/lib/python2.7/site-packages/scss/calculator.py", line 141, in evaluate_expression
return ast.evaluate(self, divide=divide)
File "/path/.virtualenvs/project/lib/python2.7/site-packages/scss/ast.py", line 346, in evaluate
raise SyntaxError("Undefined variable: '%s'." % self.name)
SyntaxError: Undefined variable: '$golden'.
I re-fixed this by downgrading modular-scale to 1.0.6
I'm working on getting the gumby framework compiling under django-pipeline-compass, and I've run into walls. Gumby Framework has dependencies on other ruby gems, namely modular-scale. I have verified that with my ruby-installed compass, I can do a compass compile.
Question: How to include other ruby gems?
When I try to use pipeline / django-pipeline-compass, and have my config.rb set to depend on the other gems, I get the following error: File "/usr/local/lib/python2.7/dist-packages/scss/compiler.py", line 860, in _at_import raise SassImportError(name, self.compiler, rule=rule) scss.errors.SassImportError: Couldn't find anything to import: modular-scale Extensions:, , , , ,
I have also tried this: PIPELINE_COMPASS_ARGUMENTS = '--debug-info -L /var/lib/gems/1.8/gems -c build/static/external/gumby/config.rb' which again leads to an empty gumby.css file
I have done some experimentation with including secondary .rb files in the settings / source_filenames, but in that case I get an empty gumby.css file as output (from django-pipeline-compass).
My config.rb file from gumby framework includes this and I have tried it both ways:
Tell compass where to find local extensions
If you followed directions and ran 'gem install modular-scale' comment the next two lines out:
extensions_dir = "sass/extensions" Compass::Frameworks.register('modular-scale', :path => File.expand_path("#{extensions_dir}/modular-scale"))
Uncomment these to use regular Ruby gems.
require 'modular-scale'
require 'sassy-math'
Thanks for your help Tamar Cohen NASA Ames Research Center