From b4082bb98f7c10ea0575da52f0725668e9dd5abd Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 30 Aug 2021 15:38:39 +0000 Subject: [PATCH 1/9] chore(python): disable dependency dashboard (#72) --- .github/.OwlBot.lock.yaml | 2 +- renovate.json | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index a9fcd07..b75186c 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/repo-automation-bots/owlbot-python:latest - digest: sha256:9743664022bd63a8084be67f144898314c7ca12f0a03e422ac17c733c129d803 + digest: sha256:d6761eec279244e57fe9d21f8343381a01d3632c034811a72f68b83119e58c69 diff --git a/renovate.json b/renovate.json index c048955..9fa8816 100644 --- a/renovate.json +++ b/renovate.json @@ -1,6 +1,8 @@ { "extends": [ - "config:base", ":preserveSemverRanges" + "config:base", + ":preserveSemverRanges", + ":disableDependencyDashboard" ], "ignorePaths": [".pre-commit-config.yaml"], "pip_requirements": { From 4799cb060787c2cfc364aff1da6c8ec1dad18246 Mon Sep 17 00:00:00 2001 From: Dan Lee <71398022+dandhlee@users.noreply.github.com> Date: Mon, 30 Aug 2021 16:29:37 -0400 Subject: [PATCH 2/9] chore: migrate to main branch (#74) --- .kokoro/build.sh | 2 +- .kokoro/test-samples-impl.sh | 2 +- CONTRIBUTING.rst | 12 ++++++------ owlbot.py | 29 +++++++++++++++++++++++++++++ 4 files changed, 37 insertions(+), 8 deletions(-) diff --git a/.kokoro/build.sh b/.kokoro/build.sh index 04608a7..ac454ba 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -41,7 +41,7 @@ python3 -m pip install --upgrade --quiet nox python3 -m nox --version # If this is a continuous build, send the test log to the FlakyBot. -# See https://github.com/googleapis/repo-automation-bots/tree/master/packages/flakybot. +# See https://github.com/googleapis/repo-automation-bots/tree/main/packages/flakybot. if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"continuous"* ]]; then cleanup() { chmod +x $KOKORO_GFILE_DIR/linux_amd64/flakybot diff --git a/.kokoro/test-samples-impl.sh b/.kokoro/test-samples-impl.sh index 311a8d5..8a324c9 100755 --- a/.kokoro/test-samples-impl.sh +++ b/.kokoro/test-samples-impl.sh @@ -80,7 +80,7 @@ for file in samples/**/requirements.txt; do EXIT=$? # If this is a periodic build, send the test log to the FlakyBot. - # See https://github.com/googleapis/repo-automation-bots/tree/master/packages/flakybot. + # See https://github.com/googleapis/repo-automation-bots/tree/main/packages/flakybot. if [[ $KOKORO_BUILD_ARTIFACTS_SUBDIR = *"periodic"* ]]; then chmod +x $KOKORO_GFILE_DIR/linux_amd64/flakybot $KOKORO_GFILE_DIR/linux_amd64/flakybot diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index 8738a0e..ea83cf2 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -50,9 +50,9 @@ You'll have to create a development environment using a Git checkout: # Configure remotes such that you can pull changes from the googleapis/python-network-connectivity # repository into your local repository. $ git remote add upstream git@github.com:googleapis/python-network-connectivity.git - # fetch and merge changes from upstream into master + # fetch and merge changes from upstream into main $ git fetch upstream - $ git merge upstream/master + $ git merge upstream/main Now your local repo is set up such that you will push changes to your GitHub repo, from which you can submit a pull request. @@ -110,12 +110,12 @@ Coding Style variables:: export GOOGLE_CLOUD_TESTING_REMOTE="upstream" - export GOOGLE_CLOUD_TESTING_BRANCH="master" + export GOOGLE_CLOUD_TESTING_BRANCH="main" By doing this, you are specifying the location of the most up-to-date version of ``python-network-connectivity``. The the suggested remote name ``upstream`` should point to the official ``googleapis`` checkout and the - the branch should be the main branch on that remote (``master``). + the branch should be the main branch on that remote (``main``). - This repository contains configuration for the `pre-commit `__ tool, which automates checking @@ -209,7 +209,7 @@ The `description on PyPI`_ for the project comes directly from the ``README``. Due to the reStructuredText (``rst``) parser used by PyPI, relative links which will work on GitHub (e.g. ``CONTRIBUTING.rst`` instead of -``https://github.com/googleapis/python-network-connectivity/blob/master/CONTRIBUTING.rst``) +``https://github.com/googleapis/python-network-connectivity/blob/main/CONTRIBUTING.rst``) may cause problems creating links or rendering the description. .. _description on PyPI: https://pypi.org/project/google-cloud-network-connectivity @@ -234,7 +234,7 @@ We support: Supported versions can be found in our ``noxfile.py`` `config`_. -.. _config: https://github.com/googleapis/python-network-connectivity/blob/master/noxfile.py +.. _config: https://github.com/googleapis/python-network-connectivity/blob/main/noxfile.py We also explicitly decided to support Python 3 beginning with version 3.6. diff --git a/owlbot.py b/owlbot.py index 628d7cf..df0b5ac 100644 --- a/owlbot.py +++ b/owlbot.py @@ -43,3 +43,32 @@ ) s.shell.run(["nox", "-s", "blacken"], hide_output=False) + +# ---------------------------------------------------------------------------- +# Main Branch migration +# ---------------------------------------------------------------------------- + +s.replace( + "*.rst", + "master", + "main" +) + +s.replace( + "*.rst", + "google-cloud-python/blob/main", + "google-cloud-python/blob/master" +) + +s.replace( + "CONTRIBUTING.rst", + "kubernetes/community/blob/main", + "kubernetes/community/blob/master" +) + +s.replace( + ".kokoro/*", + "master", + "main" +) + From a1bf617a13bcd7ac02e3149df0498cef1740da13 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Wed, 1 Sep 2021 15:44:44 +0000 Subject: [PATCH 3/9] chore(python): group renovate prs (#75) --- .github/.OwlBot.lock.yaml | 2 +- renovate.json | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index b75186c..ef3cb34 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/repo-automation-bots/owlbot-python:latest - digest: sha256:d6761eec279244e57fe9d21f8343381a01d3632c034811a72f68b83119e58c69 + digest: sha256:1456ea2b3b523ccff5e13030acef56d1de28f21249c62aa0f196265880338fa7 diff --git a/renovate.json b/renovate.json index 9fa8816..c21036d 100644 --- a/renovate.json +++ b/renovate.json @@ -1,6 +1,7 @@ { "extends": [ "config:base", + "group:all", ":preserveSemverRanges", ":disableDependencyDashboard" ], From 68a437d4f0137abf3b78252438d5be26ed779436 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Thu, 2 Sep 2021 16:51:10 -0600 Subject: [PATCH 4/9] chore(python): rename default branch to main (#76) Source-Link: https://github.com/googleapis/synthtool/commit/5c0fa62eea9c33ebe61e582424b659eb264e1ba4 Post-Processor: gcr.io/repo-automation-bots/owlbot-python:latest@sha256:0ffe3bdd6c7159692df5f7744da74e5ef19966288a6bf76023e8e04e0c424d7d Co-authored-by: Owl Bot --- .github/.OwlBot.lock.yaml | 2 +- CONTRIBUTING.rst | 6 +++--- docs/conf.py | 10 +++++----- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index ef3cb34..c07f148 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: image: gcr.io/repo-automation-bots/owlbot-python:latest - digest: sha256:1456ea2b3b523ccff5e13030acef56d1de28f21249c62aa0f196265880338fa7 + digest: sha256:0ffe3bdd6c7159692df5f7744da74e5ef19966288a6bf76023e8e04e0c424d7d diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index ea83cf2..de8b377 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -113,9 +113,9 @@ Coding Style export GOOGLE_CLOUD_TESTING_BRANCH="main" By doing this, you are specifying the location of the most up-to-date - version of ``python-network-connectivity``. The the suggested remote name ``upstream`` - should point to the official ``googleapis`` checkout and the - the branch should be the main branch on that remote (``main``). + version of ``python-network-connectivity``. The + remote name ``upstream`` should point to the official ``googleapis`` + checkout and the branch should be the default branch on that remote (``main``). - This repository contains configuration for the `pre-commit `__ tool, which automates checking diff --git a/docs/conf.py b/docs/conf.py index e09f7b3..c4bd0bd 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -76,8 +76,8 @@ # The encoding of source files. # source_encoding = 'utf-8-sig' -# The master toctree document. -master_doc = "index" +# The root toctree document. +root_doc = "index" # General information about the project. project = "google-cloud-network-connectivity" @@ -280,7 +280,7 @@ # author, documentclass [howto, manual, or own class]). latex_documents = [ ( - master_doc, + root_doc, "google-cloud-network-connectivity.tex", "google-cloud-network-connectivity Documentation", author, @@ -315,7 +315,7 @@ # (source start file, name, description, authors, manual section). man_pages = [ ( - master_doc, + root_doc, "google-cloud-network-connectivity", "google-cloud-network-connectivity Documentation", [author], @@ -334,7 +334,7 @@ # dir menu entry, description, category) texinfo_documents = [ ( - master_doc, + root_doc, "google-cloud-network-connectivity", "google-cloud-network-connectivity Documentation", author, From 5b12f6c20f0ef561f1899d54703fd2aae3ab627f Mon Sep 17 00:00:00 2001 From: Dan Lee <71398022+dandhlee@users.noreply.github.com> Date: Tue, 7 Sep 2021 11:05:23 -0400 Subject: [PATCH 5/9] chore: revert owlbot main branch templates (#77) --- owlbot.py | 28 ---------------------------- 1 file changed, 28 deletions(-) diff --git a/owlbot.py b/owlbot.py index df0b5ac..17af778 100644 --- a/owlbot.py +++ b/owlbot.py @@ -44,31 +44,3 @@ s.shell.run(["nox", "-s", "blacken"], hide_output=False) -# ---------------------------------------------------------------------------- -# Main Branch migration -# ---------------------------------------------------------------------------- - -s.replace( - "*.rst", - "master", - "main" -) - -s.replace( - "*.rst", - "google-cloud-python/blob/main", - "google-cloud-python/blob/master" -) - -s.replace( - "CONTRIBUTING.rst", - "kubernetes/community/blob/main", - "kubernetes/community/blob/master" -) - -s.replace( - ".kokoro/*", - "master", - "main" -) - From 56e89075d6f20caa3ec9921d39af30eb9de1e737 Mon Sep 17 00:00:00 2001 From: Bu Sun Kim <8822365+busunkim96@users.noreply.github.com> Date: Tue, 7 Sep 2021 11:31:04 -0600 Subject: [PATCH 6/9] chore: reference main branch of google-cloud-python (#78) --- README.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.rst b/README.rst index 72486dc..0f5a6ea 100644 --- a/README.rst +++ b/README.rst @@ -14,7 +14,7 @@ inconsistencies, etc. - `Product Documentation`_ .. |beta| image:: https://img.shields.io/badge/support-beta-orange.svg - :target: https://github.com/googleapis/google-cloud-python/blob/master/README.rst#beta-support + :target: https://github.com/googleapis/google-cloud-python/blob/main/README.rst#beta-support .. |pypi| image:: https://img.shields.io/pypi/v/google-cloud-network-connectivity.svg :target: https://pypi.org/project/google-cloud-network-connectivity/ .. |versions| image:: https://img.shields.io/pypi/pyversions/google-cloud-network-connectivity.svg @@ -84,4 +84,4 @@ Next Steps APIs that we cover. .. _Network Connectivity Center Product documentation: https://cloud.google.com/network-connectivity/docs -.. _README: https://github.com/googleapis/google-cloud-python/blob/master/README.rst +.. _README: https://github.com/googleapis/google-cloud-python/blob/main/README.rst From 213baa50b2956df64bf03b226e4baa46738dcfd7 Mon Sep 17 00:00:00 2001 From: Jeffrey Rennie Date: Tue, 21 Sep 2021 12:40:22 -0700 Subject: [PATCH 7/9] chore: relocate owl bot post processor (#80) chore: relocate owl bot post processor --- .github/.OwlBot.lock.yaml | 4 ++-- .github/.OwlBot.yaml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index c07f148..2567653 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -1,3 +1,3 @@ docker: - image: gcr.io/repo-automation-bots/owlbot-python:latest - digest: sha256:0ffe3bdd6c7159692df5f7744da74e5ef19966288a6bf76023e8e04e0c424d7d + image: gcr.io/cloud-devrel-public-resources/owlbot-python:latest + digest: sha256:87eee22d276554e4e52863ec9b1cb6a7245815dfae20439712bf644348215a5a diff --git a/.github/.OwlBot.yaml b/.github/.OwlBot.yaml index 5a63f4f..e30cae8 100644 --- a/.github/.OwlBot.yaml +++ b/.github/.OwlBot.yaml @@ -13,7 +13,7 @@ # limitations under the License. docker: - image: gcr.io/repo-automation-bots/owlbot-python:latest + image: gcr.io/cloud-devrel-public-resources/owlbot-python:latest deep-remove-regex: - /owl-bot-staging From ae7ade17d232d016130b386e30812ab7c320f046 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Fri, 24 Sep 2021 15:12:47 +0000 Subject: [PATCH 8/9] chore: use gapic-generator-python 0.51.2 (#81) - [ ] Regenerate this pull request now. fix: add 'dict' annotation type to 'request' Committer: @busunkim96 PiperOrigin-RevId: 398509016 Source-Link: https://github.com/googleapis/googleapis/commit/b224dfa52642a733ea64849d4e06d15c274bc08f Source-Link: https://github.com/googleapis/googleapis-gen/commit/63a1db7a38d74b9639592f521ed1daaf7299ad9a Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNjNhMWRiN2EzOGQ3NGI5NjM5NTkyZjUyMWVkMWRhYWY3Mjk5YWQ5YSJ9 --- .../services/hub_service/client.py | 42 +++++++++---------- .../services/hub_service/transports/base.py | 2 +- .../services/hub_service/transports/grpc.py | 6 +-- .../hub_service/transports/grpc_asyncio.py | 6 +-- .../services/hub_service/client.py | 42 +++++++++---------- .../services/hub_service/transports/base.py | 2 +- .../services/hub_service/transports/grpc.py | 6 +-- .../hub_service/transports/grpc_asyncio.py | 6 +-- .../fixup_networkconnectivity_v1_keywords.py | 22 +++++----- ...p_networkconnectivity_v1alpha1_keywords.py | 22 +++++----- 10 files changed, 78 insertions(+), 78 deletions(-) diff --git a/google/cloud/networkconnectivity_v1/services/hub_service/client.py b/google/cloud/networkconnectivity_v1/services/hub_service/client.py index 6a7f264..3f78354 100644 --- a/google/cloud/networkconnectivity_v1/services/hub_service/client.py +++ b/google/cloud/networkconnectivity_v1/services/hub_service/client.py @@ -17,7 +17,7 @@ from distutils import util import os import re -from typing import Callable, Dict, Optional, Sequence, Tuple, Type, Union +from typing import Dict, Optional, Sequence, Tuple, Type, Union import pkg_resources from google.api_core import client_options as client_options_lib # type: ignore @@ -441,7 +441,7 @@ def __init__( def list_hubs( self, - request: hub.ListHubsRequest = None, + request: Union[hub.ListHubsRequest, dict] = None, *, parent: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -451,7 +451,7 @@ def list_hubs( r"""Lists hubs in a given project. Args: - request (google.cloud.networkconnectivity_v1.types.ListHubsRequest): + request (Union[google.cloud.networkconnectivity_v1.types.ListHubsRequest, dict]): The request object. Request for [HubService.ListHubs][google.cloud.networkconnectivity.v1.HubService.ListHubs] method. @@ -521,7 +521,7 @@ def list_hubs( def get_hub( self, - request: hub.GetHubRequest = None, + request: Union[hub.GetHubRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -531,7 +531,7 @@ def get_hub( r"""Gets details about the specified hub. Args: - request (google.cloud.networkconnectivity_v1.types.GetHubRequest): + request (Union[google.cloud.networkconnectivity_v1.types.GetHubRequest, dict]): The request object. Request for [HubService.GetHub][google.cloud.networkconnectivity.v1.HubService.GetHub] method. @@ -597,7 +597,7 @@ def get_hub( def create_hub( self, - request: gcn_hub.CreateHubRequest = None, + request: Union[gcn_hub.CreateHubRequest, dict] = None, *, parent: str = None, hub: gcn_hub.Hub = None, @@ -609,7 +609,7 @@ def create_hub( r"""Creates a new hub in the specified project. Args: - request (google.cloud.networkconnectivity_v1.types.CreateHubRequest): + request (Union[google.cloud.networkconnectivity_v1.types.CreateHubRequest, dict]): The request object. Request for [HubService.CreateHub][google.cloud.networkconnectivity.v1.HubService.CreateHub] method. @@ -699,7 +699,7 @@ def create_hub( def update_hub( self, - request: gcn_hub.UpdateHubRequest = None, + request: Union[gcn_hub.UpdateHubRequest, dict] = None, *, hub: gcn_hub.Hub = None, update_mask: field_mask_pb2.FieldMask = None, @@ -711,7 +711,7 @@ def update_hub( specified hub. Args: - request (google.cloud.networkconnectivity_v1.types.UpdateHubRequest): + request (Union[google.cloud.networkconnectivity_v1.types.UpdateHubRequest, dict]): The request object. Request for [HubService.UpdateHub][google.cloud.networkconnectivity.v1.HubService.UpdateHub] method. @@ -798,7 +798,7 @@ def update_hub( def delete_hub( self, - request: hub.DeleteHubRequest = None, + request: Union[hub.DeleteHubRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -808,7 +808,7 @@ def delete_hub( r"""Deletes the specified hub. Args: - request (google.cloud.networkconnectivity_v1.types.DeleteHubRequest): + request (Union[google.cloud.networkconnectivity_v1.types.DeleteHubRequest, dict]): The request object. The request for [HubService.DeleteHub][google.cloud.networkconnectivity.v1.HubService.DeleteHub]. name (str): @@ -890,7 +890,7 @@ def delete_hub( def list_spokes( self, - request: hub.ListSpokesRequest = None, + request: Union[hub.ListSpokesRequest, dict] = None, *, parent: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -901,7 +901,7 @@ def list_spokes( location. Args: - request (google.cloud.networkconnectivity_v1.types.ListSpokesRequest): + request (Union[google.cloud.networkconnectivity_v1.types.ListSpokesRequest, dict]): The request object. The request for [HubService.ListSpokes][google.cloud.networkconnectivity.v1.HubService.ListSpokes]. parent (str): @@ -969,7 +969,7 @@ def list_spokes( def get_spoke( self, - request: hub.GetSpokeRequest = None, + request: Union[hub.GetSpokeRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -979,7 +979,7 @@ def get_spoke( r"""Gets details about the specified spoke. Args: - request (google.cloud.networkconnectivity_v1.types.GetSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1.types.GetSpokeRequest, dict]): The request object. The request for [HubService.GetSpoke][google.cloud.networkconnectivity.v1.HubService.GetSpoke]. name (str): @@ -1048,7 +1048,7 @@ def get_spoke( def create_spoke( self, - request: hub.CreateSpokeRequest = None, + request: Union[hub.CreateSpokeRequest, dict] = None, *, parent: str = None, spoke: hub.Spoke = None, @@ -1061,7 +1061,7 @@ def create_spoke( location. Args: - request (google.cloud.networkconnectivity_v1.types.CreateSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1.types.CreateSpokeRequest, dict]): The request object. The request for [HubService.CreateSpoke][google.cloud.networkconnectivity.v1.HubService.CreateSpoke]. parent (str): @@ -1156,7 +1156,7 @@ def create_spoke( def update_spoke( self, - request: hub.UpdateSpokeRequest = None, + request: Union[hub.UpdateSpokeRequest, dict] = None, *, spoke: hub.Spoke = None, update_mask: field_mask_pb2.FieldMask = None, @@ -1167,7 +1167,7 @@ def update_spoke( r"""Updates the parameters of the specified spoke. Args: - request (google.cloud.networkconnectivity_v1.types.UpdateSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1.types.UpdateSpokeRequest, dict]): The request object. Request for [HubService.UpdateSpoke][google.cloud.networkconnectivity.v1.HubService.UpdateSpoke] method. @@ -1262,7 +1262,7 @@ def update_spoke( def delete_spoke( self, - request: hub.DeleteSpokeRequest = None, + request: Union[hub.DeleteSpokeRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -1272,7 +1272,7 @@ def delete_spoke( r"""Deletes the specified spoke. Args: - request (google.cloud.networkconnectivity_v1.types.DeleteSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1.types.DeleteSpokeRequest, dict]): The request object. The request for [HubService.DeleteSpoke][google.cloud.networkconnectivity.v1.HubService.DeleteSpoke]. name (str): diff --git a/google/cloud/networkconnectivity_v1/services/hub_service/transports/base.py b/google/cloud/networkconnectivity_v1/services/hub_service/transports/base.py index 47d8b5a..7ace5df 100644 --- a/google/cloud/networkconnectivity_v1/services/hub_service/transports/base.py +++ b/google/cloud/networkconnectivity_v1/services/hub_service/transports/base.py @@ -120,7 +120,7 @@ def __init__( **scopes_kwargs, quota_project_id=quota_project_id ) - # If the credentials is service account credentials, then always try to use self signed JWT. + # If the credentials are service account credentials, then always try to use self signed JWT. if ( always_use_jwt_access and isinstance(credentials, service_account.Credentials) diff --git a/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc.py b/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc.py index 6f44d71..5e90888 100644 --- a/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc.py +++ b/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc.py @@ -86,16 +86,16 @@ def __init__( api_mtls_endpoint (Optional[str]): Deprecated. The mutual TLS endpoint. If provided, it overrides the ``host`` argument and tries to create a mutual TLS channel with client SSL credentials from - ``client_cert_source`` or applicatin default SSL credentials. + ``client_cert_source`` or application default SSL credentials. client_cert_source (Optional[Callable[[], Tuple[bytes, bytes]]]): Deprecated. A callback to provide client SSL certificate bytes and private key bytes, both in PEM format. It is ignored if ``api_mtls_endpoint`` is None. ssl_channel_credentials (grpc.ChannelCredentials): SSL credentials - for grpc channel. It is ignored if ``channel`` is provided. + for the grpc channel. It is ignored if ``channel`` is provided. client_cert_source_for_mtls (Optional[Callable[[], Tuple[bytes, bytes]]]): A callback to provide client certificate bytes and private key bytes, - both in PEM format. It is used to configure mutual TLS channel. It is + both in PEM format. It is used to configure a mutual TLS channel. It is ignored if ``channel`` or ``ssl_channel_credentials`` is provided. quota_project_id (Optional[str]): An optional project to use for billing and quota. diff --git a/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc_asyncio.py b/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc_asyncio.py index 52846b5..fda2cc0 100644 --- a/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc_asyncio.py +++ b/google/cloud/networkconnectivity_v1/services/hub_service/transports/grpc_asyncio.py @@ -133,16 +133,16 @@ def __init__( api_mtls_endpoint (Optional[str]): Deprecated. The mutual TLS endpoint. If provided, it overrides the ``host`` argument and tries to create a mutual TLS channel with client SSL credentials from - ``client_cert_source`` or applicatin default SSL credentials. + ``client_cert_source`` or application default SSL credentials. client_cert_source (Optional[Callable[[], Tuple[bytes, bytes]]]): Deprecated. A callback to provide client SSL certificate bytes and private key bytes, both in PEM format. It is ignored if ``api_mtls_endpoint`` is None. ssl_channel_credentials (grpc.ChannelCredentials): SSL credentials - for grpc channel. It is ignored if ``channel`` is provided. + for the grpc channel. It is ignored if ``channel`` is provided. client_cert_source_for_mtls (Optional[Callable[[], Tuple[bytes, bytes]]]): A callback to provide client certificate bytes and private key bytes, - both in PEM format. It is used to configure mutual TLS channel. It is + both in PEM format. It is used to configure a mutual TLS channel. It is ignored if ``channel`` or ``ssl_channel_credentials`` is provided. quota_project_id (Optional[str]): An optional project to use for billing and quota. diff --git a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/client.py b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/client.py index fd190a6..22264b6 100644 --- a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/client.py +++ b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/client.py @@ -17,7 +17,7 @@ from distutils import util import os import re -from typing import Callable, Dict, Optional, Sequence, Tuple, Type, Union +from typing import Dict, Optional, Sequence, Tuple, Type, Union import pkg_resources from google.api_core import client_options as client_options_lib # type: ignore @@ -426,7 +426,7 @@ def __init__( def list_hubs( self, - request: hub.ListHubsRequest = None, + request: Union[hub.ListHubsRequest, dict] = None, *, parent: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -436,7 +436,7 @@ def list_hubs( r"""Lists Hubs in a given project and location. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.ListHubsRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.ListHubsRequest, dict]): The request object. Request for [HubService.ListHubs][google.cloud.networkconnectivity.v1alpha1.HubService.ListHubs] method. @@ -506,7 +506,7 @@ def list_hubs( def get_hub( self, - request: hub.GetHubRequest = None, + request: Union[hub.GetHubRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -516,7 +516,7 @@ def get_hub( r"""Gets details of a single Hub. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.GetHubRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.GetHubRequest, dict]): The request object. Request for [HubService.GetHub][google.cloud.networkconnectivity.v1alpha1.HubService.GetHub] method. @@ -583,7 +583,7 @@ def get_hub( def create_hub( self, - request: gcn_hub.CreateHubRequest = None, + request: Union[gcn_hub.CreateHubRequest, dict] = None, *, parent: str = None, hub: gcn_hub.Hub = None, @@ -595,7 +595,7 @@ def create_hub( r"""Creates a new Hub in a given project and location. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.CreateHubRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.CreateHubRequest, dict]): The request object. Request for [HubService.CreateHub][google.cloud.networkconnectivity.v1alpha1.HubService.CreateHub] method. @@ -688,7 +688,7 @@ def create_hub( def update_hub( self, - request: gcn_hub.UpdateHubRequest = None, + request: Union[gcn_hub.UpdateHubRequest, dict] = None, *, hub: gcn_hub.Hub = None, update_mask: field_mask_pb2.FieldMask = None, @@ -699,7 +699,7 @@ def update_hub( r"""Updates the parameters of a single Hub. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.UpdateHubRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.UpdateHubRequest, dict]): The request object. Request for [HubService.UpdateHub][google.cloud.networkconnectivity.v1alpha1.HubService.UpdateHub] method. @@ -787,7 +787,7 @@ def update_hub( def delete_hub( self, - request: hub.DeleteHubRequest = None, + request: Union[hub.DeleteHubRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -797,7 +797,7 @@ def delete_hub( r"""Deletes a single Hub. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.DeleteHubRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.DeleteHubRequest, dict]): The request object. The request for [HubService.DeleteHub][google.cloud.networkconnectivity.v1alpha1.HubService.DeleteHub]. name (str): @@ -879,7 +879,7 @@ def delete_hub( def list_spokes( self, - request: hub.ListSpokesRequest = None, + request: Union[hub.ListSpokesRequest, dict] = None, *, parent: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -889,7 +889,7 @@ def list_spokes( r"""Lists Spokes in a given project and location. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.ListSpokesRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.ListSpokesRequest, dict]): The request object. The request for [HubService.ListSpokes][google.cloud.networkconnectivity.v1alpha1.HubService.ListSpokes]. parent (str): @@ -957,7 +957,7 @@ def list_spokes( def get_spoke( self, - request: hub.GetSpokeRequest = None, + request: Union[hub.GetSpokeRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -967,7 +967,7 @@ def get_spoke( r"""Gets details of a single Spoke. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.GetSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.GetSpokeRequest, dict]): The request object. The request for [HubService.GetSpoke][google.cloud.networkconnectivity.v1alpha1.HubService.GetSpoke]. name (str): @@ -1029,7 +1029,7 @@ def get_spoke( def create_spoke( self, - request: hub.CreateSpokeRequest = None, + request: Union[hub.CreateSpokeRequest, dict] = None, *, parent: str = None, spoke: hub.Spoke = None, @@ -1041,7 +1041,7 @@ def create_spoke( r"""Creates a new Spoke in a given project and location. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.CreateSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.CreateSpokeRequest, dict]): The request object. The request for [HubService.CreateSpoke][google.cloud.networkconnectivity.v1alpha1.HubService.CreateSpoke]. parent (str): @@ -1132,7 +1132,7 @@ def create_spoke( def update_spoke( self, - request: hub.UpdateSpokeRequest = None, + request: Union[hub.UpdateSpokeRequest, dict] = None, *, spoke: hub.Spoke = None, update_mask: field_mask_pb2.FieldMask = None, @@ -1143,7 +1143,7 @@ def update_spoke( r"""Updates the parameters of a single Spoke. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.UpdateSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.UpdateSpokeRequest, dict]): The request object. Request for [HubService.UpdateSpoke][google.cloud.networkconnectivity.v1alpha1.HubService.UpdateSpoke] method. @@ -1232,7 +1232,7 @@ def update_spoke( def delete_spoke( self, - request: hub.DeleteSpokeRequest = None, + request: Union[hub.DeleteSpokeRequest, dict] = None, *, name: str = None, retry: retries.Retry = gapic_v1.method.DEFAULT, @@ -1242,7 +1242,7 @@ def delete_spoke( r"""Deletes a single Spoke. Args: - request (google.cloud.networkconnectivity_v1alpha1.types.DeleteSpokeRequest): + request (Union[google.cloud.networkconnectivity_v1alpha1.types.DeleteSpokeRequest, dict]): The request object. The request for [HubService.DeleteSpoke][google.cloud.networkconnectivity.v1alpha1.HubService.DeleteSpoke]. name (str): diff --git a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/base.py b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/base.py index 8eb27eb..aa448a8 100644 --- a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/base.py +++ b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/base.py @@ -120,7 +120,7 @@ def __init__( **scopes_kwargs, quota_project_id=quota_project_id ) - # If the credentials is service account credentials, then always try to use self signed JWT. + # If the credentials are service account credentials, then always try to use self signed JWT. if ( always_use_jwt_access and isinstance(credentials, service_account.Credentials) diff --git a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc.py b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc.py index a2472f3..2c1ca98 100644 --- a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc.py +++ b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc.py @@ -86,16 +86,16 @@ def __init__( api_mtls_endpoint (Optional[str]): Deprecated. The mutual TLS endpoint. If provided, it overrides the ``host`` argument and tries to create a mutual TLS channel with client SSL credentials from - ``client_cert_source`` or applicatin default SSL credentials. + ``client_cert_source`` or application default SSL credentials. client_cert_source (Optional[Callable[[], Tuple[bytes, bytes]]]): Deprecated. A callback to provide client SSL certificate bytes and private key bytes, both in PEM format. It is ignored if ``api_mtls_endpoint`` is None. ssl_channel_credentials (grpc.ChannelCredentials): SSL credentials - for grpc channel. It is ignored if ``channel`` is provided. + for the grpc channel. It is ignored if ``channel`` is provided. client_cert_source_for_mtls (Optional[Callable[[], Tuple[bytes, bytes]]]): A callback to provide client certificate bytes and private key bytes, - both in PEM format. It is used to configure mutual TLS channel. It is + both in PEM format. It is used to configure a mutual TLS channel. It is ignored if ``channel`` or ``ssl_channel_credentials`` is provided. quota_project_id (Optional[str]): An optional project to use for billing and quota. diff --git a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc_asyncio.py b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc_asyncio.py index 6442757..cc7602a 100644 --- a/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc_asyncio.py +++ b/google/cloud/networkconnectivity_v1alpha1/services/hub_service/transports/grpc_asyncio.py @@ -133,16 +133,16 @@ def __init__( api_mtls_endpoint (Optional[str]): Deprecated. The mutual TLS endpoint. If provided, it overrides the ``host`` argument and tries to create a mutual TLS channel with client SSL credentials from - ``client_cert_source`` or applicatin default SSL credentials. + ``client_cert_source`` or application default SSL credentials. client_cert_source (Optional[Callable[[], Tuple[bytes, bytes]]]): Deprecated. A callback to provide client SSL certificate bytes and private key bytes, both in PEM format. It is ignored if ``api_mtls_endpoint`` is None. ssl_channel_credentials (grpc.ChannelCredentials): SSL credentials - for grpc channel. It is ignored if ``channel`` is provided. + for the grpc channel. It is ignored if ``channel`` is provided. client_cert_source_for_mtls (Optional[Callable[[], Tuple[bytes, bytes]]]): A callback to provide client certificate bytes and private key bytes, - both in PEM format. It is used to configure mutual TLS channel. It is + both in PEM format. It is used to configure a mutual TLS channel. It is ignored if ``channel`` or ``ssl_channel_credentials`` is provided. quota_project_id (Optional[str]): An optional project to use for billing and quota. diff --git a/scripts/fixup_networkconnectivity_v1_keywords.py b/scripts/fixup_networkconnectivity_v1_keywords.py index 2c61070..067b307 100644 --- a/scripts/fixup_networkconnectivity_v1_keywords.py +++ b/scripts/fixup_networkconnectivity_v1_keywords.py @@ -39,16 +39,16 @@ def partition( class networkconnectivityCallTransformer(cst.CSTTransformer): CTRL_PARAMS: Tuple[str] = ('retry', 'timeout', 'metadata') METHOD_TO_PARAMS: Dict[str, Tuple[str]] = { - 'create_hub': ('parent', 'hub', 'hub_id', 'request_id', ), - 'create_spoke': ('parent', 'spoke', 'spoke_id', 'request_id', ), - 'delete_hub': ('name', 'request_id', ), - 'delete_spoke': ('name', 'request_id', ), - 'get_hub': ('name', ), - 'get_spoke': ('name', ), - 'list_hubs': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), - 'list_spokes': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), - 'update_hub': ('hub', 'update_mask', 'request_id', ), - 'update_spoke': ('spoke', 'update_mask', 'request_id', ), + 'create_hub': ('parent', 'hub', 'hub_id', 'request_id', ), + 'create_spoke': ('parent', 'spoke', 'spoke_id', 'request_id', ), + 'delete_hub': ('name', 'request_id', ), + 'delete_spoke': ('name', 'request_id', ), + 'get_hub': ('name', ), + 'get_spoke': ('name', ), + 'list_hubs': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), + 'list_spokes': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), + 'update_hub': ('hub', 'update_mask', 'request_id', ), + 'update_spoke': ('spoke', 'update_mask', 'request_id', ), } def leave_Call(self, original: cst.Call, updated: cst.Call) -> cst.CSTNode: @@ -67,7 +67,7 @@ def leave_Call(self, original: cst.Call, updated: cst.Call) -> cst.CSTNode: return updated kwargs, ctrl_kwargs = partition( - lambda a: not a.keyword.value in self.CTRL_PARAMS, + lambda a: a.keyword.value not in self.CTRL_PARAMS, kwargs ) diff --git a/scripts/fixup_networkconnectivity_v1alpha1_keywords.py b/scripts/fixup_networkconnectivity_v1alpha1_keywords.py index 2c61070..067b307 100644 --- a/scripts/fixup_networkconnectivity_v1alpha1_keywords.py +++ b/scripts/fixup_networkconnectivity_v1alpha1_keywords.py @@ -39,16 +39,16 @@ def partition( class networkconnectivityCallTransformer(cst.CSTTransformer): CTRL_PARAMS: Tuple[str] = ('retry', 'timeout', 'metadata') METHOD_TO_PARAMS: Dict[str, Tuple[str]] = { - 'create_hub': ('parent', 'hub', 'hub_id', 'request_id', ), - 'create_spoke': ('parent', 'spoke', 'spoke_id', 'request_id', ), - 'delete_hub': ('name', 'request_id', ), - 'delete_spoke': ('name', 'request_id', ), - 'get_hub': ('name', ), - 'get_spoke': ('name', ), - 'list_hubs': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), - 'list_spokes': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), - 'update_hub': ('hub', 'update_mask', 'request_id', ), - 'update_spoke': ('spoke', 'update_mask', 'request_id', ), + 'create_hub': ('parent', 'hub', 'hub_id', 'request_id', ), + 'create_spoke': ('parent', 'spoke', 'spoke_id', 'request_id', ), + 'delete_hub': ('name', 'request_id', ), + 'delete_spoke': ('name', 'request_id', ), + 'get_hub': ('name', ), + 'get_spoke': ('name', ), + 'list_hubs': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), + 'list_spokes': ('parent', 'page_size', 'page_token', 'filter', 'order_by', ), + 'update_hub': ('hub', 'update_mask', 'request_id', ), + 'update_spoke': ('spoke', 'update_mask', 'request_id', ), } def leave_Call(self, original: cst.Call, updated: cst.Call) -> cst.CSTNode: @@ -67,7 +67,7 @@ def leave_Call(self, original: cst.Call, updated: cst.Call) -> cst.CSTNode: return updated kwargs, ctrl_kwargs = partition( - lambda a: not a.keyword.value in self.CTRL_PARAMS, + lambda a: a.keyword.value not in self.CTRL_PARAMS, kwargs ) From 463c5f8d2d38edf3f7a3dad49d6ae14fc3fea2f2 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Mon, 27 Sep 2021 15:28:15 +0000 Subject: [PATCH 9/9] chore: release 0.6.1 (#82) :robot: I have created a release \*beep\* \*boop\* --- ### [0.6.1](https://www.github.com/googleapis/python-network-connectivity/compare/v0.6.0...v0.6.1) (2021-09-24) ### Bug Fixes * add 'dict' annotation type to 'request' ([ae7ade1](https://www.github.com/googleapis/python-network-connectivity/commit/ae7ade17d232d016130b386e30812ab7c320f046)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- CHANGELOG.md | 7 +++++++ setup.py | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 36ee128..f82047f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +### [0.6.1](https://www.github.com/googleapis/python-network-connectivity/compare/v0.6.0...v0.6.1) (2021-09-24) + + +### Bug Fixes + +* add 'dict' annotation type to 'request' ([ae7ade1](https://www.github.com/googleapis/python-network-connectivity/commit/ae7ade17d232d016130b386e30812ab7c320f046)) + ## [0.6.0](https://www.github.com/googleapis/python-network-connectivity/compare/v0.5.0...v0.6.0) (2021-08-25) diff --git a/setup.py b/setup.py index 9fc4f71..3402bfb 100644 --- a/setup.py +++ b/setup.py @@ -19,7 +19,7 @@ import os import setuptools # type: ignore -version = "0.6.0" +version = "0.6.1" package_root = os.path.abspath(os.path.dirname(__file__))