desktop: Home hides subdirectory sessions and mixes unrelated global projects
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 70/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- typescript
Hướng nghiên cứu
Start with the two files the report names: home/sessions/records.ts (the pathKey exact-match filter) and home/sessions/controller.tsx (directories(project), which merges project.worktree with project.sandboxes). Reproduce via the local session and worktree APIs, then make matching segment-aware for the selected project while excluding unrelated entries from a shared global inventory, preserving Git worktrees and nested projects. Done when the child session appears under its project and the non-Git project no longer lists unrelated conversations.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Description
Summary
The Desktop Home project filter can both hide sessions whose working directory is a normal subdirectory of the selected project and display sessions from an unrelated project when the selected non-Git project uses a shared global worktree inventory.
This makes existing conversations appear lost and undermines separation between work and personal projects. The affected session metadata and messages remain available through the local API.
Environment
- opencode version:
opencode v2.3.0(verified on the reporting machine). The same symptoms were previously observed on Desktop 2.2.5. - OS: Windows 11,
Microsoft Windows NT 10.0.26200.0, x64. - Terminal: Desktop UI; diagnostic shell has
TERM=xterm-256color;TERM_PROGRAMandCOLORTERMare unset. - Shell: PowerShell 7.6.2;
ComSpec=C:\WINDOWS\system32\cmd.exe. - Install/channel: packaged Windows Desktop, standard release installation. No prerelease suffix in the reported version; the exact updater channel was not independently verified.
- Active plugins: configured globally:
opencode-supermemory,opencode-firecrawl,opencode-tavily,opencode-daytona,opencode-background-agents,opencode-vibeguard,opencode-notificator, and a localwhatsapp-notify.tsplugin. This lists configuration, not independently verified plugin runtime state. A plugin-disabled/clean-profile reproduction has not been performed.
Reproduction
The following paths and names are sanitized examples, not the reporter's real project data.
A. A child-directory session disappears from its own project filter
- Add an existing Git project at
C:\work\personal. - Create a conversation whose working directory is
C:\work\personal\android-app. - Verify that the session still has the personal project's
projectID, is not archived, and has readable message history. - Open Home and select the personal project.
- Observe that a root-directory session is listed, but the normal child-directory session is omitted.
The real affected Android-app session was confirmed through the session API with the correct project ID, a child working directory, and readable history. The corresponding folder and APK were also still present.
B. A shared global worktree inventory mixes unrelated projects
-
Have a non-Git project rooted at
C:\work\workrepresented byid: "global", plus a separate Git project atC:\work\personal. -
Reach a saved inventory state in which
GET /api/worktree?projectID=globalreturns both directories:[ {"directory":"C:\\work\\personal"}, {"directory":"C:\\work\\work"} ] -
Have separate root-directory conversations for those projects.
-
In Home, select the non-Git work project.
-
Observe personal conversations appearing in the work project's list.
The inventory state above was observed through the local API. The precise minimal sequence that first populated the shared inventory with both directories has not been isolated.
Expected Behavior
- Selecting a project should include its own ordinary subdirectory sessions, not only sessions whose directory exactly equals a root/worktree path.
- Selecting a non-Git project should not implicitly include every unrelated directory present in a shared
globalinventory. - Separately added nested projects and normal Git worktrees should retain their correct grouping.
- Showing a conversation should not require changing its working directory or moving its files.
Actual Behavior
- The Android-app conversation was absent from the personal Home list even though its session, project association, files, and messages still existed.
- The non-Git work project's Home list included personal conversations.
- There was no API deletion or archive operation associated with the missing conversation.
The shipped 2.3.0 renderer source map contains this exact-match filter in home/sessions/records.ts:
const selected = input.projectDirectories()
const directories = selected ? new Set(selected.map(pathKey)) : undefined
const sessions = directories
? input.sessions().filter((session) => directories.has(pathKey(session.location.directory)))
: input.sessions()
The corresponding helper in home/sessions/controller.tsx returns:
function directories(project: LocalProject) {
return [project.worktree, ...(project.sandboxes ?? [])]
}
The exact-match filter excludes ordinary child directories. When a shared global inventory supplies unrelated entries as sandboxes, returning all of them also allows cross-project root-directory matches.
Additional Context
- Both symptoms were observed on this installation before applying a local workaround. They reappeared after upgrading from 2.2.5 to 2.3.0, which replaced the locally modified renderer with the official one. This is not a request for the updater to preserve unsupported package modifications.
- A local renderer-only workaround limits a global selection to its selected canonical directory and allows segment-aware descendant matching for the selected project's own sessions, while excluding separately added nested projects and preserving Git worktree behavior.
- The workaround was tested against extracted packaged functions: 21 regression checks passed, including the real child session metadata; six additional repair-tool safety checks passed.
- After applying it, the Android-app session was observed in the personal Home UI tree. The final 2.3.0 work-project UI verification was interrupted by the machine locking and is not claimed as completed. Earlier 2.2.5 verification had confirmed the analogous work-child conversation visible and separate from personal conversations.
- Session IDs, project associations, parent relationships, and working directories were not changed by the workaround. Local checks preserved all 145 inventoried sessions, all preexisting messages in the two specifically checked conversations, and all 101 checked project files.
- A local workaround is not a durable fix because an official application update replaces the renderer. Please address the filtering/grouping behavior upstream.
- No private conversation content, account credentials, full user configuration, or private screenshots are attached.
Plugins
opencode-supermemory; opencode-firecrawl; opencode-tavily; opencode-daytona; opencode-background-agents; opencode-vibeguard; opencode-notificator; local whatsapp-notify.ts (configured; not independently isolated)
OpenCode version
2.3.0 (also observed on 2.2.5)
Steps to reproduce
The following paths and names are sanitized examples, not the reporter's real project data.
A. A child-directory session disappears from its own project filter
- Add an existing Git project at
C:\work\personal. - Create a conversation whose working directory is
C:\work\personal\android-app. - Verify that the session still has the personal project's
projectID, is not archived, and has readable message history. - Open Home and select the personal project.
- Observe that a root-directory session is listed, but the normal child-directory session is omitted.
The real affected Android-app session was confirmed through the session API with the correct project ID, a child working directory, and readable history. The corresponding folder and APK were also still present.
B. A shared global worktree inventory mixes unrelated projects
-
Have a non-Git project rooted at
C:\work\workrepresented byid: "global", plus a separate Git project atC:\work\personal. -
Reach a saved inventory state in which
GET /api/worktree?projectID=globalreturns both directories:[ {"directory":"C:\\work\\personal"}, {"directory":"C:\\work\\work"} ] -
Have separate root-directory conversations for those projects.
-
In Home, select the non-Git work project.
-
Observe personal conversations appearing in the work project's list.
The inventory state above was observed through the local API. The precise minimal sequence that first populated the shared inventory with both directories has not been isolated.
Screenshot
No response
Operating System
Windows 11 x64, Windows NT 10.0.26200.0
Terminal
OpenCode Desktop; diagnostics from PowerShell 7.6.2 (TERM=xterm-256color)
- Ngôn ngữ chính
- TypeScript
- Star
- 227k
- Fork
- 30.7k
- Merge trung bình
- 3 giờ 57 phút
- Pull request đã merge (30 ngày)
- 484
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của anomalyco/opencode
-
[Site] Active section detection should respect scroll-margin-topCó thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mởarea/web reproduced type/bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
anomalyco/opencode#65384 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area/cli type/feature version/v2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
anomalyco/opencode#65379 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Shell tool: no upper bound on the timeout a model can ask for, so one call can hold a turn for hoursĐang mởarea/core platform/linux type/feature version/v2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
anomalyco/opencode#65254 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
inference/go type/feature
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 72/100
anomalyco/opencode#65148 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area/providers type/feature version/v2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
anomalyco/opencode#64845 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của anomalyco/opencode
Issue tương tự
-
[Provider] antigravity-acp catalog omits gemini-4-hydrogen and gemini-4-neon that agy acp offersCó thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mởcatalog provider provider-compatibility
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
lidge-jun/opencodex#9037 · 1 bình luận · 1 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Project submission: xmcp DocsĐang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 62/100
slavakurilyak/awesome-ai-agents#1005 ·
-
kind/bug triage/unresolved
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 60/100
Maintainer thường phản hồi trong vòng 1 ngày
-
effort:S P3 refactor
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
nightscout/nocturne#3735 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
wpilibsuite/systemcore-blocks-interface#641 ·
Maintainer thường phản hồi trong vòng 2 ngày