Repository navigation
Commit 618e7e9
ikeboy003
pingdotgg#469: prove the thread-snapshot route is SERVED, not merely present in source
The route and handler are on main already — I restored both in a077b2e as
pingdotgg#436, since the abandoned clau-031c-ui merge had taken them out by resolving
server_main.rs to theirs wholesale. This adds the assertion that was missing.
A route existing in source is not the same as the router serving it. A path
registered under the wrong prefix, or shadowed by the capture_http fallback,
greps identically to a working one — and the original symptom was precisely a
fallthrough:
WARN http: no route -> 404 GET /api/orchestration/threads/29e30a3f-...
on the REAL thread id, so promotion never completed and the view stayed on
/draft/<id> while the turn ran to completion somewhere it was not looking.
So the test binds the REAL router with `build_app` and speaks HTTP to it over a
socket, which is the only form that can tell a served route from a registered
one. Raw TCP rather than a client crate: no new dependency for one GET.
It asserts NOT-404, not 200. With no such thread the honest answer is a failure
body from the handler — demanding 200 would push it to invent a snapshot for a
thread that does not exist, which is what its own "the DURABLE record is the
authority" comment refuses to do.
Falsified on woodbine: with the `.route("/api/orchestration/threads/{thread_id}",
...)` line deleted the test FAILS; restored, it passes. It discriminates.1 parent b78b109 commit 618e7e9
1 file changed
Lines changed: 59 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1248 | 1248 | | |
1249 | 1249 | | |
1250 | 1250 | | |
| 1251 | + | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
| 1258 | + | |
| 1259 | + | |
| 1260 | + | |
| 1261 | + | |
| 1262 | + | |
| 1263 | + | |
| 1264 | + | |
| 1265 | + | |
| 1266 | + | |
| 1267 | + | |
| 1268 | + | |
| 1269 | + | |
| 1270 | + | |
| 1271 | + | |
| 1272 | + | |
| 1273 | + | |
| 1274 | + | |
| 1275 | + | |
| 1276 | + | |
| 1277 | + | |
| 1278 | + | |
| 1279 | + | |
| 1280 | + | |
| 1281 | + | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
| 1285 | + | |
| 1286 | + | |
| 1287 | + | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
| 1293 | + | |
| 1294 | + | |
| 1295 | + | |
| 1296 | + | |
| 1297 | + | |
| 1298 | + | |
| 1299 | + | |
| 1300 | + | |
| 1301 | + | |
| 1302 | + | |
| 1303 | + | |
| 1304 | + | |
| 1305 | + | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
1251 | 1310 | | |
1252 | 1311 | | |
1253 | 1312 | | |
| |||
0 commit comments