Ale*_*dro 1 python less node.js odoo
我刚刚安装了 Odoo 的全新安装(没有自定义插件/模块),在创建数据库后,我在主页上收到此错误:
The style compilation failed, see the error below. Your recent actions may be the cause, please try reverting the changes you made.
(b'', b'TypeError: sys.print is not a function
at /usr/lib/nodejs/less/bin/lessc:384:25
at tree.importVisitor.finish [as _finish] (/usr/lib/nodejs/less/lib/less/parser.js:669:28)
at tree.importVisitor.run (/usr/lib/nodejs/less/lib/less/import-visitor.js:25:22)
at Object.parse (/usr/lib/nodejs/less/lib/less/parser.js:675:22)
at parseLessFile (/usr/lib/nodejs/less/bin/lessc:345:12)
at Socket. (/usr/lib/nodejs/less/bin/lessc:407:9)
at Socket.emit (events.js:228:7)
at endReadableNT (_stream_readable.js:1185:12)
at processTicksAndRejections (internal/process/task_queues.js:81:21)
')This error occured while compiling the bundle 'web.assets_common' containing:
- /web/static/lib/bootstrap/less/variables.less
....
Run Code Online (Sandbox Code Playgroud)
经过谷歌的一些研究后,我已经尝试过:
将nodejs链接到/usr/bin中的节点
重新安装node-js、less-js、uglify-js
重新安装所有 pip3 Odoo 要求
每次尝试后都会删除我的数据库
降级至 1.3.3
我的版本:
NodeJs v12.14.1
版本 6.13.4
少@3.11.1
less-plugin-clean-css@1.5.1
正如我所见,这不是一个常见的错误,并且没有详细记录在这种情况下该怎么做。有人见过类似的东西吗?
小智 5
我最近在 Ubuntu 18.04 上的 Odoo 11 上遇到了类似的错误,我安装了 less apt install node-less(它安装了 lessc 1.6.3)。安装 less npm install -g less(npm 6.13.4,nodejs 12.16.1,安装 lessc 3.11.1)使其工作。
奇怪的是你说你已经有了 lessc 3.11.1。也许尝试不太完全地删除并使用 npm 安装它。