Skip to content
This repository was archived by the owner on Mar 26, 2026. It is now read-only.

Commit 0d03d92

Browse files
committed
style: reorder imports to follow PEP 8 guidelines
1 parent f3599a3 commit 0d03d92

File tree

4 files changed

+9
-6
lines changed

4 files changed

+9
-6
lines changed

gapic/ads-templates/%namespace/%name/%version/%sub/services/%service/transports/rest.py.j2

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,13 @@ from google.iam.v1 import policy_pb2 # type: ignore
3333
from google.cloud.location import locations_pb2 # type: ignore
3434
{% endif %}
3535

36-
from requests import __version__ as requests_version
37-
from urllib.parse import urlencode
3836
import dataclasses
3937
from typing import Any, Callable, Dict, List, Optional, Sequence, Tuple, Union
38+
from urllib.parse import urlencode
4039
import warnings
4140

41+
from requests import __version__ as requests_version
42+
4243
{{ shared_macros.operations_mixin_imports(api, service, opts) }}
4344

4445
from .rest_base import _Base{{ service.name }}RestTransport

gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/rest.py.j2

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,13 @@ from google.iam.v1 import policy_pb2 # type: ignore
2727
from google.cloud.location import locations_pb2 # type: ignore
2828
{% endif %}
2929

30-
from requests import __version__ as requests_version
31-
from urllib.parse import urlencode
3230
import dataclasses
3331
from typing import Any, Callable, Dict, List, Optional, Sequence, Tuple, Union
32+
from urllib.parse import urlencode
3433
import warnings
3534

35+
from requests import __version__ as requests_version
36+
3637
{{ shared_macros.operations_mixin_imports(api, service, opts) }}
3738

3839
from .rest_base import _Base{{ service.name }}RestTransport

gapic/templates/%namespace/%name_%version/%sub/services/%service/transports/rest_asyncio.py.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ from google.iam.v1 import policy_pb2 # type: ignore
4848
from google.cloud.location import locations_pb2 # type: ignore
4949
{% endif %}
5050

51-
import json # type: ignore
5251
import dataclasses
52+
import json # type: ignore
5353
from typing import Any, Dict, List, Callable, Tuple, Optional, Sequence, Union
5454
from urllib.parse import urlencode
5555

gapic/templates/tests/unit/gapic/%name_%version/%sub/test_%service.py.j2

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@ import grpc
2121
from grpc.experimental import aio
2222
{% if "rest" in opts.transport %}
2323
from collections.abc import Iterable, AsyncIterable
24-
from google.protobuf import json_format
2524
import urllib.parse
25+
26+
from google.protobuf import json_format
2627
{% endif %}
2728
import json
2829
import math

0 commit comments

Comments
 (0)