3535from requests import __version__ as requests_version
3636import dataclasses
3737import re
38- from typing import Callable , Dict , List , Optional , Sequence , Tuple , Union
38+ from typing import Any , Callable , Dict , List , Optional , Sequence , Tuple , Union
3939import warnings
4040
4141try :
@@ -490,17 +490,15 @@ def pre_get_iam_policy(
490490 self ,
491491 request : iam_policy_pb2 .GetIamPolicyRequest ,
492492 metadata : Sequence [Tuple [str , str ]],
493- ) -> policy_pb2 . Policy :
493+ ) -> Tuple [ iam_policy_pb2 . GetIamPolicyRequest , Sequence [ Tuple [ str , str ]]] :
494494 """Pre-rpc interceptor for get_iam_policy
495495
496496 Override in a subclass to manipulate the request or metadata
497497 before they are sent to the RepositoryManager server.
498498 """
499499 return request , metadata
500500
501- def post_get_iam_policy (
502- self , response : iam_policy_pb2 .GetIamPolicyRequest
503- ) -> policy_pb2 .Policy :
501+ def post_get_iam_policy (self , response : policy_pb2 .Policy ) -> policy_pb2 .Policy :
504502 """Post-rpc interceptor for get_iam_policy
505503
506504 Override in a subclass to manipulate the response
@@ -513,17 +511,15 @@ def pre_set_iam_policy(
513511 self ,
514512 request : iam_policy_pb2 .SetIamPolicyRequest ,
515513 metadata : Sequence [Tuple [str , str ]],
516- ) -> policy_pb2 . Policy :
514+ ) -> Tuple [ iam_policy_pb2 . SetIamPolicyRequest , Sequence [ Tuple [ str , str ]]] :
517515 """Pre-rpc interceptor for set_iam_policy
518516
519517 Override in a subclass to manipulate the request or metadata
520518 before they are sent to the RepositoryManager server.
521519 """
522520 return request , metadata
523521
524- def post_set_iam_policy (
525- self , response : iam_policy_pb2 .SetIamPolicyRequest
526- ) -> policy_pb2 .Policy :
522+ def post_set_iam_policy (self , response : policy_pb2 .Policy ) -> policy_pb2 .Policy :
527523 """Post-rpc interceptor for set_iam_policy
528524
529525 Override in a subclass to manipulate the response
@@ -536,7 +532,7 @@ def pre_test_iam_permissions(
536532 self ,
537533 request : iam_policy_pb2 .TestIamPermissionsRequest ,
538534 metadata : Sequence [Tuple [str , str ]],
539- ) -> iam_policy_pb2 .TestIamPermissionsResponse :
535+ ) -> Tuple [ iam_policy_pb2 .TestIamPermissionsRequest , Sequence [ Tuple [ str , str ]]] :
540536 """Pre-rpc interceptor for test_iam_permissions
541537
542538 Override in a subclass to manipulate the request or metadata
@@ -545,7 +541,7 @@ def pre_test_iam_permissions(
545541 return request , metadata
546542
547543 def post_test_iam_permissions (
548- self , response : iam_policy_pb2 .TestIamPermissionsRequest
544+ self , response : iam_policy_pb2 .TestIamPermissionsResponse
549545 ) -> iam_policy_pb2 .TestIamPermissionsResponse :
550546 """Post-rpc interceptor for test_iam_permissions
551547
@@ -559,17 +555,15 @@ def pre_cancel_operation(
559555 self ,
560556 request : operations_pb2 .CancelOperationRequest ,
561557 metadata : Sequence [Tuple [str , str ]],
562- ) -> None :
558+ ) -> Tuple [ operations_pb2 . CancelOperationRequest , Sequence [ Tuple [ str , str ]]] :
563559 """Pre-rpc interceptor for cancel_operation
564560
565561 Override in a subclass to manipulate the request or metadata
566562 before they are sent to the RepositoryManager server.
567563 """
568564 return request , metadata
569565
570- def post_cancel_operation (
571- self , response : operations_pb2 .CancelOperationRequest
572- ) -> None :
566+ def post_cancel_operation (self , response : None ) -> None :
573567 """Post-rpc interceptor for cancel_operation
574568
575569 Override in a subclass to manipulate the response
@@ -582,7 +576,7 @@ def pre_get_operation(
582576 self ,
583577 request : operations_pb2 .GetOperationRequest ,
584578 metadata : Sequence [Tuple [str , str ]],
585- ) -> operations_pb2 .Operation :
579+ ) -> Tuple [ operations_pb2 .GetOperationRequest , Sequence [ Tuple [ str , str ]]] :
586580 """Pre-rpc interceptor for get_operation
587581
588582 Override in a subclass to manipulate the request or metadata
@@ -591,7 +585,7 @@ def pre_get_operation(
591585 return request , metadata
592586
593587 def post_get_operation (
594- self , response : operations_pb2 .GetOperationRequest
588+ self , response : operations_pb2 .Operation
595589 ) -> operations_pb2 .Operation :
596590 """Post-rpc interceptor for get_operation
597591
@@ -744,7 +738,7 @@ class _BatchCreateRepositories(RepositoryManagerRestStub):
744738 def __hash__ (self ):
745739 return hash ("BatchCreateRepositories" )
746740
747- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
741+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
748742
749743 @classmethod
750744 def _get_unset_required_fields (cls , message_dict ):
@@ -844,7 +838,7 @@ class _CreateConnection(RepositoryManagerRestStub):
844838 def __hash__ (self ):
845839 return hash ("CreateConnection" )
846840
847- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
841+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
848842 "connectionId" : "" ,
849843 }
850844
@@ -944,7 +938,7 @@ class _CreateRepository(RepositoryManagerRestStub):
944938 def __hash__ (self ):
945939 return hash ("CreateRepository" )
946940
947- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {
941+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {
948942 "repositoryId" : "" ,
949943 }
950944
@@ -1044,7 +1038,7 @@ class _DeleteConnection(RepositoryManagerRestStub):
10441038 def __hash__ (self ):
10451039 return hash ("DeleteConnection" )
10461040
1047- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1041+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
10481042
10491043 @classmethod
10501044 def _get_unset_required_fields (cls , message_dict ):
@@ -1133,7 +1127,7 @@ class _DeleteRepository(RepositoryManagerRestStub):
11331127 def __hash__ (self ):
11341128 return hash ("DeleteRepository" )
11351129
1136- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1130+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
11371131
11381132 @classmethod
11391133 def _get_unset_required_fields (cls , message_dict ):
@@ -1222,7 +1216,7 @@ class _FetchLinkableRepositories(RepositoryManagerRestStub):
12221216 def __hash__ (self ):
12231217 return hash ("FetchLinkableRepositories" )
12241218
1225- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1219+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
12261220
12271221 @classmethod
12281222 def _get_unset_required_fields (cls , message_dict ):
@@ -1315,7 +1309,7 @@ class _FetchReadToken(RepositoryManagerRestStub):
13151309 def __hash__ (self ):
13161310 return hash ("FetchReadToken" )
13171311
1318- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1312+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
13191313
13201314 @classmethod
13211315 def _get_unset_required_fields (cls , message_dict ):
@@ -1414,7 +1408,7 @@ class _FetchReadWriteToken(RepositoryManagerRestStub):
14141408 def __hash__ (self ):
14151409 return hash ("FetchReadWriteToken" )
14161410
1417- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1411+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
14181412
14191413 @classmethod
14201414 def _get_unset_required_fields (cls , message_dict ):
@@ -1515,7 +1509,7 @@ class _GetConnection(RepositoryManagerRestStub):
15151509 def __hash__ (self ):
15161510 return hash ("GetConnection" )
15171511
1518- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1512+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
15191513
15201514 @classmethod
15211515 def _get_unset_required_fields (cls , message_dict ):
@@ -1606,7 +1600,7 @@ class _GetRepository(RepositoryManagerRestStub):
16061600 def __hash__ (self ):
16071601 return hash ("GetRepository" )
16081602
1609- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1603+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
16101604
16111605 @classmethod
16121606 def _get_unset_required_fields (cls , message_dict ):
@@ -1696,7 +1690,7 @@ class _ListConnections(RepositoryManagerRestStub):
16961690 def __hash__ (self ):
16971691 return hash ("ListConnections" )
16981692
1699- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1693+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
17001694
17011695 @classmethod
17021696 def _get_unset_required_fields (cls , message_dict ):
@@ -1788,7 +1782,7 @@ class _ListRepositories(RepositoryManagerRestStub):
17881782 def __hash__ (self ):
17891783 return hash ("ListRepositories" )
17901784
1791- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1785+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
17921786
17931787 @classmethod
17941788 def _get_unset_required_fields (cls , message_dict ):
@@ -1880,7 +1874,7 @@ class _UpdateConnection(RepositoryManagerRestStub):
18801874 def __hash__ (self ):
18811875 return hash ("UpdateConnection" )
18821876
1883- __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , str ] = {}
1877+ __REQUIRED_FIELDS_DEFAULT_VALUES : Dict [str , Any ] = {}
18841878
18851879 @classmethod
18861880 def _get_unset_required_fields (cls , message_dict ):
0 commit comments