It is not written that this module is needed in any of the codes
I tried to download this module but it did not work
please help me
Require stack:
- C:\Users\danie\Desktop\DiscordBot-Template-master\node_modules\#discordjs\rest\dist\lib\handlers\SequentialHandler.js
- C:\Users\danie\Desktop\DiscordBot-Template-master\node_modules\#discordjs\rest\dist\lib\RequestManager.js
- C:\Users\danie\Desktop\DiscordBot-Template-master\node_modules\#discordjs\rest\dist\index.js
- C:\Users\danie\Desktop\DiscordBot-Template-master\bot.js
←[90m at Function.Module._resolveFilename (internal/modules/cjs/loader.js:885:15)←[39m
←[90m at Function.Module._load (internal/modules/cjs/loader.js:730:27)←[39m
←[90m at Module.require (internal/modules/cjs/loader.js:957:19)←[39m
←[90m at require (internal/modules/cjs/helpers.js:88:18)←[39m
at Object.<anonymous> (C:\Users\danie\Desktop\DiscordBot-Template-master\node_modules\←[4m#discordjs←[24m\rest\dist\lib\handlers\SequentialHandler.js:6:20)
←[90m at Module._compile (internal/modules/cjs/loader.js:1068:30)←[39m
←[90m at Object.Module._extensions..js (internal/modules/cjs/loader.js:1097:10)←[39m
←[90m at Module.load (internal/modules/cjs/loader.js:933:32)←[39m
←[90m at Function.Module._load (internal/modules/cjs/loader.js:774:14)←[39m
←[90m at Module.require (internal/modules/cjs/loader.js:957:19)←[39m {
code: ←[32m'MODULE_NOT_FOUND'←[39m,
requireStack: [
←[32m'C:\\Users\\danie\\Desktop\\DiscordBot-Template-master\\node_modules\\#discordjs\\rest\\dist\\lib\\handlers\\SequentialHandler.js'←[39m,
←[32m'C:\\Users\\danie\\Desktop\\DiscordBot-Template-master\\node_modules\\#discordjs\\rest\\dist\\lib\\RequestManager.js'←[39m,
←[32m'C:\\Users\\danie\\Desktop\\DiscordBot-Template-master\\node_modules\\#discordjs\\rest\\dist\\index.js'←[39m,
←[32m'C:\\Users\\danie\\Desktop\\DiscordBot-Template-master\\bot.js'←[39m
]
}```
It is most probably due to incompatible node version, consider downloading node.js v16 and above if it is already at v16 consider updating your types by running the following in the shell.
npm install --save-dev #types/node#latest
This issue can be solved by simple updating your node environment to node 16.x
The easiest way of doing this is by using nvm
nvm install 16
nvm use 16
Related
I'm trying run a server configuration whit this instruccion.
forever start --uid "mns_server_dev_7200" index.js.
but I can't, I have this error
module.js:549
throw err;
^
Error: Cannot find module 'mongoose'
at Function.Module._resolveFilename (module.js:547:15)
at Function.Module._load (module.js:474:25)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at Object. (/mns_server/index.js:12:16)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3) error: Forever detected script exited with code: 1
but in my npm list I have installed the module 'mongoose'
part of modules list
so, I have been readding about this bug but I couldn't resolve it
When I am trying to start my Discord.JS BOT, it shows up this error:
root#Gabitzuu-Teo:/home/5times# node bot
module.js:538
throw err;
^
Error: Cannot find module './packets/WebSocketPacketManager'
at Function.Module._resolveFilename (module.js:536:15)
at Function.Module._load (module.js:466:25)
at Module.require (module.js:579:17)
at require (internal/module.js:11:18)
at Object. (/home/5times/node_modules/discord.js/src/client/websocket/WebSocketConnection.js:5:23)
at Module._compile (module.js:635:30)
at Object.Module._extensions..js (module.js:646:10)
at Module.load (module.js:554:32)
at tryModuleLoad (module.js:497:12)
at Function.Module._load (module.js:489:3)
root#Gabitzuu-Teo:/home/5times#
(5times - my BOT's name.)
Does MySQL break it?
It would be helpful if you could provide us with your code.
It appears you're missing a module
Error: Cannot find module './packets/WebSocketPacketManager'
If you navigate to your bots folder in your terminal you can then type npm install into your terminal and it should install all dependancies listed in your package.json
I encounter the following error when trying to start the development server using yarn run. It seems something to do with path to npm package options mocha. I'm using Windows 8.1. I installed cross-env if it involved NODE env variable, but to no avail. Can you describe why this is happening?
Error: cannot resolve path (or pattern) '$npm_package_options_mocha'
at Object.lookupFiles (C:\Users\Kaleab\Desktop\addis_map\google-maps-react
ode_modules\mocha\lib\utils.js:634:15)
at C:\Users\Kaleab\Desktop\addis_map\google-maps-react\node_modules\mocha\
n\_mocha:327:30
at Array.forEach (native)
at Object.<anonymous> (C:\Users\Kaleab\Desktop\addis_map\google-maps-react
ode_modules\mocha\bin\_mocha:326:6)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.runMain (module.js:604:10)
at run (bootstrap_node.js:393:7)
at startup (bootstrap_node.js:150:9)
at bootstrap_node.js:508:3
Done in 46.84s.
i'm trying to install this plugin : https://github.com/phonegap/phonegap-plugin-barcodescanner but the following error shows up:
SyntaxError: Unexpected token =>
at exports.runInThisContext (vm.js:73:16)
at Module._compile (module.js:443:25)
at Object.Module._extensions..js (module.js:478:10)
at Module.load (module.js:355:32)
at Function.Module._load (module.js:310:12)
at Module.require (module.js:365:17)
at require (module.js:384:17)
at Object.<anonymous> (C:\Users\guadha.peralta\AppData\Roaming\npm\node_modules\phonegap\lib\phonegap\serve.js:9:23)
at Module._compile (module.js:460:26)
at Object.Module._extensions..js (module.js:478:10)
what could be the problem?
The "arrow function" => are ES6 functions. Update node to minimum v4.4.5 which starts supporting ES6. On windows you must have installed the latest version of node, which supports that type of function.
Update node on Windows
Run PowerShell as Administrator and execute the following command:
npm install -g npm-windows-upgrade
I'm working on an app using meteor and angular. It was working fine, but now when I try to start it, I get this:
While processing files with ecmascript (for target web.browser):
module.js:338:15: Cannot find module 'babel-plugin-transform-runtime'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous>
(C:\Users\user\AppData\Local\.meteor\packages\ecmascript\0.4.1\plugin.compile-ecmascript.os\npm\node_modules\meteor\babel-compiler\node_modules\meteor\babel-compiler\node_modules\meteor-babel\node_modules\babel-preset-meteor\index.js:4:6)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.getDefaults
(C:\Users\user\AppData\Local\.meteor\packages\ecmascript\0.4.1\plugin.compile-ecmascript.os\npm\node_modules\meteor\babel-compiler\node_modules\meteor\babel-compiler\node_modules\meteor-babel\options.js:11:15)
at Object.getDefaultOptions (packages/babel-compiler.js:42:29)
at packages/babel-compiler.js:133:32
at Array.forEach (native)
at BabelCompiler.BCp.processFilesForTarget (packages/babel-compiler.js:99:14)
While minifying app stylesheet:
module.js:338:15: Cannot find module 'source-map-url'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous>
(C:\Users\user\AppData\Local\.meteor\packages\standard-minifier-css\1.0.4\plugin.minifyStdCSS.os\npm\node_modules\meteor\minifier-css\node_modules\meteor\minifier-css\node_modules\css-stringify\node_modules\css\node_modules\source-map-resolve\lib\source-map-resolve-node.js:4:24)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous>
(C:\Users\user\AppData\Local\.meteor\packages\standard-minifier-css\1.0.4\plugin.minifyStdCSS.os\npm\node_modules\meteor\minifier-css\node_modules\meteor\minifier-css\node_modules\css-stringify\node_modules\css\lib\stringify\source-map-support.js:8:24)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.module.exports
(C:\Users\user\AppData\Local\.meteor\packages\standard-minifier-css\1.0.4\plugin.minifyStdCSS.os\npm\node_modules\meteor\minifier-css\node_modules\meteor\minifier-css\node_modules\css-stringify\node_modules\css\lib\stringify\index.js:32:22)
at packages/minifyStdCSS_plugin.js:95:33
at CssToolsMinifier.processFilesForBundle (packages/minifyStdCSS_plugin.js:30:16)
While processing files with ecmascript (for target os.windows.x86_32):
module.js:338:15: Cannot find module 'babel-plugin-transform-runtime'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.<anonymous>
(C:\Users\user\AppData\Local\.meteor\packages\ecmascript\0.4.1\plugin.compile-ecmascript.os\npm\node_modules\meteor\babel-compiler\node_modules\meteor\babel-compiler\node_modules\meteor-babel\node_modules\babel-preset-meteor\index.js:4:6)
at Module._compile (module.js:456:26)
at Object.Module._extensions..js (module.js:474:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:312:12)
at Module.require (module.js:364:17)
at require (module.js:380:17)
at Object.getDefaults
(C:\Users\user\AppData\Local\.meteor\packages\ecmascript\0.4.1\plugin.compile-ecmascript.os\npm\node_modules\meteor\babel-compiler\node_modules\meteor\babel-compiler\node_modules\meteor-babel\options.js:11:15)
at Object.getDefaultOptions (packages/babel-compiler.js:42:29)
at packages/babel-compiler.js:133:32
at Array.forEach (native)
at BabelCompiler.BCp.processFilesForTarget (packages/babel-compiler.js:99:14)
=> Your application has errors. Waiting for file change.
I tried running another app, and it works fine, but this one doesn't.
I'm ruuning Meteor 1.3 on windows 10
I fixed the problem by updating to a 1.3.1 release after reading this issue comment https://github.com/meteor/meteor/issues/6609#issuecomment-205016877
meteor update --release 1.3.1-rc.3
It looks like you're simply missing (at least) two modules:
babel-plugin-transform-runtime
source-map-url
Try installing them and retry...
For me, I had the same issue but fixed it by downgrading my meteor version from 1.3.3.1 to 1.3.2.4. run command
meteor update --release=METEOR#1.3.2.4
Although the process takes some good time to complete