8000 chore: use gapic-generator-python 0.56.2 (#204) · googleapis/google-cloud-python@a77e860 · GitHub
[go: up one dir, main page]

Skip to content

Commit a77e860

Browse files
chore: use gapic-generator-python 0.56.2 (#204)
* chore: update Java and Python dependencies PiperOrigin-RevId: 408420890 Source-Link: googleapis/googleapis@2921f9f Source-Link: googleapis/googleapis-gen@6598ca8 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNjU5OGNhOGNiYmY1MjI2NzMzYTA5OWM0NTA2NTE4YTVhZjZmZjc0YyJ9 * 🦉 Updates from OwlBot See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 60b8fff commit a77e860

File tree

7 files changed

+250
-102
lines changed

7 files changed

+250
-102
lines changed

packages/google-cloud-build/google/cloud/devtools/cloudbuild_v1/services/cloud_build/async_client.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,17 @@
1919
from typing import Dict, Sequence, Tuple, Type, Union
2020
import pkg_resources
2121

22-
from google.api_core.client_options import ClientOptions # type: ignore
23-
from google.api_core import exceptions as core_exceptions # type: ignore
24-
from google.api_core import gapic_v1 # type: ignore
25-
from google.api_core import retry as retries # type: ignore
22+
from google.api_core.client_options import ClientOptions
23+
from google.api_core import exceptions as core_exceptions
24+
from google.api_core import gapic_v1
25+
from google.api_core import retry as retries
2626
from google.auth import credentials as ga_credentials # type: ignore
2727
from google.oauth2 import service_account # type: ignore
2828

29-
OptionalRetry = Union[retries.Retry, object]
29+
try:
30+
OptionalRetry = Union[retries.Retry, gapic_v1.method._MethodDefault]
31+
except AttributeError: # pragma: NO COVER
32+
OptionalRetry = Union[retries.Retry, object] # type: ignore
3033

3134
from google.api_core import operation # type: ignore
3235
from google.api_core import operation_async # type: ignore

packages/google-cloud-build/google/cloud/devtools/cloudbuild_v1/services/cloud_build/client.py

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,23 +14,25 @@
1414
# limitations under the License.
1515
#
1616
from collections import OrderedDict
17-
from distutils import util
1817
import os
1918
import re
2019
from typing import Dict, Optional, Sequence, Tuple, Type, Union
2120
import pkg_resources
2221

23-
from google.api_core import client_options as client_options_lib # type: ignore
24-
from google.api_core import exceptions as core_exceptions # type: ignore
25-
from google.api_core import gapic_v1 # type: ignore
26-
from google.api_core import retry as retries # type: ignore
22+
from google.api_core import client_options as client_options_lib
23+
from google.api_core import exceptions as core_exceptions
24+
from google.api_core import gapic_v1
25+
from google.api_core import retry as retries
2726
from google.auth import credentials as ga_credentials # type: ignore
2827
from google.auth.transport import mtls # type: ignore
2928
from google.auth.transport.grpc import SslCredentials # type: ignore
3029
from google.auth.exceptions import MutualTLSChannelError # type: ignore
3130
from google.oauth2 import service_account # type: ignore
3231

33-
OptionalRetry = Union[retries.Retry, object]
32+
try:
33+
OptionalRetry = Union[retries.Retry, gapic_v1.method._MethodDefault]
34+
except AttributeError: # pragma: NO COVER
35+
OptionalRetry = Union[retries.Retry, object] # type: ignore
3436

3537
from google.api_core import operation # type: ignore
3638
from google.api_core import operation_async # type: ignore
@@ -408,8 +410,15 @@ def __init__(
408410
client_options = client_options_lib.ClientOptions()
409411

410412
# Create SSL credentials for mutual TLS if needed.
411-
use_client_cert = bool(
412-
util.strtobool(os.getenv("GOOGLE_API_USE_CLIENT_CERTIFICATE", "false"))
413+
if os.getenv("GOOGLE_API_USE_CLIENT_CERTIFICATE", "false") not in (
414+
"true",
415+
"false",
416+
):
417+
raise ValueError(
418+
"Environment variable `GOOGLE_API_USE_CLIENT_CERTIFICATE` must be either `true` or `false`"
419+
)
420+
use_client_cert = (
421+
os.getenv("GOOGLE_API_USE_CLIENT_CERTIFICATE", "false") == "true"
413422
)
414423

415424
client_cert_source_func = None

packages/google-cloud-build/google/cloud/devtools/cloudbuild_v1/services/cloud_build/transports/base.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@
1818
import pkg_resources
1919

2020
import google.auth # type: ignore
21-
import google.api_core # type: ignore
22-
from google.api_core import exceptions as core_exceptions # type: ignore
23-
from google.api_core import gapic_v1 # type: ignore
24-
from google.api_core import retry as retries # type: ignore
25-
from google.api_core import operations_v1 # type: ignore
21+
import google.api_core
22+
from google.api_core import exceptions as core_exceptions
23+
from google.api_core import gapic_v1
24+
from google.api_core import retry as retries
25+
from google.api_core import operations_v1
2626
from google.auth import credentials as ga_credentials # type: ignore
2727
from google.oauth2 import service_account # type: ignore
2828

packages/google-cloud-build/google/cloud/devtools/cloudbuild_v1/services/cloud_build/transports/grpc.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616
import warnings
1717
from typing import Callable, Dict, Optional, Sequence, Tuple, Union
1818

19-
from google.api_core import grpc_helpers # type: ignore
20-
from google.api_core import operations_v1 # type: ignore
21-
from google.api_core import gapic_v1 # type: ignore
19+
from google.api_core import grpc_helpers
20+
from google.api_core import operations_v1
21+
from google.api_core import gapic_v1
2222
import google.auth # type: ignore
2323
from google.auth import credentials as ga_credentials # type: ignore
2424
from google.auth.transport.grpc import SslCredentials # type: ignore

packages/google-cloud-build/google/cloud/devtools/cloudbuild_v1/services/cloud_build/transports/grpc_asyncio.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616
import warnings
1717
from typing import Awaitable, Callable, Dict, Optional, Sequence, Tuple, Union
1818

19-
from google.api_core import gapic_v1 # type: ignore
20-
from google.api_core import grpc_helpers_async # type: ignore
21-
from google.api_core import operations_v1 # type: ignore
19+
from google.api_core import gapic_v1
20+
from google.api_core import grpc_helpers_async
21+
from google.api_core import operations_v1
2222
from google.auth import credentials as ga_credentials # type: ignore
2323
from google.auth.transport.grpc import SslCredentials # type: ignore
2424

packages/google-cloud-build/google/cloud/devtools/cloudbuild_v1/types/cloudbuild.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,15 +171,18 @@ class RepoSource(proto.Message):
171171
The syntax of the regular expressions accepted
172172
is the syntax accepted by RE2 and described at
173173
https://github.com/google/re2/wiki/Syntax
174+
174175
This field is a member of `oneof`_ ``revision``.
175176
tag_name (str):
176177
Regex matching tags to build.
177178
The syntax of the regular expressions accepted
178179
is the syntax accepted by RE2 and described at
179180
https://github.com/google/re2/wiki/Syntax
181+
180182
This field is a member of `oneof`_ ``revision``.
181183
commit_sha (str):
182184
Explicit commit SHA to build.
185+
183186
This field is a member of `oneof`_ ``revision``.
184187
dir_ (str):
185188
Directory, relative to the source root, in which to run the
@@ -245,15 +248,18 @@ class Source(proto.Message):
245248
storage_source (google.cloud.devtools.cloudbuild_v1.types.StorageSource):
246249
If provided, get the source from this
247250
location in Google Cloud Storage.
251+
248252
This field is a member of `oneof`_ ``source``.
249253
repo_source (google.cloud.devtools.cloudbuild_v1.types.RepoSource):
250254
If provided, get the source from this
251255
location in a Cloud Source Repository.
256+
252257
This field is a member of `oneof`_ ``source``.
253258
storage_source_manifest (google.cloud.devtools.cloudbuild_v1.types.StorageSourceManifest):
254259
If provided, get the source from this manifest in Google
255260
Cloud Storage. This feature is in Preview; see description
256261
`here <https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher>`__.
262+
257263
This field is a member of `oneof`_ ``source``.
258264
"""
259265

@@ -1238,13 +1244,16 @@ class BuildTrigger(proto.Message):
12381244
12391245
Currently only available for GitHub App
12401246
Triggers.
1247+
12411248
This field is a member of `oneof`_ ``build_template``.
12421249
build (google.cloud.devtools.cloudbuild_v1.types.Build):
12431250
Contents of the build template.
1251+
12441252
This field is a member of `oneof`_ ``build_template``.
12451253
filename (str):
12461254
Path, from the source root, to the build
12471255
configuration file (i.e. cloudbuild.yaml).
1256+
12481257
This field is a member of `oneof`_ ``build_template``.
12491258
create_time (google.protobuf.timestamp_pb2.Timestamp):
12501259
Output only. Time when the trigger was
@@ -1341,10 +1350,12 @@ class GitHubEventsConfig(proto.Message):
13411350
builders is "cloud-builders".
13421351
pull_request (google.cloud.devtools.cloudbuild_v1.types.PullRequestFilter):
13431352
filter to match changes in pull requests.
1353+
13441354
This field is a member of `oneof`_ ``event``.
13451355
push (google.cloud.devtools.cloudbuild_v1.types.PushFilter):
13461356
filter to match changes in refs like
13471357
branches, tags.
1358+
13481359
This field is a member of `oneof`_ ``event``.
13491360
"""
13501361

@@ -1406,6 +1417,7 @@ class WebhookConfig(proto.Message):
14061417
secret (str):
14071418
Required. Resource name for the secret
14081419
required as a URL parameter.
1420+
14091421
This field is a member of `oneof`_ ``auth_method``.
14101422
state (google.cloud.devtools.cloudbuild_v1.types.WebhookConfig.State):
14111423
Potential issues with the underlying Pub/Sub
@@ -1438,6 +1450,7 @@ class PullRequestFilter(proto.Message):
14381450
The syntax of the regular expressions accepted
14391451
is the syntax accepted by RE2 and described at
14401452
https://github.com/google/re2/wiki/Syntax
1453+
14411454
This field is a member of `oneof`_ ``git_ref``.
14421455
comment_control (google.cloud.devtools.cloudbuild_v1.types.PullRequestFilter.CommentControl):
14431456
Configure builds to run whether a repository owner or
@@ -1475,12 +1488,14 @@ class PushFilter(proto.Message):
14751488
The syntax of the regular expressions accepted
14761489
is the syntax accepted by RE2 and described at
14771490
https://github.com/google/re2/wiki/Syntax
1491+
14781492
This field is a member of `oneof`_ ``git_ref``.
14791493
tag (str):
14801494
Regexes matching tags to build.
14811495
The syntax of the regular expressions accepted
14821496
is the syntax accepted by RE2 and described at
14831497
https://github.com/google/re2/wiki/Syntax
1498+
14841499
This field is a member of `oneof`_ ``git_ref``.
14851500
invert_regex (bool):
14861501
When true, only trigger a build if the revision regex does
@@ -1849,6 +1864,7 @@ class WorkerPool(proto.Message):
18491864
Output only. ``WorkerPool`` state.
18501865
private_pool_v1_config (google.cloud.devtools.cloudbuild_v1.types.PrivatePoolV1Config):
18511866
Private Pool using a v1 configuration.
1867+
18521868
This field is a member of `oneof`_ ``config``.
18531869
etag (str):
18541870
Output only. Checksum computed by the server.

0 commit comments

Comments
 (0)
0