Skip to content
This repository was archived by the owner on Dec 31, 2023. It is now read-only.

chore: Update gapic-generator-python to v1.6.1 #340

Merged
merged 21 commits into from
Nov 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
85585ed
chore: update to gapic-generator-python 1.5.0
gcf-owl-bot[bot] Oct 29, 2022
e3649a3
🦉 Updates from OwlBot post-processor
gcf-owl-bot[bot] Oct 29, 2022
fb32714
update version in gapic_version.py
parthea Nov 5, 2022
50ecceb
add .release-please-manifest.json with correct version
parthea Nov 5, 2022
a160e6f
set manifest to true in .github/release-please.yml
parthea Nov 7, 2022
07d4b31
add release-please-config.json
parthea Nov 7, 2022
f1f61ad
🦉 Updates from OwlBot post-processor
gcf-owl-bot[bot] Nov 7, 2022
5f4705e
chore: Update to gapic-generator-python 1.6.0
gcf-owl-bot[bot] Nov 9, 2022
a62ecb1
🦉 Updates from OwlBot post-processor
gcf-owl-bot[bot] Nov 9, 2022
8d39a09
feat: new APIs added to reflect updates to the filestore service
gcf-owl-bot[bot] Nov 10, 2022
9399d2f
🦉 Updates from OwlBot post-processor
gcf-owl-bot[bot] Nov 10, 2022
c7fcaa6
update path to snippet metadata json
parthea Nov 12, 2022
09e9854
chore: Update gapic-generator-python to v1.6.1
gcf-owl-bot[bot] Nov 12, 2022
a5aaae6
🦉 Updates from OwlBot post-processor
gcf-owl-bot[bot] Nov 12, 2022
3043253
Merge branch 'main' into owl-bot-copy
parthea Nov 21, 2022
a1db532
use templated owlbot.py and setup.py
parthea Nov 21, 2022
34dc473
Merge branch 'main' into owl-bot-copy
parthea Nov 21, 2022
6f41a74
exclude generated constraints file
parthea Nov 21, 2022
2ee8ac5
exclude autogenerated setup.py
parthea Nov 21, 2022
8190b0b
update replacements in owlbot.py
parthea Nov 22, 2022
a3c5a4f
run nox format session
parthea Nov 22, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/release-please.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
releaseType: python
handleGHRelease: true
manifest: true
# NOTE: this section is generated by synthtool.languages.python
# See https://github.com/googleapis/synthtool/blob/master/synthtool/languages/python.py
branches:
Expand Down
3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "2.9.3"
}
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys
import os
import shlex
import sys

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
Expand Down
1 change: 0 additions & 1 deletion docs/containeranalysis_v1/types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,4 @@ Types for Google Cloud Devtools Containeranalysis v1 API

.. automodule:: google.cloud.devtools.containeranalysis_v1.types
:members:
:undoc-members:
:show-inheritance:
20 changes: 11 additions & 9 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

.. include:: multiprocessing.rst

Api Reference

API Reference
-------------
.. toctree::
:maxdepth: 2
Expand All @@ -11,22 +12,23 @@ Api Reference
containeranalysis_v1/types


Changelog
----------
Migration Guide
---------------

For all previous ``google-cloud-containeranalysis`` releases:
See the guide below for instructions on migrating to the latest version.

.. toctree::
:maxdepth: 2

changelog
 UPGRADING

Migration Guide
---------------

See the guide below for instructions on migrating to the 2.x release of this library.
Changelog
---------

For a list of all ``google-cloud-containeranalysis`` releases:

.. toctree::
:maxdepth: 2

UPGRADING
changelog
13 changes: 7 additions & 6 deletions google/cloud/devtools/containeranalysis/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,19 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
from google.cloud.devtools.containeranalysis import gapic_version as package_version

__version__ = package_version.__version__


from google.cloud.devtools.containeranalysis_v1.services.container_analysis.client import (
ContainerAnalysisClient,
)
from google.cloud.devtools.containeranalysis_v1.services.container_analysis.async_client import (
ContainerAnalysisAsyncClient,
)

from google.cloud.devtools.containeranalysis_v1.types.containeranalysis import (
GetVulnerabilityOccurrencesSummaryRequest,
from google.cloud.devtools.containeranalysis_v1.services.container_analysis.client import (
ContainerAnalysisClient,
)
from google.cloud.devtools.containeranalysis_v1.types.containeranalysis import (
GetVulnerabilityOccurrencesSummaryRequest,
VulnerabilityOccurrencesSummary,
)

Expand Down
16 changes: 16 additions & 0 deletions google/cloud/devtools/containeranalysis/gapic_version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# -*- coding: utf-8 -*-
# Copyright 2022 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
__version__ = "2.9.3" # {x-release-please-version}
2 changes: 1 addition & 1 deletion google/cloud/devtools/containeranalysis/py.typed
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# Marker file for PEP 561.
# The google-cloud-devtools-containeranalysis package uses inline types.
# The google-cloud-containeranalysis package uses inline types.
15 changes: 11 additions & 4 deletions google/cloud/devtools/containeranalysis_v1/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,19 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
from google.cloud.devtools.containeranalysis import gapic_version as package_version

from .services.container_analysis import ContainerAnalysisClient
from .services.container_analysis import ContainerAnalysisAsyncClient
__version__ = package_version.__version__

from .types.containeranalysis import GetVulnerabilityOccurrencesSummaryRequest
from .types.containeranalysis import VulnerabilityOccurrencesSummary

from .services.container_analysis import (
ContainerAnalysisAsyncClient,
ContainerAnalysisClient,
)
from .types.containeranalysis import (
GetVulnerabilityOccurrencesSummaryRequest,
VulnerabilityOccurrencesSummary,
)

__all__ = (
"ContainerAnalysisAsyncClient",
Expand Down
2 changes: 1 addition & 1 deletion google/cloud/devtools/containeranalysis_v1/py.typed
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# Marker file for PEP 561.
# The google-cloud-devtools-containeranalysis package uses inline types.
# The google-cloud-containeranalysis package uses inline types.
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
from .client import ContainerAnalysisClient
from .async_client import ContainerAnalysisAsyncClient
from .client import ContainerAnalysisClient

__all__ = (
"ContainerAnalysisClient",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,32 +16,42 @@
from collections import OrderedDict
import functools
import re
from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union
import pkg_resources
from typing import (
Dict,
Mapping,
MutableMapping,
MutableSequence,
Optional,
Sequence,
Tuple,
Type,
Union,
)

from google.api_core.client_options import ClientOptions
from google.api_core import exceptions as core_exceptions
from google.api_core import gapic_v1
from google.api_core import retry as retries
from google.api_core.client_options import ClientOptions
from google.auth import credentials as ga_credentials # type: ignore
from google.oauth2 import service_account # type: ignore
import pkg_resources

try:
OptionalRetry = Union[retries.Retry, gapic_v1.method._MethodDefault]
except AttributeError: # pragma: NO COVER
OptionalRetry = Union[retries.Retry, object] # type: ignore

from google.cloud.devtools.containeranalysis_v1.types import containeranalysis
from google.iam.v1 import iam_policy_pb2 # type: ignore
from google.iam.v1 import policy_pb2 # type: ignore
from .transports.base import ContainerAnalysisTransport, DEFAULT_CLIENT_INFO
from .transports.grpc_asyncio import ContainerAnalysisGrpcAsyncIOTransport
from .client import ContainerAnalysisClient


from grafeas import grafeas_v1
from grafeas.grafeas_v1.services.grafeas import transports

from google.cloud.devtools.containeranalysis_v1.types import containeranalysis

from .client import ContainerAnalysisClient
from .transports.base import DEFAULT_CLIENT_INFO, ContainerAnalysisTransport
from .transports.grpc_asyncio import ContainerAnalysisGrpcAsyncIOTransport


class ContainerAnalysisAsyncClient:
"""Retrieves analysis results of Cloud components such as Docker
Expand Down Expand Up @@ -176,9 +186,9 @@ def transport(self) -> ContainerAnalysisTransport:
def __init__(
self,
*,
credentials: ga_credentials.Credentials = None,
credentials: Optional[ga_credentials.Credentials] = None,
transport: Union[str, ContainerAnalysisTransport] = "grpc_asyncio",
client_options: ClientOptions = None,
client_options: Optional[ClientOptions] = None,
client_info: gapic_v1.client_info.ClientInfo = DEFAULT_CLIENT_INFO,
) -> None:
"""Instantiates the container analysis client.
Expand Down Expand Up @@ -236,11 +246,11 @@ def get_grafeas_client(self) -> grafeas_v1.GrafeasClient:

async def set_iam_policy(
self,
request: Union[iam_policy_pb2.SetIamPolicyRequest, dict] = None,
request: Optional[Union[iam_policy_pb2.SetIamPolicyRequest, dict]] = None,
*,
resource: str = None,
resource: Optional[str] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> policy_pb2.Policy:
r"""Sets the access control policy on the specified note or
Expand Down Expand Up @@ -281,7 +291,7 @@ async def sample_set_iam_policy():
print(response)

Args:
request (Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]):
request (Optional[Union[google.iam.v1.iam_policy_pb2.SetIamPolicyRequest, dict]]):
The request object. Request message for `SetIamPolicy`
method.
resource (:class:`str`):
Expand Down Expand Up @@ -410,11 +420,11 @@ async def sample_set_iam_policy():

async def get_iam_policy(
self,
request: Union[iam_policy_pb2.GetIamPolicyRequest, dict] = None,
request: Optional[Union[iam_policy_pb2.GetIamPolicyRequest, dict]] = None,
*,
resource: str = None,
resource: Optional[str] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> policy_pb2.Policy:
r"""Gets the access control policy for a note or an occurrence
Expand Down Expand Up @@ -455,7 +465,7 @@ async def sample_get_iam_policy():
print(response)

Args:
request (Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]):
request (Optional[Union[google.iam.v1.iam_policy_pb2.GetIamPolicyRequest, dict]]):
The request object. Request message for `GetIamPolicy`
method.
resource (:class:`str`):
Expand Down Expand Up @@ -584,12 +594,12 @@ async def sample_get_iam_policy():

async def test_iam_permissions(
self,
request: Union[iam_policy_pb2.TestIamPermissionsRequest, dict] = None,
request: Optional[Union[iam_policy_pb2.TestIamPermissionsRequest, dict]] = None,
*,
resource: str = None,
permissions: Sequence[str] = None,
resource: Optional[str] = None,
permissions: Optional[MutableSequence[str]] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> iam_policy_pb2.TestIamPermissionsResponse:
r"""Returns the permissions that a caller has on the specified note
Expand Down Expand Up @@ -630,7 +640,7 @@ async def sample_test_iam_permissions():
print(response)

Args:
request (Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]):
request (Optional[Union[google.iam.v1.iam_policy_pb2.TestIamPermissionsRequest, dict]]):
The request object. Request message for
`TestIamPermissions` method.
resource (:class:`str`):
Expand All @@ -642,7 +652,7 @@ async def sample_test_iam_permissions():
This corresponds to the ``resource`` field
on the ``request`` instance; if ``request`` is provided, this
should not be set.
permissions (:class:`Sequence[str]`):
permissions (:class:`MutableSequence[str]`):
The set of permissions to check for the ``resource``.
Permissions with wildcards (such as '*' or 'storage.*')
are not allowed. For more information see `IAM
Expand Down Expand Up @@ -708,14 +718,14 @@ async def sample_test_iam_permissions():

async def get_vulnerability_occurrences_summary(
self,
request: Union[
containeranalysis.GetVulnerabilityOccurrencesSummaryRequest, dict
request: Optional[
Union[containeranalysis.GetVulnerabilityOccurrencesSummaryRequest, dict]
] = None,
*,
parent: str = None,
filter: str = None,
parent: Optional[str] = None,
filter: Optional[str] = None,
retry: OptionalRetry = gapic_v1.method.DEFAULT,
timeout: float = None,
timeout: Optional[float] = None,
metadata: Sequence[Tuple[str, str]] = (),
) -> containeranalysis.VulnerabilityOccurrencesSummary:
r"""Gets a summary of the number and severity of
Expand Down Expand Up @@ -748,7 +758,7 @@ async def sample_get_vulnerability_occurrences_summary():
print(response)

Args:
request (Union[google.cloud.devtools.containeranalysis_v1.types.GetVulnerabilityOccurrencesSummaryRequest, dict]):
request (Optional[Union[google.cloud.devtools.containeranalysis_v1.types.GetVulnerabilityOccurrencesSummaryRequest, dict]]):
The request object. Request to get a vulnerability
summary for some set of occurrences.
parent (:class:`str`):
Expand Down
Loading