meteor fails, can't install npm-packages from

2020-04-14 08:53发布

I have been diagnosing this issue for a few days and have tested the top issue resolutions that appear for "meteor" and "npm" dependencies that look similar to this one. Both I and my back-end engineer are stumped.

I'm using an OSX 10.10.3, ruby 1.9.3, node v0.10.36, npm 1.4.28, meteor 1.1.02.

Also, I am not behind a proxy as the error seems to indicate.

My environment PATH is:

export PATH="/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"

Here's the error:

=> Started proxy.                             
=> Started MongoDB.                           
npm-container: updating npm dependencies -- hummus, shipping-ups...
npm WARN package.json packages-for-meteor-smartpackage-1wscwem@0.0.0 No
description
npm WARN package.json packages-for-meteor-smartpackage-1wscwem@0.0.0 No
repository field.
npm WARN package.json packages-for-meteor-smartpackage-1wscwem@0.0.0 No README
data
../src/deps/LibTiff/tif_unix.c:140:6: warning: cast to 'thandle_t' (aka 'void
*') from smaller integer type 'int' [-Wint-to-void-pointer-cast]
(thandle_t) fd,
^
1 warning generated.
../src/deps/LibTiff/tif_write.c:633:49: warning: comparison of integers of
different signs: 'toff_t' (aka 'unsigned int') and 'tsize_t' (aka 'int')
[-Wsign-compare]
&& td->td_stripbytecount[strip] >= cc )
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~
1 warning generated.
npm ERR! fetch failed
http://npm.iad.ua.com:4873/strip-ansi/-/strip-ansi-2.0.1.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/escape-string-regexp/-/escape-string-regexp-1.0.3.tgz
npm ERR! fetch failed http://npm.iad.ua.com:4873/has-ansi/-/has-ansi-1.0.3.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/ansi-styles/-/ansi-styles-2.0.1.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/cryptiles/-/cryptiles-2.0.4.tgz
../deps/libexpat/lib/xmltok.c:471:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:484:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:504:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:517:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:730:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:749:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:762:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:775:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:871:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
../deps/libexpat/lib/xmltok.c:890:1: warning: missing field 'isName2'
initializer [-Wmissing-field-initializers]
};
^
10 warnings generated.
npm ERR! fetch failed http://npm.iad.ua.com:4873/sntp/-/sntp-1.0.9.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/ansi-styles/-/ansi-styles-2.0.1.tgz
npm ERR! fetch failed http://npm.iad.ua.com:4873/has-ansi/-/has-ansi-1.0.3.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/escape-string-regexp/-/escape-string-regexp-1.0.3.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/strip-ansi/-/strip-ansi-2.0.1.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/cryptiles/-/cryptiles-2.0.4.tgz
npm ERR! fetch failed http://npm.iad.ua.com:4873/sntp/-/sntp-1.0.9.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/escape-string-regexp/-/escape-string-regexp-1.0.3.tgz
npm ERR! fetch failed http://npm.iad.ua.com:4873/has-ansi/-/has-ansi-1.0.3.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/ansi-styles/-/ansi-styles-2.0.1.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/strip-ansi/-/strip-ansi-2.0.1.tgz
npm ERR! fetch failed
http://npm.iad.ua.com:4873/cryptiles/-/cryptiles-2.0.4.tgz
npm ERR! fetch failed http://npm.iad.ua.com:4873/sntp/-/sntp-1.0.9.tgz
npm ERR! network connect ETIMEDOUT
npm ERR! network This is most likely not a problem with npm itself
npm ERR! network and is related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network
settings.
npm ERR! network 
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly.  See: 'npm help config'

npm ERR! System Darwin 14.3.0
npm ERR! command
"/Users/aurorajohansenwardigo/.meteor/packages/meteor-tool/.1.1.3.1wysac9++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/node"
"/Users/aurorajohansenwardigo/.meteor/packages/meteor-tool/.1.1.3.1wysac9++os.osx.x86_64+web.browser+web.cordova/mt-os.osx.x86_64/dev_bundle/bin/npm"
"install"
npm ERR! cwd
/Users/aurorajohansenwardigo/Documents/Projects/<project folder path>/<git branch>/packages/npm-container/.npm/package-new-fwmz2e
npm ERR! node -v v0.10.36
npm ERR! npm -v 1.4.28
npm ERR! syscall connect
npm ERR! code ETIMEDOUT
npm ERR! errno ETIMEDOUT
npm ERR! not ok code 0

=> Errors prevented startup:                  

   While building package npm-container:
   error: couldn't install npm packages from npm-shrinkwrap

=> Your application has errors. Waiting for file change.

Please let me know if you need any additional info for diagnosis.

1条回答
时光不老,我们不散
2楼-- · 2020-04-14 09:39

Went back to basics and was able to get the app to run by using the following steps:

meteor remove meteorhacks:npm

If the remove command doesn't work, manually delete the "meteorhacks:npm" and "npm-contanier" references from the .meteor > packages file. Then delete the folder: /packages/npm-container

Add meteorhacks:npm back into the project:

meteor add meteorhacks:npm

Start the app to initialize the npm package:

meteor

Configure the settings.json file in the project meteor --settings settings.json

查看更多
登录 后发表回答