Skip to content

Commit cb81bd7

Browse files
committed
address feedback
1 parent a90dad5 commit cb81bd7

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

gapic/templates/%namespace/%name_%version/%sub/__init__.py.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ if hasattr(api_core, "check_python_version") and hasattr(api_core, "check_depend
5353
{# TODO(api_core): remove `type:ignore` below when minimum version of api_core makes the else clause unnecessary. #}
5454
api_core.check_python_version("{{package_path}}") # type: ignore
5555
api_core.check_dependency_versions("{{package_path}}") # type: ignore
56-
{# Add `# pragma: NO COVER` to keep `# pragma: NO COVER` on the same line #}
56+
{# Add `# fmt: skip` to keep `# pragma: NO COVER` on the same line #}
5757
else: # pragma: NO COVER # fmt: skip
5858
{# TODO(api_core): Remove this try-catch when we require api-core at a version that
5959
supports the changes in https://github.com/googleapis/python-api-core/pull/832

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -731,6 +731,7 @@ class {{ service.async_client_name }}:
731731

732732
DEFAULT_CLIENT_INFO = gapic_v1.client_info.ClientInfo(gapic_version=package_version.__version__)
733733

734+
{# Add `# fmt: skip` to keep `# pragma: NO COVER` on the same line #}
734735
if hasattr(DEFAULT_CLIENT_INFO, "protobuf_runtime_version"): # pragma: NO COVER # fmt: skip
735736
DEFAULT_CLIENT_INFO.protobuf_runtime_version = google.protobuf.__version__
736737

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ class {{ service.client_name }}Meta(type):
106106
_transport_registry["rest"] = {{ service.name }}RestTransport
107107
{# TODO(https://github.com/googleapis/gapic-generator-python/issues/2121): Remove this condition when async rest is GA. #}
108108
{% if rest_async_io_enabled %}
109+
{# Add `# fmt: skip` to keep `# pragma: NO COVER` on the same line #}
109110
if HAS_ASYNC_REST_DEPENDENCIES: # pragma: NO COVER # fmt: skip
110111
_transport_registry["rest_asyncio"] = Async{{ service.name }}RestTransport
111112
{% endif %}{# if rest_async_io_enabled #}
@@ -199,6 +200,7 @@ class {{ service.client_name }}(metaclass={{ service.client_name }}Meta):
199200
GOOGLE_API_USE_CLIENT_CERTIFICATE is set to an unexpected value.)
200201
"""
201202
# check if google-auth version supports should_use_client_cert for automatic mTLS enablement
203+
{# Add `# fmt: skip` to keep `# pragma: NO COVER` on the same line #}
202204
if hasattr(mtls, "should_use_client_cert"): # pragma: NO COVER # fmt: skip
203205
return mtls.should_use_client_cert()
204206
else: # pragma: NO COVER

0 commit comments

Comments
 (0)