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

Commit 7d3a0c6

Browse files
chore(python): add nox session to sort python imports (#99)
Source-Link: googleapis/synthtool@1b71c10 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:00c9d764fd1cd56265f12a5ef4b99a0c9e87cf261018099141e2ca5158890416 Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 30aedc9 commit 7d3a0c6

File tree

15 files changed

+121
-99
lines changed

15 files changed

+121
-99
lines changed

.github/.OwlBot.lock.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,5 @@
1313
# limitations under the License.
1414
docker:
1515
image: gcr.io/cloud-devrel-public-resources/owlbot-python:latest
16-
digest: sha256:8a5d3f6a2e43ed8293f34e06a2f56931d1e88a2694c3bb11b15df4eb256ad163
17-
# created: 2022-04-06T10:30:21.687684602Z
16+
digest: sha256:00c9d764fd1cd56265f12a5ef4b99a0c9e87cf261018099141e2ca5158890416
17+
# created: 2022-04-20T23:42:53.970438194Z

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@
2424
# All configuration values have a default; values that are commented out
2525
# serve to show the default.
2626

27-
import sys
2827
import os
2928
import shlex
29+
import sys
3030

3131
# If extensions (or modules to document with autodoc) are in another directory,
3232
# add these directories to sys.path here. If the directory is relative to the

google/cloud/shell/__init__.py

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -14,31 +14,32 @@
1414
# limitations under the License.
1515
#
1616

17+
from google.cloud.shell_v1.services.cloud_shell_service.async_client import (
18+
CloudShellServiceAsyncClient,
19+
)
1720
from google.cloud.shell_v1.services.cloud_shell_service.client import (
1821
CloudShellServiceClient,
1922
)
20-
from google.cloud.shell_v1.services.cloud_shell_service.async_client import (
21-
CloudShellServiceAsyncClient,
23+
from google.cloud.shell_v1.types.cloudshell import (
24+
AddPublicKeyMetadata,
25+
AddPublicKeyRequest,
26+
AddPublicKeyResponse,
27+
AuthorizeEnvironmentMetadata,
28+
AuthorizeEnvironmentRequest,
29+
AuthorizeEnvironmentResponse,
30+
CloudShellErrorDetails,
31+
CreateEnvironmentMetadata,
32+
DeleteEnvironmentMetadata,
33+
Environment,
34+
GetEnvironmentRequest,
35+
RemovePublicKeyMetadata,
36+
RemovePublicKeyRequest,
37+
RemovePublicKeyResponse,
38+
StartEnvironmentMetadata,
39+
StartEnvironmentRequest,
40+
StartEnvironmentResponse,
2241
)
2342

24-
from google.cloud.shell_v1.types.cloudshell import AddPublicKeyMetadata
25-
from google.cloud.shell_v1.types.cloudshell import AddPublicKeyRequest
26-
from google.cloud.shell_v1.types.cloudshell import AddPublicKeyResponse
27-
from google.cloud.shell_v1.types.cloudshell import AuthorizeEnvironmentMetadata
28-
from google.cloud.shell_v1.types.cloudshell import AuthorizeEnvironmentRequest
29-
from google.cloud.shell_v1.types.cloudshell import AuthorizeEnvironmentResponse
30-
from google.cloud.shell_v1.types.cloudshell import CloudShellErrorDetails
31-
from google.cloud.shell_v1.types.cloudshell import CreateEnvironmentMetadata
32-
from google.cloud.shell_v1.types.cloudshell import DeleteEnvironmentMetadata
33-
from google.cloud.shell_v1.types.cloudshell import Environment
34-
from google.cloud.shell_v1.types.cloudshell import GetEnvironmentRequest
35-
from google.cloud.shell_v1.types.cloudshell import RemovePublicKeyMetadata
36-
from google.cloud.shell_v1.types.cloudshell import RemovePublicKeyRequest
37-
from google.cloud.shell_v1.types.cloudshell import RemovePublicKeyResponse
38-
from google.cloud.shell_v1.types.cloudshell import StartEnvironmentMetadata
39-
from google.cloud.shell_v1.types.cloudshell import StartEnvironmentRequest
40-
from google.cloud.shell_v1.types.cloudshell import StartEnvironmentResponse
41-
4243
__all__ = (
4344
"CloudShellServiceClient",
4445
"CloudShellServiceAsyncClient",

google/cloud/shell_v1/__init__.py

Lines changed: 23 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -14,26 +14,29 @@
1414
# limitations under the License.
1515
#
1616

17-
from .services.cloud_shell_service import CloudShellServiceClient
18-
from .services.cloud_shell_service import CloudShellServiceAsyncClient
19-
20-
from .types.cloudshell import AddPublicKeyMetadata
21-
from .types.cloudshell import AddPublicKeyRequest
22-
from .types.cloudshell import AddPublicKeyResponse
23-
from .types.cloudshell import AuthorizeEnvironmentMetadata
24-
from .types.cloudshell import AuthorizeEnvironmentRequest
25-
from .types.cloudshell import AuthorizeEnvironmentResponse
26-
from .types.cloudshell import CloudShellErrorDetails
27-
from .types.cloudshell import CreateEnvironmentMetadata
28-
from .types.cloudshell import DeleteEnvironmentMetadata
29-
from .types.cloudshell import Environment
30-
from .types.cloudshell import GetEnvironmentRequest
31-
from .types.cloudshell import RemovePublicKeyMetadata
32-
from .types.cloudshell import RemovePublicKeyRequest
33-
from .types.cloudshell import RemovePublicKeyResponse
34-
from .types.cloudshell import StartEnvironmentMetadata
35-
from .types.cloudshell import StartEnvironmentRequest
36-
from .types.cloudshell import StartEnvironmentResponse
17+
from .services.cloud_shell_service import (
18+
CloudShellServiceAsyncClient,
19+
CloudShellServiceClient,
20+
)
21+
from .types.cloudshell import (
22+
AddPublicKeyMetadata,
23+
AddPublicKeyRequest,
24+
AddPublicKeyResponse,
25+
AuthorizeEnvironmentMetadata,
26+
AuthorizeEnvironmentRequest,
27+
AuthorizeEnvironmentResponse,
28+
CloudShellErrorDetails,
29+
CreateEnvironmentMetadata,
30+
DeleteEnvironmentMetadata,
31+
Environment,
32+
GetEnvironmentRequest,
33+
RemovePublicKeyMetadata,
34+
RemovePublicKeyRequest,
35+
RemovePublicKeyResponse,
36+
StartEnvironmentMetadata,
37+
StartEnvironmentRequest,
38+
StartEnvironmentResponse,
39+
)
3740

3841
__all__ = (
3942
"CloudShellServiceAsyncClient",

google/cloud/shell_v1/services/cloud_shell_service/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
from .client import CloudShellServiceClient
1716
from .async_client import CloudShellServiceAsyncClient
17+
from .client import CloudShellServiceClient
1818

1919
__all__ = (
2020
"CloudShellServiceClient",

google/cloud/shell_v1/services/cloud_shell_service/async_client.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@
1717
import functools
1818
import re
1919
from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union
20-
import pkg_resources
2120

22-
from google.api_core.client_options import ClientOptions
2321
from google.api_core import exceptions as core_exceptions
2422
from google.api_core import gapic_v1
2523
from google.api_core import retry as retries
24+
from google.api_core.client_options import ClientOptions
2625
from google.auth import credentials as ga_credentials # type: ignore
2726
from google.oauth2 import service_account # type: ignore
27+
import pkg_resources
2828

2929
try:
3030
OptionalRetry = Union[retries.Retry, gapic_v1.method._MethodDefault]
@@ -33,10 +33,12 @@
3333

3434
from google.api_core import operation # type: ignore
3535
from google.api_core import operation_async # type: ignore
36+
3637
from google.cloud.shell_v1.types import cloudshell
37-
from .transports.base import CloudShellServiceTransport, DEFAULT_CLIENT_INFO
38-
from .transports.grpc_asyncio import CloudShellServiceGrpcAsyncIOTransport
38+
3939
from .client import CloudShellServiceClient
40+
from .transports.base import DEFAULT_CLIENT_INFO, CloudShellServiceTransport
41+
from .transports.grpc_asyncio import CloudShellServiceGrpcAsyncIOTransport
4042

4143

4244
class CloudShellServiceAsyncClient:

google/cloud/shell_v1/services/cloud_shell_service/client.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,17 @@
1717
import os
1818
import re
1919
from typing import Dict, Mapping, Optional, Sequence, Tuple, Type, Union
20-
import pkg_resources
2120

2221
from google.api_core import client_options as client_options_lib
2322
from google.api_core import exceptions as core_exceptions
2423
from google.api_core import gapic_v1
2524
from google.api_core import retry as retries
2625
from google.auth import credentials as ga_credentials # type: ignore
26+
from google.auth.exceptions import MutualTLSChannelError # type: ignore
2727
from google.auth.transport import mtls # type: ignore
2828
from google.auth.transport.grpc import SslCredentials # type: ignore
29-
from google.auth.exceptions import MutualTLSChannelError # type: ignore
3029
from google.oauth2 import service_account # type: ignore
30+
import pkg_resources
3131

3232
try:
3333
OptionalRetry = Union[retries.Retry, gapic_v1.method._MethodDefault]
@@ -36,8 +36,10 @@
3636

3737
from google.api_core import operation # type: ignore
3838
from google.api_core import operation_async # type: ignore
39+
3940
from google.cloud.shell_v1.types import cloudshell
40-
from .transports.base import CloudShellServiceTransport, DEFAULT_CLIENT_INFO
41+
42+
from .transports.base import DEFAULT_CLIENT_INFO, CloudShellServiceTransport
4143
from .transports.grpc import CloudShellServiceGrpcTransport
4244
from .transports.grpc_asyncio import CloudShellServiceGrpcAsyncIOTransport
4345

google/cloud/shell_v1/services/cloud_shell_service/transports/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020
from .grpc import CloudShellServiceGrpcTransport
2121
from .grpc_asyncio import CloudShellServiceGrpcAsyncIOTransport
2222

23-
2423
# Compile a registry of transports.
2524
_transport_registry = OrderedDict() # type: Dict[str, Type[CloudShellServiceTransport]]
2625
_transport_registry["grpc"] = CloudShellServiceGrpcTransport

google/cloud/shell_v1/services/cloud_shell_service/transports/base.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,18 @@
1515
#
1616
import abc
1717
from typing import Awaitable, Callable, Dict, Optional, Sequence, Union
18-
import pkg_resources
1918

20-
import google.auth # type: ignore
2119
import google.api_core
2220
from google.api_core import exceptions as core_exceptions
23-
from google.api_core import gapic_v1
21+
from google.api_core import gapic_v1, operations_v1
2422
from google.api_core import retry as retries
25-
from google.api_core import operations_v1
23+
import google.auth # type: ignore
2624
from google.auth import credentials as ga_credentials # type: ignore
25+
from google.longrunning import operations_pb2 # type: ignore
2726
from google.oauth2 import service_account # type: ignore
27+
import pkg_resources
2828

2929
from google.cloud.shell_v1.types import cloudshell
30-
from google.longrunning import operations_pb2 # type: ignore
3130

3231
try:
3332
DEFAULT_CLIENT_INFO = gapic_v1.client_info.ClientInfo(

google/cloud/shell_v1/services/cloud_shell_service/transports/grpc.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,19 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515
#
16-
import warnings
1716
from typing import Callable, Dict, Optional, Sequence, Tuple, Union
17+
import warnings
1818

19-
from google.api_core import grpc_helpers
20-
from google.api_core import operations_v1
21-
from google.api_core import gapic_v1
19+
from google.api_core import gapic_v1, grpc_helpers, operations_v1
2220
import google.auth # type: ignore
2321
from google.auth import credentials as ga_credentials # type: ignore
2422
from google.auth.transport.grpc import SslCredentials # type: ignore
25-
23+
from google.longrunning import operations_pb2 # type: ignore
2624
import grpc # type: ignore
2725

2826
from google.cloud.shell_v1.types import cloudshell
29-
from google.longrunning import operations_pb2 # type: ignore
30-
from .base import CloudShellServiceTransport, DEFAULT_CLIENT_INFO
27+
28+
from .base import DEFAULT_CLIENT_INFO, CloudShellServiceTransport
3129

3230

3331
class CloudShellServiceGrpcTransport(CloudShellServiceTransport):

0 commit comments

Comments
 (0)