feat: add the real-condition campaign runner

campaign.py takes buildbot nightlies (or a build of the pinned commit), the test content of tests/campaign/content.yml through romfetch, and runs core_probe for the files, boot, path, alias, variants and bench checks. A fixed rule table settles hle_fallback, required, path and aliases with the record ids as evidence, the rest goes to measurements/findings.jsonl. Resumable state, load, disk and budget guards, retries, content reference counting with an LRU cap, and an autorun job after the nightly.
This commit is contained in:
Abdessamad Derraz committed 2026-10-27 11:38:01 +01:00
1 parent faa79c5920
commit ee7319d838
16 files changed
+2990 -11

No files matched your search

+4
View File
@@ -54,6 +54,7 @@ JOBS_FILE = REPO_ROOT / "automation" / "jobs.yml"
AUTORUN_DIR = Path(".cache") / "autorun"
DEFAULT_LOCK = Path.home() / ".local" / "state" / "retrobios" / "auto.lock"
LOCK_ENV = "RETROBIOS_AUTO_LOCK"
LOCK_HELD_ENV = "RETROBIOS_AUTO_LOCK_HELD"
BRANCH = "autorun"
REMOTE = "origin"
@@ -726,6 +727,9 @@ def set_alert(state: dict, name: str, active: bool, detail: str, now: str) -> No
def job_env(job: Job) -> dict[str, str]:
env = os.environ.copy()
env["RETROBIOS_AUTO"] = "1"
if job.lock:
# A step that takes the host lock itself (campaign.py) runs under ours.
env[LOCK_HELD_ENV] = "1"
if job.network:
sys.path.insert(0, str(REPO_ROOT / "scripts"))
from common import github_token