我正在运行SASS 3.3.0.rc.2并且我遇到了一个奇怪的错误。我搜索谷歌的任何信息,但找不到任何信息。此文件曾用于早期版本的3.3.0。我删除了所有SASS宝石并重新安装,但它仍然在发生。当我尝试在文件上运行Sass时,我收到以下错误:
NoMethodError: undefined method `tabs' for Sass::Tree::CommentNode:Sass::Tree::CommentNode
当我使用--trace
标志时,我得到以下回溯:
/Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:252:in `block in visit_atroot': undefined method `tabs' for Sass::Tree::CommentNode:Sass::Tree::CommentNode (NoMethodError)
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:252:in `each'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:252:in `visit_atroot'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/base.rb:36:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:21:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:41:in `block in visit_children_without_parent'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:41:in `map'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:41:in `visit_children_without_parent'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:30:in `block in visit_children'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:61:in `with_parent'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:29:in `visit_children'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/base.rb:36:in `block in visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:223:in `visit_rule'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/base.rb:36:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:21:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:41:in `block in visit_children_without_parent'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:41:in `map'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:41:in `visit_children_without_parent'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:30:in `block in visit_children'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:61:in `with_parent'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:29:in `visit_children'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/base.rb:36:in `block in visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:74:in `visit_root'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/base.rb:36:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:21:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/base.rb:24:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/visitors/cssize.rb:6:in `visit'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/root_node.rb:38:in `css_tree'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/tree/root_node.rb:20:in `render'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/engine.rb:275:in `render'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/plugin/compiler.rb:347:in `update_stylesheet'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/plugin/compiler.rb:191:in `block in update_stylesheets'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/plugin/compiler.rb:188:in `each'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/plugin/compiler.rb:188:in `update_stylesheets'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/plugin/compiler.rb:223:in `watch'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/plugin.rb:108:in `method_missing'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/exec.rb:508:in `watch_or_update'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/exec.rb:346:in `process_result'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/exec.rb:43:in `parse'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/lib/sass/exec.rb:22:in `parse!'
from /Library/Ruby/Gems/2.0.0/gems/sass-3.3.0.rc.2/bin/sass:9:in `<top (required)>'
from /usr/bin/sass:23:in `load'
from /usr/bin/sass:23:in `<main>'
我找不到任何关于此的信息,并且文件没有任何新的更改。有任何想法吗?
EDIT1:我忘了提到我在其中使用了@ at-root的其他文件,编译得很好。这让我更加困惑。
答案 0 :(得分:0)
看起来它实际上是一个错误。我已经在GitHub上的SASS项目中提交了它,它将很快得到解决。以下是感兴趣或搜索的问题的链接:https://github.com/nex3/sass/issues/1082