Skip to content

fix: avoid double loading full conversation on session open - #10794

Merged
lifeizhou-ap merged 1 commit into
aaif-goose:mainfrom
Abhijay007:fix/long-session-open-oom
Jul 29, 2026
Merged

fix: avoid double loading full conversation on session open#10794
lifeizhou-ap merged 1 commit into
aaif-goose:mainfrom
Abhijay007:fix/long-session-open-oom

Conversation

@Abhijay007

Copy link
Copy Markdown
Collaborator

Fixes #10783

Summary

handle_load_session reloads the full conversation from disk a second time after replay is complete, doubling peak memory on long sessions. The post-replay code only uses session.working_dir, session.usage, and session.recipe — none need the message history. Changing the second get_session to include_messages=false eliminates the redundant load

Testing

manual

@lifeizhou-ap
lifeizhou-ap added this pull request to the merge queue Jul 29, 2026
Merged via the queue into aaif-goose:main with commit 7f1666a Jul 29, 2026
24 checks passed
lifeizhou-ap added a commit to vincenzopalazzo/goose that referenced this pull request Jul 31, 2026
* main: (224 commits)
  fix(desktop): allow removing images when editing user messages (aaif-goose#9979)
  Fetch cursor-agent models from CLI (aaif-goose#10367)
  fix(cerebras): preserve thinking inline for models that reject reasoning_content (aaif-goose#10774)
  perf: make CLI streaming render incremental instead of O(n^2) (aaif-goose#10487)
  Moving to issues as the new PRs (aaif-goose#10818)
  ci: defer privileged recipe scans for forks (aaif-goose#10825)
  docs: adopt issue-first contribution workflow (aaif-goose#10819)
  Add Azure AI Foundry multi-LLM provider (aaif-goose#10622)
  fix(together): parse model list response (aaif-goose#10576)
  docs: remove retired site resources (aaif-goose#10817)
  feat: streaming shell output while commands run (aaif-goose#10808)
  feat(acp): allow session/new to request a Hidden session via _meta.hidden (aaif-goose#10811)
  chore: removed stale text pnpm workspace (aaif-goose#10809)
  feat(otel): emit GenAI semantic convention attributes (aaif-goose#10700)
  fix: avoid double loading full conversation on session open (aaif-goose#10794)
  feat(providers): forward images and MCP embedded-resource blobs in Anthropic and Google formats (aaif-goose#10340)
  Deprecate and remove ui/text TUI (aaif-goose#10799)
  Upgrade to rmcp 3.0 (aaif-goose#10789)
  fix(release): signing environment (aaif-goose#10797)
  feat(tools): collapse const-union enums in tool schemas (aaif-goose#10577)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Chats specially long ones often fail to open and start crashing all other sessions as well on opening

2 participants