Files
alkhttp/tasks/infra/review-002-cov-deployment-knobs.md
T
glm-5.3-flash e2c255d40c docs(tasks): decompose review-002 into 24 tasks (23 implementation + 1 bracketed follow-up)
Decomposition of docs/reviews/002-post-remediation-review.md per its
5-unit remediation plan:

- Unit 1 (security-critical): gw15-publish-body-cap,
  prj16-schema-via-call (CF-004 filed alkcall-side), fwd13-dot-segments,
  fwd16-missing-capability, oai11-ref-memoization
- Unit 2 (timeout/terminality): ws13-idle-progress,
  fwd15-stream-timeout, cli01-retry-after-budget, con17-mcp-pagination,
  con18-wss-sweep-exit
- Unit 3 (projection/docs): projection-truthfulness, mcp-batch-cap,
  gw16-status-drift
- Unit 4 (spec-import): yaml-normalization, oai13-path-item-wildcards,
  import-loudness-cluster, js01-placeholder-check,
  fwd17-19-contract-decisions
- Unit 5 (WS polish + tests): con18b-ws-polish,
  client-policy-wire-tests, cov-deployment-knobs, cov13-dead-code,
  srv11-srv12-router-ordering
- review-002-bracketed-followup: tentatively planned post-bulk pass
  (stale-check, OQA-18 enforcement decision, CON-08/09 close() lever,
  cross-crate re-checks) — deliberately not serialized against the
  bulk

Also: review-002 numbering repair (CON-14 was double-booked; MCP
pagination now CON-14, from_wss monitor renumbered CON-18, missing
CON-14 section added).

taskgraph: 66 valid, no cycles; 24 pending (all review-002);
gen-1/gen-2 parallel waves identified; workflow-cost hotspots are
prj16 (12.8) and ws13 (11.1), both carrying the reviewed slicing
guidance in their Notes.
2026-08-30 10:50:34 +00:00

3.4 KiB

id, name, status, depends_on, scope, risk, impact, level, tags
id name status depends_on scope risk impact level tags
review-002-cov-deployment-knobs Coverage — with_ws_idle_timeout integration test, call_tool production dispatch, small dark arms (COV-11b/12) pending
review-002-ws13-idle-progress
moderate low component implementation
infra
review-002
coverage
websocket
mcp

Description

Review 002's deployment-knob coverage gaps — production code paths dark in all binaries:

  • with_ws_idle_timeout (server/adapter.rs:228-242): the WS-13 server-side knob is called by no test — a regression silently disables the idle timer on the default surface while tungstenite unit tests stay green. Add: integration test building via HttpAdapter::new(...).with_ws_idle_timeout(Some(small)) → connect a WS client → assert server closes with 1001 ≈ at the knob; plus a None variant (session survives a long silence). NOTE: the progress-semantics change from review-002-ws13-idle-progress lands first — the 1001 assert must reflect final semantics (progress-based).
  • call_tool production dispatch (to_mcp.rs:459-468): all four tools + unknown-name are tested via invoke_tool, which bypasses call_tool — the rmcp-entered routing shell (what production runs) has never executed. Test: in from_mcp_integration.rs's live-server harness, one client-side peer.call_tool("search"|"batch"|"schema"| "call"|unknown) round-trip through the real rmcp protocol.
  • Small dark arms (COV-12), one test each: to_mcp missing-argument validation for schema (None args) and batch (empty/no calls) tools (:175, :221); from_mcp non-object tool arguments wrapped as {"value": …} (:405-408); routes.rs first- line-invalid-JSON /publish 400 (:263-266); decoy.rs directory→index.html resolution (:133-138); openapi_spec.rs array-of-$ref resolution (:428-433 — the arm the coverage pass initially mis-flagged; the code is correct, add the test) and style: simple + explode: true rejection (:561-566).

Acceptance Criteria

  • Idle-knob integration test (Some(small) → 1001 per final semantics; None → survives) in ws_upgrade_session.rs
  • One rmcp-protocol call_tool round-trip test per tool + unknown (feature mcp)
  • Each small arm test lands (list above; skip any proven unreachable during implementation — document which and why)
  • cargo llvm-cov --all-features re-run: http_client.rs function %, adapter.rs 228-242, to_mcp.rs call_tool no longer dark
  • cargo test --all-features, cargo clippy --all-features --all-targets -- -D warnings, cargo fmt --check pass

References

  • docs/reviews/002-post-remediation-review.md (Part G', COV-11b, COV-12)
  • src/server/adapter.rs:228-242, src/adapters/to_mcp.rs:459-468, tests/ws_upgrade_session.rs, tests/from_mcp_integration.rs
  • tasks/websocket/review-002-ws13-idle-progress.md (lands the semantics this asserts)
  • tasks/adapters/review-002-oai11-ref-memoization.md (owns the array-$ref behavior; this adds only its test if not already added there)

Notes

Sequence after ws13 (the idle-knob assert must match final semantics). The array-$ref test is coverage-only insurance — if review-002-oai11-ref-memoization already added it, check the box and skip. The from_mcp/{"value": …} wrap test goes in from_mcp_integration.rs (real wire behavior).