Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ In order to add a feature:
documentation.

- The feature must work fully on the following CPython versions:
3.9, 3.10, 3.11, 3.12, and 3.13 on both UNIX and Windows.
3.9, 3.10, 3.11, 3.12, 3.13 and 3.14 on both UNIX and Windows.

- The feature must not add unnecessary dependencies (where
"unnecessary" is of course subjective, but new dependencies should
Expand Down Expand Up @@ -72,7 +72,7 @@ We use `nox <https://nox.readthedocs.io/en/latest/>`__ to instrument our tests.

- To run a single unit test::

$ nox -s unit-3.13 -- -k <name of test>
$ nox -s unit-3.14 -- -k <name of test>


.. note::
Expand Down Expand Up @@ -143,12 +143,12 @@ Running System Tests
$ nox -s system

# Run a single system test
$ nox -s system-3.13 -- -k <name of test>
$ nox -s system-3.14 -- -k <name of test>


.. note::

System tests are only configured to run under Python 3.9, 3.12, and 3.13.
System tests are only configured to run under Python 3.9, 3.12, and 3.14.
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
Expand Down Expand Up @@ -226,12 +226,14 @@ We support:
- `Python 3.11`_
- `Python 3.12`_
- `Python 3.13`_
- `Python 3.14`_

.. _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/
.. _Python 3.12: https://docs.python.org/3.12/
.. _Python 3.13: https://docs.python.org/3.13/
.. _Python 3.14: https://docs.python.org/3.14/


Supported versions can be found in our ``noxfile.py`` `config`_.
Expand Down
38 changes: 29 additions & 9 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@
"setup.py",
]

DEFAULT_PYTHON_VERSION = "3.10"
DEFAULT_PYTHON_VERSION = "3.14"

UNIT_TEST_PYTHON_VERSIONS: List[str] = ["3.9", "3.10", "3.11", "3.12", "3.13"]
UNIT_TEST_PYTHON_VERSIONS: List[str] = ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
UNIT_TEST_STANDARD_DEPENDENCIES = [
"mock",
"asyncmock",
Expand Down Expand Up @@ -73,9 +73,14 @@
"geography",
"bqstorage",
],
"3.14": [
"tests",
"geography",
"bqstorage",
],
}

SYSTEM_TEST_PYTHON_VERSIONS: List[str] = ["3.9", "3.12", "3.13"]
SYSTEM_TEST_PYTHON_VERSIONS: List[str] = ["3.9", "3.12", "3.13", "3.14"]
SYSTEM_TEST_STANDARD_DEPENDENCIES: List[str] = [
"mock",
"pytest",
Expand All @@ -98,6 +103,11 @@
"geography",
"bqstorage",
],
"3.14": [
"tests",
"geography",
"bqstorage",
],
}

CURRENT_DIRECTORY = pathlib.Path(__file__).parent.absolute()
Expand Down Expand Up @@ -193,7 +203,7 @@ def format(session):
@_calculate_duration
def lint_setup_py(session):
"""Verify that setup.py is valid (including RST check)."""
session.install("docutils", "pygments")
session.install("docutils", "pygments", "setuptools")
session.run("python", "setup.py", "check", "--restructuredtext", "--strict")


Expand Down Expand Up @@ -234,15 +244,20 @@ def install_unittest_dependencies(session, *constraints):
def unit(session, protobuf_implementation, install_extras=True):
# Install all test dependencies, then install this package in-place.

if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12", "3.13"):
if protobuf_implementation == "cpp" and session.python in (
"3.11",
"3.12",
"3.13",
"3.14",
):
session.skip("cpp implementation is not supported in python 3.11+")

constraints_path = str(
CURRENT_DIRECTORY / "testing" / f"constraints-{session.python}.txt"
)
install_unittest_dependencies(session, "-c", constraints_path)

if install_extras and session.python in ["3.11", "3.12", "3.13"]:
if install_extras and session.python in ["3.11", "3.12", "3.13", "3.14"]:
install_target = ".[geography,alembic,tests,bqstorage]"
elif install_extras:
install_target = ".[all]"
Expand Down Expand Up @@ -419,7 +434,7 @@ def compliance(session):
"-c",
constraints_path,
)
if session.python in ["3.12", "3.13"]:
if session.python in ["3.12", "3.13", "3.14"]:
extras = "[tests,geography,alembic]"
else:
extras = "[tests]"
Expand Down Expand Up @@ -549,7 +564,7 @@ def docfx(session):
)


@nox.session(python="3.13")
@nox.session(python=DEFAULT_PYTHON_VERSION)
@nox.parametrize(
"protobuf_implementation",
["python", "upb", "cpp"],
Expand All @@ -558,7 +573,12 @@ def docfx(session):
def prerelease_deps(session, protobuf_implementation):
"""Run all tests with prerelease versions of dependencies installed."""

if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12", "3.13"):
if protobuf_implementation == "cpp" and session.python in (
"3.11",
"3.12",
"3.13",
"3.14",
):
session.skip("cpp implementation is not supported in python 3.11+")

# Install all dependencies
Expand Down
5 changes: 3 additions & 2 deletions owlbot.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,11 @@
"3.11": ["tests", "geography", "bqstorage"],
"3.12": ["tests", "geography", "bqstorage"],
"3.13": ["tests", "geography", "bqstorage"],
"3.14": ["tests", "geography", "bqstorage"],
}
templated_files = common.py_library(
unit_test_python_versions=["3.9", "3.10", "3.11", "3.12", "3.13"],
system_test_python_versions=["3.9", "3.12", "3.13"],
unit_test_python_versions=["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"],
system_test_python_versions=["3.9", "3.12", "3.13", "3.14"],
cov_level=100,
unit_test_extras=extras,
unit_test_extras_by_python=extras_by_python,
Expand Down
6 changes: 4 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,8 @@ def readme():
# grpc.Channel.close() method isn't added until 1.32.0.
# https://github.com/grpc/grpc/pull/15254
"grpcio >= 1.47.0, < 2.0.0",
"grpcio >= 1.49.1, < 2.0.0; python_version>='3.11'",
"grpcio >= 1.49.1, < 2.0.0; python_version =='3.11'",
"grpcio >= 1.75.1, < 2.0.0; python_version >= '3.14'",
"pyarrow >= 5.0.0",
],
}
Expand Down Expand Up @@ -105,6 +106,7 @@ def readme():
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Operating System :: OS Independent",
"Topic :: Database :: Front-Ends",
],
Expand All @@ -120,7 +122,7 @@ def readme():
"sqlalchemy>=1.4.16,<3.0.0",
],
extras_require=extras,
python_requires=">=3.8, <3.14",
python_requires=">=3.8, <3.15",
tests_require=["packaging", "pytz"],
entry_points={
"sqlalchemy.dialects": ["bigquery = sqlalchemy_bigquery:BigQueryDialect"]
Expand Down
Empty file added testing/constraints-3.14.txt
Empty file.