Skip to content
This repository was archived by the owner on Feb 13, 2026. It is now read-only.

feat: Adds Python 3.13 support - #319

Merged
chalmerlowe merged 39 commits into
mainfrom
feat/add-python-3.13
Oct 23, 2025
Merged

feat: Adds Python 3.13 support#319
chalmerlowe merged 39 commits into
mainfrom
feat/add-python-3.13

Conversation

@chalmerlowe

@chalmerlowechalmerlowe commented Oct 22, 2025

Copy link
Copy Markdown
Contributor

This PR introduces support for Python 3.13 and makes several updates to the CI and testing configuration:

Python 3.13 Support:

  • Adds Python 3.13 to the classifiers in setup.py.
  • A constraints-3.13.txt file was already present.

CI/Testing Updates:

  • Updates the default Python version for linting in .github/workflows/lint.yml from 3.8 to 3.10 to mirror other defaults in the nox sessions for system tests, etc.
  • Sets the NOX_SESSION environment variable in .kokoro/presubmit/presubmit.cfg to "system blacken format" to control which nox sessions run during presubmit
  • Changes DEFAULT_PYTHON_VERSION in noxfile.py from 3.8 to 3.10.
  • Updates SYSTEM_TEST_PYTHON_VERSIONS in noxfile.py from 3.8 to 3.10.

Owlbot Configuration:

  • Adds s.replace calls in owlbot.py to persist the changes in lint.yml, presubmit.cfg, and noxfile.py after owlbot post-processing. This ensures that the CI environment and test configurations use Python 3.10 by default and that the presubmit runs a specific set of nox sessions.

These changes ensure that Python 3.13 is supported and that the CI environment defaults to Python 3.10 for system tests and linting, working around known issues with older Python versions (3.7 and 3.8) in the Kokoro Docker python-multi image.

@chalmerlowe
chalmerlowe requested a review from a teamOctober 22, 2025 17:56
@product-auto-labelproduct-auto-labelBot added the size: xs Pull request size is extra small. label Oct 22, 2025
@product-auto-labelproduct-auto-labelBot added the api: dns Issues related to the googleapis/python-dns API. label Oct 22, 2025
@chalmerlowechalmerlowe added kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. and removed kokoro:run Add this label to force Kokoro to re-run the tests. labels Oct 22, 2025
@yoshi-kokoroyoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Oct 22, 2025
@product-auto-labelproduct-auto-labelBot added size: s Pull request size is small. and removed size: xs Pull request size is extra small. labels Oct 23, 2025
@chalmerlowechalmerlowe added the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2025
@gcf-owl-botgcf-owl-botBot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2025
@chalmerlowechalmerlowe added kokoro:run Add this label to force Kokoro to re-run the tests. kokoro:force-run Add this label to force Kokoro to re-run the tests. and removed kokoro:run Add this label to force Kokoro to re-run the tests. labels Oct 23, 2025
@yoshi-kokoroyoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Oct 23, 2025
@chalmerlowechalmerlowe added the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2025
@gcf-owl-botgcf-owl-botBot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2025
Comment threadsetup.py
Comment thread.kokoro/presubmit/presubmit.cfg Outdated
Comment threadowlbot.py Outdated
Comment threadowlbot.py Outdated
Comment threadsetup.py
Comment threadsetup.py Outdated
@chalmerlowechalmerlowe added the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2025
@gcf-owl-botgcf-owl-botBot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 23, 2025

env_vars: {
key: "NOX_SESSION"
value: "system blacken format"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this also have all the unit-<version> from 3.9 to 3.13?

@chalmerlowechalmerloweOct 23, 2025

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gkevinzheng

We are running unit tests in github actions so we do not need to duplicate those tests here in the kokoro session.

Our multi-python docker image does not have python 3.8 and 3.7 wheels due to an issue. We are able to run those unit tests under 3.7 and 3.8 in GitHub (as well as all the others up to 3.14) until we finally ditch 3.7 and 3.8 completely from all the split repos.

Comment threadowlbot.py Outdated
Comment on lines +61 to +73
s.replace(
"noxfile.py",
'DEFAULT_PYTHON_VERSION = "3.8"',
'DEFAULT_PYTHON_VERSION = "3.10"'
)

s.replace(
"noxfile.py",
r'SYSTEM_TEST_PYTHON_VERSIONS: List\[str\] = \["3.8"\]',
'SYSTEM_TEST_PYTHON_VERSIONS: List[str] = ["3.10"]'
)


Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can all be done with the following additional parameters in the common.py_library call:

default_python_version="3.10",
system_test_python_versions=["3.10"],

@chalmerlowe
chalmerlowe merged commit ea851ce into mainOct 23, 2025
19 checks passed
@chalmerlowe
chalmerlowe deleted the feat/add-python-3.13 branch October 23, 2025 15:30
@release-pleaserelease-pleaseBot mentioned this pull request Oct 23, 2025
parthea added a commit that referenced this pull request Nov 12, 2025
🤖 I have created a release *beep* *boop*
---
##
[0.36.0](v0.35.1...v0.36.0)
(2025-11-05)
### Features
* Add support for Python 3.14
([#321](#321))
([99c0adb](99c0adb))
* Adds Python 3.13 support
([#319](#319))
([ea851ce](ea851ce))
---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Anthonios Partheniou <partheniou@google.com>
parthea added a commit to googleapis/google-cloud-python that referenced this pull request Nov 24, 2025
🤖 I have created a release *beep* *boop*
---
##
[0.36.0](googleapis/python-dns@v0.35.1...v0.36.0)
(2025-11-05)
### Features
* Add support for Python 3.14
([#321](googleapis/python-dns#321))
([99c0adb](googleapis/python-dns@99c0adb))
* Adds Python 3.13 support
([#319](googleapis/python-dns#319))
([ea851ce](googleapis/python-dns@ea851ce))
---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com>
Co-authored-by: Anthonios Partheniou <partheniou@google.com>
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

api: dnsIssues related to the googleapis/python-dns API.size: sPull request size is small.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@chalmerlowe@gkevinzheng@chingor13@yoshi-kokoro