copilot-cli icon indicating copy to clipboard operation
copilot-cli copied to clipboard

Session date/time is displayed as 56 years ago (1970) in session picker

Open LouisFaure opened this issue 8 months ago • 2 comments

Describe the bug

In GitHub Copilot CLI, the date/time shown for sessions in the --resume picker is offset by ~56 years (1970), even though the actual event logs and JSON files show the correct current timestamps. This makes it confusing to identify recent sessions. All session-related files appear to contain valid 2026 timestamps, and the filesystem modification times are also correct.

Affected version

copilot --version output: v1.0.12

Steps to reproduce the behavior

  1. Create and use a new session in Copilot CLI
  2. Run copilot --resume
  3. Observe that the session is listed as being from "56 years ago" or Jan 1970, even though all session files have correct dates

Expected behavior

Session picker in copilot --resume should display the actual/modern session date and time, matching the event and snapshot logs.

Additional context

Tested on Linux. All session state, event logs, and snapshots have correct (2026) timestamps. The only incorrect date appears in the session resume UI. Issue persists after cleaning empty/corrupt session folders.

LouisFaure avatar Mar 28 '26 22:03 LouisFaure

I think I found the root cause: the issue is specific to running on HPC cluster (RHEL 8) with the Weka filesystem.

It looks like the session picker relies on fs.stat().birthtime to show session start times. However, Weka doesn't support or expose file creation times, so Node.js defaults to the Unix epoch (1970-01-01). This is why all sessions are showing up as starting in 1970.

Since we already have the correct timestamps inside the events.jsonl file (under session.start or session.shutdown), could we use those as a fallback instead of relying on filesystem metadata?

LouisFaure avatar Mar 28 '26 22:03 LouisFaure