3636
3737
3838class _WrappedCall (aio .Call ):
39-
4039 def __init__ (self ):
4140 self ._call = None
4241
@@ -80,7 +79,6 @@ async def wait_for_connection(self):
8079
8180
8281class _WrappedUnaryResponseMixin (_WrappedCall ):
83-
8482 def __await__ (self ):
8583 try :
8684 response = yield from self ._call .__await__ ()
@@ -90,7 +88,6 @@ def __await__(self):
9088
9189
9290class _WrappedStreamResponseMixin (_WrappedCall ):
93-
9491 def __init__ (self ):
9592 self ._wrapped_async_generator = None
9693
@@ -117,7 +114,6 @@ def __aiter__(self):
117114
118115
119116class _WrappedStreamRequestMixin (_WrappedCall ):
120-
121117 async def write (self , request ):
122118 try :
123119 await self ._call .write (request )
@@ -142,11 +138,15 @@ class _WrappedUnaryStreamCall(_WrappedStreamResponseMixin, aio.UnaryStreamCall):
142138 """Wrapped UnaryStreamCall to map exceptions."""
143139
144140
145- class _WrappedStreamUnaryCall (_WrappedUnaryResponseMixin , _WrappedStreamRequestMixin , aio .StreamUnaryCall ):
141+ class _WrappedStreamUnaryCall (
142+ _WrappedUnaryResponseMixin , _WrappedStreamRequestMixin , aio .StreamUnaryCall
143+ ):
146144 """Wrapped StreamUnaryCall to map exceptions."""
147145
148146
149- class _WrappedStreamStreamCall (_WrappedStreamRequestMixin , _WrappedStreamResponseMixin , aio .StreamStreamCall ):
147+ class _WrappedStreamStreamCall (
148+ _WrappedStreamRequestMixin , _WrappedStreamResponseMixin , aio .StreamStreamCall
149+ ):
150150 """Wrapped StreamStreamCall to map exceptions."""
151151
152152
@@ -177,7 +177,7 @@ async def error_remapped_callable(*args, **kwargs):
177177 elif isinstance (call , aio .StreamStreamCall ):
178178 call = _WrappedStreamStreamCall ().with_call (call )
179179 else :
180- raise TypeError (' Unexpected type of call %s' % type (call ))
180+ raise TypeError (" Unexpected type of call %s" % type (call ))
181181
182182 await call .wait_for_connection ()
183183 return call
@@ -207,15 +207,16 @@ def wrap_errors(callable_):
207207
208208
209209def create_channel (
210- target ,
211- credentials = None ,
212- scopes = None ,
213- ssl_credentials = None ,
214- credentials_file = None ,
215- quota_project_id = None ,
216- default_scopes = None ,
217- default_host = None ,
218- ** kwargs ):
210+ target ,
211+ credentials = None ,
212+ scopes = None ,
213+ ssl_credentials = None ,
214+ credentials_file = None ,
215+ quota_project_id = None ,
216+ default_scopes = None ,
217+ default_host = None ,
218+ ** kwargs
219+ ):
219220 """Create an AsyncIO secure channel with credentials.
220221
221222 Args:
@@ -251,7 +252,7 @@ def create_channel(
251252 default_scopes = default_scopes ,
252253 ssl_credentials = ssl_credentials ,
253254 quota_project_id = quota_project_id ,
254- default_host = default_host
255+ default_host = default_host ,
255256 )
256257
257258 return aio .secure_channel (target , composite_credentials , ** kwargs )
0 commit comments