Skip to content

fix(desktop): keep live cache averages in sync / 修复实时缓存平均命中率同步#6406

Merged
SivanCola merged 2 commits into
esengine:main-v2from
SivanCola:fix/live-cache-average-sync
Jul 13, 2026
Merged

fix(desktop): keep live cache averages in sync / 修复实时缓存平均命中率同步#6406
SivanCola merged 2 commits into
esengine:main-v2from
SivanCola:fix/live-cache-average-sync

Conversation

@SivanCola

@SivanCola SivanCola commented Jul 13, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Refresh the shared all-source ContextInfo after each provider usage event during an active turn, so the desktop status bar no longer waits for turn_done to update its session-average cache hit rate.
  • Make the status bar and context panel prefer the same live ContextInfo for their session-average cache metric, while keeping independently refreshed panel telemetry as a fallback.
  • Reject stale async snapshots by checking the active tab, usage sequence, and turn lifecycle before updating shared state.
  • Add integration coverage for executor and subagent usage, stale private panel snapshots, rendered status-bar and context-panel values, and out-of-order snapshot completion; register the delivery-mode stream tests in the standard frontend suites.

Verification

  • pnpm test:all
  • pnpm typecheck
  • pnpm test:typecheck
  • pnpm check:css
  • ./scripts/cache-guard.sh
  • git diff --check

Cache impact

Cache-impact: none — this only refreshes existing local telemetry; provider-visible prompts, tools, and request serialization are unchanged.
Cache-guard: ./scripts/cache-guard.sh passed all scenarios with tail averages of 92–95% against the 90% threshold.
System-prompt-review: N/A

@SivanCola SivanCola requested a review from esengine as a code owner July 13, 2026 07:12
@github-actions github-actions Bot added v2 Go rewrite (1.x) — main-v2 branch, active development desktop Wails desktop app (desktop/**) labels Jul 13, 2026
@SivanCola SivanCola merged commit 404ee64 into esengine:main-v2 Jul 13, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

desktop Wails desktop app (desktop/**) v2 Go rewrite (1.x) — main-v2 branch, active development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant