Firebase 云功能以代码 16 退出什么是错误代码 16,我在哪里可以找到更多信息?

编程入门 行业动态 更新时间:2024-10-11 17:29:28
本文介绍了Firebase 云功能以代码 16 退出什么是错误代码 16,我在哪里可以找到更多信息?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我在 firebase 上的一个云功能以代码 16 作为错误退出.

one of my cloud functions on firebase exits with code 16 as an error.

我试图用谷歌搜索并找出该代码是什么,但完全没有运气.

I tried to google and find out what that code is but no luck at all.

Error: Process exited with code 16 at process.on.code (/srv/node_modules/@google-cloud/functions-framework/build/src/invoker.js:393:29) at process.emit (events.js:189:13) at process.EventEmitter.emit (domain.js:441:20) at process.exit (internal/process/per_thread.js:168:15) at logAndSendError (/srv/node_modules/@google-cloud/functions-framework/build/src/invoker.js:184:9) at process.on.err (/srv/node_modules/@google-cloud/functions-framework/build/src/invoker.js:390:13) at process.emit (events.js:189:13) at process.EventEmitter.emit (domain.js:441:20) at emitPromiseRejectionWarnings (internal/process/promises.js:119:20) at process._tickCallback (internal/process/next_tick.js:69:34)

在哪里可以找到报告的错误代码,以便了解我的函数退出的原因?

Where can I find those error codes reported so I can understand why my function exits?

推荐答案

函数框架的代码其实是公开在GoogleCloudPlatform/functions-framework-nodejs 存储库(虽然没有在任何地方宣传).

The code for the function framework is actually public in the GoogleCloudPlatform/functions-framework-nodejs repository (although not advertised anywhere).

特别是您可以看到使用 killInstance 的情况,这是触发退出代码 16 的情况:

In particular you can see there the cases where killInstance is used, which is the one triggering exit code 16:

const killInstance = process.exit.bind(process, 16);

这些案例是(在撰写本文时):

These cases are (at the time of writing):

  • uncaughtException
  • unhandledRejection

更多推荐

Firebase 云功能以代码 16 退出什么是错误代码 16,我在哪里可以找到更多信息?

本文发布于:2023-11-07 10:23:55,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1566201.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:我在   更多信息   可以找到   错误代码   代码

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!