8000 chore: use gapic-generator-python 1.2.0 (#192) · googleapis/google-cloud-python@8b2ee04 · GitHub
[go: up one dir, main page]

Skip to content

Commit 8b2ee04

Browse files
chore: use gapic-generator-python 1.2.0 (#192)
* chore: use gapic-generator-python 1.2.0 PiperOrigin-RevId: 467286830 Source-Link: googleapis/googleapis@e6e875a Source-Link: googleapis/googleapis-gen@0295ea1 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMDI5NWVhMTRkOWNkNGQ0N2RkYjIzYjllYmQzOWEzMWUyMDM1ZTI4ZiJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * remove workarounds in owlbot.py; restore 100% coverge Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Anthonios Partheniou <partheniou@google.com>
1 parent cdea04e commit 8b2ee04

File tree

7 files changed

+29
-44
lines changed

7 files changed

+29
-44
lines changed

packages/google-cloud-gke-hub/.coveragerc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ branch = True
44
[report]
55
show_missing = True
66
omit =
7-
google/cloud/gkehub/multiclusteringress/__init__.py
7+
google/cloud/gkehub/__init__.py
88
exclude_lines =
99
# Re-enable the standard pragma
1010
pragma: NO COVER

packages/google-cloud-gke-hub/.github/workflows/unittest.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,4 +54,4 @@ jobs:
5454
- name: Report coverage results
5555
run: |
5656
coverage combine .coverage-results/.coverage*
57-
coverage report --show-missing --fail-under=99
57+
coverage report --show-missing --fail-under=100

packages/google-cloud-gke-hub/google/cloud/gkehub_v1beta1/services/gke_hub_membership_service/async_client.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1329,9 +1329,11 @@ async def set_iam_policy(
13291329
optionally specify a ``condition``, which is a logic
13301330
expression that further constrains the role binding
13311331
based on attributes about the request and/or target
1332-
resource. JSON Example.
1332+
resource.
13331333
1334-
.. code-block:: python
1334+
**JSON Example**
1335+
1336+
::
13351337
13361338
{
13371339
"bindings": [
@@ -1376,6 +1378,7 @@ async def set_iam_policy(
13761378
description: Does not grant access after Sep 2020
13771379
expression: request.time < timestamp('2020-10-01T00:00:00.000Z')
13781380
1381+
13791382
For a description of IAM and its features, see the `IAM
13801383
developer's
13811384
guide <https://cloud.google.com/iam/docs>`__.
@@ -1448,9 +1451,11 @@ async def get_iam_policy(
14481451
optionally specify a ``condition``, which is a logic
14491452
expression that further constrains the role binding
14501453
based on attributes about the request and/or target
1451-
resource. JSON Example.
1454+
resource.
14521455
1453-
.. code-block:: python
1456+
**JSON Example**
1457+
1458+
::
14541459
14551460
{
14561461
"bindings": [
@@ -1495,6 +1500,7 @@ async def get_iam_policy(
14951500
description: Does not grant access after Sep 2020
14961501
expression: request.time < timestamp('2020-10-01T00:00:00.000Z')
14971502
1503+
14981504
For a description of IAM and its features, see the `IAM
14991505
developer's
15001506
guide <https://cloud.google.com/iam/docs>`__.

packages/google-cloud-gke-hub/google/cloud/gkehub_v1beta1/services/gke_hub_membership_service/client.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1569,9 +1569,11 @@ def set_iam_policy(
15691569
optionally specify a ``condition``, which is a logic
15701570
expression that further constrains the role binding
15711571
based on attributes about the request and/or target
1572-
resource. JSON Example.
1572+
resource.
15731573
1574-
.. code-block:: python
1574+
**JSON Example**
1575+
1576+
::
15751577
15761578
{
15771579
"bindings": [
@@ -1616,6 +1618,7 @@ def set_iam_policy(
16161618
description: Does not grant access after Sep 2020
16171619
expression: request.time < timestamp('2020-10-01T00:00:00.000Z')
16181620
1621+
16191622
For a description of IAM and its features, see the `IAM
16201623
developer's
16211624
guide <https://cloud.google.com/iam/docs>`__.
@@ -1688,9 +1691,11 @@ def get_iam_policy(
16881691
optionally specify a ``condition``, which is a logic
16891692
expression that further constrains the role binding
16901693
based on attributes about the request and/or target
1691-
resource. JSON Example.
1694+
resource.
16921695
1693-
.. code-block:: python
1696+
**JSON Example**
1697+
1698+
::
16941699
16951700
{
16961701
"bindings": [
@@ -1735,6 +1740,7 @@ def get_iam_policy(
17351740
description: Does not grant access after Sep 2020
17361741
expression: request.time < timestamp('2020-10-01T00:00:00.000Z')
17371742
1743+
17381744
For a description of IAM and its features, see the `IAM
17391745
developer's
17401746
guide <https://cloud.google.com/iam/docs>`__.

packages/google-cloud-gke-hub/noxfile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ def cover(session):
265265
test runs (not system test runs), and then erases coverage data.
266266
"""
267267
session.install("coverage", "pytest-cov")
268-
session.run("coverage", "report", "--show-missing", "--fail-under=99")
268+
session.run("coverage", "report", "--show-missing", "--fail-under=100")
269269

270270
session.run("coverage", "erase")
271271

packages/google-cloud-gke-hub/owlbot.py

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -80,33 +80,6 @@
8080
//container.googleapis.com/projects/my-"""
8181
)
8282

83-
# work around issues with docstrings
84-
s.replace(
85-
library / "google/cloud/**/*.py",
86-
"""resource.
87-
\*\*JSON Example\*\*
88-
::""",
89-
"""resource. JSON Example.
90-
91-
.. code-block:: python\n""",
92-
)
93-
94-
s.replace(
95-
library / "google/cloud/**/*.py",
96-
"""\*\*YAML Example\*\*
97-
::""",
98-
"""\n **YAML Example**
99-
100-
::\n""",
101-
)
102-
103-
s.replace(library / "google/cloud/**/*.py",
104-
""" For a description of IAM and its features, see the `IAM
105-
developer's""",
106-
"""\n For a description of IAM and its features, see the `IAM
107-
developer's"""
108-
)
109-
11083
excludes=[
11184
"setup.py",
11285
"README.rst",
@@ -166,7 +139,7 @@
166139
# Add templated files
167140
# ----------------------------------------------------------------------------
168141

169-
templated_files = common.py_library(cov_level=99, microgenerator=True)
142+
templated_files = common.py_library(microgenerator=True)
170143
python.py_samples(skip_readmes=True)
171144

172145
# the microgenerator has a good coveragerc file

packages/google-cloud-gke-hub/tests/unit/gapic/gkehub_v1beta1/test_gke_hub_membership_service.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3371,7 +3371,7 @@ def test_delete_operation(transport: str = "grpc"):
33713371

33723372

33733373
@pytest.mark.asyncio
3374-
async def test_delete_operation(transport: str = "grpc"):
3374+
async def test_delete_operation_async(transport: str = "grpc"):
33753375
client = GkeHubMembershipServiceAsyncClient(
33763376
credentials=ga_credentials.AnonymousCredentials(),
33773377
transport=transport,
@@ -3510,7 +3510,7 @@ def test_cancel_operation(transport: str = "grpc"):
35103510

35113511

35123512
@pytest.mark.asyncio
3513-
async def test_cancel_operation(transport: str = "grpc"):
3513+
async def test_cancel_operation_async(transport: str = "grpc"):
35143514
client = GkeHubMembershipServiceAsyncClient(
35153515
credentials=ga_credentials.AnonymousCredentials(),
35163516
transport=transport,
@@ -3649,7 +3649,7 @@ def test_get_operation(transport: str = "grpc"):
36493649

36503650

36513651
@pytest.mark.asyncio
3652-
async def test_get_operation(transport: str = "grpc"):
3652+
async def test_get_operation_async(transport: str = "grpc"):
36533653
client = GkeHubMembershipServiceAsyncClient(
36543654
credentials=ga_credentials.AnonymousCredentials(),
36553655
transport=transport,
@@ -3794,7 +3794,7 @@ def test_list_operations(transport: str = "grpc"):
37943794

37953795

37963796
@pytest.mark.asyncio
3797-
async def test_list_operations(transport: str = "grpc"):
3797+
async def test_list_operations_async(transport: str = "grpc"):
37983798
client = GkeHubMembershipServiceAsyncClient(
37993799
credentials=ga_credentials.AnonymousCredentials(),
38003800
transport=transport,
@@ -3939,7 +3939,7 @@ def test_list_locations(transport: str = "grpc"):
39393939

39403940

39413941
@pytest.mark.asyncio
3942-
async def test_list_locations(transport: str = "grpc"):
3942+
async def test_list_locations_async(transport: str = "grpc"):
39433943
client = GkeHubMembershipServiceAsyncClient(
39443944
credentials=ga_credentials.AnonymousCredentials(),
39453945
transport=transport,

0 commit comments

Comments
 (0)
0