Skip to content

Commit

Permalink
fix: Add _registered_method to grpc ChannelStub (#614)
Browse files Browse the repository at this point in the history
* fix: Add _registered_method to grpc ChannelStub

* Fix format

* Fix black
  • Loading branch information
XuanWang-Amos authored Feb 14, 2024
1 parent 8eaea7a commit 5eaaea8
Showing 1 changed file with 26 additions and 4 deletions.
30 changes: 26 additions & 4 deletions google/api_core/grpc_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -569,20 +569,42 @@ def __getattr__(self, key):
except KeyError:
raise AttributeError

def unary_unary(self, method, request_serializer=None, response_deserializer=None):
def unary_unary(
self,
method,
request_serializer=None,
response_deserializer=None,
_registered_method=False,
):
"""grpc.Channel.unary_unary implementation."""
return self._stub_for_method(method)

def unary_stream(self, method, request_serializer=None, response_deserializer=None):
def unary_stream(
self,
method,
request_serializer=None,
response_deserializer=None,
_registered_method=False,
):
"""grpc.Channel.unary_stream implementation."""
return self._stub_for_method(method)

def stream_unary(self, method, request_serializer=None, response_deserializer=None):
def stream_unary(
self,
method,
request_serializer=None,
response_deserializer=None,
_registered_method=False,
):
"""grpc.Channel.stream_unary implementation."""
return self._stub_for_method(method)

def stream_stream(
self, method, request_serializer=None, response_deserializer=None
self,
method,
request_serializer=None,
response_deserializer=None,
_registered_method=False,
):
"""grpc.Channel.stream_stream implementation."""
return self._stub_for_method(method)
Expand Down

0 comments on commit 5eaaea8

Please sign in to comment.