chore: remove Python 3.9 from default nox session#17017
Conversation
There was a problem hiding this comment.
Code Review
This pull request removes Python 3.9 from the test sessions in the nox configuration for the Google Cloud Spanner package. The reviewer noted that such infrastructure updates should be applied consistently across all relevant packages in a single pull request and advised updating project metadata and following a minor version bump strategy for this breaking change.
| CURRENT_DIRECTORY = pathlib.Path(__file__).parent.absolute() | ||
|
|
||
| nox.options.sessions = [ | ||
| "unit-3.9", |
There was a problem hiding this comment.
This change appears to be part of a global infrastructure update (removal of Python 3.9). According to repository rules, changes to shared configurations should be applied consistently across all relevant packages in a single, universal pull request rather than piecemeal. When this change is consolidated, ensure that the project metadata (e.g., 'python_requires' in 'setup.py' or 'pyproject.toml') is updated to reflect the new minimum version. Additionally, since dropping support for a Python version is a breaking change, ensure a minor version bump is used instead of a patch bump to maintain the ability to provide patches for the previous version.
References
- Changes to shared configurations, like mypy flags, should be applied consistently across all relevant packages in a dedicated, universal change rather than piecemeal in individual pull requests.
- When updating the minimum supported Python version in runtime checks (e.g., 'sys.version_info' checks), ensure that the project's metadata in 'setup.py' or 'pyproject.toml' is also updated to reflect the same minimum version in 'python_requires' and Trove classifiers.
- When a release introduces breaking changes in environment requirements, such as dropping support for specific Python versions or major dependency versions (e.g., protobuf), prefer a minor version bump over a patch version bump.
This PR removes Python 3.9 from the default nox session which is used in continuous builds. Python 3.9 unit tests are still running in presubmits via Github actions but cannot be tested in continuous builds since Python 3.9 has been removed from the testing image as of googleapis/testing-infra-docker#524.