-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add client logging support for sync gRPC #2284
Conversation
5765247
to
77f47ee
Compare
f6392c9
to
30a2939
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. One non-trivial question.suggestion about the accessor.
gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/grpc.py.j2
Outdated
Show resolved
Hide resolved
gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/grpc.py.j2
Outdated
Show resolved
Hide resolved
...on/goldens/credentials/google/iam/credentials_v1/services/iam_credentials/transports/grpc.py
Outdated
Show resolved
Hide resolved
...on/goldens/credentials/google/iam/credentials_v1/services/iam_credentials/transports/grpc.py
Outdated
Show resolved
Hide resolved
@@ -186,6 +246,11 @@ def __init__(self, *, | |||
], | |||
) | |||
|
|||
self._grpc_channel = self._base_channel | |||
if CLIENT_LOGGING_SUPPORTED and _LOGGER.isEnabledFor(std_logging.DEBUG): # pragma: NO COVER |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest checking here whether any logging levels are handled at all, so using either std_logging.NOTSET
or the next highest priority, the numeric 1
(ref)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
addressed.
...on/goldens/credentials/google/iam/credentials_v1/services/iam_credentials/transports/grpc.py
Outdated
Show resolved
Hide resolved
gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/grpc.py.j2
Outdated
Show resolved
Hide resolved
gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/grpc.py.j2
Outdated
Show resolved
Hide resolved
gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/grpc.py.j2
Outdated
Show resolved
Hide resolved
gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/grpc.py.j2
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. I can do a final pass once you have the if/elif stuff down.
gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/grpc.py.j2
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One comment
excludes support for mixins and streaming calls.