build_tools
build_tools copied to clipboard
Mobile web failed to build with default configuration
cd tools/linux ./automate.py server I would get the error reports:
>> /build/web-apps/vendor/framework7-react/node_modules/ora/index.js:1
>> import process from 'node:process';
>> ^^^^^^^
>>
>> SyntaxError: Unexpected identifier
>> at Module._compile (internal/modules/cjs/loader.js:723:23)
>> at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
>> at Module.load (internal/modules/cjs/loader.js:653:32)
>> at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
>> at Function.Module._load (internal/modules/cjs/loader.js:585:3)
>> at Module.require (internal/modules/cjs/loader.js:692:17)
>> at require (internal/modules/cjs/helpers.js:25:18)
>> at Object.<anonymous> (/build/web-apps/vendor/framework7-react/build/build.js:2:13)
>> at Module._compile (internal/modules/cjs/loader.js:778:30)
>> at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
in the out directory, we do not get mobile web pages. ls build_tools/out/js/onlyoffice/builder/web-apps/apps/documenteditor/mobile/ will get: dist locale resources
Hi.
- Try to build it not only
server
but whole package via./automate.py
without any params - By building mobile client from source code it will not allow editing, since it's not a part of open-source package, it should be built, but will show license warning on opening
Hi.
- Try to build it not only
server
but whole package via./automate.py
without any params- By building mobile client from source code it will not allow editing, since it's not a part of open-source package, it should be built, but will show license warning on opening
I have tested again. With a new installed Ubuntu 16.04 system. And run ./automate.py
without any params.
Just no luck. I believe it is problem about the bundled framework7-react.
>> npm
>> WARN read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but npm-shrinkwrap.json was generated for lockfileVersion@2. I'll try to do my best with it!
......
> [email protected] deploy-word /build/web-apps/vendor/framework7-react
> cross-env TARGET_EDITOR=word NODE_ENV=production node ./build/build.js
error in promise Error: Not supported
at Object.<anonymous> (/build/web-apps/vendor/framework7-react/build/build.js:8:9)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:831:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3)
The built target contains no mobile pages. When open with mobile devices, the page will jump to 404 error.
@qianwch Ok, thanks I'll recheck
Our developers said that there is a possible workaround
Remove web-apps\vendor\framework7-react\node_modules
folder and run npm install
in web-apps\vendor\framework7-react
And after that continue build process
But I'm not 100% this helps
Our developers said that there is a possible workaround
Remove
web-apps\vendor\framework7-react\node_modules
folder and runnpm install
inweb-apps\vendor\framework7-react
And after that continue build process
But I'm not 100% this helps
Yes, still no luck.
which version of nodejs and npm do you use?
The nodejs and npm is auto installed by build_tools, v10.24.1 and 6.14.17.
Now it worked, I need to install nodejs 12.22.12, then run ./automate.py server It seems that the build script needs to be updated as nodejs 10 does not work.
Glad that you've figure it out, but there is still some bug
Since we planned that mobile viewers should work with default build config (with nodejs 10)
I've created issue 59569 in our private issue tracker to figure it out
Hello @qianwch, sorry for the late reply. It's fixed some time ago, we up node version to 16.
I close this issue. Feel free to comment or reopen it if you got further questions.