是“完成状态:'crash' "云功能正常吗? [英] Is " finished with status: 'crash' " normal for Cloud Functions?

查看:27
本文介绍了是“完成状态:'crash' "云功能正常吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我用 Python 尝试了 Google Cloud Functions,但运行它时出现问题.它说:错误:无法处理请求

I tried Google Cloud Functions with Python and there was a problem with running it. It said: Error: could not handle the request

我检查了日志,但没有错误,只是一条日志消息:

I checked the logs, but there was no error, just a log message:

Function execution took 16 ms, finished with status: 'crash'

当我将功能简化为打印输出时,它可以正常工作.然后我在打印输出之前添加了 raise Exception('test') 以查看异常是否会导致 Stackdriver Errors,但它没有,我得到了 finished with status: 'crash' 仅在日志中再次显示消息.

When I simplified the function to a printout then it worked properly. Then I added raise Exception('test') before the printout to see if the exception is going to Stackdriver Errors, but it didn't, I got the finished with status: 'crash' message again only in the log.

这是正常行为吗?或者它是一个错误,而不是崩溃,我应该在日志中将异常视为错误?

Is this normal behavior? Or is it a bug and instead of crash I should see the exception as an error in the log?

推荐答案

非常正确,正如评论中提到的那样,使用 Python 的 Google Cloud Functions 崩溃似乎有问题.该问题已报告给内部 Google Cloud Functions 工程师,评估仍在进行中.您可以监控 此链接 以进行修复

Quite rightly, as alluded to in the Comments, the crash seems buggy about Google Cloud Functions with Python. The issue was reported to the Internal Google Cloud Functions engineers and evaluation is still ongoing. You can monitor this link for fixes

这篇关于是“完成状态:'crash' "云功能正常吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆