Skip to content
This repository has been archived by the owner on Jun 2, 2024. It is now read-only.

Internal Server Error #743

Closed
mtyang opened this issue Nov 26, 2015 · 13 comments
Closed

Internal Server Error #743

mtyang opened this issue Nov 26, 2015 · 13 comments

Comments

@mtyang
Copy link

mtyang commented Nov 26, 2015

image

发布私包的时候报这个问题

@alsotang
Copy link
Member

JSON.parse 报出来的,至于是哪里的 parse,去服务器上看看日志

2015-11-26 16:06 GMT+08:00 Enzo [email protected]:

[image: image]
https://cloud.githubusercontent.com/assets/6511456/11418089/86451cf4-9457-11e5-88c7-1819667c8afb.png

发布私包的时候报这个问题


Reply to this email directly or view it on GitHub
#743.

@mtyang
Copy link
Author

mtyang commented Nov 26, 2015

0 info it worked if it ends with ok
1 verbose cli [ '/usr/local/bin/node',
1 verbose cli '/usr/local/lib/node_modules/cnpm/node_modules/.bin/npm',
1 verbose cli '--userconfig=/Users/Enzo/.cnpmrc',
1 verbose cli '--disturl=https://npm.taobao.org/mirrors/node',
1 verbose cli '--cache=/Users/Enzo/.cnpm',
1 verbose cli '--registry=http://127.0.0.1:7001/',
1 verbose cli '--node-gyp=/usr/local/lib/node_modules/cnpm/node_modules/node-gyp/bin/node-gyp.js',
1 verbose cli 'publish' ]
2 info using [email protected]
3 info using [email protected]
4 verbose publish [ '.' ]
5 silly cache add args [ '.', null ]
6 verbose cache add spec .
7 silly cache add parsed spec Result {
7 silly cache add raw: '.',
7 silly cache add scope: null,
7 silly cache add name: null,
7 silly cache add rawSpec: '.',
7 silly cache add spec: '/Users/Enzo/iwjw/cnpm',
7 silly cache add type: 'directory' }
8 verbose addLocalDirectory /Users/Enzo/.cnpm/@iwjw/slidescrollbar/0.0.1/package.tgz not in flight; packing
9 verbose tar pack [ '/Users/Enzo/.cnpm/@iwjw/slidescrollbar/0.0.1/package.tgz',
9 verbose tar pack '/Users/Enzo/iwjw/cnpm' ]
10 verbose tarball /Users/Enzo/.cnpm/@iwjw/slidescrollbar/0.0.1/package.tgz
11 verbose folder /Users/Enzo/iwjw/cnpm
12 info prepublish @iwjw/[email protected]
13 verbose addLocalTarball adding from inside cache /Users/Enzo/.cnpm/@iwjw/slidescrollbar/0.0.1/package.tgz
14 silly cache afterAdd @iwjw/[email protected]
15 verbose afterAdd /Users/Enzo/.cnpm/@iwjw/slidescrollbar/0.0.1/package/package.json not in flight; writing
16 verbose afterAdd /Users/Enzo/.cnpm/@iwjw/slidescrollbar/0.0.1/package/package.json written
17 silly publish { name: '@iwjw/slidescrollbar',
17 silly publish version: '0.0.1',
17 silly publish description: '移动端侧边栏',
17 silly publish main: 'index.js',
17 silly publish scripts: { test: 'test' },
17 silly publish repository:
17 silly publish { type: 'git',
17 silly publish url: 'git+https://github.com/mtyang/slideScrollBar.git' },
17 silly publish keywords: [ 'slidebar', 'scrollbar' ],
17 silly publish author: { name: 'Enzoyang' },
17 silly publish license: 'ISC',
17 silly publish bugs: { url: 'https://github.com/mtyang/slideScrollBar/issues' },
17 silly publish homepage: 'https://github.com/mtyang/slideScrollBar#readme',
17 silly publish readme: '...',
17 silly publish _id: '@iwjw/[email protected]',
17 silly publish _shasum: 'f06154a7b65dd9505f79662a81e5c4ae7bfb9ea4',
17 silly publish _from: '.' }
18 verbose getPublishConfig undefined
19 silly mapToRegistry name @iwjw/slidescrollbar
20 silly mapToRegistry scope (from package name) @iwjw
21 verbose mapToRegistry no registry URL found in name for scope @iwjw
22 silly mapToRegistry using default registry
23 silly mapToRegistry registry http://127.0.0.1:7001/
24 silly mapToRegistry uri http://127.0.0.1:7001/@iwjw%2fslidescrollbar
25 verbose publish registryBase http://127.0.0.1:7001/
26 silly publish uploading /Users/Enzo/.cnpm/@iwjw/slidescrollbar/0.0.1/package.tgz
27 verbose request uri http://127.0.0.1:7001/@iwjw%2fslidescrollbar
28 verbose request sending authorization for write operation
29 info attempt registry request try #1 at 16:22:08
30 verbose request id fb58cc1f819398ac
31 http request PUT http://127.0.0.1:7001/@iwjw%2fslidescrollbar
32 http 500 http://127.0.0.1:7001/@iwjw%2fslidescrollbar
33 verbose bad json Internal Server Error
34 error registry error parsing json
35 verbose headers { 'content-type': 'text/plain; charset=utf-8',
35 verbose headers 'content-length': '21',
35 verbose headers date: 'Thu, 26 Nov 2015 08:22:08 GMT',
35 verbose headers connection: 'keep-alive' }
36 info retry will retry, error on last attempt: SyntaxError: Unexpected token I
36 info retry Internal Server Error
37 info attempt registry request try #2 at 16:22:18
38 http request PUT http://127.0.0.1:7001/@iwjw%2fslidescrollbar
39 http 500 http://127.0.0.1:7001/@iwjw%2fslidescrollbar
40 verbose bad json Internal Server Error
41 error registry error parsing json
42 verbose headers { 'content-type': 'text/plain; charset=utf-8',
42 verbose headers 'content-length': '21',
42 verbose headers date: 'Thu, 26 Nov 2015 08:22:18 GMT',
42 verbose headers connection: 'keep-alive' }
43 info retry will retry, error on last attempt: SyntaxError: Unexpected token I
43 info retry Internal Server Error
44 info attempt registry request try #3 at 16:23:18
45 http request PUT http://127.0.0.1:7001/@iwjw%2fslidescrollbar
46 http 500 http://127.0.0.1:7001/@iwjw%2fslidescrollbar
47 verbose bad json Internal Server Error
48 error registry error parsing json
49 verbose headers { 'content-type': 'text/plain; charset=utf-8',
49 verbose headers 'content-length': '21',
49 verbose headers date: 'Thu, 26 Nov 2015 08:23:18 GMT',
49 verbose headers connection: 'keep-alive' }
50 verbose request invalidating /Users/Enzo/.cnpm/127.0.0.1_7001/_40iwjw_252fslidescrollbar on PUT
51 error publish Failed PUT 500
52 verbose stack SyntaxError: Unexpected token I
52 verbose stack Internal Server Error
52 verbose stack at Object.parse (native)
52 verbose stack at CachingRegistryClient. (/usr/local/lib/node_modules/cnpm/node_modules/npm/node_modules/npm-registry-client/lib/request.js:199:23)
52 verbose stack at Request._callback (/usr/local/lib/node_modules/cnpm/node_modules/npm/node_modules/npm-registry-client/lib/request.js:172:14)
52 verbose stack at Request.self.callback (/usr/local/lib/node_modules/cnpm/node_modules/npm/node_modules/request/request.js:198:22)
52 verbose stack at emitTwo (events.js:87:13)
52 verbose stack at Request.emit (events.js:172:7)
52 verbose stack at Request. (/usr/local/lib/node_modules/cnpm/node_modules/npm/node_modules/request/request.js:1082:10)
52 verbose stack at emitOne (events.js:82:20)
52 verbose stack at Request.emit (events.js:169:7)
52 verbose stack at IncomingMessage. (/usr/local/lib/node_modules/cnpm/node_modules/npm/node_modules/request/request.js:1009:12)
53 verbose cwd /Users/Enzo/iwjw/cnpm
54 error Darwin 15.0.0
55 error argv "/usr/local/bin/node" "/usr/local/lib/node_modules/cnpm/node_modules/.bin/npm" "--userconfig=/Users/Enzo/.cnpmrc" "--disturl=https://npm.taobao.org/mirrors/node" "--cache=/Users/Enzo/.cnpm" "--registry=http://127.0.0.1:7001/" "--node-gyp=/usr/local/lib/node_modules/cnpm/node_modules/node-gyp/bin/node-gyp.js" "publish"
56 error node v4.0.0
57 error npm v2.14.11
58 error Unexpected token I
58 error Internal Server Error
59 error If you need help, you may report this error at:
59 error https://github.com/npm/npm/issues
60 verbose exit [ 1, true ]

@dead-horse
Copy link
Member

看看你的服务端日志吧

@mtyang
Copy link
Author

mtyang commented Nov 26, 2015

已经贴上去了

@alsotang
Copy link
Member

verbose stack SyntaxError: Unexpected token I
verbose stack Internal Server Error

我看这两句像是有关联的。。。上面的 token I 可能来自下面的 Internal

2015-11-26 17:58 GMT+08:00 Enzo [email protected]:

已经贴上去了


Reply to this email directly or view it on GitHub
#743 (comment).

@dead-horse
Copy link
Member

@mtyang 你这个是客户端打印的啊,到底服务端报什么错了?

@mtyang
Copy link
Author

mtyang commented Nov 27, 2015

@dead-horse

2015-11-27 10:29:39.724 nodejs.TypeErrorException: TypeError: Cannot read property 'uploadBuffer' of null
at Object.save (/Users/Enzo/cnpmjs/controllers/registry/package/save.js:181:31)
at next (native)
at Object.publishable (/Users/Enzo/cnpmjs/middleware/publishable.js:45:21)
at next (native)
at Object.login (/Users/Enzo/cnpmjs/middleware/login.js:41:10)
at next (native)
at Object. (/Users/Enzo/cnpmjs/node_modules/koa-middlewares/node_modules/koa-router/node_modules/koa-compose/index.js:29:12)
at next (native)
at Object.dispatch (/Users/Enzo/cnpmjs/node_modules/koa-middlewares/node_modules/koa-router/lib/router.js:97:44)
at next (native)
at Object.etag (/Users/Enzo/cnpmjs/node_modules/koa-middlewares/node_modules/koa-etag/index.js:25:12)
at next (native)
at Object.conditional (/Users/Enzo/cnpmjs/node_modules/koa-middlewares/node_modules/koa-conditional-get/index.js:16:12)
at next (native)
at Object.notFound (/Users/Enzo/cnpmjs/middleware/registry_not_found.js:18:10)
at next (native)
pid: 12685
domainThrown: false
Host: yangenpengdeMacBook-Pro.local
URL: /@iwjw%2fslidescrollbar
Data: ''
2015-11-27 10:29:39.724

@mtyang
Copy link
Author

mtyang commented Nov 27, 2015

我看431那里貌似有同样的问题,升级NPM之后解决了,但是我的NPM版本是v2.14.11

@mtyang
Copy link
Author

mtyang commented Nov 30, 2015

@dead-horse

@dead-horse
Copy link
Member

你的配置有问题吧?nfs 配的是什么?

@mtyang
Copy link
Author

mtyang commented Nov 30, 2015

image

这里要配置什么?

@mtyang
Copy link
Author

mtyang commented Nov 30, 2015

把nfs删掉之后成功了!!!谢谢!

@dead-horse
Copy link
Member

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants