Skip to content

Commit dc6d4f7

Browse files
achew22vchudnov-gparthea
authored
fix: missing DEFAULT_HOST should still result in compiling code (#2051)
Co-authored-by: Victor Chudnovsky <[email protected]> Co-authored-by: Anthonios Partheniou <[email protected]>
1 parent 868f201 commit dc6d4f7

File tree

12 files changed

+12
-1
lines changed
  • gapic/templates/%namespace/%name_%version/%sub/services/%service/transports
  • tests/integration/goldens
    • asset/google/cloud/asset_v1/services/asset_service/transports
    • credentials/google/iam/credentials_v1/services/iam_credentials/transports
    • eventarc/google/cloud/eventarc_v1/services/eventarc/transports
    • logging/google/cloud/logging_v2/services
      • config_service_v2/transports
      • logging_service_v2/transports
      • metrics_service_v2/transports
    • logging_internal/google/cloud/logging_v2/services
      • config_service_v2/transports
      • logging_service_v2/transports
      • metrics_service_v2/transports
    • redis/google/cloud/redis_v1/services/cloud_redis/transports
    • redis_selective/google/cloud/redis_v1/services/cloud_redis/transports

12 files changed

+12
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ class {{ service.name }}Transport(abc.ABC):
6161
{% endfor %}
6262
)
6363

64-
DEFAULT_HOST: str = {% if service.host %}'{{ service.host }}'{% else %}{{ '' }}{% endif %}
64+
DEFAULT_HOST: str = '{% if service.host %}{{ service.host }}{% endif %}'
6565

6666
def __init__(
6767
self, *,

tests/integration/goldens/asset/google/cloud/asset_v1/services/asset_service/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ class AssetServiceTransport(abc.ABC):
4242
)
4343

4444
DEFAULT_HOST: str = 'cloudasset.googleapis.com'
45+
4546
def __init__(
4647
self, *,
4748
host: str = DEFAULT_HOST,

tests/integration/goldens/credentials/google/iam/credentials_v1/services/iam_credentials/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ class IAMCredentialsTransport(abc.ABC):
3939
)
4040

4141
DEFAULT_HOST: str = 'iamcredentials.googleapis.com'
42+
4243
def __init__(
4344
self, *,
4445
host: str = DEFAULT_HOST,

tests/integration/goldens/eventarc/google/cloud/eventarc_v1/services/eventarc/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ class EventarcTransport(abc.ABC):
5050
)
5151

5252
DEFAULT_HOST: str = 'eventarc.googleapis.com'
53+
5354
def __init__(
5455
self, *,
5556
host: str = DEFAULT_HOST,

tests/integration/goldens/logging/google/cloud/logging_v2/services/config_service_v2/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class ConfigServiceV2Transport(abc.ABC):
4545
)
4646

4747
DEFAULT_HOST: str = 'logging.googleapis.com'
48+
4849
def __init__(
4950
self, *,
5051
host: str = DEFAULT_HOST,

tests/integration/goldens/logging/google/cloud/logging_v2/services/logging_service_v2/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class LoggingServiceV2Transport(abc.ABC):
4545
)
4646

4747
DEFAULT_HOST: str = 'logging.googleapis.com'
48+
4849
def __init__(
4950
self, *,
5051
host: str = DEFAULT_HOST,

tests/integration/goldens/logging/google/cloud/logging_v2/services/metrics_service_v2/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class MetricsServiceV2Transport(abc.ABC):
4545
)
4646

4747
DEFAULT_HOST: str = 'logging.googleapis.com'
48+
4849
def __init__(
4950
self, *,
5051
host: str = DEFAULT_HOST,

tests/integration/goldens/logging_internal/google/cloud/logging_v2/services/config_service_v2/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class ConfigServiceV2Transport(abc.ABC):
4545
)
4646

4747
DEFAULT_HOST: str = 'logging.googleapis.com'
48+
4849
def __init__(
4950
self, *,
5051
host: str = DEFAULT_HOST,

tests/integration/goldens/logging_internal/google/cloud/logging_v2/services/logging_service_v2/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class LoggingServiceV2Transport(abc.ABC):
4545
)
4646

4747
DEFAULT_HOST: str = 'logging.googleapis.com'
48+
4849
def __init__(
4950
self, *,
5051
host: str = DEFAULT_HOST,

tests/integration/goldens/logging_internal/google/cloud/logging_v2/services/metrics_service_v2/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ class MetricsServiceV2Transport(abc.ABC):
4545
)
4646

4747
DEFAULT_HOST: str = 'logging.googleapis.com'
48+
4849
def __init__(
4950
self, *,
5051
host: str = DEFAULT_HOST,

tests/integration/goldens/redis/google/cloud/redis_v1/services/cloud_redis/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ class CloudRedisTransport(abc.ABC):
4242
)
4343

4444
DEFAULT_HOST: str = 'redis.googleapis.com'
45+
4546
def __init__(
4647
self, *,
4748
host: str = DEFAULT_HOST,

tests/integration/goldens/redis_selective/google/cloud/redis_v1/services/cloud_redis/transports/base.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ class CloudRedisTransport(abc.ABC):
4242
)
4343

4444
DEFAULT_HOST: str = 'redis.googleapis.com'
45+
4546
def __init__(
4647
self, *,
4748
host: str = DEFAULT_HOST,

0 commit comments

Comments
 (0)