openclaw - 💡(How to fix) Fix Bug: session reset preserves compaction checkpoint metadata [2 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#81346Fetched 2026-05-14 03:33:06
View on GitHub
Comments
2
Participants
3
Timeline
3
Reactions
1
Timeline (top)
commented ×2closed ×1

/new and /reset currently create a new session entry but preserve compactionCount and compactionCheckpoints from the previous session. That means a supposedly fresh session can still carry old compaction summaries into later turns.

Root Cause

Note

I could not open a cross-repo PR because moeedahmed/openclaw is not registered as a fork of openclaw/openclaw, and this account does not have upstream branch write permission.

Fix Action

Fix / Workaround

Patch branch

I prepared a clean branch with a regression test here: https://github.com/moeedahmed/openclaw/tree/fix/session-reset-clears-compaction

RAW_BUFFERClick to expand / collapse

Summary

/new and /reset currently create a new session entry but preserve compactionCount and compactionCheckpoints from the previous session. That means a supposedly fresh session can still carry old compaction summaries into later turns.

Expected

Reset should preserve user-level settings such as model/mode, but clear stale compaction metadata so the next turn is actually clean.

Patch branch

I prepared a clean branch with a regression test here: https://github.com/moeedahmed/openclaw/tree/fix/session-reset-clears-compaction

Commit: 7715abd3ec

Test

pnpm vitest run src/gateway/server.sessions.reset-models.test.ts

Result: 1 file passed, 7 tests passed.

Note

I could not open a cross-repo PR because moeedahmed/openclaw is not registered as a fork of openclaw/openclaw, and this account does not have upstream branch write permission.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix Bug: session reset preserves compaction checkpoint metadata [2 comments, 3 participants]