From 93447967e8b6b89d954b37e5637c8c6ad22a6640 Mon Sep 17 00:00:00 2001 From: Bu Sun Kim Date: Mon, 5 Oct 2020 23:45:00 +0000 Subject: [PATCH 1/5] fix: re-add py sessions to noxfile --- noxfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/noxfile.py b/noxfile.py index b203d2e28c..0e83aab566 100644 --- a/noxfile.py +++ b/noxfile.py @@ -26,9 +26,9 @@ BLACK_VERSION = "black==19.10b0" BLACK_PATHS = ["docs", "google", "tests", "noxfile.py", "setup.py"] -DEFAULT_PYTHON_VERSION = "" -SYSTEM_TEST_PYTHON_VERSIONS = [] -UNIT_TEST_PYTHON_VERSIONS = [] +DEFAULT_PYTHON_VERSION = "3.8" +SYSTEM_TEST_PYTHON_VERSIONS = ["3.8"] +UNIT_TEST_PYTHON_VERSIONS = ["3.6", "3.7", "3.8"] @nox.session(python=DEFAULT_PYTHON_VERSION) From 4642de1c21b83252ca69b4d62ecd6db1b0899296 Mon Sep 17 00:00:00 2001 From: Vinny Senthil Date: Fri, 9 Oct 2020 14:11:51 -0700 Subject: [PATCH 2/5] Add pytest to requirements.txt from PR #11 --- samples/requirements.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/samples/requirements.txt b/samples/requirements.txt index e69de29bb2..fcd7031d0e 100644 --- a/samples/requirements.txt +++ b/samples/requirements.txt @@ -0,0 +1,3 @@ +pytest==6.0.1 +# TODO (vinnysenthil): Replace Github library src with PyPi package name (google-cloud-aiplatform) +git+git://github.com/googleapis/python-aiplatform.git@dc5e5cdb3844622bf6dfecbda6e0857b8a228a8d \ No newline at end of file From 34829a67352fe1b6386e4f7d26dd64ba34d96f10 Mon Sep 17 00:00:00 2001 From: Bu Sun Kim Date: Mon, 19 Oct 2020 21:32:57 +0000 Subject: [PATCH 3/5] chore: move tests, fix lint --- google/cloud/aiplatform/__init__.py | 2 -- noxfile.py | 2 +- synth.py | 3 +++ .../unit/{aiplatform_v1beta1 => gapic}/test_dataset_service.py | 0 .../{aiplatform_v1beta1 => gapic}/test_endpoint_service.py | 0 tests/unit/{aiplatform_v1beta1 => gapic}/test_job_service.py | 0 tests/unit/{aiplatform_v1beta1 => gapic}/test_model_service.py | 0 .../{aiplatform_v1beta1 => gapic}/test_pipeline_service.py | 0 .../{aiplatform_v1beta1 => gapic}/test_prediction_service.py | 0 .../test_specialist_pool_service.py | 0 10 files changed, 4 insertions(+), 3 deletions(-) rename tests/unit/{aiplatform_v1beta1 => gapic}/test_dataset_service.py (100%) rename tests/unit/{aiplatform_v1beta1 => gapic}/test_endpoint_service.py (100%) rename tests/unit/{aiplatform_v1beta1 => gapic}/test_job_service.py (100%) rename tests/unit/{aiplatform_v1beta1 => gapic}/test_model_service.py (100%) rename tests/unit/{aiplatform_v1beta1 => gapic}/test_pipeline_service.py (100%) rename tests/unit/{aiplatform_v1beta1 => gapic}/test_prediction_service.py (100%) rename tests/unit/{aiplatform_v1beta1 => gapic}/test_specialist_pool_service.py (100%) diff --git a/google/cloud/aiplatform/__init__.py b/google/cloud/aiplatform/__init__.py index 28e26764b9..17172cbb56 100644 --- a/google/cloud/aiplatform/__init__.py +++ b/google/cloud/aiplatform/__init__.py @@ -15,6 +15,4 @@ # limitations under the License. # -from google.cloud.aiplatform import gapic - __all__ = () diff --git a/noxfile.py b/noxfile.py index 0e83aab566..3b51bc5832 100644 --- a/noxfile.py +++ b/noxfile.py @@ -156,7 +156,7 @@ def docs(session): shutil.rmtree(os.path.join("docs", "_build"), ignore_errors=True) session.run( "sphinx-build", - "-W", # warnings as errors + "-T", # show full traceback on exception "-N", # no colors "-b", diff --git a/synth.py b/synth.py index 11a7129153..31c3e11493 100644 --- a/synth.py +++ b/synth.py @@ -128,4 +128,7 @@ templated_files, excludes=[".coveragerc"] ) # the microgenerator has a good coveragerc file +# Don't treat docs warnings as errors +s.replace("noxfile.py", """["']-W["'], # warnings as errors""", "") + s.shell.run(["nox", "-s", "blacken"], hide_output=False) diff --git a/tests/unit/aiplatform_v1beta1/test_dataset_service.py b/tests/unit/gapic/test_dataset_service.py similarity index 100% rename from tests/unit/aiplatform_v1beta1/test_dataset_service.py rename to tests/unit/gapic/test_dataset_service.py diff --git a/tests/unit/aiplatform_v1beta1/test_endpoint_service.py b/tests/unit/gapic/test_endpoint_service.py similarity index 100% rename from tests/unit/aiplatform_v1beta1/test_endpoint_service.py rename to tests/unit/gapic/test_endpoint_service.py diff --git a/tests/unit/aiplatform_v1beta1/test_job_service.py b/tests/unit/gapic/test_job_service.py similarity index 100% rename from tests/unit/aiplatform_v1beta1/test_job_service.py rename to tests/unit/gapic/test_job_service.py diff --git a/tests/unit/aiplatform_v1beta1/test_model_service.py b/tests/unit/gapic/test_model_service.py similarity index 100% rename from tests/unit/aiplatform_v1beta1/test_model_service.py rename to tests/unit/gapic/test_model_service.py diff --git a/tests/unit/aiplatform_v1beta1/test_pipeline_service.py b/tests/unit/gapic/test_pipeline_service.py similarity index 100% rename from tests/unit/aiplatform_v1beta1/test_pipeline_service.py rename to tests/unit/gapic/test_pipeline_service.py diff --git a/tests/unit/aiplatform_v1beta1/test_prediction_service.py b/tests/unit/gapic/test_prediction_service.py similarity index 100% rename from tests/unit/aiplatform_v1beta1/test_prediction_service.py rename to tests/unit/gapic/test_prediction_service.py diff --git a/tests/unit/aiplatform_v1beta1/test_specialist_pool_service.py b/tests/unit/gapic/test_specialist_pool_service.py similarity index 100% rename from tests/unit/aiplatform_v1beta1/test_specialist_pool_service.py rename to tests/unit/gapic/test_specialist_pool_service.py From dca44e6c128995eca540109eaad21e07fccce03a Mon Sep 17 00:00:00 2001 From: Bu Sun Kim Date: Mon, 19 Oct 2020 21:35:44 +0000 Subject: [PATCH 4/5] chore: remove accidentally commited file --- samples/requirements.txt | 3 --- 1 file changed, 3 deletions(-) delete mode 100644 samples/requirements.txt diff --git a/samples/requirements.txt b/samples/requirements.txt deleted file mode 100644 index fcd7031d0e..0000000000 --- a/samples/requirements.txt +++ /dev/null @@ -1,3 +0,0 @@ -pytest==6.0.1 -# TODO (vinnysenthil): Replace Github library src with PyPi package name (google-cloud-aiplatform) -git+git://github.com/googleapis/python-aiplatform.git@dc5e5cdb3844622bf6dfecbda6e0857b8a228a8d \ No newline at end of file From 8b343ecc0ddcdb1cc51cecbdbf0920061fe07457 Mon Sep 17 00:00:00 2001 From: Bu Sun Kim Date: Mon, 19 Oct 2020 21:44:02 +0000 Subject: [PATCH 5/5] chore: blacken noxfile --- noxfile.py | 1 - 1 file changed, 1 deletion(-) diff --git a/noxfile.py b/noxfile.py index 3b51bc5832..615e2c6793 100644 --- a/noxfile.py +++ b/noxfile.py @@ -156,7 +156,6 @@ def docs(session): shutil.rmtree(os.path.join("docs", "_build"), ignore_errors=True) session.run( "sphinx-build", - "-T", # show full traceback on exception "-N", # no colors "-b",