functions-framework-dart icon indicating copy to clipboard operation
functions-framework-dart copied to clipboard

Consider outputting log information for Cloud Error Reporting

Open kevmoo opened this issue 5 years ago • 0 comments

Might be nice

            // https://cloud.google.com/error-reporting/docs/formatting-error-messages#json_representation
            '@type':
                'type.googleapis.com/google.devtools.clouderrorreporting.v1beta1.ReportedErrorEvent',
            'serviceContext': {
              'service': Platform.environment['K_SERVICE'],
              'version': Platform.environment['K_REVISION'],
            },
            if (stackFrame != null)
              'context': {
                'reportLocation': {
                  'filePath': stackFrame.library,
                  if (stackFrame.line != null) 'lineNumber': stackFrame.line,
                  'functionName': stackFrame.member,
                }
              },

kevmoo avatar Dec 01 '20 22:12 kevmoo