Closed youngl98 closed 7 years ago
Looks like an NPM bug? Does NPM respect those environment variables?
On Mon, Jul 18, 2016 at 5:36 PM, youngl98 notifications@github.com wrote:
Please follow the steps below to help us help you.
1.
Please supply the header (i.e. the first few lines) of your most recent log file for each node in your cluster. On most unix-based systems running with defaults, this boils down to the output of
grep -F '[config]' cockroach-data/logs/cockroach.INFO
When log files are not available, supply the output of cockroach version and all flags/environment variables passed to cockroach start instead. 2.
Please describe the issue you observed:
- What did you do?
I am behind a corporate proxy, modified the build/builder.sh as per @kena https://github.com/kena (Thanx kena) and ran it on Mac OS (El Capitan 10.11.5). I am not if this is relevant, but I am using zsh to build.
docker run -i ${tty-} ${rm} \ ... \ --env="http_proxy=http://internet.visa.com:80" \ --env="https_proxy=http://internet.visa.com:443" \ npm-debug.log.txt
--env="HTTP_PROXY=http://internet.visa.com:80" \ --env="HTTPS_PROXY=http://internet.visa.com:443" \
- What did you expect to see?
I expected the build to complete.
- What did you see instead?
I am getting the following error...
npm WARN ui No repository field. npm WARN ui No license field. npm ERR! Linux 4.4.12-boot2docker npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "--no-progress" npm ERR! node v6.2.1 npm ERR! npm v3.9.3 npm ERR! path /go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall chmod
npm ERR! enoent ENOENT: no such file or directory, chmod '/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js' npm ERR! enoent ENOENT: no such file or directory, chmod '/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent
npm ERR! Please include the following file with any support request: npm ERR! /go/src/github.com/cockroachdb/cockroach/ui/npm-debug.log Makefile:86 http://github.com/cockroachdb/cockroach/ui/npm-debug.logMakefile:86: recipe for target 'npm.installed' failed make: *\ [npm.installed] Error 254 ui/ui.go:21: running "make": exit status 2 stringer: checking package: decimal.go:30:2: could not import gopkg.in/inf.v0 (can't find import: gopkg.in/inf.v0) util/encoding/encoding.go:840: running "stringer": exit status 1
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/cockroachdb/cockroach/issues/7900, or mute the thread https://github.com/notifications/unsubscribe-auth/ABdsPI7eUzgaIaAzzwAiNOYyzb0NAXRqks5qW_HGgaJpZM4JPKmo .
@tamird unlikely; the other npm packages prior to nopt are downloaded and build properly.
Yeah this does seem like it could be an npm issue, possibly https://github.com/npm/npm/issues/9633
@youngl98 would you mind trying the npm install again?
In the ui
directory, run:
rm -rf node_modules
npm cache clean
npm install
Hi,
I installed npm as per your request
younglee at xxxxxx in ~/go/src/github.com/cockroachdb/cockroach/ui (master●) $ brew install npm ==> Downloading https://homebrew.bintray.com/bottles/node-6.3.0.el_capitan.bottle.tar.gz ######################################################################## 100.0% ==> Pouring node-6.3.0.el_capitan.bottle.tar.gz ==> Caveats Please note by default only English locale support is provided. If you need full locale support you should either rebuild with full icu:
brew reinstall node --with-full-icu`
or add full icu data at runtime following:
https://github.com/nodejs/node/wiki/Intl#using-and-customizing-the-small-icu-build
Bash completion has been installed to: /usr/local/etc/bash_completion.d ==> Summary 🍺 /usr/local/Cellar/node/6.3.0: 3,829 files, 39.8M
younglee at xxxxxxxxx in ~/go/src/github.com/cockroachdb/cockroach/ui (master●) $ npm cache clean
younglee at xxxxxxxx in ~/go/src/github.com/cockroachdb/cockroach/ui (master●) $ npm install npm WARN deprecated jade@0.26.3: Jade has been renamed to pug, please install the latest version of pug instead of jade npm WARN deprecated minimatch@0.3.0: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue npm WARN deprecated to-iso-string@0.0.2: to-iso-string has been deprecated, use @segment/to-iso-string instead. npm WARN deprecated minimatch@2.0.10: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
fsevents@1.0.12 install /Users/younglee/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents node-pre-gyp install --fallback-to-build
SOLINK_MODULE(target) Release/.node CXX(target) Release/obj.target/fse/fsevents.o ./Release/.deps/Release/obj.target/fse/fsevents.o.d.raw { dev: 16777220, mode: 33188, nlink: 1, uid: 377609176, gid: 2066069167, rdev: 0, blksize: 4096, ino: 2859340, size: 1386, blocks: 8, atime: 2016-07-20T03:11:51.000Z, mtime: 2016-07-20T03:11:51.000Z, ctime: 2016-07-20T03:11:51.000Z, birthtime: 2016-07-20T03:11:51.000Z } SOLINK_MODULE(target) Release/fse.node COPY /Users/younglee/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/lib/binding/Release/node-v48-darwin-x64/fse.node TOUCH Release/obj.target/action_after_build.stamp Release/obj.target/action_after_build.stamp { dev: 16777220, mode: 33188, nlink: 1, uid: 377609176, gid: 2066069167, rdev: 0, blksize: 4096, ino: 2859360, size: 0, blocks: 0, atime: 2016-07-20T03:11:52.000Z, mtime: 2016-07-20T03:11:52.000Z, ctime: 2016-07-20T03:11:52.000Z, birthtime: 2016-07-20T03:11:52.000Z }
phantomjs-prebuilt@2.1.7 install /Users/younglee/go/src/github.com/cockroachdb/cockroach/ui/node_modules/phantomjs-prebuilt node install.js
PhantomJS not found on PATH Downloading https://github.com/Medium/phantomjs/releases/download/v2.1.1//phantomjs-2.1.1-macosx.zip Saving to /var/folders/kt/0xqp7b1s5fn16rjj3r0hzx04b83pyr/T/phantomjs/phantomjs-2.1.1-macosx.zip Receiving... [=======================================-] 98% Received 16746K total. Extracting zip contents Removing /Users/younglee/go/src/github.com/cockroachdb/cockroach/ui/node_modules/phantomjs-prebuilt/lib/phantom Copying extracted folder /var/folders/kt/0xqp7b1s5fn16rjj3r0hzx04b83pyr/T/phantomjs/phantomjs-2.1.1-macosx.zip-extract-1468984353490/phantomjs-2.1.1-macosx -> /Users/younglee/go/src/github.com/cockroachdb/cockroach/ui/node_modules/phantomjs-prebuilt/lib/phantom Writing location.js file Done. Phantomjs binary available at /Users/younglee/go/src/github.com/cockroachdb/cockroach/ui/node_modules/phantomjs-prebuilt/lib/phantom/bin/phantomjs /Users/younglee/go/src/github.com/cockroachdb/cockroach/ui ├── abbrev@1.0.9 ├── accepts@1.1.4 ... ... npm WARN ui No repository field. npm WARN ui No license field.`
I re-ran the build/builder.sh and got the same error
`npm WARN ui No repository field. npm WARN ui No license field. npm ERR! Linux 4.4.12-boot2docker npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "--no-progress" npm ERR! node v6.2.1 npm ERR! npm v3.9.3 npm ERR! path /go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js npm ERR! code ENOENT npm ERR! errno -2 npm ERR! syscall chmod
npm ERR! enoent ENOENT: no such file or directory, chmod '/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js' npm ERR! enoent ENOENT: no such file or directory, chmod '/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js' npm ERR! enoent This is most likely not a problem with npm itself npm ERR! enoent and is related to npm not being able to find a file. npm ERR! enoent
npm ERR! Please include the following file with any support request: npm ERR! /go/src/github.com/cockroachdb/cockroach/ui/npm-debug.log Makefile:86: recipe for target 'npm.installed' failed make: *\ [npm.installed] Error 254 ui/ui.go:21: running "make": exit status 2 stringer: checking package: decimal.go:30:2: could not import gopkg.in/inf.v0 (can't find import: gopkg.in/inf.v0) util/encoding/encoding.go:840: running "stringer": exit status 1 ` Attached the npm-debug.log file to this comment as well. npm-debug.log.txt
You can ignore the npm WARN ui No repository field.
and npm WARN ui No license field.
Does this mean the original npm install
succeeded?
I'm confused why the path is wrong. It looks like /go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js
should be
/Users/younglee/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/nopt/bin/nopt.js
When I run make, it looks like this:
npm sill build nopt@3.0.6
npm info linkStuff nopt@3.0.6
npm sill linkStuff nopt@3.0.6 has /Users/maxlang/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules as its parent node_modules
npm verb linkBins nopt@3.0.6
npm verb link bins [ { nopt: './bin/nopt.js' },
npm verb link bins '/Users/maxlang/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/.bin',
npm verb link bins false ]
npm verb linkMans nopt@3.0.6
npm sill gentlyRm /Users/maxlang/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/.bin/nopt is being purged
npm verb gentlyRm don't care about contents; nuking /Users/maxlang/go/src/github.com/cockroachdb/cockroach/ui/node_modules/fsevents/node_modules/node-pre-gyp/node_modules/.bin/nopt
Might be something to do with docker, brew, or npm.
Looks like the node_modules directory is being shared between docker and the host OS, which is no bueno because done dependencies are platform-specific and npm is stupid and doesn't provide pristine node_modules when you run npm install.
On Jul 20, 2016 17:58, "Max Lang" notifications@github.com wrote:
Might be something to do with docker, brew, or npm.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/cockroachdb/cockroach/issues/7900#issuecomment-234096741, or mute the thread https://github.com/notifications/unsubscribe-auth/ABdsPB1WBQW54jo7ZJ6Ouhm69R1eL3Ltks5qXpoZgaJpZM4JPKmo .
s/done/some/
On Jul 20, 2016 19:41, "Tamir Duberstein" tamir@cockroachlabs.com wrote:
Looks like the node_modules directory is being shared between docker and the host OS, which is no bueno because done dependencies are platform-specific and npm is stupid and doesn't provide pristine node_modules when you run npm install.
On Jul 20, 2016 17:58, "Max Lang" notifications@github.com wrote:
Might be something to do with docker, brew, or npm.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/cockroachdb/cockroach/issues/7900#issuecomment-234096741, or mute the thread https://github.com/notifications/unsubscribe-auth/ABdsPB1WBQW54jo7ZJ6Ouhm69R1eL3Ltks5qXpoZgaJpZM4JPKmo .
@youngl98 can you try separating the node_modules
directory as suggested by tamir, and report back your findings?
I am not getting it. How do I separate the node_modules?
I think that advice is out of date. @youngl98 is that problem still occurring with current code?
I am getting a different error now.
ounglee at wm-C02RQ2QUG8WM in ~/go/src/github.com/cockroachdb/cockroach (develop●) $ build/builder.sh env SKIP_BOOTSTRAP=0 go generate ./... Makefile:219: .bootstrap: No such file or directory go get github.com/robfig/glock go install runtime/internal/sys: mkdir /usr/local/go/pkg/linux_amd64/runtime: permission denied Makefile:207: recipe for target '../../../../bin/glock' failed make: * [../../../../bin/glock] Error 1 main.go:19: running "make": exit status 2 sed: couldn't open temporary file ./sedCpBdXA: Permission denied base/main_test.go:29: running "../util/leaktest/add-leaktest.sh": exit status 4 cli/context.go:69: running "stringer": exec: "stringer": executable file not found in $PATH sed: couldn't open temporary file ./seduCcXvE: Permission denied config/main_test.go:19: running "../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedQXhHCD: Permission denied gossip/main_test.go:28: running "../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedkQtUdH: Permission denied internal/client/main_test.go:38: running "../../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sed875ReG: Permission denied kv/main_test.go:31: running "../util/leaktest/add-leaktest.sh": exit status 4 roachpb/method.go:22: running "stringer": exec: "stringer": executable file not found in $PATH sed: couldn't open temporary file ./sed8s6Q9I: Permission denied rpc/main_test.go:33: running "../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sed4SYF2I: Permission denied security/main_test.go:42: running "../util/leaktest/add-leaktest.sh": exit status 4 security/securitytest/securitytest.go:26: running "go-bindata": exec: "go-bindata": executable file not found in $PATH sed: couldn't open temporary file ./sedo9XJYM: Permission denied server/main_test.go:35: running "../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedOyAfOK: Permission denied server/status/main_test.go:28: running "../../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedG7KwcO: Permission denied sql/main_test.go:41: running "../util/leaktest/add-leaktest.sh": exit status 4 Type checking sql.y ./sql_union.sh: line 15: ../../../../../../bin/yacc: No such file or directory Makefile:5: recipe for target 'sql.go' failed make: * [sql.go] Error 1 sql/parser/parse.go:34: running "make": exit status 2 sed: couldn't open temporary file ./sedQlypNS: Permission denied sql/pgwire/main_test.go:28: running "../../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedusiDFV: Permission denied sql/privilege/main_test.go:24: running "../../util/leaktest/add-leaktest.sh": exit status 4 sql/sqlbase/structured.go:53: running "stringer": exec: "stringer": executable file not found in $PATH sed: couldn't open temporary file ./sedYrI27Y: Permission denied storage/main_test.go:33: running "../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedQqUi1W: Permission denied storage/engine/main_test.go:19: running "../../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedktkPx0: Permission denied testutils/testcluster/main_test.go:29: running "../../util/leaktest/add-leaktest.sh": exit status 4 sed: couldn't open temporary file ./sedOLrxy1: Permission denied ts/main_test.go:35: running "../util/leaktest/add-leaktest.sh": exit status 4 rm -rf node_modules npm install --no-progress npm WARN deprecated to-iso-string@0.0.2: to-iso-string has been deprecated, use @segment/to-iso-string instead. npm WARN deprecated jade@0.26.3: Jade has been renamed to pug, please install the latest version of pug instead of jade npm ERR! Linux 4.4.17-boot2docker npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "--no-progress" npm ERR! node v6.3.1 npm ERR! npm v3.10.3 npm ERR! path /root/.npm/lodash.isplainobject/4.0.5 npm ERR! code EACCES npm ERR! errno -13 npm ERR! syscall mkdir
npm ERR! Error: EACCES: permission denied, mkdir '/root/.npm/lodash.isplainobject/4.0.5' npm ERR! at Error (native) npm ERR! { Error: EACCES: permission denied, mkdir '/root/.npm/lodash.isplainobject/4.0.5' npm ERR! at Error (native) npm ERR! errno: -13, npm ERR! code: 'EACCES', npm ERR! syscall: 'mkdir', npm ERR! path: '/root/.npm/lodash.isplainobject/4.0.5' } npm ERR! npm ERR! Please try running this command again as root/Administrator. npm ERR! Linux 4.4.17-boot2docker npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install" "--no-progress" npm ERR! node v6.3.1 npm ERR! npm v3.10.3 npm ERR! path npm-debug.log.843396064 npm ERR! code EACCES npm ERR! errno -13 npm ERR! syscall open
npm ERR! Error: EACCES: permission denied, open 'npm-debug.log.843396064' npm ERR! at Error (native) npm ERR! { Error: EACCES: permission denied, open 'npm-debug.log.843396064' npm ERR! at Error (native) npm ERR! errno: -13, npm ERR! code: 'EACCES', npm ERR! syscall: 'open', npm ERR! path: 'npm-debug.log.843396064' } npm ERR! npm ERR! Please try running this command again as root/Administrator.
npm ERR! Please include the following file with any support request: npm ERR! /go/src/github.com/cockroachdb/cockroach/ui/npm-debug.log Makefile:86: recipe for target 'npm.installed' failed make: *\ [npm.installed] Error 243 ui/ui.go:21: running "make": exit status 2 util/encoding/encoding.go:840: running "stringer": exec: "stringer": executable file not found in $PATH sed: couldn't open temporary file ./sedGeiDPx: Permission denied util/stop/main_test.go:20: running "../leaktest/add-leaktest.sh": exit status 4
Closing as stale.
I am behind a corporate proxy, modified the build/builder.sh as per @knz (Thanx kena) and ran it on Mac OS (El Capitan 10.11.5). I am not if this is relevant, but I am using zsh to build.
I expected the build to complete.
I am getting the following error...
See:
npm-debug.log.txt