Skip to content
This repository was archived by the owner on Feb 13, 2024. It is now read-only.

Commit 8cc57cc

Browse files
fix: disable always_use_jwt_access (#171)
fix: disable always_use_jwt_access Committer: @busunkim96 PiperOrigin-RevId: 382142900 Source-Link: googleapis/googleapis@513440f Source-Link: https://github.com/googleapis/googleapis-gen/commit/7b1e2c31233f79a704ec21ca410bf661d6bc68d0
1 parent cb5f6b9 commit 8cc57cc

File tree

32 files changed

+248
-128
lines changed

32 files changed

+248
-128
lines changed

google/cloud/vision_v1/services/image_annotator/transports/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ def __init__(
101101
scopes_kwargs = self._get_scopes_kwargs(self._host, scopes)
102102

103103
# Save the scopes.
104-
self._scopes = scopes or self.AUTH_SCOPES
104+
self._scopes = scopes
105105

106106
# If no credentials are provided, then determine the appropriate
107107
# defaults.

google/cloud/vision_v1/services/image_annotator/transports/grpc.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ def __init__(
6262
client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None,
6363
quota_project_id: Optional[str] = None,
6464
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
65+
always_use_jwt_access: Optional[bool] = False,
6566
) -> None:
6667
"""Instantiate the transport.
6768
@@ -102,6 +103,8 @@ def __init__(
102103
API requests. If ``None``, then default info will be used.
103104
Generally, you only need to set this if you're developing
104105
your own client library.
106+
always_use_jwt_access (Optional[bool]): Whether self signed JWT should
107+
be used for service account credentials.
105108
106109
Raises:
107110
google.auth.exceptions.MutualTLSChannelError: If mutual TLS transport
@@ -155,7 +158,7 @@ def __init__(
155158
scopes=scopes,
156159
quota_project_id=quota_project_id,
157160
client_info=client_info,
158-
always_use_jwt_access=True,
161+
always_use_jwt_access=always_use_jwt_access,
159162
)
160163

161164
if not self._grpc_channel:

google/cloud/vision_v1/services/image_annotator/transports/grpc_asyncio.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ def __init__(
108108
client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None,
109109
quota_project_id=None,
110110
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
111+
always_use_jwt_access: Optional[bool] = False,
111112
) -> None:
112113
"""Instantiate the transport.
113114
@@ -149,6 +150,8 @@ def __init__(
149150
API requests. If ``None``, then default info will be used.
150151
Generally, you only need to set this if you're developing
151152
your own client library.
153+
always_use_jwt_access (Optional[bool]): Whether self signed JWT should
154+
be used for service account credentials.
152155
153156
Raises:
154157
google.auth.exceptions.MutualTlsChannelError: If mutual TLS transport
@@ -201,7 +204,7 @@ def __init__(
201204
scopes=scopes,
202205
quota_project_id=quota_project_id,
203206
client_info=client_info,
204-
always_use_jwt_access=True,
207+
always_use_jwt_access=always_use_jwt_access,
205208
)
206209

207210
if not self._grpc_channel:

google/cloud/vision_v1/services/product_search/transports/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ def __init__(
102102
scopes_kwargs = self._get_scopes_kwargs(self._host, scopes)
103103

104104
# Save the scopes.
105-
self._scopes = scopes or self.AUTH_SCOPES
105+
self._scopes = scopes
106106

107107
# If no credentials are provided, then determine the appropriate
108108
# defaults.

google/cloud/vision_v1/services/product_search/transports/grpc.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ def __init__(
7777
client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None,
7878
quota_project_id: Optional[str] = None,
7979
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
80+
always_use_jwt_access: Optional[bool] = False,
8081
) -> None:
8182
"""Instantiate the transport.
8283
@@ -117,6 +118,8 @@ def __init__(
117118
API requests. If ``None``, then default info will be used.
118119
Generally, you only need to set this if you're developing
119120
your own client library.
121+
always_use_jwt_access (Optional[bool]): Whether self signed JWT should
122+
be used for service account credentials.
120123
121124
Raises:
122125
google.auth.exceptions.MutualTLSChannelError: If mutual TLS transport
@@ -170,7 +173,7 @@ def __init__(
170173
scopes=scopes,
171174
quota_project_id=quota_project_id,
172175
client_info=client_info,
173-
always_use_jwt_access=True,
176+
always_use_jwt_access=always_use_jwt_access,
174177
)
175178

176179
if not self._grpc_channel:

google/cloud/vision_v1/services/product_search/transports/grpc_asyncio.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,7 @@ def __init__(
123123
client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None,
124124
quota_project_id=None,
125125
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
126+
always_use_jwt_access: Optional[bool] = False,
126127
) -> None:
127128
"""Instantiate the transport.
128129
@@ -164,6 +165,8 @@ def __init__(
164165
API requests. If ``None``, then default info will be used.
165166
Generally, you only need to set this if you're developing
166167
your own client library.
168+
always_use_jwt_access (Optional[bool]): Whether self signed JWT should
169+
be used for service account credentials.
167170
168171
Raises:
169172
google.auth.exceptions.MutualTlsChannelError: If mutual TLS transport
@@ -216,7 +219,7 @@ def __init__(
216219
scopes=scopes,
217220
quota_project_id=quota_project_id,
218221
client_info=client_info,
219-
always_use_jwt_access=True,
222+
always_use_jwt_access=always_use_jwt_access,
220223
)
221224

222225
if not self._grpc_channel:

google/cloud/vision_v1p1beta1/services/image_annotator/transports/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def __init__(
9999
scopes_kwargs = self._get_scopes_kwargs(self._host, scopes)
100100

101101
# Save the scopes.
102-
self._scopes = scopes or self.AUTH_SCOPES
102+
self._scopes = scopes
103103

104104
# If no credentials are provided, then determine the appropriate
105105
# defaults.

google/cloud/vision_v1p1beta1/services/image_annotator/transports/grpc.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ def __init__(
6060
client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None,
6161
quota_project_id: Optional[str] = None,
6262
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
63+
always_use_jwt_access: Optional[bool] = False,
6364
) -> None:
6465
"""Instantiate the transport.
6566
@@ -100,6 +101,8 @@ def __init__(
100101
API requests. If ``None``, then default info will be used.
101102
Generally, you only need to set this if you're developing
102103
your own client library.
104+
always_use_jwt_access (Optional[bool]): Whether self signed JWT should
105+
be used for service account credentials.
103106
104107
Raises:
105108
google.auth.exceptions.MutualTLSChannelError: If mutual TLS transport
@@ -152,7 +155,7 @@ def __init__(
152155
scopes=scopes,
153156
quota_project_id=quota_project_id,
154157
client_info=client_info,
155-
always_use_jwt_access=True,
158+
always_use_jwt_access=always_use_jwt_access,
156159
)
157160

158161
if not self._grpc_channel:

google/cloud/vision_v1p1beta1/services/image_annotator/transports/grpc_asyncio.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ def __init__(
106106
client_cert_source_for_mtls: Callable[[], Tuple[bytes, bytes]] = None,
107107
quota_project_id=None,
108108
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
109+
always_use_jwt_access: Optional[bool] = False,
109110
) -> None:
110111
"""Instantiate the transport.
111112
@@ -147,6 +148,8 @@ def __init__(
147148
API requests. If ``None``, then default info will be used.
148149
Generally, you only need to set this if you're developing
149150
your own client library.
151+
always_use_jwt_access (Optional[bool]): Whether self signed JWT should
152+
be used for service account credentials.
150153
151154
Raises:
152155
google.auth.exceptions.MutualTlsChannelError: If mutual TLS transport
@@ -198,7 +201,7 @@ def __init__(
198201
scopes=scopes,
199202
quota_project_id=quota_project_id,
200203
client_info=client_info,
201-
always_use_jwt_access=True,
204+
always_use_jwt_access=always_use_jwt_access,
202205
)
203206

204207
if not self._grpc_channel:

google/cloud/vision_v1p2beta1/services/image_annotator/transports/base.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ def __init__(
101101
scopes_kwargs = self._get_scopes_kwargs(self._host, scopes)
102102

103103
# Save the scopes.
104-
self._scopes = scopes or self.AUTH_SCOPES
104+
self._scopes = scopes
105105

106106
# If no credentials are provided, then determine the appropriate
107107
# defaults.

0 commit comments

Comments
 (0)