-
Notifications
You must be signed in to change notification settings - Fork 57
Closed
Labels
api: loggingIssues related to the googleapis/python-logging API.Issues related to the googleapis/python-logging API.lang: pythonIssues specific to Python.Issues specific to Python.priority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Milestone
Description
Hi Team,
Following the code example to list entries, we want the response data in json format.
We used the function of LogEntry to_api_repr() and works for most logs.
e.g. print(entry.to_api_repr())
This causes an exception for certain log types.
Reproduce:
- Edit iam permission for a user
- Poll list of logs using python client e.g. client.list_entries
- Print each log in json format using to_api_repr() function.
e.g.
for entry in entries:
print(entry.to_api_repr())
For this particular event you'll get an exception below:
Can not find message descriptor by type_url: type.googleapis.com/google.iam.v1.logging.AuditData
I unfortunately can't post the log, I can later perhaps if required, have to strip out some data first.
Metadata
Metadata
Assignees
Labels
api: loggingIssues related to the googleapis/python-logging API.Issues related to the googleapis/python-logging API.lang: pythonIssues specific to Python.Issues specific to Python.priority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.