Skip to content

chore(dataflow/gemma): update dependencies and format code#14321

Draft
XrossFox wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
XrossFox:package-update-dataflow-gemma
Draft

chore(dataflow/gemma): update dependencies and format code#14321
XrossFox wants to merge 1 commit into
GoogleCloudPlatform:mainfrom
XrossFox:package-update-dataflow-gemma

Conversation

@XrossFox

Copy link
Copy Markdown
Contributor

Description

  • Update tensorflow base image to 2.20.0-gpu and beam sdk to 3.11/2.74.0
  • Update apache_beam, keras, keras_nlp, and protobuf dependencies
  • Update test dependencies including google-cloud-aiplatform, storage, and pytest
  • Format custom_model_gemma.py and e2e_test.py
  • Update ignored python versions in noxfile_config.py

Fixes b/521868825

Checklist

Testing

  • I have tested this change on a live environment and verified it works as intended.

Compliance & Style


Post-Approval Actions

  • Please merge this PR for me once it is approved

 - Update tensorflow base image to 2.20.0-gpu and beam sdk to 3.11/2.74.0
 - Update apache_beam, keras, keras_nlp, and protobuf dependencies
 - Update test dependencies including google-cloud-aiplatform, storage, and pytest
 - Format custom_model_gemma.py and e2e_test.py
 - Update ignored python versions in noxfile_config.py
@product-auto-label product-auto-label Bot added api: dataflow Issues related to the Dataflow API. samples Issues that are directly related to samples. labels Jun 16, 2026

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

Copy link
Copy Markdown
Contributor

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 Gemma Dataflow sample by changing the Python SDK base image from version 3.14 to 3.11, upgrading TensorFlow to 2.20.0, and updating Apache Beam to 2.74.0. It also upgrades several runtime and test dependencies and applies code formatting across multiple files. Feedback on the changes suggests updating noxfile_config.py to ignore Python versions 3.12, 3.13, and 3.14 to align with the target Python 3.11 environment and prevent redundant test runs.

"PYTHONPATH": ".."
},
# Note: Docker-based sample, testing only against version specified in Dockerfile (3.11)
"ignored_versions": ["3.8", "3.9", "3.10"],

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

medium

The comment on line 21 states that this is a Docker-based sample, testing only against the Python version specified in the Dockerfile (3.11). However, the ignored_versions list only ignores 3.8, 3.9, and 3.10, which means tests will still run on 3.12, 3.13, and 3.14. To align with the comment and avoid redundant test runs on other Python versions, please ignore all versions except 3.11.

Suggested change
"ignored_versions": ["3.8", "3.9", "3.10"],
"ignored_versions": ["3.8", "3.9", "3.10", "3.12", "3.13", "3.14"],
References
  1. When upgrading test dependencies that require a minimum Python version, ensure that test configurations (e.g., ignored_versions in noxfile_config.py) are updated to ignore incompatible Python versions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: dataflow Issues related to the Dataflow API. samples Issues that are directly related to samples.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant