ci(molecule): check container removal by listing what is left
Build / build (pull_request) Successful in 14s
Lint / lint (pull_request) Successful in 1m1s
Molecule / molecule (pull_request) Successful in 14m54s

A removal that fails because another run's sweep was first is harmless,
but checking that with `docker container inspect` also passed when the
daemon could not be reached. Both removal steps now remove what they
can and then list the containers they meant to remove; a failing list
or a container still listed fails the step.

The workflow rules name the test that holds the sweep's age bound to
the job timeout.

Assisted-by: Claude Code:claude-opus-5-5
This commit is contained in:
Defame1297 committed 2026-11-24 10:00:30 +00:00
1 parent 3726b5c53f
commit 1885b3fe99
3 files changed
+20 -16

No files matched your search

+4 -2
View File
@@ -87,8 +87,10 @@ issue.
older than its timeout, which a cancelled run left, and finally its own. The scenarios of one
run overlap (`scripts/run_molecule_scenarios.sh`, `MOLECULE_LANES` at a time), so no two
scenarios may share a platform name. *Why:* a cancelled run is killed before it can remove its
instances, and a younger container may belong to a run still going. *Held:* review; the names
and labels are held by the test the `test_sequence` rule below names.
instances, and a younger container may belong to a run still going. *Held:* review; control:
the names and labels by the test the `test_sequence` rule below names, and the sweep's age bound
equal to the job timeout by `test_the_sweep_spares_containers_younger_than_the_job_timeout` in
`tests/scripts/test_run_molecule_scenarios.py`.
- **Molecule tests the pull request's pins, as Lint and Build do.** It runs molecule in the pinned
`ci` image and, when a pin file differs from `/opt/ci-pins.sha256`, installs the pull request's
tools and the collections of `requirements.yml` and `extensions/molecule/requirements.yml` first.