Commit graph

10 commits

Author SHA1 Message Date
9802566ec9 Refactor mass rebuild scripts to use dynamic MASSREBUILDS config (#13425) (#13045)
All checks were successful
/ test (push) Successful in 2s
This PR addresses ticket #13425 by centralizing the release configuration for the mass rebuild orchestration tools, establishing a single source of truth for future Fedora release cycles.

Previously, scripts like `find_failures.py` and `need_rebuild.py` relied on hardcoded variables (e.g., `rebuildid = 'f45'`) that required manual bumps in multiple files.

**Changes Made:**

* **Centralized Configuration:** Removed hardcoded variables from `find_failures.py` and `need_rebuild.py`. They now import the `MASSREBUILDS` dictionary from `mass_rebuilds_info.py` to pull `buildtag`, `desttag`, `epoch`, and `targets`.
* **Dynamic Resolution:** By default, scripts will now dynamically calculate and target the highest release version available in the dictionary.
* **Added CLI Flag:** Introduced a `--rebuildid` argument via `argparse` to allow operators to override the default and target specific older releases (e.g., `--rebuildid f44`).
* **Documentation:** Appended a usage section to the `README.md` detailing the new flag and the centralized configuration source.

**Testing Notes:**

* Verified the scripts parse arguments and load the dictionary correctly locally via `--help`.
* *Note:* The existing `test_mass_rebuild.py` test suite only covers the network retry mechanisms in `mass_rebuild.py` and does not currently mock or cover `find_failures.py` or `need_rebuild.py`.

**Resolves:** #13425

Reviewed-on: #13045
2026-09-08 04:54:25 +00:00
d13191f8b3 Harden dist-git gating: fix TOCTOU, surface Koji errors, add edge-case tests
All checks were successful
/ test (push) Successful in 2s
Self-review caught a few rough edges in the dist-git mismatch skip
  logic added in c93d4ef:

  - append_distgit_skip_report checked file existence before opening it;
    replaced with report.tell() == 0 inside the open context to close
    the race window.
  - getBuild fallback was silently swallowing exceptions; now logs a
    warning to stderr so Koji flaps are visible in the run log.
  - Guarded tagged_nvr against None in the skip message to avoid
    confusing "tagged build None" output.
  - Added two missing test cases: a releng bump stacked on top of a
    maintainer commit (must still skip), and divergent history from a
    force-push (merge-base --is-ancestor must catch it).

Signed-off-by: Samyak Jain <samyak.jn11@gmail.com>
2026-09-07 06:21:35 +00:00
cb7cf5fd86 use runmeoutput for git probes and log skip reasons
Signed-off-by: Samyak Jain <samyak.jn11@gmail.com>
2026-09-07 06:21:35 +00:00
4fb4081d0f Skip mass rebuilds when dist-git is ahead of the tagged build
Avoid rebuilding packages whose rawhide HEAD has non-releng commits
beyond the latest build in desttag, so failed-gating content is not
bumped into the rebuild tag. Log skips to skipped_distgit_mismatch.txt.

Fixes: releng/tickets#13428

Signed-off-by: Samyak Jain <samyak.jn11@gmail.com>
2026-09-07 06:21:35 +00:00
26278a8bf3 Restore mass rebuild restart skips and fix live logging.
All checks were successful
/ test (push) Successful in 3s
Skip packages that already have a checkout, so interrupted runs
Resume past cloned trees instead of deleting and recloning.
Line-buffer output for tee, we used to do it in the last script.

Signed-off-by: jnsamyak <samyak.jn11@gmail.com>
2026-07-15 18:35:14 +00:00
64e7c8dad5 Fix mass rebuild retry logic for safer first run - shorten backoff
All checks were successful
/ test (push) Successful in 3s
Signed-off-by: Samyak Jain <samyak.jn11@gmail.com>
2026-07-15 22:48:50 +05:30
Patrik Polakovič
6252b47ca4 Update mass rebuild scripts for F45
All checks were successful
/ test (push) Successful in 3s
Signed-off-by: Patrik Polakovič <patrik@alphamail.org>
2026-07-15 19:14:18 +02:00
d964027a7b More refine the mass rebuild script with the feedback recieved
All checks were successful
/ test (push) Successful in 2s
Signed-off-by: Samyak Jain <samyak.jn11@gmail.com>
2026-03-08 03:44:23 +00:00
b2a1fdc17d feat(mass_rebuild): updating mass rebuild scripts for f44
Signed-off-by: Anton Medvedev <amedvede@redhat.com>
2026-01-14 23:33:00 +01:00
6554031ffb Migration to Forgejo: releng/tooling Pt 1
Signed-off-by: Samyak Jain <samyak.jn11@gmail.com>
2025-10-10 12:59:13 +05:30
Renamed from scripts_new/release-process/mass-rebuilds/mass_rebuild.py (Browse further)