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
We have migrated from xsjs to async-xsjs using tool and we can see async as well as await blocks.
But when we run the node app, it throws error as below.
File "/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/lib/termdbreptask.xsjs" rejected: vm.SourceTextModule is not a constructor#
Aug 02, 2023 11:06:24 AM Logger.js [] ERROR: vm.SourceTextModule is not a constructor
TypeError: vm.SourceTextModule is not a constructor
at EcmaModule.getModule (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/runtime.js:729:18)
at async Runtime.xsjs (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/runtime.js:637:5)
at async Object.createRuntime (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/runtime.js:446:9)
at async module.exports (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/index.js:38:12)
at async startServer (file:///home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/server.js:52:27)
[ERROR] Node XSJS Server not running Some of the files in the working dir(s) were rejected. Check the logs.
The text was updated successfully, but these errors were encountered:
@KeshavHeda I had the same issue and was able to get my application running by adding the --experimental-vm-modules option to my startup command: node --experimental-vm-modules start.js
We have migrated from xsjs to async-xsjs using tool and we can see async as well as await blocks.
But when we run the node app, it throws error as below.
File "/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/lib/termdbreptask.xsjs" rejected: vm.SourceTextModule is not a constructor#
Aug 02, 2023 11:06:24 AM Logger.js [] ERROR: vm.SourceTextModule is not a constructor
TypeError: vm.SourceTextModule is not a constructor
at EcmaModule.getModule (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/runtime.js:729:18)
at async Runtime.xsjs (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/runtime.js:637:5)
at async Object.createRuntime (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/runtime.js:446:9)
at async module.exports (/home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/node_modules/@sap/async-xsjs/lib/index.js:38:12)
at async startServer (file:///home/user/projects/SAP-TERMINOLOGY-DB/termdb_sched/server.js:52:27)
[ERROR] Node XSJS Server not running Some of the files in the working dir(s) were rejected. Check the logs.
The text was updated successfully, but these errors were encountered: