5

I've been using Cloud Functions for over a year now and in the last month or so, there's been a change that's made it much more difficult to troubleshoot errors.

Previously, something as simple as the following would generate an Error in Logging with the offending line number and traceback (KeyError: 'test' here), but now Logging just shows Function execution took X ms, finished with status: 'crash' categorized under Debug.

def hello_world(request):
    request_json = request.get_json()
    print(request_json)
    print(request_json['test'])
    return f'Hello World!'

Does anybody have any insights on what happened, and advice on how to proceed to troubleshoot Cloud Functions with crashes going forward please? Thank you in advance!

chengineer
  • 61
  • 2
  • I'm getting the impression that something is broken .... see also: https://stackoverflow.com/questions/61987350/is-finished-with-status-crash-normal-for-cloud-functions – Kolban May 24 '20 at 19:08
  • Thanks @Kolban for pointing out the earlier thread. From logs of all my Cloud Functions, the first occurrence of a "crash" without traceback and categorized as "Debug" was on 2020-04-24T20:53:01.610 UTC, so this bug has been here for a month now. – chengineer May 24 '20 at 20:13
  • 1
    GCP Support got back to me with the following update: I've identified your issue as a known issue being fixed by the Cloud Functions product team. The symptoms of this issue are missing log statements in Python 3.7 functions, starting as of mid-April. This appears to match the details you've provided, though please let me know if anything sounds off. – chengineer May 24 '20 at 21:53
  • 3
    (continued): The fix for this issue has been implemented and the rollout has already begun. Rollouts can take a number of days based on the gradual rollout process used, and based on previous rollouts, I anticipate this being available in production by Friday this week. Please note that this ETA could be altered by a paused rollout or other unexpected delay, and we'll update you if we see anything change. – chengineer May 24 '20 at 21:53
  • 2
    Still occurring for me. – Ory Band Jun 18 '20 at 13:30
  • Still happening. – Aseem Jul 08 '20 at 03:08
  • Still happening... – Alex Jul 15 '20 at 19:00

1 Answers1

1

@chengineer provided the answer in the comment thread, this issue affected the Cloud Functions and it is currently under fix. The following updates will be posted on https://issuetracker.google.com/issues/155215191.

Juancki
  • 1,793
  • 1
  • 14
  • 21