Skip to content

[Feature request] Add setting to disable agent checkpoint refs (refs/agents/*) #5323

Description

@scar20

Describe the feature or problem you'd like to solve

Every agent turn creates a commit under refs/agents/<session-id>/checkpoints/turn/N in the user's repository. These refs: - are authored with the user's own git identity (user.name/user.email) - appear in any tool that renders all refs (e.g. GitLens Commit Graph), burying the user's actual history under dozens of "Agent host session" rows - cannot be disabled via any exposed setting - checkpoints are created even for read-only turns, which makes the noise-to-value ratio worst exactly for users who never let the agent write.

Proposed solution

A configuration option (e.g. agent.checkpoints.enabled: false) to disable
git-ref checkpointing entirely, or alternatively:

  • store checkpoints outside the repository (e.g. under ~/.copilot/), or
  • use a distinct bot identity so they can be filtered by author, or
  • clean up refs automatically when a session ends

Environment

  • VS Code <1,144.0>, Copilot agent host (vscode-agent-host client)
  • full: Version: 1.144.0
    Commit: 2c33b50b16c472efe58357d1d2a8a5414bc23fbf
    Date: 2026-10-27T20:18:03Z
    Electron: 43.8.3
    ElectronBuildId: 15784459
    Chromium: 150.0.7871.250
    Node.js: 24.22.1
    V8: 15.0.245.31-electron.0
    @github/copilot: 1.0.103.r40031404408.gba6c003
    @github/copilot-sdk: 1.0.27.40031404408.gba6c003
    OS: Linux x64 6.8.0-138-generic snap
  • Repro: run any agent session in a git repo, then git for-each-ref refs/agents

Example prompts or workflows

No response

Additional context

No response

Activity

  1. added theissue type on Nov 2, 2026
  2. tebeco commented on Nov 4, 2026

    @tebeco

    this is ultra annoying and severly poluting

    in the meanwhile, how to list or yeet that shit:

        git for-each-ref --format="%(refname)" refs/copilot/checkpoints
    
        git for-each-ref --format="delete %(refname)" refs/copilot/checkpoints | git update-ref --stdin
  3. Simon-Hayden-Dev commented on Nov 9, 2026

    @Simon-Hayden-Dev

    You can filter those commits by adding --exclude='refs/agents/*/checkpoints/turn/*' to git log. Just in case you don't want to flat-out delete the commits, in case they become useful at some point 😄

    This is especially useful if anybody happens to use the GitLG VSCode extension. Toggle the Configure... dropdown at the top left corner and then add --exclude=... before the --all flag.

  4. tebeco commented on Nov 9, 2026

    @tebeco

    to be clear it's nice to filter etc ...

    though it's just utterly polluting if you run 20 session per day over 20 repo

    i don't want to filter these
    i want these to never exists by default

  5. Simon-Hayden-Dev commented on Nov 9, 2026

    @Simon-Hayden-Dev

    Yeah I get that point and fully agree. What's even worse IMO, is that it's so silent. I didn't even find a blog post or release notes mentioning that this is going to happen from now on...

    For now, I just don't want to delete them just in case they actually serve a useful purpose and/or deleting them breaks something 🤷

  6. tebeco commented on Nov 9, 2026

    @tebeco

    because

    • people don't look at their git tree history
    • vibe coding and worktree doesn't make it important the same way (trust me bro from the AI app with no visibility of that)
    • some git client doesn't show that
    • copilot is not that used compared to Anthropic / OpenAI
    • devs are not all interested the same way in git or don't yet see the pollution this feature is going to create yet
    • it's sold as a "maybe you want to rewind" feature and have no "auto delete after X" or "never do that by default"

    you can't even disable worktree by default iirc in copilot app, which is seriously bad also

    pick your poison

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions