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

Commit 8dd8aec

Browse files
chore: use gapic-generator-python 0.62.1 (#217)
- [ ] Regenerate this pull request now. fix: resolve DuplicateCredentialArgs error when using credentials_file committer: parthea PiperOrigin-RevId: 425964861 Source-Link: googleapis/googleapis@84b1a5a Source-Link: https://github.com/googleapis/googleapis-gen/commit/4fb761bbd8506ac156f49bac5f18306aa8eb3aa8 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNGZiNzYxYmJkODUwNmFjMTU2ZjQ5YmFjNWYxODMwNmFhOGViM2FhOCJ9
1 parent ce21598 commit 8dd8aec

File tree

15 files changed

+326
-119
lines changed

15 files changed

+326
-119
lines changed

google/cloud/tasks_v2/services/cloud_tasks/async_client.py

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ async def list_queues(
249249
250250
"""
251251
# Create or coerce a protobuf request object.
252-
# Sanity check: If we got a request object, we should *not* have
252+
# Quick check: If we got a request object, we should *not* have
253253
# gotten any keyword arguments that map to the request.
254254
has_flattened_params = any([parent])
255255
if request is not None and has_flattened_params:
@@ -340,7 +340,7 @@ async def get_queue(
340340
341341
"""
342342
# Create or coerce a protobuf request object.
343-
# Sanity check: If we got a request object, we should *not* have
343+
# Quick check: If we got a request object, we should *not* have
344344
# gotten any keyword arguments that map to the request.
345345
has_flattened_params = any([name])
346346
if request is not None and has_flattened_params:
@@ -450,7 +450,7 @@ async def create_queue(
450450
451451
"""
452452
# Create or coerce a protobuf request object.
453-
# Sanity check: If we got a request object, we should *not* have
453+
# Quick check: If we got a request object, we should *not* have
454454
# gotten any keyword arguments that map to the request.
455455
has_flattened_params = any([parent, queue])
456456
if request is not None and has_flattened_params:
@@ -558,7 +558,7 @@ async def update_queue(
558558
559559
"""
560560
# Create or coerce a protobuf request object.
561-
# Sanity check: If we got a request object, we should *not* have
561+
# Quick check: If we got a request object, we should *not* have
562562
# gotten any keyword arguments that map to the request.
563563
has_flattened_params = any([queue, update_mask])
564564
if request is not None and has_flattened_params:
@@ -638,7 +638,7 @@ async def delete_queue(
638638
sent along with the request as metadata.
639639
"""
640640
# Create or coerce a protobuf request object.
641-
# Sanity check: If we got a request object, we should *not* have
641+
# Quick check: If we got a request object, we should *not* have
642642
# gotten any keyword arguments that map to the request.
643643
has_flattened_params = any([name])
644644
if request is not None and has_flattened_params:
@@ -727,7 +727,7 @@ async def purge_queue(
727727
728728
"""
729729
# Create or coerce a protobuf request object.
730-
# Sanity check: If we got a request object, we should *not* have
730+
# Quick check: If we got a request object, we should *not* have
731731
# gotten any keyword arguments that map to the request.
732732
has_flattened_params = any([name])
733733
if request is not None and has_flattened_params:
@@ -809,7 +809,7 @@ async def pause_queue(
809809
810810
"""
811811
# Create or coerce a protobuf request object.
812-
# Sanity check: If we got a request object, we should *not* have
812+
# Quick check: If we got a request object, we should *not* have
813813
# gotten any keyword arguments that map to the request.
814814
has_flattened_params = any([name])
815815
if request is not None and has_flattened_params:
@@ -898,7 +898,7 @@ async def resume_queue(
898898
899899
"""
900900
# Create or coerce a protobuf request object.
901-
# Sanity check: If we got a request object, we should *not* have
901+
# Quick check: If we got a request object, we should *not* have
902902
# gotten any keyword arguments that map to the request.
903903
has_flattened_params = any([name])
904904
if request is not None and has_flattened_params:
@@ -1032,7 +1032,7 @@ async def get_iam_policy(
10321032
10331033
"""
10341034
# Create or coerce a protobuf request object.
1035-
# Sanity check: If we got a request object, we should *not* have
1035+
# Quick check: If we got a request object, we should *not* have
10361036
# gotten any keyword arguments that map to the request.
10371037
has_flattened_params = any([resource])
10381038
if request is not None and has_flattened_params:
@@ -1180,7 +1180,7 @@ async def set_iam_policy(
11801180
11811181
"""
11821182
# Create or coerce a protobuf request object.
1183-
# Sanity check: If we got a request object, we should *not* have
1183+
# Quick check: If we got a request object, we should *not* have
11841184
# gotten any keyword arguments that map to the request.
11851185
has_flattened_params = any([resource])
11861186
if request is not None and has_flattened_params:
@@ -1269,7 +1269,7 @@ async def test_iam_permissions(
12691269
Response message for TestIamPermissions method.
12701270
"""
12711271
# Create or coerce a protobuf request object.
1272-
# Sanity check: If we got a request object, we should *not* have
1272+
# Quick check: If we got a request object, we should *not* have
12731273
# gotten any keyword arguments that map to the request.
12741274
has_flattened_params = any([resource, permissions])
12751275
if request is not None and has_flattened_params:
@@ -1365,7 +1365,7 @@ async def list_tasks(
13651365
13661366
"""
13671367
# Create or coerce a protobuf request object.
1368-
# Sanity check: If we got a request object, we should *not* have
1368+
# Quick check: If we got a request object, we should *not* have
13691369
# gotten any keyword arguments that map to the request.
13701370
has_flattened_params = any([parent])
13711371
if request is not None and has_flattened_params:
@@ -1451,7 +1451,7 @@ async def get_task(
14511451
A unit of scheduled work.
14521452
"""
14531453
# Create or coerce a protobuf request object.
1454-
# Sanity check: If we got a request object, we should *not* have
1454+
# Quick check: If we got a request object, we should *not* have
14551455
# gotten any keyword arguments that map to the request.
14561456
has_flattened_params = any([name])
14571457
if request is not None and has_flattened_params:
@@ -1584,7 +1584,7 @@ async def create_task(
15841584
A unit of scheduled work.
15851585
"""
15861586
# Create or coerce a protobuf request object.
1587-
# Sanity check: If we got a request object, we should *not* have
1587+
# Quick check: If we got a request object, we should *not* have
15881588
# gotten any keyword arguments that map to the request.
15891589
has_flattened_params = any([parent, task])
15901590
if request is not None and has_flattened_params:
@@ -1655,7 +1655,7 @@ async def delete_task(
16551655
sent along with the request as metadata.
16561656
"""
16571657
# Create or coerce a protobuf request object.
1658-
# Sanity check: If we got a request object, we should *not* have
1658+
# Quick check: If we got a request object, we should *not* have
16591659
# gotten any keyword arguments that map to the request.
16601660
has_flattened_params = any([name])
16611661
if request is not None and has_flattened_params:
@@ -1760,7 +1760,7 @@ async def run_task(
17601760
A unit of scheduled work.
17611761
"""
17621762
# Create or coerce a protobuf request object.
1763-
# Sanity check: If we got a request object, we should *not* have
1763+
# Quick check: If we got a request object, we should *not* have
17641764
# gotten any keyword arguments that map to the request.
17651765
has_flattened_params = any([name])
17661766
if request is not None and has_flattened_params:

google/cloud/tasks_v2/services/cloud_tasks/client.py

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@ def list_queues(
464464
465465
"""
466466
# Create or coerce a protobuf request object.
467-
# Sanity check: If we got a request object, we should *not* have
467+
# Quick check: If we got a request object, we should *not* have
468468
# gotten any keyword arguments that map to the request.
469469
has_flattened_params = any([parent])
470470
if request is not None and has_flattened_params:
@@ -545,7 +545,7 @@ def get_queue(
545545
546546
"""
547547
# Create or coerce a protobuf request object.
548-
# Sanity check: If we got a request object, we should *not* have
548+
# Quick check: If we got a request object, we should *not* have
549549
# gotten any keyword arguments that map to the request.
550550
has_flattened_params = any([name])
551551
if request is not None and has_flattened_params:
@@ -645,7 +645,7 @@ def create_queue(
645645
646646
"""
647647
# Create or coerce a protobuf request object.
648-
# Sanity check: If we got a request object, we should *not* have
648+
# Quick check: If we got a request object, we should *not* have
649649
# gotten any keyword arguments that map to the request.
650650
has_flattened_params = any([parent, queue])
651651
if request is not None and has_flattened_params:
@@ -753,7 +753,7 @@ def update_queue(
753753
754754
"""
755755
# Create or coerce a protobuf request object.
756-
# Sanity check: If we got a request object, we should *not* have
756+
# Quick check: If we got a request object, we should *not* have
757757
# gotten any keyword arguments that map to the request.
758758
has_flattened_params = any([queue, update_mask])
759759
if request is not None and has_flattened_params:
@@ -833,7 +833,7 @@ def delete_queue(
833833
sent along with the request as metadata.
834834
"""
835835
# Create or coerce a protobuf request object.
836-
# Sanity check: If we got a request object, we should *not* have
836+
# Quick check: If we got a request object, we should *not* have
837837
# gotten any keyword arguments that map to the request.
838838
has_flattened_params = any([name])
839839
if request is not None and has_flattened_params:
@@ -912,7 +912,7 @@ def purge_queue(
912912
913913
"""
914914
# Create or coerce a protobuf request object.
915-
# Sanity check: If we got a request object, we should *not* have
915+
# Quick check: If we got a request object, we should *not* have
916916
# gotten any keyword arguments that map to the request.
917917
has_flattened_params = any([name])
918918
if request is not None and has_flattened_params:
@@ -994,7 +994,7 @@ def pause_queue(
994994
995995
"""
996996
# Create or coerce a protobuf request object.
997-
# Sanity check: If we got a request object, we should *not* have
997+
# Quick check: If we got a request object, we should *not* have
998998
# gotten any keyword arguments that map to the request.
999999
has_flattened_params = any([name])
10001000
if request is not None and has_flattened_params:
@@ -1083,7 +1083,7 @@ def resume_queue(
10831083
10841084
"""
10851085
# Create or coerce a protobuf request object.
1086-
# Sanity check: If we got a request object, we should *not* have
1086+
# Quick check: If we got a request object, we should *not* have
10871087
# gotten any keyword arguments that map to the request.
10881088
has_flattened_params = any([name])
10891089
if request is not None and has_flattened_params:
@@ -1217,7 +1217,7 @@ def get_iam_policy(
12171217
12181218
"""
12191219
# Create or coerce a protobuf request object.
1220-
# Sanity check: If we got a request object, we should *not* have
1220+
# Quick check: If we got a request object, we should *not* have
12211221
# gotten any keyword arguments that map to the request.
12221222
has_flattened_params = any([resource])
12231223
if request is not None and has_flattened_params:
@@ -1354,7 +1354,7 @@ def set_iam_policy(
13541354
13551355
"""
13561356
# Create or coerce a protobuf request object.
1357-
# Sanity check: If we got a request object, we should *not* have
1357+
# Quick check: If we got a request object, we should *not* have
13581358
# gotten any keyword arguments that map to the request.
13591359
has_flattened_params = any([resource])
13601360
if request is not None and has_flattened_params:
@@ -1442,7 +1442,7 @@ def test_iam_permissions(
14421442
Response message for TestIamPermissions method.
14431443
"""
14441444
# Create or coerce a protobuf request object.
1445-
# Sanity check: If we got a request object, we should *not* have
1445+
# Quick check: If we got a request object, we should *not* have
14461446
# gotten any keyword arguments that map to the request.
14471447
has_flattened_params = any([resource, permissions])
14481448
if request is not None and has_flattened_params:
@@ -1527,7 +1527,7 @@ def list_tasks(
15271527
15281528
"""
15291529
# Create or coerce a protobuf request object.
1530-
# Sanity check: If we got a request object, we should *not* have
1530+
# Quick check: If we got a request object, we should *not* have
15311531
# gotten any keyword arguments that map to the request.
15321532
has_flattened_params = any([parent])
15331533
if request is not None and has_flattened_params:
@@ -1603,7 +1603,7 @@ def get_task(
16031603
A unit of scheduled work.
16041604
"""
16051605
# Create or coerce a protobuf request object.
1606-
# Sanity check: If we got a request object, we should *not* have
1606+
# Quick check: If we got a request object, we should *not* have
16071607
# gotten any keyword arguments that map to the request.
16081608
has_flattened_params = any([name])
16091609
if request is not None and has_flattened_params:
@@ -1726,7 +1726,7 @@ def create_task(
17261726
A unit of scheduled work.
17271727
"""
17281728
# Create or coerce a protobuf request object.
1729-
# Sanity check: If we got a request object, we should *not* have
1729+
# Quick check: If we got a request object, we should *not* have
17301730
# gotten any keyword arguments that map to the request.
17311731
has_flattened_params = any([parent, task])
17321732
if request is not None and has_flattened_params:
@@ -1797,7 +1797,7 @@ def delete_task(
17971797
sent along with the request as metadata.
17981798
"""
17991799
# Create or coerce a protobuf request object.
1800-
# Sanity check: If we got a request object, we should *not* have
1800+
# Quick check: If we got a request object, we should *not* have
18011801
# gotten any keyword arguments that map to the request.
18021802
has_flattened_params = any([name])
18031803
if request is not None and has_flattened_params:
@@ -1892,7 +1892,7 @@ def run_task(
18921892
A unit of scheduled work.
18931893
"""
18941894
# Create or coerce a protobuf request object.
1895-
# Sanity check: If we got a request object, we should *not* have
1895+
# Quick check: If we got a request object, we should *not* have
18961896
# gotten any keyword arguments that map to the request.
18971897
has_flattened_params = any([name])
18981898
if request is not None and has_flattened_params:

google/cloud/tasks_v2/services/cloud_tasks/transports/grpc.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,11 @@ def __init__(
166166
if not self._grpc_channel:
167167
self._grpc_channel = type(self).create_channel(
168168
self._host,
169+
# use the credentials which are saved
169170
credentials=self._credentials,
170-
credentials_file=credentials_file,
171+
# Set ``credentials_file`` to ``None`` here as
172+
# the credentials that we saved earlier should be used.
173+
credentials_file=None,
171174
scopes=self._scopes,
172175
ssl_credentials=self._ssl_channel_credentials,
173176
quota_project_id=quota_project_id,

google/cloud/tasks_v2/services/cloud_tasks/transports/grpc_asyncio.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,8 +211,11 @@ def __init__(
211211
if not self._grpc_channel:
212212
self._grpc_channel = type(self).create_channel(
213213
self._host,
214+
# use the credentials which are saved
214215
credentials=self._credentials,
215-
credentials_file=credentials_file,
216+
# Set ``credentials_file`` to ``None`` here as
217+
# the credentials that we saved earlier should be used.
218+
credentials_file=None,
216219
scopes=self._scopes,
217220
ssl_credentials=self._ssl_channel_credentials,
218221
quota_project_id=quota_project_id,

0 commit comments

Comments
 (0)