You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Without that I observed that quite often (3 of 5) a clean run (platform with plugins readded) of project with local plugin with several frameworks with clashing dependency lists fails on some random error in regards to imports from node modules.
Each time I found some installed packages with missing files.
Sample error:
2021-10-07 17:07:05.078] [error] UncaughtException on origin uncaughtException Error: Cannot find module './utf8'
Require stack:
- D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\platforms\electron\www\node_modules\jszip\lib\object.js
- D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\platforms\electron\www\node_modules\jszip\lib\index.js
- D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\platforms\electron\www\node_modules\unzip-crx-3\dist\index.js
- D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\platforms\electron\www\node_modules\electron-devtools-installer\dist\downloadChromeExtension.js
- D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\platforms\electron\www\node_modules\electron-devtools-installer\dist\index.js
- D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\platforms\electron\www\cdv-electron-main.js
- D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\node_modules\electron\dist\resources\default_app.asar\main.js
-
at Module._resolveFilename (internal/modules/cjs/loader.js:892:15)
at Function.n._resolveFilename (electron/js2c/browser_init.js:245:1128)
at Module._load (internal/modules/cjs/loader.js:737:27)
at Function.f._load (electron/js2c/asar_bundle.js:5:12913)
at Module.require (internal/modules/cjs/loader.js:964:19)
at require (internal/modules/cjs/helpers.js:88:18)
at Object.<anonymous> (D:\ACTTool\Meta\projects\App-ACTTool-FrontEnd-TestTool\cordova\platforms\electron\www\node_modules\jszip\lib\object.js:2:12)
at Module._compile (internal/modules/cjs/loader.js:1083:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1113:10)
at Module.load (internal/modules/cjs/loader.js:940:32)
The source of problem seems to be asynchroncity of execa.
I have a related problem, but the proposed solution does not fix it.
To reproduce my scenario, you need a plugin that support electron and another platform (I'm using android). The electron part needs to use a framework entry. Then the steps are:
create a new cordova project
add the 2 platforms supported by your plugin
add the plugin
rm -rf platforms plugins
cordova prepare android (use the other platform instead of android if you didn't use android)
cordova prepare electron
The suggested fix does not help, because at that point platforms/electron/www does not exist yet. So the npm command fails. Creating the directory does not help, because package.json would be missing anyway.
If you think this is a different issue, I'm happy to open a separate issue.
Hi! 👋
Firstly, thanks for your work on this project! 🙂
Today I used patch-package to patch
[email protected]
for the project I'm working on.Without that I observed that quite often (3 of 5) a clean run (platform with plugins readded) of project with local plugin with several frameworks with clashing dependency lists fails on some random error in regards to imports from node modules.
Each time I found some installed packages with missing files.
Sample error:
The source of problem seems to be asynchroncity of execa.
Here is the diff that solved my problem:
This issue body was partially generated by patch-package.
The text was updated successfully, but these errors were encountered: