diff --git a/packages/google-cloud-container/.github/.OwlBot.lock.yaml b/packages/google-cloud-container/.github/.OwlBot.lock.yaml index bc893c979e20..7c454abf76f3 100644 --- a/packages/google-cloud-container/.github/.OwlBot.lock.yaml +++ b/packages/google-cloud-container/.github/.OwlBot.lock.yaml @@ -13,5 +13,5 @@ # limitations under the License. docker: image: gcr.io/cloud-devrel-public-resources/owlbot-python:latest - digest: sha256:8a5d3f6a2e43ed8293f34e06a2f56931d1e88a2694c3bb11b15df4eb256ad163 -# created: 2022-04-06T10:30:21.687684602Z + digest: sha256:00c9d764fd1cd56265f12a5ef4b99a0c9e87cf261018099141e2ca5158890416 +# created: 2022-04-20T23:42:53.970438194Z diff --git a/packages/google-cloud-container/docs/conf.py b/packages/google-cloud-container/docs/conf.py index 36a7a8a04027..b72c85eca56f 100644 --- a/packages/google-cloud-container/docs/conf.py +++ b/packages/google-cloud-container/docs/conf.py @@ -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 diff --git a/packages/google-cloud-container/google/cloud/container/__init__.py b/packages/google-cloud-container/google/cloud/container/__init__.py index a84e021abed0..59467da88f38 100644 --- a/packages/google-cloud-container/google/cloud/container/__init__.py +++ b/packages/google-cloud-container/google/cloud/container/__init__.py @@ -14,152 +14,137 @@ # limitations under the License. # -from google.cloud.container_v1.services.cluster_manager.client import ( - ClusterManagerClient, -) from google.cloud.container_v1.services.cluster_manager.async_client import ( ClusterManagerAsyncClient, ) - -from google.cloud.container_v1.types.cluster_service import AcceleratorConfig -from google.cloud.container_v1.types.cluster_service import AddonsConfig -from google.cloud.container_v1.types.cluster_service import AdvancedMachineFeatures -from google.cloud.container_v1.types.cluster_service import AuthenticatorGroupsConfig -from google.cloud.container_v1.types.cluster_service import Autopilot -from google.cloud.container_v1.types.cluster_service import ( - AutoprovisioningNodePoolDefaults, +from google.cloud.container_v1.services.cluster_manager.client import ( + ClusterManagerClient, ) -from google.cloud.container_v1.types.cluster_service import AutoUpgradeOptions -from google.cloud.container_v1.types.cluster_service import BinaryAuthorization -from google.cloud.container_v1.types.cluster_service import CancelOperationRequest -from google.cloud.container_v1.types.cluster_service import ClientCertificateConfig -from google.cloud.container_v1.types.cluster_service import CloudRunConfig -from google.cloud.container_v1.types.cluster_service import Cluster -from google.cloud.container_v1.types.cluster_service import ClusterAutoscaling -from google.cloud.container_v1.types.cluster_service import ClusterUpdate -from google.cloud.container_v1.types.cluster_service import CompleteIPRotationRequest -from google.cloud.container_v1.types.cluster_service import ConfidentialNodes -from google.cloud.container_v1.types.cluster_service import ConfigConnectorConfig -from google.cloud.container_v1.types.cluster_service import CreateClusterRequest -from google.cloud.container_v1.types.cluster_service import CreateNodePoolRequest -from google.cloud.container_v1.types.cluster_service import DailyMaintenanceWindow -from google.cloud.container_v1.types.cluster_service import DatabaseEncryption -from google.cloud.container_v1.types.cluster_service import DefaultSnatStatus -from google.cloud.container_v1.types.cluster_service import DeleteClusterRequest -from google.cloud.container_v1.types.cluster_service import DeleteNodePoolRequest -from google.cloud.container_v1.types.cluster_service import DnsCacheConfig -from google.cloud.container_v1.types.cluster_service import DNSConfig from google.cloud.container_v1.types.cluster_service import ( + AcceleratorConfig, + AddonsConfig, + AdvancedMachineFeatures, + AuthenticatorGroupsConfig, + Autopilot, + AutoprovisioningNodePoolDefaults, + AutoUpgradeOptions, + BinaryAuthorization, + CancelOperationRequest, + ClientCertificateConfig, + CloudRunConfig, + Cluster, + ClusterAutoscaling, + ClusterUpdate, + CompleteIPRotationRequest, + ConfidentialNodes, + ConfigConnectorConfig, + CreateClusterRequest, + CreateNodePoolRequest, + DailyMaintenanceWindow, + DatabaseEncryption, + DatapathProvider, + DefaultSnatStatus, + DeleteClusterRequest, + DeleteNodePoolRequest, + DnsCacheConfig, + DNSConfig, GcePersistentDiskCsiDriverConfig, -) -from google.cloud.container_v1.types.cluster_service import GcfsConfig -from google.cloud.container_v1.types.cluster_service import GcpFilestoreCsiDriverConfig -from google.cloud.container_v1.types.cluster_service import GetClusterRequest -from google.cloud.container_v1.types.cluster_service import GetJSONWebKeysRequest -from google.cloud.container_v1.types.cluster_service import GetJSONWebKeysResponse -from google.cloud.container_v1.types.cluster_service import GetNodePoolRequest -from google.cloud.container_v1.types.cluster_service import GetOpenIDConfigRequest -from google.cloud.container_v1.types.cluster_service import GetOpenIDConfigResponse -from google.cloud.container_v1.types.cluster_service import GetOperationRequest -from google.cloud.container_v1.types.cluster_service import GetServerConfigRequest -from google.cloud.container_v1.types.cluster_service import HorizontalPodAutoscaling -from google.cloud.container_v1.types.cluster_service import HttpLoadBalancing -from google.cloud.container_v1.types.cluster_service import ILBSubsettingConfig -from google.cloud.container_v1.types.cluster_service import IntraNodeVisibilityConfig -from google.cloud.container_v1.types.cluster_service import IPAllocationPolicy -from google.cloud.container_v1.types.cluster_service import Jwk -from google.cloud.container_v1.types.cluster_service import KubernetesDashboard -from google.cloud.container_v1.types.cluster_service import LegacyAbac -from google.cloud.container_v1.types.cluster_service import LinuxNodeConfig -from google.cloud.container_v1.types.cluster_service import ListClustersRequest -from google.cloud.container_v1.types.cluster_service import ListClustersResponse -from google.cloud.container_v1.types.cluster_service import ListNodePoolsRequest -from google.cloud.container_v1.types.cluster_service import ListNodePoolsResponse -from google.cloud.container_v1.types.cluster_service import ListOperationsRequest -from google.cloud.container_v1.types.cluster_service import ListOperationsResponse -from google.cloud.container_v1.types.cluster_service import ListUsableSubnetworksRequest -from google.cloud.container_v1.types.cluster_service import ( + GcfsConfig, + GcpFilestoreCsiDriverConfig, + GetClusterRequest, + GetJSONWebKeysRequest, + GetJSONWebKeysResponse, + GetNodePoolRequest, + GetOpenIDConfigRequest, + GetOpenIDConfigResponse, + GetOperationRequest, + GetServerConfigRequest, + HorizontalPodAutoscaling, + HttpLoadBalancing, + ILBSubsettingConfig, + IntraNodeVisibilityConfig, + IPAllocationPolicy, + Jwk, + KubernetesDashboard, + LegacyAbac, + LinuxNodeConfig, + ListClustersRequest, + ListClustersResponse, + ListNodePoolsRequest, + ListNodePoolsResponse, + ListOperationsRequest, + ListOperationsResponse, + ListUsableSubnetworksRequest, ListUsableSubnetworksResponse, -) -from google.cloud.container_v1.types.cluster_service import LoggingComponentConfig -from google.cloud.container_v1.types.cluster_service import LoggingConfig -from google.cloud.container_v1.types.cluster_service import MaintenanceExclusionOptions -from google.cloud.container_v1.types.cluster_service import MaintenancePolicy -from google.cloud.container_v1.types.cluster_service import MaintenanceWindow -from google.cloud.container_v1.types.cluster_service import MasterAuth -from google.cloud.container_v1.types.cluster_service import ( + LoggingComponentConfig, + LoggingConfig, + MaintenanceExclusionOptions, + MaintenancePolicy, + MaintenanceWindow, + MasterAuth, MasterAuthorizedNetworksConfig, -) -from google.cloud.container_v1.types.cluster_service import MaxPodsConstraint -from google.cloud.container_v1.types.cluster_service import MeshCertificates -from google.cloud.container_v1.types.cluster_service import MonitoringComponentConfig -from google.cloud.container_v1.types.cluster_service import MonitoringConfig -from google.cloud.container_v1.types.cluster_service import NetworkConfig -from google.cloud.container_v1.types.cluster_service import NetworkPolicy -from google.cloud.container_v1.types.cluster_service import NetworkPolicyConfig -from google.cloud.container_v1.types.cluster_service import NodeConfig -from google.cloud.container_v1.types.cluster_service import NodeConfigDefaults -from google.cloud.container_v1.types.cluster_service import NodeKubeletConfig -from google.cloud.container_v1.types.cluster_service import NodeManagement -from google.cloud.container_v1.types.cluster_service import NodeNetworkConfig -from google.cloud.container_v1.types.cluster_service import NodePool -from google.cloud.container_v1.types.cluster_service import NodePoolAutoscaling -from google.cloud.container_v1.types.cluster_service import NodePoolDefaults -from google.cloud.container_v1.types.cluster_service import NodeTaint -from google.cloud.container_v1.types.cluster_service import NotificationConfig -from google.cloud.container_v1.types.cluster_service import Operation -from google.cloud.container_v1.types.cluster_service import OperationProgress -from google.cloud.container_v1.types.cluster_service import PrivateClusterConfig -from google.cloud.container_v1.types.cluster_service import ( + MaxPodsConstraint, + MeshCertificates, + MonitoringComponentConfig, + MonitoringConfig, + NetworkConfig, + NetworkPolicy, + NetworkPolicyConfig, + NodeConfig, + NodeConfigDefaults, + NodeKubeletConfig, + NodeManagement, + NodeNetworkConfig, + NodePool, + NodePoolAutoscaling, + NodePoolDefaults, + NodeTaint, + NotificationConfig, + Operation, + OperationProgress, + PrivateClusterConfig, PrivateClusterMasterGlobalAccessConfig, -) -from google.cloud.container_v1.types.cluster_service import RecurringTimeWindow -from google.cloud.container_v1.types.cluster_service import ReleaseChannel -from google.cloud.container_v1.types.cluster_service import ReservationAffinity -from google.cloud.container_v1.types.cluster_service import ResourceLimit -from google.cloud.container_v1.types.cluster_service import ResourceUsageExportConfig -from google.cloud.container_v1.types.cluster_service import ( + PrivateIPv6GoogleAccess, + RecurringTimeWindow, + ReleaseChannel, + ReservationAffinity, + ResourceLimit, + ResourceUsageExportConfig, RollbackNodePoolUpgradeRequest, -) -from google.cloud.container_v1.types.cluster_service import SandboxConfig -from google.cloud.container_v1.types.cluster_service import SecurityBulletinEvent -from google.cloud.container_v1.types.cluster_service import ServerConfig -from google.cloud.container_v1.types.cluster_service import ServiceExternalIPsConfig -from google.cloud.container_v1.types.cluster_service import SetAddonsConfigRequest -from google.cloud.container_v1.types.cluster_service import SetLabelsRequest -from google.cloud.container_v1.types.cluster_service import SetLegacyAbacRequest -from google.cloud.container_v1.types.cluster_service import SetLocationsRequest -from google.cloud.container_v1.types.cluster_service import SetLoggingServiceRequest -from google.cloud.container_v1.types.cluster_service import SetMaintenancePolicyRequest -from google.cloud.container_v1.types.cluster_service import SetMasterAuthRequest -from google.cloud.container_v1.types.cluster_service import SetMonitoringServiceRequest -from google.cloud.container_v1.types.cluster_service import SetNetworkPolicyRequest -from google.cloud.container_v1.types.cluster_service import ( + SandboxConfig, + SecurityBulletinEvent, + ServerConfig, + ServiceExternalIPsConfig, + SetAddonsConfigRequest, + SetLabelsRequest, + SetLegacyAbacRequest, + SetLocationsRequest, + SetLoggingServiceRequest, + SetMaintenancePolicyRequest, + SetMasterAuthRequest, + SetMonitoringServiceRequest, + SetNetworkPolicyRequest, SetNodePoolAutoscalingRequest, -) -from google.cloud.container_v1.types.cluster_service import SetNodePoolManagementRequest -from google.cloud.container_v1.types.cluster_service import SetNodePoolSizeRequest -from google.cloud.container_v1.types.cluster_service import ShieldedInstanceConfig -from google.cloud.container_v1.types.cluster_service import ShieldedNodes -from google.cloud.container_v1.types.cluster_service import StartIPRotationRequest -from google.cloud.container_v1.types.cluster_service import StatusCondition -from google.cloud.container_v1.types.cluster_service import TimeWindow -from google.cloud.container_v1.types.cluster_service import UpdateClusterRequest -from google.cloud.container_v1.types.cluster_service import UpdateMasterRequest -from google.cloud.container_v1.types.cluster_service import UpdateNodePoolRequest -from google.cloud.container_v1.types.cluster_service import UpgradeAvailableEvent -from google.cloud.container_v1.types.cluster_service import UpgradeEvent -from google.cloud.container_v1.types.cluster_service import UsableSubnetwork -from google.cloud.container_v1.types.cluster_service import ( + SetNodePoolManagementRequest, + SetNodePoolSizeRequest, + ShieldedInstanceConfig, + ShieldedNodes, + StartIPRotationRequest, + StatusCondition, + TimeWindow, + UpdateClusterRequest, + UpdateMasterRequest, + UpdateNodePoolRequest, + UpgradeAvailableEvent, + UpgradeEvent, + UpgradeResourceType, + UsableSubnetwork, UsableSubnetworkSecondaryRange, + VerticalPodAutoscaling, + VirtualNIC, + WorkloadIdentityConfig, + WorkloadMetadataConfig, ) -from google.cloud.container_v1.types.cluster_service import VerticalPodAutoscaling -from google.cloud.container_v1.types.cluster_service import VirtualNIC -from google.cloud.container_v1.types.cluster_service import WorkloadIdentityConfig -from google.cloud.container_v1.types.cluster_service import WorkloadMetadataConfig -from google.cloud.container_v1.types.cluster_service import DatapathProvider -from google.cloud.container_v1.types.cluster_service import PrivateIPv6GoogleAccess -from google.cloud.container_v1.types.cluster_service import UpgradeResourceType __all__ = ( "ClusterManagerClient", diff --git a/packages/google-cloud-container/google/cloud/container_v1/__init__.py b/packages/google-cloud-container/google/cloud/container_v1/__init__.py index 69276ad0fa0e..3d33a5e46072 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1/__init__.py @@ -14,132 +14,132 @@ # limitations under the License. # -from .services.cluster_manager import ClusterManagerClient -from .services.cluster_manager import ClusterManagerAsyncClient - -from .types.cluster_service import AcceleratorConfig -from .types.cluster_service import AddonsConfig -from .types.cluster_service import AdvancedMachineFeatures -from .types.cluster_service import AuthenticatorGroupsConfig -from .types.cluster_service import Autopilot -from .types.cluster_service import AutoprovisioningNodePoolDefaults -from .types.cluster_service import AutoUpgradeOptions -from .types.cluster_service import BinaryAuthorization -from .types.cluster_service import CancelOperationRequest -from .types.cluster_service import ClientCertificateConfig -from .types.cluster_service import CloudRunConfig -from .types.cluster_service import Cluster -from .types.cluster_service import ClusterAutoscaling -from .types.cluster_service import ClusterUpdate -from .types.cluster_service import CompleteIPRotationRequest -from .types.cluster_service import ConfidentialNodes -from .types.cluster_service import ConfigConnectorConfig -from .types.cluster_service import CreateClusterRequest -from .types.cluster_service import CreateNodePoolRequest -from .types.cluster_service import DailyMaintenanceWindow -from .types.cluster_service import DatabaseEncryption -from .types.cluster_service import DefaultSnatStatus -from .types.cluster_service import DeleteClusterRequest -from .types.cluster_service import DeleteNodePoolRequest -from .types.cluster_service import DnsCacheConfig -from .types.cluster_service import DNSConfig -from .types.cluster_service import GcePersistentDiskCsiDriverConfig -from .types.cluster_service import GcfsConfig -from .types.cluster_service import GcpFilestoreCsiDriverConfig -from .types.cluster_service import GetClusterRequest -from .types.cluster_service import GetJSONWebKeysRequest -from .types.cluster_service import GetJSONWebKeysResponse -from .types.cluster_service import GetNodePoolRequest -from .types.cluster_service import GetOpenIDConfigRequest -from .types.cluster_service import GetOpenIDConfigResponse -from .types.cluster_service import GetOperationRequest -from .types.cluster_service import GetServerConfigRequest -from .types.cluster_service import HorizontalPodAutoscaling -from .types.cluster_service import HttpLoadBalancing -from .types.cluster_service import ILBSubsettingConfig -from .types.cluster_service import IntraNodeVisibilityConfig -from .types.cluster_service import IPAllocationPolicy -from .types.cluster_service import Jwk -from .types.cluster_service import KubernetesDashboard -from .types.cluster_service import LegacyAbac -from .types.cluster_service import LinuxNodeConfig -from .types.cluster_service import ListClustersRequest -from .types.cluster_service import ListClustersResponse -from .types.cluster_service import ListNodePoolsRequest -from .types.cluster_service import ListNodePoolsResponse -from .types.cluster_service import ListOperationsRequest -from .types.cluster_service import ListOperationsResponse -from .types.cluster_service import ListUsableSubnetworksRequest -from .types.cluster_service import ListUsableSubnetworksResponse -from .types.cluster_service import LoggingComponentConfig -from .types.cluster_service import LoggingConfig -from .types.cluster_service import MaintenanceExclusionOptions -from .types.cluster_service import MaintenancePolicy -from .types.cluster_service import MaintenanceWindow -from .types.cluster_service import MasterAuth -from .types.cluster_service import MasterAuthorizedNetworksConfig -from .types.cluster_service import MaxPodsConstraint -from .types.cluster_service import MeshCertificates -from .types.cluster_service import MonitoringComponentConfig -from .types.cluster_service import MonitoringConfig -from .types.cluster_service import NetworkConfig -from .types.cluster_service import NetworkPolicy -from .types.cluster_service import NetworkPolicyConfig -from .types.cluster_service import NodeConfig -from .types.cluster_service import NodeConfigDefaults -from .types.cluster_service import NodeKubeletConfig -from .types.cluster_service import NodeManagement -from .types.cluster_service import NodeNetworkConfig -from .types.cluster_service import NodePool -from .types.cluster_service import NodePoolAutoscaling -from .types.cluster_service import NodePoolDefaults -from .types.cluster_service import NodeTaint -from .types.cluster_service import NotificationConfig -from .types.cluster_service import Operation -from .types.cluster_service import OperationProgress -from .types.cluster_service import PrivateClusterConfig -from .types.cluster_service import PrivateClusterMasterGlobalAccessConfig -from .types.cluster_service import RecurringTimeWindow -from .types.cluster_service import ReleaseChannel -from .types.cluster_service import ReservationAffinity -from .types.cluster_service import ResourceLimit -from .types.cluster_service import ResourceUsageExportConfig -from .types.cluster_service import RollbackNodePoolUpgradeRequest -from .types.cluster_service import SandboxConfig -from .types.cluster_service import SecurityBulletinEvent -from .types.cluster_service import ServerConfig -from .types.cluster_service import ServiceExternalIPsConfig -from .types.cluster_service import SetAddonsConfigRequest -from .types.cluster_service import SetLabelsRequest -from .types.cluster_service import SetLegacyAbacRequest -from .types.cluster_service import SetLocationsRequest -from .types.cluster_service import SetLoggingServiceRequest -from .types.cluster_service import SetMaintenancePolicyRequest -from .types.cluster_service import SetMasterAuthRequest -from .types.cluster_service import SetMonitoringServiceRequest -from .types.cluster_service import SetNetworkPolicyRequest -from .types.cluster_service import SetNodePoolAutoscalingRequest -from .types.cluster_service import SetNodePoolManagementRequest -from .types.cluster_service import SetNodePoolSizeRequest -from .types.cluster_service import ShieldedInstanceConfig -from .types.cluster_service import ShieldedNodes -from .types.cluster_service import StartIPRotationRequest -from .types.cluster_service import StatusCondition -from .types.cluster_service import TimeWindow -from .types.cluster_service import UpdateClusterRequest -from .types.cluster_service import UpdateMasterRequest -from .types.cluster_service import UpdateNodePoolRequest -from .types.cluster_service import UpgradeAvailableEvent -from .types.cluster_service import UpgradeEvent -from .types.cluster_service import UsableSubnetwork -from .types.cluster_service import UsableSubnetworkSecondaryRange -from .types.cluster_service import VerticalPodAutoscaling -from .types.cluster_service import VirtualNIC -from .types.cluster_service import WorkloadIdentityConfig -from .types.cluster_service import WorkloadMetadataConfig -from .types.cluster_service import DatapathProvider -from .types.cluster_service import PrivateIPv6GoogleAccess -from .types.cluster_service import UpgradeResourceType +from .services.cluster_manager import ClusterManagerAsyncClient, ClusterManagerClient +from .types.cluster_service import ( + AcceleratorConfig, + AddonsConfig, + AdvancedMachineFeatures, + AuthenticatorGroupsConfig, + Autopilot, + AutoprovisioningNodePoolDefaults, + AutoUpgradeOptions, + BinaryAuthorization, + CancelOperationRequest, + ClientCertificateConfig, + CloudRunConfig, + Cluster, + ClusterAutoscaling, + ClusterUpdate, + CompleteIPRotationRequest, + ConfidentialNodes, + ConfigConnectorConfig, + CreateClusterRequest, + CreateNodePoolRequest, + DailyMaintenanceWindow, + DatabaseEncryption, + DatapathProvider, + DefaultSnatStatus, + DeleteClusterRequest, + DeleteNodePoolRequest, + DnsCacheConfig, + DNSConfig, + GcePersistentDiskCsiDriverConfig, + GcfsConfig, + GcpFilestoreCsiDriverConfig, + GetClusterRequest, + GetJSONWebKeysRequest, + GetJSONWebKeysResponse, + GetNodePoolRequest, + GetOpenIDConfigRequest, + GetOpenIDConfigResponse, + GetOperationRequest, + GetServerConfigRequest, + HorizontalPodAutoscaling, + HttpLoadBalancing, + ILBSubsettingConfig, + IntraNodeVisibilityConfig, + IPAllocationPolicy, + Jwk, + KubernetesDashboard, + LegacyAbac, + LinuxNodeConfig, + ListClustersRequest, + ListClustersResponse, + ListNodePoolsRequest, + ListNodePoolsResponse, + ListOperationsRequest, + ListOperationsResponse, + ListUsableSubnetworksRequest, + ListUsableSubnetworksResponse, + LoggingComponentConfig, + LoggingConfig, + MaintenanceExclusionOptions, + MaintenancePolicy, + MaintenanceWindow, + MasterAuth, + MasterAuthorizedNetworksConfig, + MaxPodsConstraint, + MeshCertificates, + MonitoringComponentConfig, + MonitoringConfig, + NetworkConfig, + NetworkPolicy, + NetworkPolicyConfig, + NodeConfig, + NodeConfigDefaults, + NodeKubeletConfig, + NodeManagement, + NodeNetworkConfig, + NodePool, + NodePoolAutoscaling, + NodePoolDefaults, + NodeTaint, + NotificationConfig, + Operation, + OperationProgress, + PrivateClusterConfig, + PrivateClusterMasterGlobalAccessConfig, + PrivateIPv6GoogleAccess, + RecurringTimeWindow, + ReleaseChannel, + ReservationAffinity, + ResourceLimit, + ResourceUsageExportConfig, + RollbackNodePoolUpgradeRequest, + SandboxConfig, + SecurityBulletinEvent, + ServerConfig, + ServiceExternalIPsConfig, + SetAddonsConfigRequest, + SetLabelsRequest, + SetLegacyAbacRequest, + SetLocationsRequest, + SetLoggingServiceRequest, + SetMaintenancePolicyRequest, + SetMasterAuthRequest, + SetMonitoringServiceRequest, + SetNetworkPolicyRequest, + SetNodePoolAutoscalingRequest, + SetNodePoolManagementRequest, + SetNodePoolSizeRequest, + ShieldedInstanceConfig, + ShieldedNodes, + StartIPRotationRequest, + StatusCondition, + TimeWindow, + UpdateClusterRequest, + UpdateMasterRequest, + UpdateNodePoolRequest, + UpgradeAvailableEvent, + UpgradeEvent, + UpgradeResourceType, + UsableSubnetwork, + UsableSubnetworkSecondaryRange, + VerticalPodAutoscaling, + VirtualNIC, + WorkloadIdentityConfig, + WorkloadMetadataConfig, +) __all__ = ( "ClusterManagerAsyncClient", diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/__init__.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/__init__.py index da06b070d3ae..8445ce150fbd 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/__init__.py @@ -13,8 +13,8 @@ # See the License for the specific language governing permissions and # limitations under the License. # -from .client import ClusterManagerClient from .async_client import ClusterManagerAsyncClient +from .client import ClusterManagerClient __all__ = ( "ClusterManagerClient", diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/async_client.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/async_client.py index 6a79ae1cb1fd..f8f5cda865fa 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/async_client.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/async_client.py @@ -17,27 +17,29 @@ import functools import re from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union -import pkg_resources import warnings -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.rpc import status_pb2 # type: ignore + from google.cloud.container_v1.services.cluster_manager import pagers from google.cloud.container_v1.types import cluster_service -from google.rpc import status_pb2 # type: ignore -from .transports.base import ClusterManagerTransport, DEFAULT_CLIENT_INFO -from .transports.grpc_asyncio import ClusterManagerGrpcAsyncIOTransport + from .client import ClusterManagerClient +from .transports.base import DEFAULT_CLIENT_INFO, ClusterManagerTransport +from .transports.grpc_asyncio import ClusterManagerGrpcAsyncIOTransport class ClusterManagerAsyncClient: diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/client.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/client.py index ab14a01aff27..4f7bf8940160 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/client.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/client.py @@ -17,7 +17,6 @@ import os import re from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union -import pkg_resources import warnings from google.api_core import client_options as client_options_lib @@ -25,20 +24,23 @@ from google.api_core import gapic_v1 from google.api_core import retry as retries from google.auth import credentials as ga_credentials # type: ignore +from google.auth.exceptions import MutualTLSChannelError # type: ignore from google.auth.transport import mtls # type: ignore from google.auth.transport.grpc import SslCredentials # type: ignore -from google.auth.exceptions import MutualTLSChannelError # 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.rpc import status_pb2 # type: ignore + from google.cloud.container_v1.services.cluster_manager import pagers from google.cloud.container_v1.types import cluster_service -from google.rpc import status_pb2 # type: ignore -from .transports.base import ClusterManagerTransport, DEFAULT_CLIENT_INFO + +from .transports.base import DEFAULT_CLIENT_INFO, ClusterManagerTransport from .transports.grpc import ClusterManagerGrpcTransport from .transports.grpc_asyncio import ClusterManagerGrpcAsyncIOTransport diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/pagers.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/pagers.py index dc606db3adec..39f4b7c8a1b1 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/pagers.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/pagers.py @@ -18,10 +18,10 @@ AsyncIterator, Awaitable, Callable, + Iterator, + Optional, Sequence, Tuple, - Optional, - Iterator, ) from google.cloud.container_v1.types import cluster_service diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/__init__.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/__init__.py index b6375e92a8a4..b794d72c1bc1 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/__init__.py @@ -20,7 +20,6 @@ from .grpc import ClusterManagerGrpcTransport from .grpc_asyncio import ClusterManagerGrpcAsyncIOTransport - # Compile a registry of transports. _transport_registry = OrderedDict() # type: Dict[str, Type[ClusterManagerTransport]] _transport_registry["grpc"] = ClusterManagerGrpcTransport diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/base.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/base.py index 674fb4fb91c7..fbcaad68c73a 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/base.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/base.py @@ -15,18 +15,18 @@ # import abc from typing import Awaitable, Callable, Dict, Optional, Sequence, Union -import pkg_resources -import google.auth # type: ignore import google.api_core from google.api_core import exceptions as core_exceptions from google.api_core import gapic_v1 from google.api_core import retry as retries +import google.auth # type: ignore from google.auth import credentials as ga_credentials # type: ignore from google.oauth2 import service_account # type: ignore +from google.protobuf import empty_pb2 # type: ignore +import pkg_resources from google.cloud.container_v1.types import cluster_service -from google.protobuf import empty_pb2 # type: ignore try: DEFAULT_CLIENT_INFO = gapic_v1.client_info.ClientInfo( diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc.py index bcce7b887a4f..79643edcc650 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc.py @@ -13,20 +13,19 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import warnings from typing import Callable, Dict, Optional, Sequence, Tuple, Union +import warnings -from google.api_core import grpc_helpers -from google.api_core import gapic_v1 +from google.api_core import gapic_v1, grpc_helpers import google.auth # type: ignore from google.auth import credentials as ga_credentials # type: ignore from google.auth.transport.grpc import SslCredentials # type: ignore - +from google.protobuf import empty_pb2 # type: ignore import grpc # type: ignore from google.cloud.container_v1.types import cluster_service -from google.protobuf import empty_pb2 # type: ignore -from .base import ClusterManagerTransport, DEFAULT_CLIENT_INFO + +from .base import DEFAULT_CLIENT_INFO, ClusterManagerTransport class ClusterManagerGrpcTransport(ClusterManagerTransport): diff --git a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc_asyncio.py b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc_asyncio.py index 052036a70b8e..a895fd76abf8 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc_asyncio.py +++ b/packages/google-cloud-container/google/cloud/container_v1/services/cluster_manager/transports/grpc_asyncio.py @@ -13,20 +13,19 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import warnings from typing import Awaitable, Callable, Dict, Optional, Sequence, Tuple, Union +import warnings -from google.api_core import gapic_v1 -from google.api_core import grpc_helpers_async +from google.api_core import gapic_v1, grpc_helpers_async from google.auth import credentials as ga_credentials # type: ignore from google.auth.transport.grpc import SslCredentials # type: ignore - +from google.protobuf import empty_pb2 # type: ignore import grpc # type: ignore from grpc.experimental import aio # type: ignore from google.cloud.container_v1.types import cluster_service -from google.protobuf import empty_pb2 # type: ignore -from .base import ClusterManagerTransport, DEFAULT_CLIENT_INFO + +from .base import DEFAULT_CLIENT_INFO, ClusterManagerTransport from .grpc import ClusterManagerGrpcTransport diff --git a/packages/google-cloud-container/google/cloud/container_v1/types/__init__.py b/packages/google-cloud-container/google/cloud/container_v1/types/__init__.py index 89f6ba10fac7..a6e864856829 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/types/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1/types/__init__.py @@ -35,6 +35,7 @@ CreateNodePoolRequest, DailyMaintenanceWindow, DatabaseEncryption, + DatapathProvider, DefaultSnatStatus, DeleteClusterRequest, DeleteNodePoolRequest, @@ -96,6 +97,7 @@ OperationProgress, PrivateClusterConfig, PrivateClusterMasterGlobalAccessConfig, + PrivateIPv6GoogleAccess, RecurringTimeWindow, ReleaseChannel, ReservationAffinity, @@ -128,15 +130,13 @@ UpdateNodePoolRequest, UpgradeAvailableEvent, UpgradeEvent, + UpgradeResourceType, UsableSubnetwork, UsableSubnetworkSecondaryRange, VerticalPodAutoscaling, VirtualNIC, WorkloadIdentityConfig, WorkloadMetadataConfig, - DatapathProvider, - PrivateIPv6GoogleAccess, - UpgradeResourceType, ) __all__ = ( diff --git a/packages/google-cloud-container/google/cloud/container_v1/types/cluster_service.py b/packages/google-cloud-container/google/cloud/container_v1/types/cluster_service.py index c7d4b88046d9..33f1b470238a 100644 --- a/packages/google-cloud-container/google/cloud/container_v1/types/cluster_service.py +++ b/packages/google-cloud-container/google/cloud/container_v1/types/cluster_service.py @@ -13,13 +13,11 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import proto # type: ignore - from google.protobuf import timestamp_pb2 # type: ignore from google.protobuf import wrappers_pb2 # type: ignore from google.rpc import code_pb2 # type: ignore from google.rpc import status_pb2 # type: ignore - +import proto # type: ignore __protobuf__ = proto.module( package="google.container.v1", diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/__init__.py b/packages/google-cloud-container/google/cloud/container_v1beta1/__init__.py index b8454da53ccf..fd68ddf737d6 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/__init__.py @@ -14,150 +14,150 @@ # limitations under the License. # -from .services.cluster_manager import ClusterManagerClient -from .services.cluster_manager import ClusterManagerAsyncClient - -from .types.cluster_service import AcceleratorConfig -from .types.cluster_service import AddonsConfig -from .types.cluster_service import AdvancedMachineFeatures -from .types.cluster_service import AuthenticatorGroupsConfig -from .types.cluster_service import Autopilot -from .types.cluster_service import AutoprovisioningNodePoolDefaults -from .types.cluster_service import AutoUpgradeOptions -from .types.cluster_service import BinaryAuthorization -from .types.cluster_service import CancelOperationRequest -from .types.cluster_service import ClientCertificateConfig -from .types.cluster_service import CloudRunConfig -from .types.cluster_service import Cluster -from .types.cluster_service import ClusterAutoscaling -from .types.cluster_service import ClusterTelemetry -from .types.cluster_service import ClusterUpdate -from .types.cluster_service import CompleteIPRotationRequest -from .types.cluster_service import ConfidentialNodes -from .types.cluster_service import ConfigConnectorConfig -from .types.cluster_service import CreateClusterRequest -from .types.cluster_service import CreateNodePoolRequest -from .types.cluster_service import DailyMaintenanceWindow -from .types.cluster_service import DatabaseEncryption -from .types.cluster_service import DefaultSnatStatus -from .types.cluster_service import DeleteClusterRequest -from .types.cluster_service import DeleteNodePoolRequest -from .types.cluster_service import DnsCacheConfig -from .types.cluster_service import DNSConfig -from .types.cluster_service import EphemeralStorageConfig -from .types.cluster_service import GcePersistentDiskCsiDriverConfig -from .types.cluster_service import GcfsConfig -from .types.cluster_service import GcpFilestoreCsiDriverConfig -from .types.cluster_service import GetClusterRequest -from .types.cluster_service import GetJSONWebKeysRequest -from .types.cluster_service import GetJSONWebKeysResponse -from .types.cluster_service import GetNodePoolRequest -from .types.cluster_service import GetOpenIDConfigRequest -from .types.cluster_service import GetOpenIDConfigResponse -from .types.cluster_service import GetOperationRequest -from .types.cluster_service import GetServerConfigRequest -from .types.cluster_service import GkeBackupAgentConfig -from .types.cluster_service import HorizontalPodAutoscaling -from .types.cluster_service import HttpLoadBalancing -from .types.cluster_service import IdentityServiceConfig -from .types.cluster_service import ILBSubsettingConfig -from .types.cluster_service import IntraNodeVisibilityConfig -from .types.cluster_service import IPAllocationPolicy -from .types.cluster_service import IstioConfig -from .types.cluster_service import Jwk -from .types.cluster_service import KalmConfig -from .types.cluster_service import KubernetesDashboard -from .types.cluster_service import LegacyAbac -from .types.cluster_service import LinuxNodeConfig -from .types.cluster_service import ListClustersRequest -from .types.cluster_service import ListClustersResponse -from .types.cluster_service import ListLocationsRequest -from .types.cluster_service import ListLocationsResponse -from .types.cluster_service import ListNodePoolsRequest -from .types.cluster_service import ListNodePoolsResponse -from .types.cluster_service import ListOperationsRequest -from .types.cluster_service import ListOperationsResponse -from .types.cluster_service import ListUsableSubnetworksRequest -from .types.cluster_service import ListUsableSubnetworksResponse -from .types.cluster_service import Location -from .types.cluster_service import LoggingComponentConfig -from .types.cluster_service import LoggingConfig -from .types.cluster_service import MaintenanceExclusionOptions -from .types.cluster_service import MaintenancePolicy -from .types.cluster_service import MaintenanceWindow -from .types.cluster_service import ManagedPrometheusConfig -from .types.cluster_service import Master -from .types.cluster_service import MasterAuth -from .types.cluster_service import MasterAuthorizedNetworksConfig -from .types.cluster_service import MaxPodsConstraint -from .types.cluster_service import MeshCertificates -from .types.cluster_service import MonitoringComponentConfig -from .types.cluster_service import MonitoringConfig -from .types.cluster_service import NetworkConfig -from .types.cluster_service import NetworkPolicy -from .types.cluster_service import NetworkPolicyConfig -from .types.cluster_service import NetworkTags -from .types.cluster_service import NodeConfig -from .types.cluster_service import NodeConfigDefaults -from .types.cluster_service import NodeKubeletConfig -from .types.cluster_service import NodeLabels -from .types.cluster_service import NodeManagement -from .types.cluster_service import NodeNetworkConfig -from .types.cluster_service import NodePool -from .types.cluster_service import NodePoolAutoscaling -from .types.cluster_service import NodePoolDefaults -from .types.cluster_service import NodeTaint -from .types.cluster_service import NodeTaints -from .types.cluster_service import NotificationConfig -from .types.cluster_service import Operation -from .types.cluster_service import OperationProgress -from .types.cluster_service import PodSecurityPolicyConfig -from .types.cluster_service import PrivateClusterConfig -from .types.cluster_service import PrivateClusterMasterGlobalAccessConfig -from .types.cluster_service import RecurringTimeWindow -from .types.cluster_service import ReleaseChannel -from .types.cluster_service import ReservationAffinity -from .types.cluster_service import ResourceLimit -from .types.cluster_service import ResourceUsageExportConfig -from .types.cluster_service import RollbackNodePoolUpgradeRequest -from .types.cluster_service import SandboxConfig -from .types.cluster_service import SecurityBulletinEvent -from .types.cluster_service import ServerConfig -from .types.cluster_service import ServiceExternalIPsConfig -from .types.cluster_service import SetAddonsConfigRequest -from .types.cluster_service import SetLabelsRequest -from .types.cluster_service import SetLegacyAbacRequest -from .types.cluster_service import SetLocationsRequest -from .types.cluster_service import SetLoggingServiceRequest -from .types.cluster_service import SetMaintenancePolicyRequest -from .types.cluster_service import SetMasterAuthRequest -from .types.cluster_service import SetMonitoringServiceRequest -from .types.cluster_service import SetNetworkPolicyRequest -from .types.cluster_service import SetNodePoolAutoscalingRequest -from .types.cluster_service import SetNodePoolManagementRequest -from .types.cluster_service import SetNodePoolSizeRequest -from .types.cluster_service import ShieldedInstanceConfig -from .types.cluster_service import ShieldedNodes -from .types.cluster_service import StartIPRotationRequest -from .types.cluster_service import StatusCondition -from .types.cluster_service import TimeWindow -from .types.cluster_service import TpuConfig -from .types.cluster_service import UpdateClusterRequest -from .types.cluster_service import UpdateMasterRequest -from .types.cluster_service import UpdateNodePoolRequest -from .types.cluster_service import UpgradeAvailableEvent -from .types.cluster_service import UpgradeEvent -from .types.cluster_service import UsableSubnetwork -from .types.cluster_service import UsableSubnetworkSecondaryRange -from .types.cluster_service import VerticalPodAutoscaling -from .types.cluster_service import VirtualNIC -from .types.cluster_service import WindowsVersions -from .types.cluster_service import WorkloadCertificates -from .types.cluster_service import WorkloadIdentityConfig -from .types.cluster_service import WorkloadMetadataConfig -from .types.cluster_service import DatapathProvider -from .types.cluster_service import PrivateIPv6GoogleAccess -from .types.cluster_service import UpgradeResourceType +from .services.cluster_manager import ClusterManagerAsyncClient, ClusterManagerClient +from .types.cluster_service import ( + AcceleratorConfig, + AddonsConfig, + AdvancedMachineFeatures, + AuthenticatorGroupsConfig, + Autopilot, + AutoprovisioningNodePoolDefaults, + AutoUpgradeOptions, + BinaryAuthorization, + CancelOperationRequest, + ClientCertificateConfig, + CloudRunConfig, + Cluster, + ClusterAutoscaling, + ClusterTelemetry, + ClusterUpdate, + CompleteIPRotationRequest, + ConfidentialNodes, + ConfigConnectorConfig, + CreateClusterRequest, + CreateNodePoolRequest, + DailyMaintenanceWindow, + DatabaseEncryption, + DatapathProvider, + DefaultSnatStatus, + DeleteClusterRequest, + DeleteNodePoolRequest, + DnsCacheConfig, + DNSConfig, + EphemeralStorageConfig, + GcePersistentDiskCsiDriverConfig, + GcfsConfig, + GcpFilestoreCsiDriverConfig, + GetClusterRequest, + GetJSONWebKeysRequest, + GetJSONWebKeysResponse, + GetNodePoolRequest, + GetOpenIDConfigRequest, + GetOpenIDConfigResponse, + GetOperationRequest, + GetServerConfigRequest, + GkeBackupAgentConfig, + HorizontalPodAutoscaling, + HttpLoadBalancing, + IdentityServiceConfig, + ILBSubsettingConfig, + IntraNodeVisibilityConfig, + IPAllocationPolicy, + IstioConfig, + Jwk, + KalmConfig, + KubernetesDashboard, + LegacyAbac, + LinuxNodeConfig, + ListClustersRequest, + ListClustersResponse, + ListLocationsRequest, + ListLocationsResponse, + ListNodePoolsRequest, + ListNodePoolsResponse, + ListOperationsRequest, + ListOperationsResponse, + ListUsableSubnetworksRequest, + ListUsableSubnetworksResponse, + Location, + LoggingComponentConfig, + LoggingConfig, + MaintenanceExclusionOptions, + MaintenancePolicy, + MaintenanceWindow, + ManagedPrometheusConfig, + Master, + MasterAuth, + MasterAuthorizedNetworksConfig, + MaxPodsConstraint, + MeshCertificates, + MonitoringComponentConfig, + MonitoringConfig, + NetworkConfig, + NetworkPolicy, + NetworkPolicyConfig, + NetworkTags, + NodeConfig, + NodeConfigDefaults, + NodeKubeletConfig, + NodeLabels, + NodeManagement, + NodeNetworkConfig, + NodePool, + NodePoolAutoscaling, + NodePoolDefaults, + NodeTaint, + NodeTaints, + NotificationConfig, + Operation, + OperationProgress, + PodSecurityPolicyConfig, + PrivateClusterConfig, + PrivateClusterMasterGlobalAccessConfig, + PrivateIPv6GoogleAccess, + RecurringTimeWindow, + ReleaseChannel, + ReservationAffinity, + ResourceLimit, + ResourceUsageExportConfig, + RollbackNodePoolUpgradeRequest, + SandboxConfig, + SecurityBulletinEvent, + ServerConfig, + ServiceExternalIPsConfig, + SetAddonsConfigRequest, + SetLabelsRequest, + SetLegacyAbacRequest, + SetLocationsRequest, + SetLoggingServiceRequest, + SetMaintenancePolicyRequest, + SetMasterAuthRequest, + SetMonitoringServiceRequest, + SetNetworkPolicyRequest, + SetNodePoolAutoscalingRequest, + SetNodePoolManagementRequest, + SetNodePoolSizeRequest, + ShieldedInstanceConfig, + ShieldedNodes, + StartIPRotationRequest, + StatusCondition, + TimeWindow, + TpuConfig, + UpdateClusterRequest, + UpdateMasterRequest, + UpdateNodePoolRequest, + UpgradeAvailableEvent, + UpgradeEvent, + UpgradeResourceType, + UsableSubnetwork, + UsableSubnetworkSecondaryRange, + VerticalPodAutoscaling, + VirtualNIC, + WindowsVersions, + WorkloadCertificates, + WorkloadIdentityConfig, + WorkloadMetadataConfig, +) __all__ = ( "ClusterManagerAsyncClient", diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/__init__.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/__init__.py index da06b070d3ae..8445ce150fbd 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/__init__.py @@ -13,8 +13,8 @@ # See the License for the specific language governing permissions and # limitations under the License. # -from .client import ClusterManagerClient from .async_client import ClusterManagerAsyncClient +from .client import ClusterManagerClient __all__ = ( "ClusterManagerClient", diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/async_client.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/async_client.py index 56bbf343774f..e69ff1c0b222 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/async_client.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/async_client.py @@ -17,27 +17,29 @@ import functools import re from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union -import pkg_resources import warnings -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.rpc import status_pb2 # type: ignore + from google.cloud.container_v1beta1.services.cluster_manager import pagers from google.cloud.container_v1beta1.types import cluster_service -from google.rpc import status_pb2 # type: ignore -from .transports.base import ClusterManagerTransport, DEFAULT_CLIENT_INFO -from .transports.grpc_asyncio import ClusterManagerGrpcAsyncIOTransport + from .client import ClusterManagerClient +from .transports.base import DEFAULT_CLIENT_INFO, ClusterManagerTransport +from .transports.grpc_asyncio import ClusterManagerGrpcAsyncIOTransport class ClusterManagerAsyncClient: diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/client.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/client.py index 1171691ab0d2..50360b33eb9c 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/client.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/client.py @@ -17,7 +17,6 @@ import os import re from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union -import pkg_resources import warnings from google.api_core import client_options as client_options_lib @@ -25,20 +24,23 @@ from google.api_core import gapic_v1 from google.api_core import retry as retries from google.auth import credentials as ga_credentials # type: ignore +from google.auth.exceptions import MutualTLSChannelError # type: ignore from google.auth.transport import mtls # type: ignore from google.auth.transport.grpc import SslCredentials # type: ignore -from google.auth.exceptions import MutualTLSChannelError # 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.rpc import status_pb2 # type: ignore + from google.cloud.container_v1beta1.services.cluster_manager import pagers from google.cloud.container_v1beta1.types import cluster_service -from google.rpc import status_pb2 # type: ignore -from .transports.base import ClusterManagerTransport, DEFAULT_CLIENT_INFO + +from .transports.base import DEFAULT_CLIENT_INFO, ClusterManagerTransport from .transports.grpc import ClusterManagerGrpcTransport from .transports.grpc_asyncio import ClusterManagerGrpcAsyncIOTransport diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/pagers.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/pagers.py index a92dc3ba84cd..44036d873327 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/pagers.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/pagers.py @@ -18,10 +18,10 @@ AsyncIterator, Awaitable, Callable, + Iterator, + Optional, Sequence, Tuple, - Optional, - Iterator, ) from google.cloud.container_v1beta1.types import cluster_service diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/__init__.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/__init__.py index b6375e92a8a4..b794d72c1bc1 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/__init__.py @@ -20,7 +20,6 @@ from .grpc import ClusterManagerGrpcTransport from .grpc_asyncio import ClusterManagerGrpcAsyncIOTransport - # Compile a registry of transports. _transport_registry = OrderedDict() # type: Dict[str, Type[ClusterManagerTransport]] _transport_registry["grpc"] = ClusterManagerGrpcTransport diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/base.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/base.py index e494a6f22d25..2d54204dd86a 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/base.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/base.py @@ -15,18 +15,18 @@ # import abc from typing import Awaitable, Callable, Dict, Optional, Sequence, Union -import pkg_resources -import google.auth # type: ignore import google.api_core from google.api_core import exceptions as core_exceptions from google.api_core import gapic_v1 from google.api_core import retry as retries +import google.auth # type: ignore from google.auth import credentials as ga_credentials # type: ignore from google.oauth2 import service_account # type: ignore +from google.protobuf import empty_pb2 # type: ignore +import pkg_resources from google.cloud.container_v1beta1.types import cluster_service -from google.protobuf import empty_pb2 # type: ignore try: DEFAULT_CLIENT_INFO = gapic_v1.client_info.ClientInfo( diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc.py index 4846d22805e0..311b145bc0ab 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc.py @@ -13,20 +13,19 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import warnings from typing import Callable, Dict, Optional, Sequence, Tuple, Union +import warnings -from google.api_core import grpc_helpers -from google.api_core import gapic_v1 +from google.api_core import gapic_v1, grpc_helpers import google.auth # type: ignore from google.auth import credentials as ga_credentials # type: ignore from google.auth.transport.grpc import SslCredentials # type: ignore - +from google.protobuf import empty_pb2 # type: ignore import grpc # type: ignore from google.cloud.container_v1beta1.types import cluster_service -from google.protobuf import empty_pb2 # type: ignore -from .base import ClusterManagerTransport, DEFAULT_CLIENT_INFO + +from .base import DEFAULT_CLIENT_INFO, ClusterManagerTransport class ClusterManagerGrpcTransport(ClusterManagerTransport): diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc_asyncio.py b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc_asyncio.py index 9ffacb932907..38bc7c68c1cf 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc_asyncio.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/services/cluster_manager/transports/grpc_asyncio.py @@ -13,20 +13,19 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import warnings from typing import Awaitable, Callable, Dict, Optional, Sequence, Tuple, Union +import warnings -from google.api_core import gapic_v1 -from google.api_core import grpc_helpers_async +from google.api_core import gapic_v1, grpc_helpers_async from google.auth import credentials as ga_credentials # type: ignore from google.auth.transport.grpc import SslCredentials # type: ignore - +from google.protobuf import empty_pb2 # type: ignore import grpc # type: ignore from grpc.experimental import aio # type: ignore from google.cloud.container_v1beta1.types import cluster_service -from google.protobuf import empty_pb2 # type: ignore -from .base import ClusterManagerTransport, DEFAULT_CLIENT_INFO + +from .base import DEFAULT_CLIENT_INFO, ClusterManagerTransport from .grpc import ClusterManagerGrpcTransport diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/types/__init__.py b/packages/google-cloud-container/google/cloud/container_v1beta1/types/__init__.py index 085984e1c461..c477bff16f9a 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/types/__init__.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/types/__init__.py @@ -36,6 +36,7 @@ CreateNodePoolRequest, DailyMaintenanceWindow, DatabaseEncryption, + DatapathProvider, DefaultSnatStatus, DeleteClusterRequest, DeleteNodePoolRequest, @@ -111,6 +112,7 @@ PodSecurityPolicyConfig, PrivateClusterConfig, PrivateClusterMasterGlobalAccessConfig, + PrivateIPv6GoogleAccess, RecurringTimeWindow, ReleaseChannel, ReservationAffinity, @@ -144,6 +146,7 @@ UpdateNodePoolRequest, UpgradeAvailableEvent, UpgradeEvent, + UpgradeResourceType, UsableSubnetwork, UsableSubnetworkSecondaryRange, VerticalPodAutoscaling, @@ -152,9 +155,6 @@ WorkloadCertificates, WorkloadIdentityConfig, WorkloadMetadataConfig, - DatapathProvider, - PrivateIPv6GoogleAccess, - UpgradeResourceType, ) __all__ = ( diff --git a/packages/google-cloud-container/google/cloud/container_v1beta1/types/cluster_service.py b/packages/google-cloud-container/google/cloud/container_v1beta1/types/cluster_service.py index 4a70429217c9..542f625c0572 100644 --- a/packages/google-cloud-container/google/cloud/container_v1beta1/types/cluster_service.py +++ b/packages/google-cloud-container/google/cloud/container_v1beta1/types/cluster_service.py @@ -13,14 +13,12 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import proto # type: ignore - from google.protobuf import timestamp_pb2 # type: ignore from google.protobuf import wrappers_pb2 # type: ignore from google.rpc import code_pb2 # type: ignore from google.rpc import status_pb2 # type: ignore from google.type import date_pb2 # type: ignore - +import proto # type: ignore __protobuf__ = proto.module( package="google.container.v1beta1", diff --git a/packages/google-cloud-container/noxfile.py b/packages/google-cloud-container/noxfile.py index 6ee5e8ab96d9..7c1742d2cc93 100644 --- a/packages/google-cloud-container/noxfile.py +++ b/packages/google-cloud-container/noxfile.py @@ -17,6 +17,7 @@ # Generated by synthtool. DO NOT EDIT! from __future__ import absolute_import + import os import pathlib import shutil @@ -25,7 +26,8 @@ import nox BLACK_VERSION = "black==22.3.0" -BLACK_PATHS = ["docs", "google", "tests", "noxfile.py", "setup.py"] +ISORT_VERSION = "isort==5.10.1" +LINT_PATHS = ["docs", "google", "tests", "noxfile.py", "setup.py"] DEFAULT_PYTHON_VERSION = "3.8" @@ -83,7 +85,7 @@ def lint(session): session.run( "black", "--check", - *BLACK_PATHS, + *LINT_PATHS, ) session.run("flake8", "google", "tests") @@ -94,7 +96,27 @@ def blacken(session): session.install(BLACK_VERSION) session.run( "black", - *BLACK_PATHS, + *LINT_PATHS, + ) + + +@nox.session(python=DEFAULT_PYTHON_VERSION) +def format(session): + """ + Run isort to sort imports. Then run black + to format code to uniform standard. + """ + session.install(BLACK_VERSION, ISORT_VERSION) + # Use the --fss option to sort imports using strict alphabetical order. + # See https://pycqa.github.io/isort/docs/configuration/options.html#force-sort-within-sections + session.run( + "isort", + "--fss", + *LINT_PATHS, + ) + session.run( + "black", + *LINT_PATHS, ) diff --git a/packages/google-cloud-container/samples/snippets/create_cluster_test.py b/packages/google-cloud-container/samples/snippets/create_cluster_test.py index 728c07509de6..75a281c96015 100644 --- a/packages/google-cloud-container/samples/snippets/create_cluster_test.py +++ b/packages/google-cloud-container/samples/snippets/create_cluster_test.py @@ -17,9 +17,7 @@ import uuid import backoff - from google.cloud import container_v1 as gke - import pytest import create_cluster as gke_create diff --git a/packages/google-cloud-container/samples/snippets/delete_cluster_test.py b/packages/google-cloud-container/samples/snippets/delete_cluster_test.py index fc7845d3465e..5e187d84de1a 100644 --- a/packages/google-cloud-container/samples/snippets/delete_cluster_test.py +++ b/packages/google-cloud-container/samples/snippets/delete_cluster_test.py @@ -17,10 +17,8 @@ import uuid import backoff - from google.api_core import exceptions as googleEx from google.cloud import container_v1 as gke - import pytest import delete_cluster as gke_delete diff --git a/packages/google-cloud-container/samples/snippets/noxfile.py b/packages/google-cloud-container/samples/snippets/noxfile.py index 25f87a215d4c..3b3ffa5d2b0f 100644 --- a/packages/google-cloud-container/samples/snippets/noxfile.py +++ b/packages/google-cloud-container/samples/snippets/noxfile.py @@ -22,7 +22,6 @@ import nox - # WARNING - WARNING - WARNING - WARNING - WARNING # WARNING - WARNING - WARNING - WARNING - WARNING # DO NOT EDIT THIS FILE EVER! @@ -30,6 +29,7 @@ # WARNING - WARNING - WARNING - WARNING - WARNING BLACK_VERSION = "black==22.3.0" +ISORT_VERSION = "isort==5.10.1" # Copy `noxfile_config.py` to your directory and modify it instead. @@ -168,12 +168,33 @@ def lint(session: nox.sessions.Session) -> None: @nox.session def blacken(session: nox.sessions.Session) -> None: + """Run black. Format code to uniform standard.""" session.install(BLACK_VERSION) python_files = [path for path in os.listdir(".") if path.endswith(".py")] session.run("black", *python_files) +# +# format = isort + black +# + + +@nox.session +def format(session: nox.sessions.Session) -> None: + """ + Run isort to sort imports. Then run black + to format code to uniform standard. + """ + session.install(BLACK_VERSION, ISORT_VERSION) + python_files = [path for path in os.listdir(".") if path.endswith(".py")] + + # Use the --fss option to sort imports using strict alphabetical order. + # See https://pycqa.github.io/isort/docs/configuration/options.html#force-sort-within-sections + session.run("isort", "--fss", *python_files) + session.run("black", *python_files) + + # # Sample Tests # diff --git a/packages/google-cloud-container/setup.py b/packages/google-cloud-container/setup.py index 045f45aaac11..c1d6527ccfba 100644 --- a/packages/google-cloud-container/setup.py +++ b/packages/google-cloud-container/setup.py @@ -17,7 +17,6 @@ import setuptools - # Package metadata. name = "google-cloud-container" diff --git a/packages/google-cloud-container/tests/unit/gapic/container_v1/test_cluster_manager.py b/packages/google-cloud-container/tests/unit/gapic/container_v1/test_cluster_manager.py index fdc5c3e20566..e2df048271ab 100644 --- a/packages/google-cloud-container/tests/unit/gapic/container_v1/test_cluster_manager.py +++ b/packages/google-cloud-container/tests/unit/gapic/container_v1/test_cluster_manager.py @@ -13,35 +13,33 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import os -import mock - -import grpc -from grpc.experimental import aio import math -import pytest -from proto.marshal.rules.dates import DurationRule, TimestampRule - +import os +from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template from google.api_core import client_options from google.api_core import exceptions as core_exceptions -from google.api_core import gapic_v1 -from google.api_core import grpc_helpers -from google.api_core import grpc_helpers_async -from google.api_core import path_template +import google.auth from google.auth import credentials as ga_credentials from google.auth.exceptions import MutualTLSChannelError -from google.cloud.container_v1.services.cluster_manager import ClusterManagerAsyncClient -from google.cloud.container_v1.services.cluster_manager import ClusterManagerClient -from google.cloud.container_v1.services.cluster_manager import pagers -from google.cloud.container_v1.services.cluster_manager import transports -from google.cloud.container_v1.types import cluster_service from google.oauth2 import service_account from google.protobuf import timestamp_pb2 # type: ignore from google.protobuf import wrappers_pb2 # type: ignore from google.rpc import code_pb2 # type: ignore from google.rpc import status_pb2 # type: ignore -import google.auth +import grpc +from grpc.experimental import aio +import mock +from proto.marshal.rules.dates import DurationRule, TimestampRule +import pytest + +from google.cloud.container_v1.services.cluster_manager import ( + ClusterManagerAsyncClient, + ClusterManagerClient, + pagers, + transports, +) +from google.cloud.container_v1.types import cluster_service def client_cert_source_callback(): diff --git a/packages/google-cloud-container/tests/unit/gapic/container_v1beta1/test_cluster_manager.py b/packages/google-cloud-container/tests/unit/gapic/container_v1beta1/test_cluster_manager.py index 5934865f354f..fdf85744497f 100644 --- a/packages/google-cloud-container/tests/unit/gapic/container_v1beta1/test_cluster_manager.py +++ b/packages/google-cloud-container/tests/unit/gapic/container_v1beta1/test_cluster_manager.py @@ -13,37 +13,33 @@ # See the License for the specific language governing permissions and # limitations under the License. # -import os -import mock - -import grpc -from grpc.experimental import aio import math -import pytest -from proto.marshal.rules.dates import DurationRule, TimestampRule - +import os +from google.api_core import gapic_v1, grpc_helpers, grpc_helpers_async, path_template from google.api_core import client_options from google.api_core import exceptions as core_exceptions -from google.api_core import gapic_v1 -from google.api_core import grpc_helpers -from google.api_core import grpc_helpers_async -from google.api_core import path_template +import google.auth from google.auth import credentials as ga_credentials from google.auth.exceptions import MutualTLSChannelError -from google.cloud.container_v1beta1.services.cluster_manager import ( - ClusterManagerAsyncClient, -) -from google.cloud.container_v1beta1.services.cluster_manager import ClusterManagerClient -from google.cloud.container_v1beta1.services.cluster_manager import pagers -from google.cloud.container_v1beta1.services.cluster_manager import transports -from google.cloud.container_v1beta1.types import cluster_service from google.oauth2 import service_account from google.protobuf import timestamp_pb2 # type: ignore from google.protobuf import wrappers_pb2 # type: ignore from google.rpc import code_pb2 # type: ignore from google.rpc import status_pb2 # type: ignore -import google.auth +import grpc +from grpc.experimental import aio +import mock +from proto.marshal.rules.dates import DurationRule, TimestampRule +import pytest + +from google.cloud.container_v1beta1.services.cluster_manager import ( + ClusterManagerAsyncClient, + ClusterManagerClient, + pagers, + transports, +) +from google.cloud.container_v1beta1.types import cluster_service def client_cert_source_callback():