-
Notifications
You must be signed in to change notification settings - Fork 21
Closed
Description
See https://github.com/mozilla/fx-private-relay/pull/82/files#r395097199 ... not sure why this code:
python-dockerflow/src/dockerflow/logging.py
Lines 122 to 123 in 6cc0662
| if message and not self.is_value_jsonlike(message): | |
| fields["msg"] = message |
is skipping log records where messages are already json-like? This means code like the following:
logger.info({
'event_type': 'email_relay',
'relay_address_id': relay_address.id,
'relay_address': sha256(local_portion.encode('utf-8')).hexdigest(),
'real_address': sha256(
relay_address.user.email.encode('utf-8')
).hexdigest(),
})Omits the dictionary from the output. So this outputs:
{"Timestamp": 1584647678788551936, "Type": "events", "Logger": "fx-private-relay", "Hostname": "groovetop", "EnvVersion": "2.0", "Severity": 6, "Pid": 4031, "Fields": {}}
?
Which makes no sense to me. Is there a different way I should be logging JSON-like objects via dockerflow.
Metadata
Metadata
Assignees
Labels
No labels