Skip to content

fix(multica): match workspace by session directory when opening a ses…#609

Merged
linkai0924 merged 1 commit into
devfrom
fix/multica-open-session-workspace-match
Jul 22, 2026
Merged

fix(multica): match workspace by session directory when opening a ses…#609
linkai0924 merged 1 commit into
devfrom
fix/multica-open-session-workspace-match

Conversation

@linkai0924

Copy link
Copy Markdown
Collaborator

…sion

findWorkspaceForDevice reused the first workspace on the probed device regardless of directory. A workflow session lives in an isolated per-task worktree, so it landed in an unrelated workspace: the page showed the wrong project path, the session fell out of the directory-scoped session list, and a refresh dropped the conversation.

Replace it with findWorkspaceForSession: only consider workspaces on the owning device whose registered directories contain the session's directory (longest match wins), and create a workspace for the session's own directory when nothing contains it.

Issue for this PR

Closes #

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Please provide a description of the issue, the changes you made to fix it, and why they work. It is expected that you understand why your changes work and if you do not understand why at least say as much so a maintainer knows how much to value the PR.

If you paste a large clearly AI generated description here your PR may be IGNORED or CLOSED!

How did you verify your code works?

Screenshots / recordings

If this is a UI change, please include a screenshot or recording.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

If you do not follow this template your PR will be automatically rejected.

…sion

findWorkspaceForDevice reused the first workspace on the probed device
regardless of directory. A workflow session lives in an isolated
per-task worktree, so it landed in an unrelated workspace: the page
showed the wrong project path, the session fell out of the
directory-scoped session list, and a refresh dropped the conversation.

Replace it with findWorkspaceForSession: only consider workspaces on
the owning device whose registered directories contain the session's
directory (longest match wins), and create a workspace for the
session's own directory when nothing contains it.

Co-Authored-By: Claude <noreply@anthropic.com>
@linkai0924
linkai0924 merged commit 955ff69 into dev Jul 22, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant