Cannot find module error
Closed this issue · 4 comments
Hi,
I'm trying to use local-action. But I'm getting error
Error: Cannot find module 'C:UsersKKAMIAppDataRoamingnpmnode_modules@githublocal-actionsrcbootstrap.js'
Require stack:
- internal/preload
at Module._resolveFilename (node:internal/modules/cjs/loader:1143:15)
at Module._load (node:internal/modules/cjs/loader:984:27)
at internalRequire (node:internal/modules/cjs/loader:174:19)
at Module._preloadModules (node:internal/modules/cjs/loader:1574:5)
at loadPreloadModules (node:internal/process/pre_execution:723:5)
at setupUserModules (node:internal/process/pre_execution:203:5)
at prepareExecution (node:internal/process/pre_execution:159:5)
at prepareMainThreadExecution (node:internal/process/pre_execution:54:10)
at node:internal/main/run_main_module:11:19 {
code: 'MODULE_NOT_FOUND',
requireStack: [ 'internal/preload' ]
I tried both ways of installation - via npm (npm i -g @github/local-action) and from cloned repository. In both scenarios I'm getting this error. With cloned repository just module path is changed.
I'm getting this error when I'm trying to run my local action locally, but also when I run help and version commands (local-action --help, local-action --version).
I see that path 'C:UsersKKAMIAppDataRoamingnpmnode_modules@githublocal-actionsrcbootstrap.js' does not contain slashes or backslashes, maybe here something is wrong? Do you know what I should do to use local-action?
Hmmm...definitely looks like an issue with path resolution on Windows vs macOS/Linux. I will test this out a bit today and reply back when I have some info :)
This should be fixed in v1.5.0 of @github/local-action
:) Please try installing the latest version and let me know if you run into any issues!
Awesome, glad to hear it!