Skip to content

fix(providers): recover rejected 9router fields and preserve retry bodies - #16133

Merged
diegosouzapw merged 1 commit into
release/v3.8.52from
fix/14629-ninerouter-residual-1010
Oct 10, 2026
Merged

diegosouzapw merged 1 commit into
release/v3.8.52from
fix/14629-ninerouter-residual-1010

Conversation

@diegosouzapw

Copy link
Copy Markdown
Owner

After a 9router reasoning retry, the executor returned the original request body even though it had sent a corrected one. It also returned recoverable field-rejection 400s directly and repeated known reasoning failures on subsequent calls.

This completes the proven NineRouter portion after #15946:

  • Return the body actually sent after recovery, preserving the caller's input.
  • Apply the existing bounded field-downgrade helper after reasoning recovery, for HTTP 400 only, using the same URL, headers and abort signal.
  • Apply only observed reasoning-effort capabilities before subsequent attempts. Use the forwarded model identity consistently, preserving inner slashes and transparency for models with no learned capability.

Refs #14629

This is a partial umbrella delivery. Other named executor paths still require their own contract/probe checks; it does not migrate every override, extend generic recovery to 422, or add speculative static normalization. No shared helper or other provider is changed.

Validation

Three TDD slices on exact base 122b43b35dbacab03ea67d0f0b46e713280ccd86, with identical fixture hashes for each RED/GREEN pair:

  • Returned-body consistency: 1 failing case plus 1 passing control → 2 passed.
  • Named fields and reasoning→field chaining: 3 failures plus 2 controls → 5 passed.
  • Learned effort across calls and model-prefix variants: 3 failures plus 5 controls → 8 passed.

Final matrix: 17/17 passed. All direct importers and related reasoning/field/NineRouter suites: 26 files, 323/323 passed, no skips or cancellations. Tests cover both forwarded protocol shapes, caller immutability, transport preservation, bounded retries, unknown/absent fields, 401/429/500, generic 422 and service-unavailable behavior.

Core and dashboard typechecks, cyclomatic and cognitive complexity, focused ESLint/Prettier, file-size, test discovery, changelog integrity and normal automatic commit hooks passed. Independent SPEC/Standards review found no blocking issues; all three frozen file hashes remained unchanged through commit.

Tests use isolated HOME/DATA_DIR/plugins and blocked external sockets with intercepted HTTP. They prove executor dispatch/body behavior and abort-signal propagation, not a live 9router deployment or an upstream account run. The repository-wide CI/base work remains tracked in #15306; existing PRs #16130 and #15945/#15948 cover mutation selection and generated-skills issues rather than duplicating them here.

@github-actions

Copy link
Copy Markdown
Contributor

CI Coverage Report

  • Coverage job: skipped
  • PR test policy: success

Coverage artifact was not available for this run.

@diegosouzapw
diegosouzapw merged commit 8a53d9f into release/v3.8.52 Oct 10, 2026
26 of 51 checks passed
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