Repository navigation
fix(dispatch): diagnose non-JSON dispatch responses - #385
Merged
Merged
Conversation
what changed: dispatchCollection parses successful responses through readJsonBody; the existing malformed-body regression now covers dispatch as well as run/artifact lookup. why: A maintenance page was diagnosed as missing workflow_run_id and suggested pinning an API version already pinned. This restores the existing BAD_BODY contract; no alternative design was set aside. what it touched: dispatch.mjs, dispatch.test.mjs, its architecture map row and CHANGELOG.md; existing ADR-0033 semantics, no new domain terms. what you verified: verified - red-first dispatch reproduction (31 passed, one expected failure), then passing targeted dispatch tests. The required complete offline suite runs in the commit gate. what you got wrong and fixed: mistake - running six full suites concurrently exceeded the default 3900-second budget; where - local commit validation on this Windows host; impact - affected hooks refused commits before publication; cause - excess concurrent subprocess and filesystem work; fix - retry one commit at a time with the ADR-0142 timeout extension (RESEARCH_KIT_GATE_TIMEOUT=7920); verified - the required full-suite commit gate accepted the commit.
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.
A successful HTTP dispatch response containing HTML instead of JSON was reported as
NO_RUN_ID, with a remedy to pin the API version already pinned on the request. Parse dispatch responses through the existingreadJsonBodyhelper so this case returnsBAD_BODYand the proxy/maintenance-page remedy. JSON missing a run ID still returnsNO_RUN_ID.Fixes #377
what changed: Shared successful-body parsing with run and artifact lookup, and extended existing malformed-body coverage to dispatch.
why: Diagnose an unreadable response body separately from a valid JSON response lacking its required run ID. No alternative design was set aside.
what it touched:
lib/dispatch.mjs, dispatch tests, architecture row and changelog. Existing ADR-0033 behavior; no new domain term or interface.what you verified: verified - red-first reproduction (31 passed, one expected failure), then 32 passing dispatch tests. The required full suite was accepted by the repository commit gate.
what you got wrong and fixed: mistake - running six full suites concurrently exceeded the default 3900-second budget; where - local commit validation on this Windows host; impact - affected hooks refused commits before publication; cause - excess concurrent subprocess and filesystem work; fix - retry one commit at a time with the ADR-0142 timeout extension (RESEARCH_KIT_GATE_TIMEOUT=7920); verified - the required full-suite commit gate accepted the commit.
Full-suite detail: verified - 1777 passed, 0 failed, 12 unsupported capabilities on win32/Node 24.20.0 in 1662.8 seconds. The gate's documented local unsupported-capability opt-in was used; CI exercises its supported platforms separately.