chore(multiple samples) Update pytest dependencies to solve dependabot security alerts.#14147
Open
XrossFox wants to merge 12 commits into
Open
chore(multiple samples) Update pytest dependencies to solve dependabot security alerts.#14147XrossFox wants to merge 12 commits into
XrossFox wants to merge 12 commits into
Conversation
dpendencies that were failing to build.
Contributor
There was a problem hiding this comment.
Code Review
This pull request updates several dependencies, but the review identifies that the specified versions for pytest and google-cloud-storage do not exist on PyPI, which will cause installation failures. Additionally, the reviewer suggests splitting the PR to separate test and production dependency updates to follow the best practice of focusing on a single change per pull request.
supportd, and max version supported (3.10 and 3.14).
… of python (3.10 and 3.14)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR is an attempt at upgrading Pytest dependencies for all samples. Update from various older versions to Pytest 9.0.3. This is to solve about 381 dependabot security alerts.
Also took the liberty to update most noxfile_config.py files to run the most older and newest versions of python, 3.10 and 3.14. This is because Pytest 9.0.3 only supports Python 3.10 onwards, since previous python versions have already been discontinued by October 31 2025.
Also updated base noxfile-template to reflect this change.
Extra: fixed some dependencies that had ditched support for older python versions, and ran linter for some samples as part of nox test command.
Fixes b/511241844
Regarding failing pipelines:
I have reviewed pipelines and all remaining errors or failures are unrelated to Pytest updates, with one exception.
This is the list of failing samples, which will be fixed in a case by case basis independently at a later point.
all appengine/ (most appengine samples are older and do not use nox)
appengine/flexible/storage
appengine/flexible/tasks
asset/snippets/
custom-credentials/aws/
custom-credentials/okta
cloud_tasks/http_queues
cloud_tasks/snippets
compute/client_library
compute/oslogin
dataflow/gemma/streaming
dataflow/gpu-examples/pytorch-minimal
gpu-examples/tensorflow-minimal
dataflow/run-inference
dataflow/snippets
datalabeling/snippets [BREAKING CHANGE with Pytest 9.0.3]
-dataproc/snippets
-datastore/samples/snippets
-alloydb/notebooks
-automl/snippets
-blog/introduction_to_data_models_in_cloud_datastore
-contact-center-insights/snippets
contentwarehouse/snippets
dialogflow
dlp/snippets
document/ai
iam/cloud-client/snippets
genai/video_generation
model_garden/anthropic
monitoring/opencensus
optimization/snippets
people-and-planet-ai/weather-forecasting/tests/overview_tests
pubsublite/spark-connector
recaptcha_enterprise/snippets
retail/interactive-tutorials/search
securitycenter/snippets_management_api
securitycenter/snippets_v2
tpu