Node.js (节点:13606)未处理的PromisejectionWarning:未处理的承诺拒绝(拒绝id:1):[object object]-离子框架

Node.js (节点:13606)未处理的PromisejectionWarning:未处理的承诺拒绝(拒绝id:1):[object object]-离子框架,node.js,ionic-framework,ionic3,Node.js,Ionic Framework,Ionic3,我正在使用第三版的Ionic Framework,当我运行Ionic cordova构建版android时,我遇到了以下错误: (node:13791) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): [object Object] (node:13791) [DEP0018] DeprecationWarning: Unhandled promise rejections are

我正在使用第三版的Ionic Framework,当我运行Ionic cordova构建版android时,我遇到了以下错误:

(node:13791) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): [object Object]
(node:13791) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

关于这件事的其他线索并没有把我带到任何地方。请帮助

我的第一次尝试是检查我的代码是否存在未处理的拒绝承诺

如何检测未处理的拒绝承诺

假设我们有这样的代码:

asyncAction.then(success => {
 // do stuff with the result of success
})
因此,如果asyncActions失败,就会有一个未处理的承诺拒绝,因为我们永远无法捕捉到对承诺的拒绝。为了抓住拒绝,我们需要这样做:

asyncAction.then(success => {
  // do stuff with the result of success
}, rejection => {
// handle action failed
})

我解决了将cordova版本降级到7.1.0的问题