Thanks to the quick implementation in js-controller v6 adding custom modules from a GitHub URL now works again. 👍
The only remaining small "issue" is that in scripts you need to require the module by its full URL instead of its module name, as it used to be.
Example:
// Does NOT work anymore -> Error: Cannot find module 'node-mihome'
const mihome = require("node-mihome");
// Does work now
const mihome = require("git+https://github.com/Black-Thunder/node-mihome.git");
I'm sure that
Script type
any
The problem
Follow-up issue to https://github.com/ioBroker/ioBroker.js-controller/issues/2796
Thanks to the quick implementation in js-controller v6 adding custom modules from a GitHub URL now works again. 👍 The only remaining small "issue" is that in scripts you need to require the module by its full URL instead of its module name, as it used to be.
Example:
Probably because of this line where it is stored in "context.mods" by its "depName" instead of its "moduleName": https://github.com/ioBroker/ioBroker.javascript/blob/3330827ddd24c642955d47bda3a50ba2f4f5ae0e/main.js#L1873
Is this the intended behaviour now? If so, maybe this should be added to the docs.
iobroker.current.log (in debug mode!)
No response
Version of nodejs
20.14.0
Version of ioBroker js-controller
6.0.4
Version of adapter
latest GitHub version as of now (commit 3330827)