Run the level 4 scenarios with one command

make level4 runs the level 3 and level 4 scenarios of the pipeline suite
and the invariants into evidence/level4.json. New scenarios: worker_limits
(a 40 Mpx render under a 0.5 s timeout and a 200 MiB address space fails
with processing_failed while the worker keeps running, then succeeds with
the default limits under the container limit), retry_backoff_jitter
(delays from the job journal stay within [d/2, d] and differ) and
failed_retention (failed staging is kept, removed after the retention,
then replay answers expired). The stalled holder must be fenced and the
republished copy must be a no-op. The faults override passes the stall,
render limits and retention through; the admin CLI is python -m
messenger.admin. make failed, make replay ID=... and make dlq are the
operator entry points; the lab 4 target becomes lab4-level4. CI runs
level4 instead of level3. The registry prints ISO timestamps.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Artyom
2026-10-29 03:19:28 +03:00
co-authored by Claude Opus 5.5
parent b568fcf9c9
commit b9d28d190e
8 changed files with 136 additions and 18 deletions
+2 -1
View File
@@ -2,7 +2,7 @@ import asyncio
import json
import subprocess
import sys
from datetime import timedelta
from datetime import datetime, timedelta
from uuid import UUID, uuid4
import pytest
@@ -295,6 +295,7 @@ async def test_operator_cli_lists_failed_jobs_and_replays(
assert await serve(["failed", "--limit", "500"]) == 0
registry = json.loads(capsys.readouterr().out.splitlines()[-1])["failed"]
(mine,) = [row for row in registry if row["attachment_id"] == attachment_id]
assert datetime.fromisoformat(mine["failed_at"]).utcoffset() == timedelta(0)
assert (mine["error_code"], mine["attempt"], mine["last_error"]) == (
"retry_exhausted",
5,