github / github/app

Copilot App inconsistently discovers CLI sessions

Đang mở
#955 0 bình luận 2 reaction 0 người được giao Xem trên GitHub
Bugs
Ngôn ngữ chính
Không có dữ liệu ngôn ngữ
Star
2.1k
Fork
153
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

## Description

Not all CLI sessions appear in the Copilot App. Two sessions with identical metadata (both have git repos, ADO host, valid branches, checkpoints) show different behavior — one loads, the other doesn't.

## Details

**Session that loaded:** `Org/Repo-A`, CWD `Q:\src\repo-a`, branch `user/myuser/feature-branch`
**Session that didn't:** `Org/Repo-B`, CWD `Q:\src\repo-b`, branch `main`

Both sessions have:
- Valid git repositories
- ADO host type
- Multiple turns and checkpoints
- Recent `updated_at` timestamps

Additionally, sessions started in non-git directories (e.g., agent-launched sessions with `repository: None`) are **never** discovered, even when the exact CWD is added to the app.

## Expected Behavior

All CLI sessions should be discoverable in the Copilot App, either by repo match or CWD match, regardless of:
- Whether the directory is a git repo
- Which branch the session was on
- The host type

## Steps to Reproduce

1. Start two Copilot CLI sessions in different git repos
2. Open the Copilot App and add both repo directories
3. Observe that only one session appears

For non-git sessions:
1. Start a Copilot CLI session in a non-git directory (e.g., an agent workspace)
2. Add that directory in the Copilot App
3. Session does not appear (`repository: None` in `session-store.db`)

## Environment

- **App version:** v0.2.30
- **OS:** Windows 11
- **Session store:** `~/.copilot/session-store.db`

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Hướng nghiên cứu

Start by inspecting the Copilot App's session-discovery logic and how it reads ~/.copilot/session-store.db, then reproduce the mismatch with the two Windows repository sessions. Trace repo, CWD, branch, and host matching, including entries with repository: None. Done means matching sessions consistently appear when their repository or CWD is added, with coverage for git and non-git directories.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
git, github
Lĩnh vực
cli, desktop
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Ít trao đổi
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
45/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.