omnigraph/crates/omnigraph-server
Ragnor Comerford 7d19a76997
mr-668: regression test for nested-route path extraction (red)
`server_branch_delete` and `server_commit_show` use bare
`Path<String>` extractors. In single-mode flat routes
(`/branches/{branch}`, `/commits/{commit_id}`) this works — one
capture, one value. In multi-graph cluster routes
(`/graphs/{graph_id}/branches/{branch}`,
`/graphs/{graph_id}/commits/{commit_id}`) axum 0.8 propagates the
outer `{graph_id}` capture into the inner handler, so the
extractor sees two captures and 500s with
"Wrong number of path arguments. Expected 1 but got 2."

`cluster_routes_dispatch_per_graph_handle` only exercises
`/snapshot` (no Path extractor), so the regression slipped through.
This test closes that gap structurally: every cluster route with
an inner path param gets exercised here.

Currently fails with the exact symptom above. Fix in the next
commit makes it pass.

Per AGENTS.md rule 12, the red test commit lands just before the
fix so the pair is visible in `git log` and a reviewer can check
out this commit alone to reproduce.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 18:18:49 +02:00
..
examples Rename repo terminology to graph (#118) 2026-05-24 16:46:00 +01:00
src mr-668: remove ServerMode, registry field, and the SINGLE_GRAPH sentinel 2026-05-27 13:50:25 +02:00
tests mr-668: regression test for nested-route path extraction (red) 2026-05-27 18:18:49 +02:00
Cargo.toml mr-668: remove POST /graphs and CLI graphs create (defer runtime graph mgmt) 2026-05-26 17:49:38 +02:00