From 92882675cc4e9e0ae19af2b25dfdf058235f97e7 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Fri, 20 Jan 2023 10:42:58 -0500 Subject: [PATCH 1/2] docs: Add documentation for enums (#196) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * docs: Add documentation for enums fix: Add context manager return types chore: Update gapic-generator-python to v1.8.1 PiperOrigin-RevId: 503210727 Source-Link: https://github.com/googleapis/googleapis/commit/a391fd1dac18dfdfa00c18c8404f2c3a6ff8e98e Source-Link: https://github.com/googleapis/googleapis-gen/commit/0080f830dec37c3384157082bce279e37079ea58 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMDA4MGY4MzBkZWMzN2MzMzg0MTU3MDgyYmNlMjc5ZTM3MDc5ZWE1OCJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot --- .../services/api_gateway_service/client.py | 2 +- .../cloud/apigateway_v1/types/apigateway.py | 64 ++++++++++++++++++- ...t_metadata_google.cloud.apigateway.v1.json | 2 +- 3 files changed, 63 insertions(+), 5 deletions(-) diff --git a/google/cloud/apigateway_v1/services/api_gateway_service/client.py b/google/cloud/apigateway_v1/services/api_gateway_service/client.py index eb42047..bbc0c58 100644 --- a/google/cloud/apigateway_v1/services/api_gateway_service/client.py +++ b/google/cloud/apigateway_v1/services/api_gateway_service/client.py @@ -2379,7 +2379,7 @@ def sample_delete_api_config(): # Done; return the response. return response - def __enter__(self): + def __enter__(self) -> "ApiGatewayServiceClient": return self def __exit__(self, type, value, traceback): diff --git a/google/cloud/apigateway_v1/types/apigateway.py b/google/cloud/apigateway_v1/types/apigateway.py index 2a22f87..e2c3ddb 100644 --- a/google/cloud/apigateway_v1/types/apigateway.py +++ b/google/cloud/apigateway_v1/types/apigateway.py @@ -79,7 +79,22 @@ class Api(proto.Message): """ class State(proto.Enum): - r"""All the possible API states.""" + r"""All the possible API states. + + Values: + STATE_UNSPECIFIED (0): + API does not have a state yet. + CREATING (1): + API is being created. + ACTIVE (2): + API is active. + FAILED (3): + API creation failed. + DELETING (4): + API is being deleted. + UPDATING (5): + API is being updated. + """ STATE_UNSPECIFIED = 0 CREATING = 1 ACTIVE = 2 @@ -179,7 +194,27 @@ class ApiConfig(proto.Message): """ class State(proto.Enum): - r"""All the possible API Config states.""" + r"""All the possible API Config states. + + Values: + STATE_UNSPECIFIED (0): + API Config does not have a state yet. + CREATING (1): + API Config is being created and deployed to + the API Controller. + ACTIVE (2): + API Config is ready for use by Gateways. + FAILED (3): + API Config creation failed. + DELETING (4): + API Config is being deleted. + UPDATING (5): + API Config is being updated. + ACTIVATING (6): + API Config settings are being activated in + downstream systems. API Configs in this state + cannot be used by Gateways. + """ STATE_UNSPECIFIED = 0 CREATING = 1 ACTIVE = 2 @@ -341,7 +376,22 @@ class Gateway(proto.Message): """ class State(proto.Enum): - r"""All the possible Gateway states.""" + r"""All the possible Gateway states. + + Values: + STATE_UNSPECIFIED (0): + Gateway does not have a state yet. + CREATING (1): + Gateway is being created. + ACTIVE (2): + Gateway is running and ready for requests. + FAILED (3): + Gateway creation failed. + DELETING (4): + Gateway is being deleted. + UPDATING (5): + Gateway is being updated. + """ STATE_UNSPECIFIED = 0 CREATING = 1 ACTIVE = 2 @@ -786,6 +836,14 @@ class GetApiConfigRequest(proto.Message): class ConfigView(proto.Enum): r"""Enum to control which fields should be included in the response. + + Values: + CONFIG_VIEW_UNSPECIFIED (0): + + BASIC (1): + Do not include configuration source files. + FULL (2): + Include configuration source files. """ CONFIG_VIEW_UNSPECIFIED = 0 BASIC = 1 diff --git a/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json b/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json index 3ee3e66..fdf9818 100644 --- a/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json +++ b/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-api-gateway", - "version": "1.6.0" + "version": "0.1.0" }, "snippets": [ { From 57e4bc0e4d58cfb5c3fe4a9392af00fe9db312a4 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Mon, 23 Jan 2023 10:36:10 -0500 Subject: [PATCH 2/2] chore(main): release 1.6.1 (#197) Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com> --- .release-please-manifest.json | 2 +- CHANGELOG.md | 12 ++++++++++++ google/cloud/apigateway/gapic_version.py | 2 +- google/cloud/apigateway_v1/gapic_version.py | 2 +- .../snippet_metadata_google.cloud.apigateway.v1.json | 2 +- 5 files changed, 16 insertions(+), 4 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 0d1bebe..093be7e 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "1.6.0" + ".": "1.6.1" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 7c4efd4..ec36a67 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,17 @@ # Changelog +## [1.6.1](https://github.com/googleapis/python-api-gateway/compare/v1.6.0...v1.6.1) (2023-01-20) + + +### Bug Fixes + +* Add context manager return types ([9288267](https://github.com/googleapis/python-api-gateway/commit/92882675cc4e9e0ae19af2b25dfdf058235f97e7)) + + +### Documentation + +* Add documentation for enums ([9288267](https://github.com/googleapis/python-api-gateway/commit/92882675cc4e9e0ae19af2b25dfdf058235f97e7)) + ## [1.6.0](https://github.com/googleapis/python-api-gateway/compare/v1.5.1...v1.6.0) (2023-01-10) diff --git a/google/cloud/apigateway/gapic_version.py b/google/cloud/apigateway/gapic_version.py index a016bdf..b4028ab 100644 --- a/google/cloud/apigateway/gapic_version.py +++ b/google/cloud/apigateway/gapic_version.py @@ -13,4 +13,4 @@ # See the License for the specific language governing permissions and # limitations under the License. # -__version__ = "1.6.0" # {x-release-please-version} +__version__ = "1.6.1" # {x-release-please-version} diff --git a/google/cloud/apigateway_v1/gapic_version.py b/google/cloud/apigateway_v1/gapic_version.py index a016bdf..b4028ab 100644 --- a/google/cloud/apigateway_v1/gapic_version.py +++ b/google/cloud/apigateway_v1/gapic_version.py @@ -13,4 +13,4 @@ # See the License for the specific language governing permissions and # limitations under the License. # -__version__ = "1.6.0" # {x-release-please-version} +__version__ = "1.6.1" # {x-release-please-version} diff --git a/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json b/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json index fdf9818..96bf4e4 100644 --- a/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json +++ b/samples/generated_samples/snippet_metadata_google.cloud.apigateway.v1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-api-gateway", - "version": "0.1.0" + "version": "1.6.1" }, "snippets": [ {