when I tried to run vscode-install, it would fail to sync vscode.d.ts. The problem seems random, most of our machines could not success, but two of our machines could success.
The error information is as follows:
Detected VS Code engine version: ^1.23.0
Error installing vscode.d.ts: Error: read ECONNRESET
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! lispvsext#0.0.1 postinstall: `vscode-install && node ./node_modules/vscode/bin/install`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the lispvsext#0.0.1 postinstall 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\*\AppData\Roaming\npm-cache\_logs\2019-02-15T09_28_45_624Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! lispvsext#1.0.8 postinstall: `cd extension && npm install && cd ..`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the lispvsext#1.0.8 postinstall 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\*\AppData\Roaming\npm-cache\_logs\2019-02-15T09_28_45_805Z-debug.log
I had a similar problem, where the VSCode engine in package.json was very old (1.32.0) compared to the current VSCode version (1.64.2). I just updated the engine to the same as my VSCode version in package.json:
"engines": {
"vscode": "^1.64.2"
},
and the tests runner proceeds instead of erroring as before.
Unfortunately, I then got another error:
Error: Running extension tests from the command line is currently only supported if no other instance of Code is running.
which is a different problem and a limitation of VSCode at the moment (1.64.2), though there is a workaround for that.
Related
I'm trying to deploy an app to heroku but for some reason when I run the deploy command I keep on getting this error:
rator-cli\postgrator-cli.js:143
rl.history = rl.history.slice(1);
^
TypeError: Cannot read property 'slice' of undefined
at C:\Users\Zackr\Documents\node\noteful-exercise\noteful-server\node_modules\postgrator-cli\postgrator-cli.js:143:33
at Interface._onLine (readline.js:327:5)
at Interface._normalWrite (readline.js:474:12)
at Socket.ondata (readline.js:186:10)
at Socket.emit (events.js:315:20)
at addChunk (_stream_readable.js:295:12)
at readableAddChunk (_stream_readable.js:271:9)
at Socket.Readable.push (_stream_readable.js:212:10)
at Pipe.onStreamRead (internal/stream_base_commons.js:186:23)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! noteful-server#1.0.0 migrate: `postgrator --config postgrator-config.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the noteful-server#1.0.0 migrate 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\Zackr\AppData\Roaming\npm-cache\_logs\2021-01-04T22_04_36_447Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! noteful-server#1.0.0 migrate:production: `env SSL=true DATABASE_URL=$postgres://rwdhntkhuroptu:48522106b9f5aaf0890905df7abe67c75710e00aba50b80edcf01a07d5cbe918#ec2-52-203-49-58.compute-1.amazonaws.com:5432/dcgq78oje0lmb6 npm run migrate`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the noteful-server#1.0.0 migrate:production 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\Zackr\AppData\Roaming\npm-cache\_logs\2021-01-04T22_04_36_547Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! noteful-server#1.0.0 postdeploy: `npm run migrate:production`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the noteful-server#1.0.0 postdeploy 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\Zackr\AppData\Roaming\npm-cache\_logs\2021-01-04T22_04_36_614Z-debug.log
The scripts for my package.json is:
"scripts": {
"test": "mocha --require test/setup.js",
"dev": "nodemon src/server.js",
"migrate": "postgrator --config postgrator-config.js",
"migrate:test": "env NODE_ENV=test npm run migrate",
"migrate:production": "env SSL=true DATABASE_URL=$(heroku config:get DATABASE_URL) npm run migrate",
"start": "node src/server.js",
"predeploy": "npm audit && npm run migrate:production",
"deploy": "git push heroku main"
},
I have the connection string and url for the database and the normal migration worked until I changed the url to the heroku URL instead of my local host server.
Node.js 6 was end-of-lifed in April 2018. It has known security vulnerabilities and most libraries don't support it. Update to at least Node.js 10.x, and preferably 14.x.
Current version of postgrator-cli is 4.0.0 and it explicitly doesn't support Node.js prior to 10.x. The last version of postgrator-cli to support Node.js 6.x was postgrator-cli 3.2.0, published in September 2019. So if you cannot upgrade Node.js, another option is to downgrade postgrator-cli to 3.2.0.
I'm creating an app with Electron (the GitHub instrument to create apps with html and node.js).
This app will be used by some computer that they aren't connected to internet.
I need to show a map and collocate markers on it (I found Leaflet), but all maps service require internet.
With Open Street Maps I can export an osm file but I can't find a way to render it into Leaflet, because the only library for node (mapbox-gl-native-master) who do it require C++11 and it gives me error in installation:
$ npm install mapbox-gl-native
> mapbox-gl-native#3.2.1 preinstall /home/dpd-/node_modules/.staging/mapbox-gl-native-eb973ff7
> npm install node-pre-gyp
npm ERR! Linux 4.4.0-24-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "node-pre-gyp"
npm ERR! node v4.2.6
npm ERR! npm v3.5.2
npm ERR! Cannot read property 'target' of null
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR! <https://github.com/npm/npm/issues>
npm ERR! Please include the following file with any support request:
npm ERR! /home/dpd-/node_modules/.staging/mapbox-gl-native-eb973ff7/npm-debug.log
npm WARN enoent ENOENT: no such file or directory, open '/home /dpd-/package.json'
npm WARN dpd- No description
npm WARN dpd- No repository field.
npm WARN dpd- No README data
npm WARN dpd- No license field.
npm ERR! Linux 4.4.0-24-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "mapbox-gl-native"
npm ERR! node v4.2.6
npm ERR! npm v3.5.2
npm ERR! code ELIFECYCLE
npm ERR! mapbox-gl-native#3.2.1 preinstall: `npm install node-pre-gyp`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the mapbox-gl-native#3.2.1 preinstall script 'npm install node-pre-gyp'.
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 mapbox-gl-native package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! npm install node-pre-gyp
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs mapbox-gl-native
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls mapbox-gl-native
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/dpd-/npm-debug.log
Take a look at either Kothic or Mapnik, Both should be more than capable of handling offline osm files. I guess Kothic will be a tad easier to implement (pure JS), since Mapnik essentially is a C++ library with a node.js interface. Additionally, Kothic claims easy integration with Leaflet, so I imagine this should suit you quite well.
Hi am getting the following error while trying to precompile my JSX code. I have been using it but something happened and I am unable to install this
npm install babel-preset-es2015 babel-preset-react
It is showing this error message:
npm ERR! Linux 3.13.0-85-generic npm ERR! argv "/usr/bin/nodejs"
"/usr/bin/npm" "install" "babel-preset-es2015" "babel-preset-react"
npm ERR! node v4.4.5 npm ERR! npm v2.15.5 npm ERR! file
/home/name/.npm/babel-plugin-check-es2015-constants/6.8.0/package/package.json
npm ERR! code EJSONPARSE
npm ERR! Failed to parse json npm ERR! Unexpected token '\u0000' at
1:1374 npm ERR!
e#readme","_id":"is-finite#1.0.1","_from":"is-finite#>=1.0.0 <2.0.0"}
npm ERR!
^ npm ERR! File:
/home/name/.npm/babel-plugin-check-es2015-constants/6.8.0/package/package.json
npm ERR! Failed to parse package.json data. npm ERR! package.json must
be actual JSON, not just JavaScript. npm ERR! npm ERR! This is not a
bug in npm. npm ERR! Tell the package author to fix their package.json
file. JSON.parse
npm ERR! Please include the following file with any support request:
npm ERR! /var/www/html/js/npm-debug.log
How to fix this?
If you want to install globally on your computer those modules, add -g:
npm install -g babel-preset-es2015 babel-preset-react
Otherwise, it meand you want to install it locally. Make sure your have package.json in the root used to launch that command. Follow package rules. Here is an example. Your can try to validate your package.json on package-json-validator.com
I have created the IBM Watson Natural Language Processor service and I'm trying to deploy the training application. It creates the project, clones the repository, and configures the pipeline, but gets an error during the 'Deploy to Bluemix' step.
The error is:
Cloning the 'master' branch from repo 'https://P90MSG01:3041/git/esilky/ibmwatson-nlc-groundtruth-esilky-952'
/opt/IBM/node/bin/npm -> /opt/IBM/node/lib/node_modules/npm/bin/npm-cli.js
npm ERR! Error: EACCES, mkdir '/opt/IBM/node/share/man/man3'
npm ERR! { [Error: EACCES, mkdir '/opt/IBM/node/share/man/man3']
npm ERR! errno: 3,
npm ERR! code: 'EACCES',
npm ERR! path: '/opt/IBM/node/share/man/man3' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
npm ERR! System Linux 3.13.0-52-generic
npm ERR! command "/opt/IBM/node/bin/node" "/opt/IBM/node/bin/npm" "install" "npm#2.14.4" "-g"
npm ERR! cwd /home/pipeline/6abb55b0-7254-4bc1-8d74-aa4550db9b1b
npm ERR! node -v v0.10.29
npm ERR! npm -v 1.4.14
npm ERR! path /opt/IBM/node/share/man/man3
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, mkdir '/opt/IBM/node/share/man/man3'
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/pipeline/6abb55b0-7254-4bc1-8d74-aa4550db9b1b/npm-debug.log
npm ERR! not ok code 0
Finished: ERRORED
What needs to be done to resolve this?
Looks like your question was already answered here.
According to Patrick Wagstrom, the problem was fixed in December 7, 2015
If you try to deploy the NLC toolkit today it will work.
NLC Toolkit: https://hub.jazz.net/project/wdctools/ibmwatson-nlc-groundtruth/overview
I'm running an example from build-nodejs-npm-installation-package-scratch. Instead of uploading to npm repository I'm putting it on Github and trying to download it via npm instead. I run npm install git+https://github.com/t2wu/replaceme.git and got the following:
npm ERR! Error: ENOENT, chmod '/private/tmp/node_modules/replaceme_tim/replaceme.js'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Darwin 13.2.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "git+https://github.com/t2wu/replaceme.git"
npm ERR! cwd /private/tmp
npm ERR! node -v v0.10.28
npm ERR! npm -v 1.4.9
npm ERR! path /private/tmp/node_modules/replaceme_tim/replaceme.js
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /private/tmp/npm-debug.log
npm ERR! not ok code 0
I have a package.json in there, I cannot figure out what is wrong.
EDIT: I can install Express OK, but I can't install my practice module
This happens due to missing permissions or unlinked files while npm was working. This topicc is also seen at github, here.
Try running with admin perms.