Open pierredelisle7 opened 3 years ago
It would be interesting to see if we can leverage the existing framework
abstraction:
https://github.com/actions-on-google/actions-on-google-nodejs/tree/master/src/framework
To automatically use the Firebase Cloud Functions logger SDK when detected that we're deployed in a Firebase Cloud Functions environment.
Looks like this is currently done by running framework specific checks againt the arguments of the handler: https://github.com/actions-on-google/actions-on-google-nodejs/blob/master/src/assistant.ts#L74
See https://github.com/googlecodelabs/smarthome-washer/issues/39 for background information.
The ask is for the node.js smarthome client library to support configuring its various loggers (debug, info, warn, error).
The ability to configure the loggers would, for example, allow client applications that use firebase cloud functions to improve substantially the readability of their logs as is shown below.
Currently, one log message coming from this client library appears with multiple log entries in the "firebase cloud functions log console" which impacts readability substantially:
If logging were configurable (PR coming shortly), log messages from this library would have a single log entry, which improves readability tremendously: