我想用ava测试我的代码,但是当我尝试它时,我得到了以下错误.我想有个陷阱不见了.
(node:7640) UnhandledPromiseRejectionWarning: C:\...\TesBoard-db\node_modules\ava\lib\node-arguments.js:9
} catch {
^
(node:7640) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:7640) [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.知道怎么解决这个吗.?
提前谢谢。
发布于 2020-02-24 19:35:04
是的,更新节点。<-他们建议在发布线程中使用Node.js 12.15。
对于将来的参考,以及StackOverflow,您希望搜索堆栈中任何抛出或错误行为的GitHub问题。
https://stackoverflow.com/questions/60381954
复制相似问题