From 74ed955cfad96da440bac3acec773f8cb23a89bf Mon Sep 17 00:00:00 2001 From: yoshi-automation Date: Tue, 23 Apr 2019 05:32:43 -0700 Subject: [PATCH 1/3] [CHANGE ME] Re-generated translate to pick up changes in the API or client library generator. --- .../gapic/translation_service_client.py | 14 +++++++------- translate/noxfile.py | 5 ++--- translate/synth.metadata | 14 +++++++------- 3 files changed, 16 insertions(+), 17 deletions(-) diff --git a/translate/google/cloud/translate_v3beta1/gapic/translation_service_client.py b/translate/google/cloud/translate_v3beta1/gapic/translation_service_client.py index 5977262b3f35..f90d86a77d22 100644 --- a/translate/google/cloud/translate_v3beta1/gapic/translation_service_client.py +++ b/translate/google/cloud/translate_v3beta1/gapic/translation_service_client.py @@ -76,22 +76,22 @@ def from_service_account_file(cls, filename, *args, **kwargs): from_service_account_json = from_service_account_file @classmethod - def location_path(cls, project, location): - """Return a fully-qualified location string.""" + def glossary_path(cls, project, location, glossary): + """Return a fully-qualified glossary string.""" return google.api_core.path_template.expand( - "projects/{project}/locations/{location}", + "projects/{project}/locations/{location}/glossaries/{glossary}", project=project, location=location, + glossary=glossary, ) @classmethod - def glossary_path(cls, project, location, glossary): - """Return a fully-qualified glossary string.""" + def location_path(cls, project, location): + """Return a fully-qualified location string.""" return google.api_core.path_template.expand( - "projects/{project}/locations/{location}/glossaries/{glossary}", + "projects/{project}/locations/{location}", project=project, location=location, - glossary=glossary, ) def __init__( diff --git a/translate/noxfile.py b/translate/noxfile.py index 755db8e2ec41..5d53dea0d25c 100644 --- a/translate/noxfile.py +++ b/translate/noxfile.py @@ -140,12 +140,11 @@ def cover(session): session.run("coverage", "erase") -@nox.session(python='3.6') +@nox.session(python="3.7") def docs(session): - """Build the docs.""" + """Build the docs for this library.""" session.install('sphinx', 'alabaster', 'recommonmark') - session.install('-e', '.') shutil.rmtree(os.path.join('docs', '_build'), ignore_errors=True) session.run( diff --git a/translate/synth.metadata b/translate/synth.metadata index d4194a55308a..e6453c7c4b72 100644 --- a/translate/synth.metadata +++ b/translate/synth.metadata @@ -1,26 +1,26 @@ { - "updateTime": "2019-04-08T22:42:12.391231Z", + "updateTime": "2019-04-23T12:32:43.079835Z", "sources": [ { "generator": { "name": "artman", - "version": "0.16.25", - "dockerImage": "googleapis/artman@sha256:d9597f983d1d4e61272c63cb97b7d8f8234da9999526c35d357de3d781f0ec1b" + "version": "0.17.0", + "dockerImage": "googleapis/artman@sha256:c58f4ec3838eb4e0718eb1bccc6512bd6850feaa85a360a9e38f6f848ec73bc2" } }, { "git": { "name": "googleapis", - "remote": "git@github.com:googleapis/googleapis.git", - "sha": "9a02c5acecb43f38fae4fa52c6420f21c335b888", - "internalRef": "242170119" + "remote": "https://github.com/googleapis/googleapis.git", + "sha": "547e19e7df398e9290e8e3674d7351efc500f9b0", + "internalRef": "244712781" } }, { "template": { "name": "python_library", "origin": "synthtool.gcp", - "version": "2019.2.26" + "version": "2019.4.10" } } ], From 848e82e4fff19b39c87f2ece253b51db57a24f1e Mon Sep 17 00:00:00 2001 From: Bu Sun Kim Date: Tue, 30 Apr 2019 13:00:25 -0700 Subject: [PATCH 2/3] Update noxfile.py and synth.py to support separate docs build. --- translate/noxfile.py | 1 + translate/synth.py | 1 + 2 files changed, 2 insertions(+) diff --git a/translate/noxfile.py b/translate/noxfile.py index 5d53dea0d25c..02b58e16335a 100644 --- a/translate/noxfile.py +++ b/translate/noxfile.py @@ -144,6 +144,7 @@ def cover(session): def docs(session): """Build the docs for this library.""" + session.install('.e', '.') session.install('sphinx', 'alabaster', 'recommonmark') shutil.rmtree(os.path.join('docs', '_build'), ignore_errors=True) diff --git a/translate/synth.py b/translate/synth.py index 553d4a9d7479..37ef0f24849a 100644 --- a/translate/synth.py +++ b/translate/synth.py @@ -38,6 +38,7 @@ s.move(library / f'google/cloud/translate_{version}', excludes=excludes) s.move(library / 'tests') s.move(library / f"docs/gapic/{version}") + s.move(library / "docs/conf.py") # translation -> translate s.replace( From d1dcd0702155a04fbd07d89885e316c890fd6547 Mon Sep 17 00:00:00 2001 From: Bu Sun Kim Date: Tue, 30 Apr 2019 13:24:00 -0700 Subject: [PATCH 3/3] Fix noxfile.py --- translate/noxfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/translate/noxfile.py b/translate/noxfile.py index 02b58e16335a..6ee03ef540e0 100644 --- a/translate/noxfile.py +++ b/translate/noxfile.py @@ -144,7 +144,7 @@ def cover(session): def docs(session): """Build the docs for this library.""" - session.install('.e', '.') + session.install('-e', '.') session.install('sphinx', 'alabaster', 'recommonmark') shutil.rmtree(os.path.join('docs', '_build'), ignore_errors=True)