I'm programming a discord bot using discord.js and am trying to use Heroku to host the bot.
When I deploy it Heroku says the deployment was successful but my bot is still offline in discord. When I check the log it shows :
2020-01-10T21:55:49.598875+00:00 app[worker.1]: npm ERR! code ELIFECYCLE
2020-01-10T21:55:49.599295+00:00 app[worker.1]: npm ERR! errno 1
2020-01-10T21:55:49.600878+00:00 app[worker.1]: npm ERR! funamibot#1.0.0 start: `node index.js`
2020-01-10T21:55:49.601091+00:00 app[worker.1]: npm ERR! Exit status 1
2020-01-10T21:55:49.601329+00:00 app[worker.1]: npm ERR!
2020-01-10T21:55:49.601552+00:00 app[worker.1]: npm ERR! Failed at the funamibot#1.0.0 start script.
2020-01-10T21:55:49.601651+00:00 app[worker.1]: npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
2020-01-10T21:55:49.607761+00:00 app[worker.1]:
2020-01-10T21:55:49.607944+00:00 app[worker.1]: npm ERR! A complete log of this run can be found in:
2020-01-10T21:55:49.608089+00:00 app[worker.1]: npm ERR! /app/.npm/_logs/2020-01-10T21_55_49_602Z-debug.log
From the error it gives it seems to do with the start script in the package.json file, but i'm not sure what the problem is or how to fix it.
The bot code on github : https://github.com/Yunoxa/funamibot/
You must include the versions to use for both node and npm (I'd recommend using the latest):
"engines": {
"node": "12.14.1",
"npm": "6.13.4"
},
However if you are using specific versions of either node or npm, do this and replace the version numbers I specified:
node -v (Returns the current version of Node you're running.)
npm -v (Returns the current version of NPM you're running.)
Related
When i am opening a page it shows error
Vite manifest not found at: C:\xampp\htdocs\laravel_project\lara_project\public/build/manifest.json
and my command prompt showing error
# dev C:\xampp\htdocs\laravel_project\lara_project
vite
internal/process/esm_loader.js:74
internalBinding('errors').triggerUncaughtException(
^
Error [ERR_UNSUPPORTED_ESM_URL_SCHEME]: Only file and data URLs are supported by the default ESM loader. Received protocol 'node:'
at Loader.defaultResolve [as _resolve] (internal/modules/esm/resolve.js:756:11)
at Loader.resolve (internal/modules/esm/loader.js:85:40)
at Loader.getModuleJob (internal/modules/esm/loader.js:229:28)
at ModuleWrap. (internal/modules/esm/module_job.js:51:40)
at link (internal/modules/esm/module_job.js:50:36) {
code: 'ERR_UNSUPPORTED_ESM_URL_SCHEME'
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! # dev: vite
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the # dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Sudha\AppData\Roaming\npm-cache_logs\2022-07-24T09_53_42_124Z-debug.log
hello i'm beginner at Laravel. i'm trying to learn Laravel Authentication but i'm facing errors.
I'm facing errors in my Laravel learning project where I'm facing npm run dev problem in Laravel Authentication how can i solve this problem?
here are the steps i've took
I've installed node.js and set the Authentication by
composer require laravel/ui
php artisan ui vue --auth
after that
npm install --verbose
here Is my CMD Command
PS C:\xampp\htdocs\myapp> npm run dev
Here is the errors I'm Facing:
> # dev C:\xampp\htdocs\myapp
> npm run development
> # development C:\xampp\htdocs\myapp
> mix
[webpack-cli] Error: Cannot find module 'webpack/lib/rules/DescriptionDataMatcherRulePlugin'
Require stack:
- C:\xampp\htdocs\myapp\node_modules\vue-loader\lib\plugin-webpack5.js
- C:\xampp\htdocs\myapp\node_modules\vue-loader\lib\plugin.js
- C:\xampp\htdocs\myapp\node_modules\vue-loader\lib\index.js
- C:\xampp\htdocs\myapp\node_modules\laravel-mix\src\components\Vue.js
- C:\xampp\htdocs\myapp\node_modules\laravel-mix\src\components\ComponentRegistrar.js
- C:\xampp\htdocs\myapp\node_modules\laravel-mix\src\Mix.js
- C:\xampp\htdocs\myapp\node_modules\laravel-mix\setup\webpack.config.js
- C:\xampp\htdocs\myapp\node_modules\webpack-cli\lib\webpack-cli.js
- C:\xampp\htdocs\myapp\node_modules\webpack-cli\lib\bootstrap.js
- C:\xampp\htdocs\myapp\node_modules\webpack-cli\bin\cli.js
- C:\xampp\htdocs\myapp\node_modules\webpack\bin\webpack.js
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:889:15)
at Function.Module._load (internal/modules/cjs/loader.js:745:27)
at Module.require (internal/modules/cjs/loader.js:961:19)
at require (C:\xampp\htdocs\myapp\node_modules\v8-compile-cache\v8-compile-cache.js:159:20)
at Object.<anonymous> (C:\xampp\htdocs\myapp\node_modules\vue-loader\lib\plugin-webpack5.js:6:42)
at Module._compile (C:\xampp\htdocs\myapp\node_modules\v8-compile-cache\v8-compile-cache.js:192:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1101:10)
at Module.load (internal/modules/cjs/loader.js:937:32)
at Function.Module._load (internal/modules/cjs/loader.js:778:12)
at Module.require (internal/modules/cjs/loader.js:961:19) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'C:\\xampp\\htdocs\\myapp\\node_modules\\vue-loader\\lib\\plugin-webpack5.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\vue-loader\\lib\\plugin.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\vue-loader\\lib\\index.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\laravel-mix\\src\\components\\Vue.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\laravel-mix\\src\\components\\ComponentRegistrar.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\laravel-mix\\src\\Mix.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\laravel-mix\\setup\\webpack.config.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\webpack-cli\\lib\\webpack-cli.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\webpack-cli\\lib\\bootstrap.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\webpack-cli\\bin\\cli.js',
'C:\\xampp\\htdocs\\myapp\\node_modules\\webpack\\bin\\webpack.js'
]
}
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! # development: `mix`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the # development script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\ASUS\AppData\Roaming\npm-cache\_logs\2021-09-21T05_52_12_933Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! # dev: `npm run development`
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the # dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\ASUS\AppData\Roaming\npm-cache\_logs\2021-09-21T05_52_12_972Z-debug.log
I am not able to npm start STRAPI, it shows follwiting error. I'm using STRAPI 3.1.3
> my-project#0.1.0 strapi /Users/mac/Documents/Development_env/jobBackend/my-project
> strapi "develop"
Error while running command develop: undefined
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! my-prject#0.1.0 strapi: `strapi "develop"` npm ERR! Exit status 1
npm ERR!
macs-Air:my-project mac$ npm start
> my-project#0.1.0 start /Users/mac/Documents/Development_env/jobBackend/my-project
> strapi start
Error while running command start: undefined
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! my-project#0.1.0 start: `strapi start`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the my-project#0.1.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/mac/.npm/_logs/2020-08-13T17_02_08_854Z-debug.log
I just saw this error too. I upgraded to strapi 3.1.4 and got a more useful error indicating a syntax error in one of my functions files. After fixing that, strapi commands worked as ever.
npm run build
npm start
Or install strapi-cli globally using below command.
npm install -g strapi#beta
After successful installation use
strapi develop
to start the project
I am trying to deploy on heroku but I keep getting this .env error, but it is present in my project. Could someone give some direction as to what I can do to resolve this or any possible mistakes I made?
tmp/build_057816491291ab18684f7791472a55f4/config/env.js:7
throw Error(’.env not found, please copy sample.env to .env.’);
^
Error: .env not found, please copy sample.env to .env.
at Object. (/tmp/build_057816491291ab18684f7791472a55f4/config/env.js:7:11)
at Module._compile (internal/modules/cjs/loader.js:1138:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:1158:10)
at Module.load (internal/modules/cjs/loader.js:986:32)
at Function.Module._load (internal/modules/cjs/loader.js:879:14)
at Module.require (internal/modules/cjs/loader.js:1026:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object. (/tmp/build_057816491291ab18684f7791472a55f4/tools/scripts/build/ensure-env.js:5:13)
at Module._compile (internal/modules/cjs/loader.js:1138:30)
at Object.Module._extensions…js (internal/modules/cjs/loader.js:1158:10)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! #freecodecamp/freecodecamp#0.0.1 ensure-env: cross-env DEBUG=fcc:* node ./tools/scripts/build/ensure-env.js
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the #freecodecamp/freecodecamp#0.0.1 ensure-env script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /tmp/npmcache.kGGVT/_logs/2020-07-09T14_23_29_322Z-debug.log
ERROR: “ensure-env” exited with 1.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! #freecodecamp/freecodecamp#0.0.1 build: npm-run-all ensure-env -p build:*
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the #freecodecamp/freecodecamp#0.0.1 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /tmp/npmcache.kGGVT/_logs/2020-07-09T14_23_29_344Z-debug.log
you will not be able to use a .env file on heroku.You need to either use the heroku cli to set this
heroku config:set DBHOST=database_host_here
heroku config:set DBPASS=database_pass_here
or you can use the heroku dashboard settings tab to edit config vars
reference: https://devcenter.heroku.com/articles/config-vars
Installing parse-server onto my dev box, I'm getting the following error when working through
/z/www/parse-server-example/node_modules/parse-server/lib/index.js:335
throw err;
^
TypeError: ParseServer.createLiveQueryServer is not a function
at Object.<anonymous> (/z/www/parse-server-example/index.js:55:13)
at Module._compile (module.js:413:34)
at Object.Module._extensions..js (module.js:422:10)
at Module.load (module.js:357:32)
at Function.Module._load (module.js:314:12)
at Function.Module.runMain (module.js:447:10)
at startup (node.js:142:18)
at node.js:939:3
npm ERR! Linux 3.13.0-83-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "start"
npm ERR! node v5.9.0
npm ERR! npm v3.7.3
npm ERR! code ELIFECYCLE
npm ERR! parse-server-example#1.4.0 start: `node index.js`
npm ERR! Exit status 7
npm ERR!
npm ERR! Failed at the parse-server-example#1.4.0 start script 'node index.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the parse-server-example package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node index.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs parse-server-example
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls parse-server-example
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /z/www/parse-server-example/npm-debug.log
I get the same error whether running nodejs index.js or npm start. I'm following the digital ocean instructions for parse-server installation. Has anyone ran into this issue or have any advice?
I used this guide and it works great, I prefer to use the parse-server and not the example version, all the environment variables are now supported so I would suggest to just follow the tutorial (U will not create a index.js but you will do it with ecosystem.json)
There was an issue with a commit the same day I was trying this, works fine now.