高版本的libsass模块编译scss文件时报错:Error: Custom property values may not be empty.

admin 2019-11-5 10719

今天把odoo13的运行环境中python升级到3.7,源码包中指定的libsass版本是0.12.3,不支持python3.7,所以干脆安装了最高版本 0.19.4,然后启动odoo后,发现编译scss文件出错了(web_gantt.scss):

sassc: error: Error: Custom property values may not be empty.
        on line 299:19 of web_gantt.scss
>>                 &:first-child() {
   ------------------^

肉眼查看scss并无问题。于是怀疑是libsass的问题,从0.12.3开始一个个版本往上加,加到0.15.1(0.14.x都不支持python3.7),再编译,问题解决。


教训:

python模块并非版本越高越好!!

====================

附:手工编译scss文件的例子:

f:>GOdoo13> runtime\python\scripts\sassc.exe web_gantt.scss web_gantt.css
f:\GOdoo13\runtime\python\lib\site-packages\sassc.py:9: FutureWarning: The `sassc` entrypoint is deprecated, please use `pysassc`
  FutureWarning,
sassc: error: Error: Custom property values may not be empty.
        on line 299:19 of web_gantt.scss
>>                 &:first-child() {
   ------------------^


最新回复 (0)
返回