Repository navigation
fix(server): cache compaction patch follows upstream's optional Claude usage counters - #299
Merged
fireboltdude1357 merged 572 commits intoNov 22, 2026
Conversation
… app does (pingdotgg#28597) Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: maria-rcks <254055478+maria-rcks@users.noreply.github.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…rogress (pingdotgg#37859) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…dotgg#38895) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…dotgg#30925) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…ingdotgg#39670) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…t page by default (pingdotgg#40003) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…hanges (pingdotgg#24841) Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…tgg#24888) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…s current (pingdotgg#36868) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…checkout (pingdotgg#37191) Co-authored-by: Julius Marminge <julius0216@outlook.com>
… errors (pingdotgg#40042) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…ingdotgg#39994) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…nvironment inputs (pingdotgg#39992)
…Button, and ControlPill (pingdotgg#40002)
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
pingdotgg#40133) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…40020) Co-authored-by: Simone <185146821+Lucenx9@users.noreply.github.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…us (pingdotgg#31295) Co-authored-by: Justin <159104807+Justin24506@users.noreply.github.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…d back to the end (pingdotgg#31907)
…(body edit 10.3 s → 5.4 s) (pingdotgg#30879) Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…queue (pingdotgg#40763) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…laced and abandoned staging (pingdotgg#40817)
…tgg#31349) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…gg#26661) Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…h the agent (pingdotgg#40777) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…0816) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…ingdotgg#29438) Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…usage frames (pingdotgg#40804) Co-authored-by: lvning.liu <lvning.liu@weimob.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…pingdotgg#40830) Co-authored-by: lvning.liu <lvning.liu@weimob.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…ad of stepping through stale states (pingdotgg#27401) Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
pingdotgg#40841) Co-authored-by: Julius Marminge <julius0216@outlook.com>
pingdotgg#27391) Co-authored-by: Enmani <43571965+Enmani@users.noreply.github.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…on (pingdotgg#21667) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…e-expiry-compaction-upstream-b479ce2 # Conflicts: # apps/server/src/orchestration-v2/Adapters/ClaudeAdapterV2.test.ts # apps/server/src/orchestration-v2/Adapters/ClaudeAdapterV2.ts
fireboltdude1357
merged commit Nov 22, 2026
f72738c
into
patch/cache-expiry-compaction
1 check passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The fork's nightly build fails because
patch/cache-expiry-compactionconflicts with upstream b479ce2 inapps/server/src/orchestration-v2/Adapters/ClaudeAdapterV2.tsand its test.Upstream pingdotgg#40804 makes every Claude usage counter optional and cleans each one with
optionalClaudeUsageTokenCount, so empty or partial stream frames no longer stall a turn. The patch rewrites the same functions: it reads context size from the last"message"iteration and carries a known prompt cache TTL forward without dating a cache-only read's expiry.I took upstream's version of these helpers and re-applied the patch to it.
ClaudeUsageCountersnow has upstream's optional fields. The iteration'soutput_tokensandcache_read_input_tokensgo throughoptionalClaudeUsageTokenCount, like upstream's top-level fields.mergeClaudeStreamUsagekeeps upstream's cleanup and also carriesiterations. In the test file, both sides added a test at the same spot, and I kept both.On a scratch stack of upstream b479ce2 with all 19 patches and both fix branches (#299 and #300),
pnpm install --no-frozen-lockfile,vp run typecheck(43 of 43) andvp test runon the 50 test files the patches touch (1521 tests) all pass.Made by Claude Opus 5.5 in Claude Code.
🤖 Generated with Claude Code