Hmbown/CodeWhale · error · PersistenceBacklogError
baseline_observation.accepted_requests must equal requests_a
Error message
baseline_observation.accepted_requests must equal requests_attempted
What it means
Raised by validate_budget() when baseline_observation.accepted_requests is not exactly 128, the FIXTURE requests_attempted. The baseline records an all-sends-accepted run: the paused persistence channel must not reject sends, because dropping requests would trivially shrink the backlog. The same accepted == attempted equality is enforced on every receipt.
Source
Thrown at scripts/check-persistence-backlog-budget.py:274
raise PersistenceBacklogError("budget baseline_receipt path changed")
ceilings = budget.get("ceilings")
baseline = budget.get("baseline_observation")
if not isinstance(ceilings, dict) or not isinstance(baseline, dict):
raise PersistenceBacklogError("budget needs ceilings and baseline_observation objects")
for field in CEILING_FIELDS:
ceiling = non_negative_integer(ceilings.get(field), f"ceilings.{field}")
observed = non_negative_integer(
baseline.get(field), f"baseline_observation.{field}"
)
if observed > ceiling:
raise PersistenceBacklogError(
f"baseline_observation.{field} exceeds its ceiling"
)
baseline_accepted = non_negative_integer(
baseline.get("accepted_requests"), "baseline_observation.accepted_requests"
)
if baseline_accepted != FIXTURE["requests_attempted"]:
raise PersistenceBacklogError(
"baseline_observation.accepted_requests must equal requests_attempted"
)
baseline_applied = non_negative_integer(
baseline.get("applied_version"), "baseline_observation.applied_version"
)
if baseline_applied != FIXTURE["expected_applied_version"]:
raise PersistenceBacklogError(
"baseline_observation.applied_version must be the final sent version"
)
baseline_retained = baseline["retained_queued_requests"]
baseline_payload = baseline["estimated_retained_payload_bytes"]
if baseline_retained == 0 or baseline_payload == 0:
raise PersistenceBacklogError(
"baseline_observation must retain the final request and payload"
)
if baseline_retained > baseline_accepted:
raise PersistenceBacklogError(
"baseline_observation.retained_queued_requests exceeds accepted_requests"View on GitHub (pinned to 8880682c63)
Solutions
- Set baseline_observation.accepted_requests to 128
- If the real run rejected sends, fix the persistence channel's acceptance path rather than editing the baseline
- Regenerate the baseline from a clean run of the frozen 128-request workload
Example fix
// before (budget.json)
"baseline_observation": { "accepted_requests": 127, ... }
// after
"baseline_observation": { "accepted_requests": 128, ... } Defensive patterns
Strategy: validation
Validate before calling
def baseline_accepted_ok(budget: dict, attempted: int = 128) -> bool:
return budget.get("baseline_observation", {}).get("accepted_requests") == attempted Prevention
- Load budgets from the repo checkout (scripts/persistence-backlog-budget.json) instead of hand-maintained copies
- Validate budget JSON with python -m json.tool and a key-set check before running the checker
- Change FIXTURE/SCHEMA_VERSION in the checker only together with regenerating budget and baseline receipt in one commit
When it happens
Trigger: baseline_observation.accepted_requests set to 127, 0, a float, or missing - either by hand-editing or because the baseline run's channel actually rejected a send.
Common situations: Hand-crafting a 'smaller' baseline; a baseline captured with a fixture that sent fewer requests; confusing accepted_requests with applied_version counts.
Related errors
- budget fixture no longer matches the frozen workload
- budget fixture.{field} must remain {expected!r}
- baseline_observation.applied_version must be the final sent
- rss_during_delta_bytes is inconsistent
- rss_after_delta_bytes is inconsistent
AI-assisted analysis of Hmbown/CodeWhale@8880682c63 (2026-08-16).
Data as JSON: /api/errors/de3cdb5f1d990763.
Report an issue: GitHub.