Skip to content

Subagent sessions duplicate the full parent transcript and create 10+ GB JSONL files #42518

Open

Description

@zhoulihe1981

Codex Desktop on Windows is creating extremely large session files under:

%USERPROFILE%.codex\sessions

In the September session directory, 6 subagent JSONL files consume about 62.8 GB. Each file is approximately 10.4–10.7 GB and references the same parent session.

Investigation shows:

  • 1 MB samples taken at 1 GB, 5 GB, and 10 GB offsets are byte-identical across all six files.
  • In one representative 10.4 GB file, 273 "compacted" records occupy 10.18 GB (97.8% of the file).
  • Most of the duplicated data appears to be image-related parent context.
  • Individual compacted JSONL records can reach approximately 92.6 MB.
  • The same issue previously produced multiple 8 GB subagent session files.

Expected behavior:
Subagent sessions should reference or deduplicate the parent transcript and store only their own incremental history.

Actual behavior:
Every spawned subagent stores a near-complete copy of the large parent transcript, causing tens of gigabytes of disk usage within a few hours.

Environment:

  • Windows
  • Codex Desktop
  • Bundled Codex CLI: 0.153.0-alpha.5

Activity

  1. added
    bugSomething isn't working
    appIssues related to the Codex desktop app
    windows-osIssues related to Codex on Windows systems
    subagentIssues involving subagents or multi-agent features
    on Sep 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appIssues related to the Codex desktop appbugSomething isn't workingperformancesubagentIssues involving subagents or multi-agent featureswindows-osIssues related to Codex on Windows systems

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions