我正在尝试在离子框架v1 中实施推送通知。
这就是我开始下载空白模板的原因,我收到' statusCode' 错误。
C:\Users\sif-\Desktop\vConnect_31_5_16>ionic start vConnectPro blank
Creating Ionic app in folder C:\Users\sif-\Desktop\vConnect_31_5_16\vConnectPro
based on blank project
Downloading: https://github.com/driftyco/ionic-app-base/archive/master.zip
[=============================] 100% 0.0s
Downloading: https://github.com/driftyco/ionic-starter-blank/archive/master.zip
[=============================] 100% 0.0s
Updated the hooks directory to have execute permissions
Update Config.xml
Initializing cordova project
? ♫ ? ♫ Your Ionic app is ready to go! ? ♫ ? ♫
Make sure to cd into your new app directory:
cd vConnectPro
To run your app in the browser (great for initial development):
ionic serve
To run on iOS:
ionic run ios
To run on Android:
ionic run android
To test your app on a device easily, try Ionic View:
http://view.ionic.io
New! Add push notifications, live app updates, and more with Ionic Platform!
https://apps.ionic.io/signup
C:\Users\sif-\AppData\Roaming\npm\node_modules\ionic\lib\cli.js:474
process.stdout.write('Unable to fetch', err, res.statusCode);
^
TypeError: Cannot read property 'statusCode' of undefined
at Request._callback (C:\Users\sif-\AppData\Roaming\npm\node_modules\ionic\l
ib\cli.js:474:55)
at self.callback (C:\Users\sif-\AppData\Roaming\npm\node_modules\ionic\node_
modules\request\request.js:373:22)
at emitOne (events.js:77:13)
at Request.emit (events.js:169:7)
at Request.onRequestError (C:\Users\sif-\AppData\Roaming\npm\node_modules\io
nic\node_modules\request\request.js:971:8)
at emitOne (events.js:77:13)
at ClientRequest.emit (events.js:169:7)
at Socket.socketErrorListener (_http_client.js:256:9)
at emitOne (events.js:77:13)
at Socket.emit (events.js:169:7)
起初我忽略了这个,因为空白的应用程序运行正常,但是在实现了所有必要的
之后推送通知代码我再次收到与' statusCode' 相关的错误。这对我来说是一个阻挡者。
我应该怎么做才能解决错误?
答案 0 :(得分:1)
这可能是代理问题
当您在代理
后面时会产生此问题确保您使用的是直接连接到互联网的电脑或笔记本电脑