Skip to content

feat(client-contract): add the timed_out no_data reason - #19

Merged
jm-rivera merged 1 commit into
devfrom
feat/gap-timed-out
Oct 24, 2026
Merged

jm-rivera merged 1 commit into
devfrom
feat/gap-timed-out

Conversation

@jm-rivera

Copy link
Copy Markdown
Contributor

Search answers a part that its request deadline cut short with a no_data reason of its own, so a client can tell "Search ran out of time" from "Search found nothing". DevelopmentFinanceObservatory/apis#98 introduced that reason as timeout, which is already the client code for a transport timeout, with action report and no gap kind. A consumer that looked up the action by code would tell the user to report a part that is worth sending again.

registries/codes.json (and its copy under python/spec-kit) gains the active refusal timed_out, owned by search, mapped on search.resolve for the raw_text, parsed and dataset_resubmit doors on the no_data_reason channel, the same doors as variable_not_resolved. actions.json gains its row with action ask_data_question and gap kind timed_out, and actions.schema.json admits timed_out as a gap kind; scenario.schema.json and the capture and validator tools already used that gap kind for parts flagged by diagnostics.timed_out. The timeout entry is unchanged. apis renames its reason to timed_out and pins this commit in DevelopmentFinanceObservatory/apis#98.

The schema has no retry action, so the row takes ask_data_question, the action every other no_data reason without a choice takes.

Testing: tools/validate_registry.py (205 entries) and tools/validate_client_contract.py (102 action rows, 118 scenarios) pass; tools/tests 519 passed, python/client-contract 78 passed, python/spec-kit 259 passed. A new validator case drops the timed_out row and expects the validator to refuse.

Search gives a part its request deadline cut short a no_data reason of
its own. The registry and actions.json gain timed_out, with action
ask_data_question and gap kind timed_out, which actions.schema.json now
admits. The name keeps clear of the client code timeout, a transport
timeout with action report.
@jm-rivera
jm-rivera merged commit ba976a2 into dev Oct 24, 2026
19 checks passed
@jm-rivera
jm-rivera deleted the feat/gap-timed-out branch October 24, 2026 09:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant