Skip to content

ci: test on pull requests against Keras 3 and Keras 2 - #27

Merged
JesperDramsch merged 3 commits into
mainfrom
ci/keras3-and-keras2
Oct 12, 2026
Merged

JesperDramsch merged 3 commits into
mainfrom
ci/keras3-and-keras2

Conversation

@JesperDramsch

@JesperDramsch JesperDramsch commented Oct 12, 2026 •

Copy link
Copy Markdown
Owner

Replaces the push-only workflow, which tested Python 3.8 to 3.10 against whatever TensorFlow was latest, with jobs that run on pull requests and pushes to main.

Jobs

Job Installed Result on current main
Keras 3, Python 3.11 tensorflow 2.21.0, keras 3.15.1 5 failed, 3 passed
Keras 3, Python 3.12 tensorflow 2.21.0, keras 3.15.1 5 failed, 3 passed
Keras 3, Python 3.13 tensorflow 2.21.0, keras 3.15.1 5 failed, 3 passed
Keras 2 (TensorFlow 2.15), Python 3.11 tensorflow 2.15.1, keras 2.15.0 8 passed
Keras 2 (tf-keras), Python 3.11 tensorflow 2.21.0, tf-keras 2.21.0, TF_USE_LEGACY_KERAS=1 8 passed
lint flake8, syntax errors and undefined names only, as before passed

The Keras 3 failures are expected. They are #23: add_weight receives the name positionally in ComplexConv, and ComplexBatchNormalization uses add_update/K.in_train_phase, which Keras 3 removed. Merging this first means #24 and the batch-norm fix that follows can show their results in CI, and you can watch the Keras 3 jobs go green.

Details

  • fetch-depth: 0, so setuptools-scm finds the tags.
  • fail-fast: false, so one failing job doesn't cancel the rest. That cancellation hid the 3.8 and 3.9 results in the old workflow.
  • uv through astral-sh/setup-uv@v10.3.0, pinned to an exact tag because that action publishes no floating major tag.
  • Each job logs the TensorFlow, Keras and tf-keras versions it installed.
  • The workflow file passes the GitHub workflow schema (check-jsonschema --builtin-schema vendor.github-workflows).

pre-commit.ci

The pre-commit.ci app runs on this repo but found no config, so every PR got "error during ci config". The new commit adds a .pre-commit-config.yaml with read-only hooks from pre-commit-hooks v6.0.0: check-yaml, check-toml, check-merge-conflict and check-added-large-files. Nothing gets reformatted, so it doesn't collide with #24.

.gitignore has ignored every *.yaml file since the 2017 import, which would have kept the config out of git. It now has one exception for this file; the blanket rule stays. All four hooks pass locally (uvx pre-commit run --all-files) and on pre-commit.ci.

@JesperDramsch
JesperDramsch merged commit 989c4d4 into main Oct 12, 2026
4 of 7 checks passed
@JesperDramsch
JesperDramsch deleted the ci/keras3-and-keras2 branch October 12, 2026 10:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant