Commit af81d57
fix(sdk): persist injected context alongside a compaction
saveTranscript made compaction and injections mutually exclusive in the
persisted runtime state, but restoreModelLane treats them independently:
injections anchored past a valid compaction apply on top, and if the
compaction fingerprint fails to match at boot the whole compacted lane is
discarded. In that case a same-turn injection that only lived in the
dropped `injections` field was lost. Emit both fields; restore already
filters injections that a valid compaction covers, so there is no
double-apply.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VG39FXXkFFU24U5EtJMwPi1 parent d967cc1 commit af81d57
2 files changed
Lines changed: 55 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7171 | 7171 | | |
7172 | 7172 | | |
7173 | 7173 | | |
7174 | | - | |
7175 | | - | |
7176 | | - | |
| 7174 | + | |
| 7175 | + | |
7177 | 7176 | | |
7178 | 7177 | | |
7179 | 7178 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
547 | 547 | | |
548 | 548 | | |
549 | 549 | | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
550 | 603 | | |
0 commit comments