Skip to content

fix: match a continued thread's project by its whole name - #81

Merged
youdie006 merged 2 commits into
mainfrom
fix/continue-project-suffix
Oct 30, 2026
Merged

youdie006 merged 2 commits into
mainfrom
fix/continue-project-suffix

Conversation

@youdie006

Copy link
Copy Markdown
Owner

Problem

threadMatchesProject tested the project name as a suffix of the thread URL's project segment, so --project Notes also matched a thread of a project called "My Notes" (/g/g-p-<id>-my-notes/c/...).

--continue (and MCP continue_thread) uses this match when the sidebar gave no project id and no recorded thread carries exactly that name. In that case the follow-up continued the other project's conversation. A continued thread is pinned, which skips the project step, so nothing later caught it and the prompt went into the other project.

Change

The name must be all of what follows the id in the segment (^g-p-<hex>-(name)$). An id-only segment still falls back to the recorded project ids as before.

Verification

  • tsc --noEmit, npm run build, npm test: 1842 passed, 3 skipped.
  • New test in tests/continue-thread.test.ts:
    • "Notes" no longer matches my-notes;
    • "My Notes" still does;
    • resolveContinuationThread refuses instead of picking the other project's thread.
    • It fails without the change.
  • Built module spot check for "Notes": notes=true, my-notes=false, notes-archive=false.
  • Not reproduced live: that would take creating look-alike projects in the account.

threadMatchesProject tested the project name as a suffix of the thread
URL's project segment, so "Notes" also matched "g-p-<id>-my-notes".
--continue (and MCP continue_thread) uses it when the sidebar gave no id
and no recorded thread carries exactly that name; the follow-up then
continued the other project's conversation, and since a continued thread
is pinned, the project step that would have caught it is skipped.

The name must now be all of what follows the id in the segment.

Verified: tsc, build, npm test (1842 passed, 3 skipped); the new test
fails without the change. Spot check on the built module: for "Notes",
notes=true, my-notes=false, notes-archive=false. Not reproduced live,
which would take creating look-alike projects in the account.

Claude-Session: https://claude.ai/code/session_01EMqNwnnhHXznd2P2PDsaDV
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-30T08:20:11.363898Z 3ba2017 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

What this touches

  • tests

3 file(s), 24 line(s) changed. Tests changed.

This is an automated first pass, not a review. CI is the gate; a person decides.

@youdie006
youdie006 merged commit c78efb8 into main Oct 30, 2026
7 checks passed
youdie006 added a commit that referenced this pull request Oct 30, 2026
…he container image

--continue matched the project as a suffix of the thread URL's project
segment, so "Notes" also matched "my-notes" and a follow-up could go into
another project's conversation when the sidebar gave no id. The name must
now be all that follows the id. The patch from main applied as-is.

Verified: tsc, build, npm test (2154 passed, 3 skipped).

Claude-Session: https://claude.ai/code/session_01EMqNwnnhHXznd2P2PDsaDV
youdie006 added a commit that referenced this pull request Oct 30, 2026
Merging PR #83 after #79-#81 left two "## Unreleased / ### Fixed"
headings: git joined the branch's new section and main's without a
conflict. The four entries are now one list.

Claude-Session: https://claude.ai/code/session_01EMqNwnnhHXznd2P2PDsaDV
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