WARN on and ignore Pulp-hosted shaman results when package_source: shaman AND sha1s of package repos lacking a container image - #2245
Open
djgalloway wants to merge 3 commits into
Open
Conversation
Security builds from the cve-pipeline are pushed to the lab-internal Pulp
but still registered in shaman, with `url`/`chacra_url` pointing at
Pulp. shaman lists them first (newest), so ShamanProject picked them for
sha1s that also had a regular chacra build and then 404'd fetching
`<chacra_url>/repo` from the Pulp API:
HTTPError: 404 Client Error: Not Found for url:
https://pulp.front.sepia.ceph.com/pulp/api/v3/repositories/rpm/rpm/<uuid>/repo
ShamanProject now filters out Pulp-hosted entries and uses the first
usable (chacra) one. A sha1 that only has a Pulp build is treated as not
found; the new `pulp_only` property lets teuthology-suite tell the two
cases apart.
Signed-off-by: David Galloway <david.galloway@ibm.com>
When backtracking with --newest, a sha1 whose packages exist only on the lab-internal Pulp (e.g. a security build) is now skipped with a warning that says so and, if the run does not select `package_source: pulp` and `defaults.cephadm.containers.image: quay-int.front.sepia.ceph.com/ceph-ci/ceph`, how to opt in. The same hint is logged for non-newest runs before they fail on missing packages. To know what the run selects, teuthology-suite now reads the extra <config_yaml> files it is given (previously only forwarded to teuthology-schedule). A job-level `package_source` is also honored for the schedule-time package checks, mirroring teuthology.run, so a run that passes a pulp.yaml has --newest verify sha1s against Pulp instead of shaman. If no Pulp credentials are configured on the scheduling host it falls back to the site package_source with a warning. Signed-off-by: David Galloway <david.galloway@ibm.com>
djgalloway
requested review from
kshtsk and
zmc
and removed request for
a team
August 18, 2026 15:40
Release builds (ceph-release-pipeline -> ceph-dev-pipeline with
CI_CONTAINER=false) publish packages and register as completed in shaman,
but push no ceph-ci container. teuthology-suite only checked shaman, so
--newest would happily pick such a sha1 and every cephadm job would then
fail pulling quay.ceph.io/ceph-ci/ceph:<sha1>.
For jobs whose tasks use cephadm, ask the registry of the configured
cephadm image (defaults/overrides.cephadm.containers.image) whether
<image>:<sha1> exists, via the registry v2 manifest endpoint (anonymous
bearer tokens are fetched when challenged). If it does not:
ceph sha1 <sha1> has packages but no container at <image>:<sha1>.
Pending release build, or failed container build of a passed package
build? Moving on to the next sha1 of <ref>
and, in --newest mode, the sha1 is treated like one with missing packages
so we back off to the next one. Without --newest it is only a warning.
If the registry can't be queried (auth we can't satisfy, network error),
scheduling proceeds as before. Jobs that don't use cephadm never trigger
the lookup, so non-container suites can still test release sha1s.
Signed-off-by: David Galloway <david.galloway@ibm.com>
djgalloway
force-pushed
the
teuthology-latest-warning-0a486d
branch
from
August 18, 2026 16:40
0c237ff to
5791486
Compare
Member
|
Why are pulp-only builds registered with shaman at all? |
Contributor
Author
The pulp GUI is half-baked as you know. Devs would have no way of knowing the status of their branch being built. We could make shaman interface with pulp directly but, for now, we're tricking shaman by giving it pulp URLs. |
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.
Problem
Security builds from the cve-pipeline are pushed to the lab-internal Pulp but still registered in shaman, with
url/chacra_urlpointing at Pulp. Shaman lists them first (newest), so for a sha1 that has both a cve build and a regular chacra build,ShamanProjectpicked the Pulp-hosted entry and 404'd fetching<chacra_url>/repofrom the Pulp API:Because
teuthology-suite's schedule-time package check uses the sameShamanProject,--newesthappily scheduled that sha1 too.Changes
packaging: ignore Pulp-hosted shaman resultsShamanProjectfilters out search results whoseurl/chacra_urlare Pulp-hosted and uses the first usable (chacra) one. For the sha1 above,repo_urlnow resolves tohttps://3.chacra.ceph.com/repos/ceph/tentacle/66f67bca.../rocky/10/flavors/default/repo(verified against live shaman).package_source: shaman, a sha1 that only has a Pulp build is treated as not found; newpulp_onlyproperty tells the two cases apart.package_source: pulpis unaffected:PulpProjectnever consults shaman, it searches the Pulp API directly.suite: warn and back off when --newest hits a Pulp-only sha1--newest: a Pulp-only sha1 is skipped with a warning saying so and, if the run doesn't selectpackage_source: pulpanddefaults.cephadm.containers.image: quay-int.front.sepia.ceph.com/ceph-ci/ceph, how to opt in. Non-newest runs get the same hint in the error before failing on missing packages.teuthology-suitenow reads the extra<config_yaml>files it's given (previously only forwarded toteuthology-schedule) so it can tell what the run selects.package_sourceis honored for the schedule-time checks (mirroringteuthology.run), so passingpulp.yamlmakes--newestverify against Pulp instead of shaman. Falls back to the sitepackage_sourcewith a warning if no Pulp credentials are configured on the scheduling host.--newesthelp text updated.suite: back off with --newest when a sha1 has packages but no containerRelease builds (
ceph-release-pipeline→ceph-dev-pipelinewithCI_CONTAINER=false) have packages and acompletedshaman build record, but no ceph-ci container — e.g. tentacle7f793731…right now: shaman says ready,quay.ceph.io/ceph-ci/ceph:7f793731…is 404. Nothing in shaman records this, so--newestwould pick it and cephadm jobs would fail to pull.For jobs whose tasks use
cephadm, ask the registry of the configured cephadm image (defaults/overrides.cephadm.containers.image) whether<image>:<sha1>exists (registry v2 manifest HEAD; anonymous bearer token fetched when challenged). If not:and with
--newestthe sha1 is treated like missing packages so we back off. Without--newestit's only a warning. If the registry can't be queried, scheduling proceeds as before. Non-cephadm jobs never trigger the lookup, so non-container suites can still test release sha1s.Verified live:
quay.ceph.io/ceph-ci/ceph:7f793731…→ missing,:66f67bca…→ exists; Docker Hub token flow works (alpine:latest).Reviewer notes
chacra_url/url. If that ever stops, Pulp-only sha1s just look "not found" (no false positives, but the explanatory warning goes away). Noted inShamanProject.pulp_onlyandutil.hash_only_in_pulp.teuthology/suite/run.py(INTERNAL_*); happy to make them site-config knobs if preferred.Testing
tests/test_packaging.py,tests/suite,tests/scripts/test_suite.py,tests/task/test_install.py: 321 passed. New tests cover the exact two-entry shaman response from the failing job, the Pulp-only case, config-based detection of pulp/quay-int selection, an end-to-end--newestrun that skips a Pulp-only sha1 with one warning, the registry helper (200/404/401+token/error), and an end-to-end--newestrun that skips a container-less sha1.