Error: Cannot find module './client/BaseClient' - node.js

I was testing a discord bot package that was included in a Xenforo Addon. However, when I wanted to run the bot, it just returned this error
Error: Cannot find module './client/BaseClient'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
at Function.Module._load (internal/modules/cjs/loader.js:562:25)
at Module.require (internal/modules/cjs/loader.js:692:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object.<anonymous> (/home/bot/node_modules/discord.js/src/index.js:4:22)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
Any solution for that? Google doesn't seem to be good help at all.

Related

Cannot find module 'map-cache'

When I gulp serve my SPFx Webpart getting this error, also when creating a new webpart the result is same as below. I had searched a lot but I have not found any solution. Guys please help me to find out what is wrong.
D:\Mileage>gulp serve
internal/modules/cjs/loader.js:638
throw err;
^
Error: Cannot find module 'map-cache'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
at Function.Module._load (internal/modules/cjs/loader.js:562:25)
at Module.require (internal/modules/cjs/loader.js:690:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object.<anonymous> (C:\Users\cdku7557807\AppData\Roaming\npm\node_modules
\gulp\node_modules\parse-filepath\index.js:6:16)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
install npm package
npm install map-cache --save

How to fix `Cannot find module ./logging/Logger` in Webpack-cli

When i tried webpack build using webpack-cli by jenkins, following error comes up.
I already tried yarn upgrade, global added webpack-cli..
but nothing happens.
Following code is got by jenkins.
/var/lib/jenkins/workspace/websdk (develop)/node_modules/webpack-cli/bin/cli.js:93
throw err;
^
Error: Cannot find module './logging/Logger'
at Function.Module._resolveFilename (module.js:548:15)
at Function.Module._load (module.js:475:25)
at Module.require (module.js:597:17)
at require (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:161:20)
at Object.<anonymous> (/var/lib/jenkins/workspace/websdk (develop)/node_modules/webpack/lib/Stats.js:12:21)
at Module._compile (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:192:30)
at Object.Module._extensions..js (module.js:664:10)
at Module.load (module.js:566:32)
at tryModuleLoad (module.js:506:12)
at Function.Module._load (module.js:498:3)
at Module.require (module.js:597:17)
at require (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:161:20)
at Object.<anonymous> (/var/lib/jenkins/workspace/websdk (develop)/node_modules/webpack/lib/Compilation.js:30:15)
at Module._compile (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:192:30)
at Object.Module._extensions..js (module.js:664:10)
at Module.load (module.js:566:32)
at tryModuleLoad (module.js:506:12)
at Function.Module._load (module.js:498:3)
at Module.require (module.js:597:17)
at require (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:161:20)
at Object.<anonymous> (/var/lib/jenkins/workspace/websdk (develop)/node_modules/webpack/lib/Compiler.js:20:21)
at Module._compile (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:192:30)
at Object.Module._extensions..js (module.js:664:10)
at Module.load (module.js:566:32)
at tryModuleLoad (module.js:506:12)
at Function.Module._load (module.js:498:3)
at Module.require (module.js:597:17)
at require (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:161:20)
at Object.<anonymous> (/var/lib/jenkins/workspace/websdk (develop)/node_modules/webpack/lib/webpack.js:7:18)
at Module._compile (/var/lib/jenkins/workspace/websdk (develop)/node_modules/v8-compile-cache/v8-compile-cache.js:192:30)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Use npm install webpack in terminal and try

Error: Cannot find module 'symbol-observable' in Ionic 4

Tried running ng serve this error keep appearing
Error: Cannot find module 'symbol-observable'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:636:15)
at Function.Module._load (internal/modules/cjs/loader.js:562:25)
at Module.require (internal/modules/cjs/loader.js:690:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object.<anonymous> (C:\Users\USER\AppData\Roaming\npm\node_modules\#angular\cli\lib\init.js:10:1)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
using npm
npm install --save symbol-observable
https://github.com/benlesh/symbol-observable
then import it where you using
import Symbol_observable from 'symbol-observable';

Cannot find module '#babel/runtime/core-js/object/create' Node js Express

I have an express project and its running perfectly on my local machine (Windows).
When i try to deploy it (on ubuntu), i am getting
Error: Cannot find module '#babel/runtime/core-js/object/create'
at Function.Module._resolveFilename (module.js:548:15)
at Function.Module._load (module.js:475:25)
at Module.require (module.js:597:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (/var/www/project/node_modules/xregexp/lib/xregexp.js:10:38)
at Module._compile (module.js:653:30)
at Object.Module._extensions..js (module.js:664:10)
at Module.load (module.js:566:32)
at tryModuleLoad (module.js:506:12)
at Function.Module._load (module.js:498:3)
at Module.require (module.js:597:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (/var/www/project/node_modules/xregexp/lib/index.js:10:39)
at Module._compile (module.js:653:30)
at Object.Module._extensions..js (module.js:664:10)
at Module.load (module.js:566:32)
at tryModuleLoad (module.js:506:12)
at Function.Module._load (module.js:498:3)
at Module.require (module.js:597:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (/var/www/project/controllers/script.js:3:15)
at Module._compile (module.js:653:30)
I tried npm install babel-runtime --save but it didn't solve anything
hit this issue this morning as well. Are you by chance using xregexp? If so, lock the version to 4.2.0 in your package.json by removing any leading carrot. "xregexp": "4.2.0"
https://github.com/slevithan/xregexp/issues/262
Update: Looks like they have fixed it in 4.2.3.

Cannot Package Visual...'PBIVIZ Package' Errors Out

I've been developing a Power BI visual and it works fine using pbiviz start and the Power BI site's developer visual. So I'm ready to package it. I tried pbiviz package, but get these errors:
C:\Users\MARC_000\Desktop\OrdinalScatterChart>pbiviz package
module.js:472
throw err;
^
Error: Cannot find module './nodejs/NodejsStreamInputAdapter'
at Function.Module._resolveFilename (module.js:470:15)
at Function.Module._load (module.js:418:25)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (C:\Users\MARC_000\AppData\Roaming\npm\node_modules\powerbi-visuals-tools\node_modules\jszip\lib\object.js:11:32)
at Module._compile (module.js:571:32)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
Any idea why I'm getting these and how to fix my problem?

Resources