From 87b00d104aab39f655a482f0923493c84ec7f18e Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Tue, 24 Jun 2025 09:47:46 +0000 Subject: [PATCH 1/8] Remove support for Python 3.8 This commit removes Python 3.8 from the supported versions. Updates include changes in noxfiles, GitHub workflows, setup.py, Kokoro configurations, and documentation to reflect Python 3.9 as the minimum supported version. --- .github/sync-repo-settings.yaml | 2 -- .github/workflows/unittest.yml | 2 +- .kokoro/presubmit/system-3.8.cfg | 7 ---- .kokoro/samples/python3.8/common.cfg | 40 --------------------- .kokoro/samples/python3.8/continuous.cfg | 6 ---- .kokoro/samples/python3.8/periodic-head.cfg | 11 ------ .kokoro/samples/python3.8/periodic.cfg | 6 ---- .kokoro/samples/python3.8/presubmit.cfg | 6 ---- CONTRIBUTING.rst | 8 ++--- noxfile.py | 4 +-- samples/snippets/noxfile.py | 2 +- setup.py | 3 +- testing/constraints-3.8.txt | 22 ------------ 13 files changed, 8 insertions(+), 111 deletions(-) delete mode 100644 .kokoro/presubmit/system-3.8.cfg delete mode 100644 .kokoro/samples/python3.8/common.cfg delete mode 100644 .kokoro/samples/python3.8/continuous.cfg delete mode 100644 .kokoro/samples/python3.8/periodic-head.cfg delete mode 100644 .kokoro/samples/python3.8/periodic.cfg delete mode 100644 .kokoro/samples/python3.8/presubmit.cfg delete mode 100644 testing/constraints-3.8.txt diff --git a/.github/sync-repo-settings.yaml b/.github/sync-repo-settings.yaml index 692ec5b6..130dd1fe 100644 --- a/.github/sync-repo-settings.yaml +++ b/.github/sync-repo-settings.yaml @@ -11,7 +11,6 @@ branchProtectionRules: - 'OwlBot Post Processor' - 'docs' - 'lint' - - 'unit (3.8)' - 'unit (3.9)' - 'unit (3.10)' - 'unit (3.11)' @@ -20,7 +19,6 @@ branchProtectionRules: - 'cover' - 'Kokoro' - 'Samples - Lint' - - 'Samples - Python 3.8' - 'Samples - Python 3.9' - 'Samples - Python 3.10' - 'Samples - Python 3.11' diff --git a/.github/workflows/unittest.yml b/.github/workflows/unittest.yml index 4a4c5d93..7137d0ad 100644 --- a/.github/workflows/unittest.yml +++ b/.github/workflows/unittest.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-22.04 strategy: matrix: - python: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13'] + python: ['3.9', '3.10', '3.11', '3.12', '3.13'] steps: - name: Checkout uses: actions/checkout@v4 diff --git a/.kokoro/presubmit/system-3.8.cfg b/.kokoro/presubmit/system-3.8.cfg deleted file mode 100644 index 15b14528..00000000 --- a/.kokoro/presubmit/system-3.8.cfg +++ /dev/null @@ -1,7 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Only run the following session(s) -env_vars: { - key: "NOX_SESSION" - value: "system-3.8" -} \ No newline at end of file diff --git a/.kokoro/samples/python3.8/common.cfg b/.kokoro/samples/python3.8/common.cfg deleted file mode 100644 index 7424a3b9..00000000 --- a/.kokoro/samples/python3.8/common.cfg +++ /dev/null @@ -1,40 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Build logs will be here -action { - define_artifacts { - regex: "**/*sponge_log.xml" - } -} - -# Specify which tests to run -env_vars: { - key: "RUN_TESTS_SESSION" - value: "py-3.8" -} - -# Declare build specific Cloud project. -env_vars: { - key: "BUILD_SPECIFIC_GCLOUD_PROJECT" - value: "python-docs-samples-tests-py38" -} - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/python-bigquery-pandas/.kokoro/test-samples.sh" -} - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker" -} - -# Download secrets for samples -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples" - -# Download trampoline resources. -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" - -# Use the trampoline script to run in docker. -build_file: "python-bigquery-pandas/.kokoro/trampoline_v2.sh" \ No newline at end of file diff --git a/.kokoro/samples/python3.8/continuous.cfg b/.kokoro/samples/python3.8/continuous.cfg deleted file mode 100644 index a1c8d975..00000000 --- a/.kokoro/samples/python3.8/continuous.cfg +++ /dev/null @@ -1,6 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "INSTALL_LIBRARY_FROM_SOURCE" - value: "True" -} \ No newline at end of file diff --git a/.kokoro/samples/python3.8/periodic-head.cfg b/.kokoro/samples/python3.8/periodic-head.cfg deleted file mode 100644 index 98efde4d..00000000 --- a/.kokoro/samples/python3.8/periodic-head.cfg +++ /dev/null @@ -1,11 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "INSTALL_LIBRARY_FROM_SOURCE" - value: "True" -} - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/python-bigquery-pandas/.kokoro/test-samples-against-head.sh" -} diff --git a/.kokoro/samples/python3.8/periodic.cfg b/.kokoro/samples/python3.8/periodic.cfg deleted file mode 100644 index 71cd1e59..00000000 --- a/.kokoro/samples/python3.8/periodic.cfg +++ /dev/null @@ -1,6 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "INSTALL_LIBRARY_FROM_SOURCE" - value: "False" -} diff --git a/.kokoro/samples/python3.8/presubmit.cfg b/.kokoro/samples/python3.8/presubmit.cfg deleted file mode 100644 index a1c8d975..00000000 --- a/.kokoro/samples/python3.8/presubmit.cfg +++ /dev/null @@ -1,6 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "INSTALL_LIBRARY_FROM_SOURCE" - value: "True" -} \ No newline at end of file diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index 28f54669..2e8e9860 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -22,7 +22,7 @@ In order to add a feature: documentation. - The feature must work fully on the following CPython versions: - 3.8, 3.9, 3.10, 3.11, 3.12 and 3.13 on both UNIX and Windows. + 3.9, 3.10, 3.11, 3.12 and 3.13 on both UNIX and Windows. - The feature must not add unnecessary dependencies (where "unnecessary" is of course subjective, but new dependencies should @@ -148,7 +148,7 @@ Running System Tests .. note:: - System tests are only configured to run under Python 3.8, 3.9, 3.10, 3.11, 3.12 and 3.13. + System tests are only configured to run under Python 3.9, 3.10, 3.11, 3.12 and 3.13. For expediency, we do not run them in older versions of Python 3. This alone will not run the tests. You'll need to change some local @@ -221,14 +221,12 @@ Supported Python Versions We support: -- `Python 3.8`_ - `Python 3.9`_ - `Python 3.10`_ - `Python 3.11`_ - `Python 3.12`_ - `Python 3.13`_ -.. _Python 3.8: https://docs.python.org/3.8/ .. _Python 3.9: https://docs.python.org/3.9/ .. _Python 3.10: https://docs.python.org/3.10/ .. _Python 3.11: https://docs.python.org/3.11/ @@ -241,7 +239,7 @@ Supported versions can be found in our ``noxfile.py`` `config`_. .. _config: https://github.com/googleapis/python-bigquery-pandas/blob/main/noxfile.py -We also explicitly decided to support Python 3 beginning with version 3.8. +We also explicitly decided to support Python 3 beginning with version 3.9. Reasons for this include: - Encouraging use of newest versions of Python 3 diff --git a/noxfile.py b/noxfile.py index 52bdcde1..e246b05d 100644 --- a/noxfile.py +++ b/noxfile.py @@ -35,7 +35,7 @@ DEFAULT_PYTHON_VERSION = "3.10" -UNIT_TEST_PYTHON_VERSIONS = ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] +UNIT_TEST_PYTHON_VERSIONS = ["3.9", "3.10", "3.11", "3.12", "3.13"] UNIT_TEST_STANDARD_DEPENDENCIES = [ "mock", "asyncmock", @@ -57,7 +57,7 @@ "3.9": [], } -SYSTEM_TEST_PYTHON_VERSIONS = ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] +SYSTEM_TEST_PYTHON_VERSIONS = ["3.9", "3.10", "3.11", "3.12", "3.13"] SYSTEM_TEST_STANDARD_DEPENDENCIES = [ "mock", "pytest", diff --git a/samples/snippets/noxfile.py b/samples/snippets/noxfile.py index 494639d2..61ed29bf 100644 --- a/samples/snippets/noxfile.py +++ b/samples/snippets/noxfile.py @@ -88,7 +88,7 @@ def get_pytest_env_vars() -> Dict[str, str]: # DO NOT EDIT - automatically generated. # All versions used to test samples. -ALL_VERSIONS = ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] +ALL_VERSIONS = ["3.7", "3.9", "3.10", "3.11", "3.12", "3.13"] # Any default versions that should be ignored. IGNORED_VERSIONS = TEST_CONFIG["ignored_versions"] diff --git a/setup.py b/setup.py index 681a80aa..893d801b 100644 --- a/setup.py +++ b/setup.py @@ -85,7 +85,6 @@ "License :: OSI Approved :: BSD License", "Programming Language :: Python", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", @@ -99,7 +98,7 @@ packages=packages, install_requires=dependencies, extras_require=extras, - python_requires=">=3.8", + python_requires=">=3.9", include_package_data=True, zip_safe=False, ) diff --git a/testing/constraints-3.8.txt b/testing/constraints-3.8.txt deleted file mode 100644 index 8d6ef4f4..00000000 --- a/testing/constraints-3.8.txt +++ /dev/null @@ -1,22 +0,0 @@ -# This constraints file is used to check that lower bounds -# are correct in setup.py -# List *all* library dependencies and extras in this file. -# Pin the version to the lower bound. -# -# e.g., if setup.py has "foo >= 1.14.0, < 2.0.0dev", -# Then this file should have foo==1.14.0 -# protobuf==3.19.5 -db-dtypes==1.0.4 -geopandas==0.9.0 -google-api-core==2.10.2 -google-auth==2.13.0 -google-auth-oauthlib==0.7.0 -google-cloud-bigquery==3.4.2 -google-cloud-bigquery-storage==2.16.2 -numpy==1.18.1 -pandas==1.1.4 -pyarrow==4.0.0 -pydata-google-auth==1.5.0 -Shapely==1.8.4 -tqdm==4.23.0 -packaging==22.0.0 From d58423d69005fb6f1bdc4ebd7fa4b0944bcc9059 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Tue, 24 Jun 2025 10:25:21 +0000 Subject: [PATCH 2/8] Apply follow-up changes for Python 3.8 removal This commit addresses items missed in the initial Python 3.8 removal: * Adds `kokoro/presubmit/system-3.9.cfg`. * Updates example commands in `CONTRIBUTING.rst`. * Modifies the warning in `pandas_gbq/__init__.py` for Python < 3.9. * Updates Python versions in `owlbot.py`. * Removes 3.8-specific line from `samples/snippets/requirements.txt`. * Populates `testing/constraints-3.9.txt` with correct lower bounds. --- .kokoro/presubmit/system-3.9.cfg | 7 +++++++ CONTRIBUTING.rst | 4 ++-- owlbot.py | 4 ++-- pandas_gbq/__init__.py | 14 +++++++------- samples/snippets/requirements.txt | 1 - testing/constraints-3.9.txt | 22 +++++++++++++++++++++- 6 files changed, 39 insertions(+), 13 deletions(-) create mode 100644 .kokoro/presubmit/system-3.9.cfg diff --git a/.kokoro/presubmit/system-3.9.cfg b/.kokoro/presubmit/system-3.9.cfg new file mode 100644 index 00000000..be5a8124 --- /dev/null +++ b/.kokoro/presubmit/system-3.9.cfg @@ -0,0 +1,7 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Only run the following session(s) +env_vars: { + key: "NOX_SESSION" + value: "system-3.9" +} diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index 2e8e9860..f5c072e9 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -195,11 +195,11 @@ configure them just like the System Tests. # Run all tests in a folder $ cd samples/snippets - $ nox -s py-3.8 + $ nox -s py-3.9 # Run a single sample test $ cd samples/snippets - $ nox -s py-3.8 -- -k + $ nox -s py-3.9 -- -k ******************************************** Note About ``README`` as it pertains to PyPI diff --git a/owlbot.py b/owlbot.py index 35e19fcf..b45d2a20 100644 --- a/owlbot.py +++ b/owlbot.py @@ -35,8 +35,8 @@ extras = ["tqdm", "geopandas"] templated_files = common.py_library( default_python_version="3.10", - unit_test_python_versions=["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"], - system_test_python_versions=["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"], + unit_test_python_versions=["3.9", "3.10", "3.11", "3.12", "3.13"], + system_test_python_versions=["3.9", "3.10", "3.11", "3.12", "3.13"], cov_level=96, unit_test_external_dependencies=["freezegun"], unit_test_extras=extras, diff --git a/pandas_gbq/__init__.py b/pandas_gbq/__init__.py index 184f8c44..6e70e7bf 100644 --- a/pandas_gbq/__init__.py +++ b/pandas_gbq/__init__.py @@ -11,14 +11,14 @@ from .gbq import read_gbq, to_gbq # noqa sys_major, sys_minor, sys_micro = _versions_helpers.extract_runtime_version() -if sys_major == 3 and sys_minor in (7, 8): +if sys_major == 3 and sys_minor < 9: warnings.warn( - "The python-bigquery library will stop supporting Python 3.7 " - "and Python 3.8 in a future major release expected in Q4 2024. " - f"Your Python version is {sys_major}.{sys_minor}.{sys_micro}. We " - "recommend that you update soon to ensure ongoing support. For " - "more details, see: [Google Cloud Client Libraries Supported Python Versions policy](https://cloud.google.com/python/docs/supported-python-versions)", - PendingDeprecationWarning, + "pandas-gbq will stop supporting Python versions older than 3.9 " + "in a future release. Your Python version is " + f"{sys_major}.{sys_minor}.{sys_micro}. Please update " + "to Python 3.9 or newer to ensure ongoing support. For more details, " + "see: https://cloud.google.com/python/docs/supported-python-versions", + FutureWarning, ) __version__ = pandas_gbq_version.__version__ diff --git a/samples/snippets/requirements.txt b/samples/snippets/requirements.txt index a451f10a..ae826361 100644 --- a/samples/snippets/requirements.txt +++ b/samples/snippets/requirements.txt @@ -1,6 +1,5 @@ google-cloud-bigquery-storage==2.29.1 google-cloud-bigquery==3.30.0 pandas-gbq==0.28.0 -pandas===2.0.3; python_version == '3.8' pandas==2.2.3; python_version >= '3.9' pyarrow==19.0.1; python_version >= '3.9' diff --git a/testing/constraints-3.9.txt b/testing/constraints-3.9.txt index 76864a66..cee7853e 100644 --- a/testing/constraints-3.9.txt +++ b/testing/constraints-3.9.txt @@ -1,2 +1,22 @@ -numpy==1.19.4 +# This constraints file is used to check that lower bounds +# are correct in setup.py +# List *all* library dependencies and extras in this file. +# Pin the version to the lower bound. +# +# e.g., if setup.py has "foo >= 1.14.0, < 2.0.0dev", +# Then this file should have foo==1.14.0 +db-dtypes==1.0.4 +numpy==1.18.1 pandas==1.1.4 +pyarrow==4.0.0 +pydata-google-auth==1.5.0 +google-api-core==2.10.2 +google-auth==2.13.0 +google-auth-oauthlib==0.7.0 +google-cloud-bigquery==3.4.2 +packaging==22.0.0 +# Extras +google-cloud-bigquery-storage==2.16.2 +tqdm==4.23.0 +geopandas==0.9.0 +Shapely==1.8.4 From 5fea48ff330dafee2b2915c60a6f89c8c375ec93 Mon Sep 17 00:00:00 2001 From: Chalmer Lowe Date: Tue, 24 Jun 2025 06:50:01 -0400 Subject: [PATCH 3/8] Update pandas_gbq/__init__.py --- pandas_gbq/__init__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pandas_gbq/__init__.py b/pandas_gbq/__init__.py index 6e70e7bf..a842c81f 100644 --- a/pandas_gbq/__init__.py +++ b/pandas_gbq/__init__.py @@ -13,8 +13,8 @@ sys_major, sys_minor, sys_micro = _versions_helpers.extract_runtime_version() if sys_major == 3 and sys_minor < 9: warnings.warn( - "pandas-gbq will stop supporting Python versions older than 3.9 " - "in a future release. Your Python version is " + "pandas-gbq no longer supports Python versions older than 3.9. " + "Your Python version is " f"{sys_major}.{sys_minor}.{sys_micro}. Please update " "to Python 3.9 or newer to ensure ongoing support. For more details, " "see: https://cloud.google.com/python/docs/supported-python-versions", From 9b50b36f802ae627e3aa205a09fd2184637496d9 Mon Sep 17 00:00:00 2001 From: Chalmer Lowe Date: Tue, 24 Jun 2025 06:50:57 -0400 Subject: [PATCH 4/8] Update samples/snippets/noxfile.py --- samples/snippets/noxfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/snippets/noxfile.py b/samples/snippets/noxfile.py index 61ed29bf..68c05d2d 100644 --- a/samples/snippets/noxfile.py +++ b/samples/snippets/noxfile.py @@ -88,7 +88,7 @@ def get_pytest_env_vars() -> Dict[str, str]: # DO NOT EDIT - automatically generated. # All versions used to test samples. -ALL_VERSIONS = ["3.7", "3.9", "3.10", "3.11", "3.12", "3.13"] +ALL_VERSIONS = ["3.9", "3.10", "3.11", "3.12", "3.13"] # Any default versions that should be ignored. IGNORED_VERSIONS = TEST_CONFIG["ignored_versions"] From c96c2a8c06d051d875f36abb8a6229a62619e217 Mon Sep 17 00:00:00 2001 From: Chalmer Lowe Date: Tue, 24 Jun 2025 06:54:51 -0400 Subject: [PATCH 5/8] Update requirements.txt --- samples/snippets/requirements.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/samples/snippets/requirements.txt b/samples/snippets/requirements.txt index ae826361..ca1e1d0c 100644 --- a/samples/snippets/requirements.txt +++ b/samples/snippets/requirements.txt @@ -1,5 +1,5 @@ google-cloud-bigquery-storage==2.29.1 google-cloud-bigquery==3.30.0 pandas-gbq==0.28.0 -pandas==2.2.3; python_version >= '3.9' -pyarrow==19.0.1; python_version >= '3.9' +pandas==2.2.3 +pyarrow==19.0.1 From c2c7823e3de3bab2dc07e97d8322a501d81088b5 Mon Sep 17 00:00:00 2001 From: Chalmer Lowe Date: Tue, 24 Jun 2025 06:57:15 -0400 Subject: [PATCH 6/8] Update testing/constraints-3.9.txt --- testing/constraints-3.9.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testing/constraints-3.9.txt b/testing/constraints-3.9.txt index cee7853e..db8a499a 100644 --- a/testing/constraints-3.9.txt +++ b/testing/constraints-3.9.txt @@ -6,7 +6,7 @@ # e.g., if setup.py has "foo >= 1.14.0, < 2.0.0dev", # Then this file should have foo==1.14.0 db-dtypes==1.0.4 -numpy==1.18.1 +numpy==1.19.4 pandas==1.1.4 pyarrow==4.0.0 pydata-google-auth==1.5.0 From b65bc5278908b9c906e957a25c5d48be7f9c50eb Mon Sep 17 00:00:00 2001 From: Chalmer Lowe Date: Tue, 24 Jun 2025 07:17:18 -0400 Subject: [PATCH 7/8] Update owlbot.py --- owlbot.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/owlbot.py b/owlbot.py index b45d2a20..1d5d912f 100644 --- a/owlbot.py +++ b/owlbot.py @@ -57,8 +57,9 @@ "docs/multiprocessing.rst", "noxfile.py", "README.rst", - # exclude this file as we have an alternate prerelease.cfg ".github/workflows/docs.yml", + ".github/sync-repo-settings.yaml", + # exclude this file as we have an alternate prerelease.cfg ".kokoro/presubmit/prerelease-deps.cfg", ".kokoro/presubmit/presubmit.cfg", ], From 2118f2ceb1895f27b18c228a4f89a8c0a54d205b Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Tue, 24 Jun 2025 11:40:20 +0000 Subject: [PATCH 8/8] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- .kokoro/samples/python3.8/common.cfg | 40 +++++++++++++++++++++ .kokoro/samples/python3.8/continuous.cfg | 6 ++++ .kokoro/samples/python3.8/periodic-head.cfg | 11 ++++++ .kokoro/samples/python3.8/periodic.cfg | 6 ++++ .kokoro/samples/python3.8/presubmit.cfg | 6 ++++ CONTRIBUTING.rst | 4 +-- samples/snippets/noxfile.py | 2 +- 7 files changed, 72 insertions(+), 3 deletions(-) create mode 100644 .kokoro/samples/python3.8/common.cfg create mode 100644 .kokoro/samples/python3.8/continuous.cfg create mode 100644 .kokoro/samples/python3.8/periodic-head.cfg create mode 100644 .kokoro/samples/python3.8/periodic.cfg create mode 100644 .kokoro/samples/python3.8/presubmit.cfg diff --git a/.kokoro/samples/python3.8/common.cfg b/.kokoro/samples/python3.8/common.cfg new file mode 100644 index 00000000..7424a3b9 --- /dev/null +++ b/.kokoro/samples/python3.8/common.cfg @@ -0,0 +1,40 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Build logs will be here +action { + define_artifacts { + regex: "**/*sponge_log.xml" + } +} + +# Specify which tests to run +env_vars: { + key: "RUN_TESTS_SESSION" + value: "py-3.8" +} + +# Declare build specific Cloud project. +env_vars: { + key: "BUILD_SPECIFIC_GCLOUD_PROJECT" + value: "python-docs-samples-tests-py38" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/python-bigquery-pandas/.kokoro/test-samples.sh" +} + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/python-samples-testing-docker" +} + +# Download secrets for samples +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/python-docs-samples" + +# Download trampoline resources. +gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" + +# Use the trampoline script to run in docker. +build_file: "python-bigquery-pandas/.kokoro/trampoline_v2.sh" \ No newline at end of file diff --git a/.kokoro/samples/python3.8/continuous.cfg b/.kokoro/samples/python3.8/continuous.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/python3.8/continuous.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/.kokoro/samples/python3.8/periodic-head.cfg b/.kokoro/samples/python3.8/periodic-head.cfg new file mode 100644 index 00000000..98efde4d --- /dev/null +++ b/.kokoro/samples/python3.8/periodic-head.cfg @@ -0,0 +1,11 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/python-bigquery-pandas/.kokoro/test-samples-against-head.sh" +} diff --git a/.kokoro/samples/python3.8/periodic.cfg b/.kokoro/samples/python3.8/periodic.cfg new file mode 100644 index 00000000..71cd1e59 --- /dev/null +++ b/.kokoro/samples/python3.8/periodic.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "False" +} diff --git a/.kokoro/samples/python3.8/presubmit.cfg b/.kokoro/samples/python3.8/presubmit.cfg new file mode 100644 index 00000000..a1c8d975 --- /dev/null +++ b/.kokoro/samples/python3.8/presubmit.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "INSTALL_LIBRARY_FROM_SOURCE" + value: "True" +} \ No newline at end of file diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index f5c072e9..2e8e9860 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -195,11 +195,11 @@ configure them just like the System Tests. # Run all tests in a folder $ cd samples/snippets - $ nox -s py-3.9 + $ nox -s py-3.8 # Run a single sample test $ cd samples/snippets - $ nox -s py-3.9 -- -k + $ nox -s py-3.8 -- -k ******************************************** Note About ``README`` as it pertains to PyPI diff --git a/samples/snippets/noxfile.py b/samples/snippets/noxfile.py index 68c05d2d..494639d2 100644 --- a/samples/snippets/noxfile.py +++ b/samples/snippets/noxfile.py @@ -88,7 +88,7 @@ def get_pytest_env_vars() -> Dict[str, str]: # DO NOT EDIT - automatically generated. # All versions used to test samples. -ALL_VERSIONS = ["3.9", "3.10", "3.11", "3.12", "3.13"] +ALL_VERSIONS = ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13"] # Any default versions that should be ignored. IGNORED_VERSIONS = TEST_CONFIG["ignored_versions"]