[Bug] Session restoration causes incorrect token usage reporting after auto-compact

Resolved 💬 4 comments Opened Apr 18, 2026 by chenvaltzer Closed Apr 18, 2026

Bug Description
My 5 hours session was just reset and somehow the 5 hours tokens jumped to 7%!!! this keeps happening for me in the past session restorations. Even if it did session restore there is no way it filled my context to 7%... i haven't ran anything i just reopened this terminal and it asked me if i want to compact and i clicked yes and than immediately it jumped to 7%.. This is either a bug or something with the usage counting wrong. This is worth alot of money to me since we are paying per usage

Environment Info

  • Platform: win32
  • Terminal: null
  • Version: 2.1.113
  • Feedback ID: e11b3a8b-ce05-458a-a253-cd91f176f8b4

Errors

[{"error":"Error: Plugin MCP server error - mcp-config-invalid: MCP server github invalid: Missing environment variables: GITHUB_PERSONAL_ACCESS_TOKEN\n    at PjH (B:/~BUN/root/src/entrypoints/cli.js:2807:30077)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-18T13:01:03.589Z"},{"error":"Error: Plugin MCP server error - mcp-config-invalid: MCP server github invalid: Missing environment variables: GITHUB_PERSONAL_ACCESS_TOKEN\n    at PjH (B:/~BUN/root/src/entrypoints/cli.js:2807:30077)\n    at async V (B:/~BUN/root/src/entrypoints/cli.js:6187:11830)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-18T13:01:07.889Z"},{"error":"Error: Plugin MCP server error - mcp-config-invalid: MCP server github invalid: Missing environment variables: GITHUB_PERSONAL_ACCESS_TOKEN\n    at PjH (B:/~BUN/root/src/entrypoints/cli.js:2807:30077)\n    at async G (B:/~BUN/root/src/entrypoints/cli.js:6187:11023)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-18T13:01:07.890Z"}]

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗