mirror of
https://github.com/kuhyx/testsAndMisc.git
synced 2026-11-10 19:07:04 +01:00
Trigger Python tests when meta/requirements.txt changes
The previous commit fixed the dependency resolution failure that had kept Python tests red since ~2026-08-19 -- and then did not run it, because the workflow's path filter lists "requirements.txt" while the root file is a SYMLINK into meta/. GitHub matches filters against the path as git records it, so editing the real file matched nothing and the red result stayed pinned to an older commit. A gate that cannot be triggered by the change it gates is the same class of problem as the two found earlier today: it reports a stale answer and looks fine. Both spellings are now listed, in the push and pull_request filters. The other root symlinks -- pyproject.toml, run.sh, lint_python.sh, .fvmrc -- are in no workflow filter today, so they carry the same latent trap if one is ever added. CI_GREEN_SKIP=1: the baseline is red only from the pre-fix Python tests run this commit exists to make reachable. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PJrqKERAo5QUeEHWS5Asgp
This commit is contained in:
parent
32de221550
commit
12058a4201
12
.github/workflows/python-tests.yml
vendored
12
.github/workflows/python-tests.yml
vendored
@ -9,7 +9,13 @@ on:
|
||||
- "tests/**"
|
||||
- "linux_configuration/scripts/periodic_background/system-maintenance/bin/**"
|
||||
- "linux_configuration/tests/**"
|
||||
# Both spellings: the root requirements.txt is a SYMLINK into meta/,
|
||||
# and GitHub matches path filters against the changed path as git
|
||||
# records it. Editing meta/requirements.txt therefore did NOT match
|
||||
# "requirements.txt", so a dependency fix silently skipped this
|
||||
# workflow and the red run stayed on an older commit.
|
||||
- "requirements.txt"
|
||||
- "meta/requirements.txt"
|
||||
- ".github/workflows/python-tests.yml"
|
||||
pull_request:
|
||||
branches: [main]
|
||||
@ -19,7 +25,13 @@ on:
|
||||
- "tests/**"
|
||||
- "linux_configuration/scripts/periodic_background/system-maintenance/bin/**"
|
||||
- "linux_configuration/tests/**"
|
||||
# Both spellings: the root requirements.txt is a SYMLINK into meta/,
|
||||
# and GitHub matches path filters against the changed path as git
|
||||
# records it. Editing meta/requirements.txt therefore did NOT match
|
||||
# "requirements.txt", so a dependency fix silently skipped this
|
||||
# workflow and the red run stayed on an older commit.
|
||||
- "requirements.txt"
|
||||
- "meta/requirements.txt"
|
||||
- ".github/workflows/python-tests.yml"
|
||||
workflow_dispatch: {}
|
||||
|
||||
|
||||
@ -0,0 +1,34 @@
|
||||
{
|
||||
"intent": "Make the Python tests workflow actually trigger when the dependency list changes, so a requirements fix cannot silently skip the workflow it is meant to repair.",
|
||||
"scope": [
|
||||
".github/workflows/python-tests.yml (push and pull_request path filters)",
|
||||
"Non-goal: changing the symlink layout, which the repo documents deliberately"
|
||||
],
|
||||
"changes": [
|
||||
"Added meta/requirements.txt alongside requirements.txt in both path filters. The root file is a symlink into meta/, and GitHub matches filters against the path as git records it, so editing the real file did not match the symlink's name."
|
||||
],
|
||||
"verification": [
|
||||
{
|
||||
"command": "Observed on commit 32de2215, which changed meta/requirements.txt",
|
||||
"result": "fail",
|
||||
"evidence": "Dependency Graph, Shell tests and Pre-commit checks all ran; Python tests did NOT trigger at all, leaving the last Python tests result on the older red commit 5ba2cbd4"
|
||||
},
|
||||
{
|
||||
"command": "python3 -c \"import yaml; yaml.safe_load(open('.github/workflows/python-tests.yml'))\"",
|
||||
"result": "pass",
|
||||
"evidence": "YAML valid; both the push and pull_request filter lists were patched (2 occurrences)"
|
||||
},
|
||||
{
|
||||
"command": "gh workflow run 'Python tests' --ref main",
|
||||
"result": "pass",
|
||||
"evidence": "Dispatched run 32645075080 to confirm the dependency fix itself, since the filter bug prevented an automatic run"
|
||||
}
|
||||
],
|
||||
"risks": [
|
||||
"The other root symlinks (pyproject.toml, run.sh, lint_python.sh, .fvmrc) are not referenced by any workflow path filter today, so they carry the same latent trap if one is ever added."
|
||||
],
|
||||
"rollback": [
|
||||
"Remove the meta/requirements.txt lines from both filters.",
|
||||
"After rollback, a change to meta/requirements.txt will once again skip this workflow."
|
||||
]
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user