Commit 36d1c25
fix(client): warn loudly when self-healing accepts stale proxy data
Addresses three findings from external review of the self-healing PR:
1. Detect and warn when a post-self-heal response carries the same
handle we just marked expired. Previously the client silently
accepted stale data with no operator signal — now it emits a
targeted warning naming the handle and pointing at the proxy
cache-key misconfiguration that causes this.
2. Tighten the recovery-guard clearing check from
`accepted + kind === live` to an explicit `status === 204`, matching
the comment's intent and removing latent fragility if the state
machine ever starts transitioning to live for non-204 responses.
3. Update the `#reset()` comment to list all three callers
(#requestShape's 409 handler, #checkFastLoop, and stale-retry
self-healing) instead of only the 409 handler.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 1f7a5f4 commit 36d1c25
File tree
2 files changed
+55
-8
lines changed- packages/typescript-client
- src
- test
2 files changed
+55
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
624 | 624 | | |
625 | 625 | | |
626 | 626 | | |
| 627 | + | |
627 | 628 | | |
628 | 629 | | |
629 | 630 | | |
| |||
1225 | 1226 | | |
1226 | 1227 | | |
1227 | 1228 | | |
| 1229 | + | |
| 1230 | + | |
| 1231 | + | |
| 1232 | + | |
| 1233 | + | |
| 1234 | + | |
| 1235 | + | |
| 1236 | + | |
| 1237 | + | |
| 1238 | + | |
| 1239 | + | |
| 1240 | + | |
| 1241 | + | |
| 1242 | + | |
| 1243 | + | |
| 1244 | + | |
| 1245 | + | |
| 1246 | + | |
| 1247 | + | |
1228 | 1248 | | |
1229 | 1249 | | |
1230 | 1250 | | |
| |||
1239 | 1259 | | |
1240 | 1260 | | |
1241 | 1261 | | |
1242 | | - | |
1243 | | - | |
1244 | | - | |
| 1262 | + | |
| 1263 | + | |
| 1264 | + | |
1245 | 1265 | | |
1246 | 1266 | | |
1247 | 1267 | | |
| |||
1265 | 1285 | | |
1266 | 1286 | | |
1267 | 1287 | | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
| 1293 | + | |
| 1294 | + | |
| 1295 | + | |
| 1296 | + | |
| 1297 | + | |
1268 | 1298 | | |
1269 | 1299 | | |
1270 | 1300 | | |
| |||
1770 | 1800 | | |
1771 | 1801 | | |
1772 | 1802 | | |
1773 | | - | |
1774 | | - | |
1775 | | - | |
| 1803 | + | |
| 1804 | + | |
| 1805 | + | |
| 1806 | + | |
1776 | 1807 | | |
1777 | 1808 | | |
1778 | 1809 | | |
| |||
Lines changed: 18 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
673 | 673 | | |
674 | 674 | | |
675 | 675 | | |
676 | | - | |
| 676 | + | |
677 | 677 | | |
678 | 678 | | |
679 | 679 | | |
680 | | - | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
681 | 683 | | |
682 | 684 | | |
683 | 685 | | |
| |||
744 | 746 | | |
745 | 747 | | |
746 | 748 | | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
| 756 | + | |
| 757 | + | |
| 758 | + | |
| 759 | + | |
| 760 | + | |
| 761 | + | |
| 762 | + | |
747 | 763 | | |
748 | 764 | | |
749 | 765 | | |
| |||
0 commit comments