Skip to content

chore(several samples) Updating all instances of Pytest up to version 9.0.3 Part II#14231

Draft
XrossFox wants to merge 4 commits into
GoogleCloudPlatform:mainfrom
XrossFox:python-pytest-dependency-update-II
Draft

chore(several samples) Updating all instances of Pytest up to version 9.0.3 Part II#14231
XrossFox wants to merge 4 commits into
GoogleCloudPlatform:mainfrom
XrossFox:python-pytest-dependency-update-II

Conversation

@XrossFox
Copy link
Copy Markdown
Contributor

@XrossFox XrossFox commented May 25, 2026

to close security alerts from dependabot.

Directories that start from C to F.

Extra: modified versions on which pipelines are wllowed to rune, since python 9.0.3 only support Python 3.10 onwards, so pipelines will only run 3.10 and 3.14 versions, which are the older and latest versions that are still maintained.

Some surrounding packages had it's versions updated to avoid building issues with pip.

Notes for specific samples (will be socumented on b/514353082):

  • Composer samples should be addressed on a different PR, it appears most samples cannot simply be updated due to how Airflow works.

  • dataflow/custom-containers have docker images that must be updated to run python 3.10, otherwise will only run python 3.9 internally anyways.

  • dataflow/flex-templates/streaming_beam: same as custom-containers.

Description

Fixes #

Note: Before submitting a pull request, please open an issue for discussion if you are not associated with Google.

Checklist

… 9.0.3 Part II

to close security alerts from dependabot.

Directories that start from C to F.

Extra: modified versions on which pipelines are wllowed to rune, since python 9.0.3 only support Python 3.10 onwards, so pipelines will only run 3.10 and 3.14 versions, which are the older and latest versions that are still maintained.

Some surrounding packages had it's versions updated to avoid building issues with pip.
@product-auto-label product-auto-label Bot added samples Issues that are directly related to samples. api: cloudbuild Issues related to the Cloud Build API. api: cloudmedia Issues related to the Media Livestream API. api: cloudsql api: composer Issues related to the Cloud Composer API. api: tasks Issues related to the Tasks API API. labels May 25, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates the pytest dependency to version 9.0.3 (requiring Python 3.10+) across numerous sample directories and adjusts noxfile_config.py configurations to target Python 3.10 by ignoring other versions. It also updates several Airflow constraints files. The review feedback highlights a critical compatibility issue where upgrading constraints to Airflow 3 in composer/airflow_1_samples will break the Airflow 1.x samples. Additionally, several noxfile_config.py files contain outdated comments referencing older Python versions (such as 3.8, 3.9, or 3.11) as the active test targets, which should be updated to accurately reflect the new Python 3.10 testing environment.

Comment thread composer/airflow_1_samples/constraints.txt Outdated
Comment thread composer/2022_airflow_summit/noxfile_config.py Outdated
Comment thread cloudbuild/snippets/noxfile_config.py Outdated
Comment thread dataflow/custom-containers/miniconda/noxfile_config.py Outdated
Comment thread dataflow/custom-containers/minimal/noxfile_config.py Outdated
Comment thread dataflow/flex-templates/pipeline_with_dependencies/noxfile_config.py Outdated
Comment thread dataflow/flex-templates/streaming_beam/noxfile_config.py Outdated
Comment thread dataflow/gemma/noxfile_config.py Outdated
Comment thread dataflow/run-inference/noxfile_config.py Outdated
Comment thread composer/blog/gcp-tech-blog/unit-test-dags-cloud-build/noxfile_config.py Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: cloudbuild Issues related to the Cloud Build API. api: cloudmedia Issues related to the Media Livestream API. api: cloudsql api: composer Issues related to the Cloud Composer API. api: tasks Issues related to the Tasks API API. samples Issues that are directly related to samples.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant