pingdotgg / pingdotgg/t3code

[Bug]: Opening a release PR (dev → main) retroactively adopts every thread on the shared branch — all settled threads wake up stamped with the new PR number

Open
#5,514 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
23k
Forks
5.9k
Avg merge
11h 14m
Merged PRs (30d)
357

Description

Before submitting
  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.
Area

apps/web

Steps to reproduce
  1. Use a long-lived integration branch (dev) in a local checkout; accumulate several threads on it over time and settle them as they finish.
  2. Open a release PR from dev to main (e.g. #562 in my repo).
  3. Look at the sidebar.
Expected behavior

The release PR is unrelated to those historical threads. Settled threads stay settled and keep whatever PR association they had (or none).

Actual behavior

Every thread whose checkout branch is dev — including threads settled hours ago — instantly wakes up and displays the new PR badge. One release PR resurrects the entire history of the branch in the Active list.

Additional context

Root cause looks the same as #4970 and #4752: the thread↔PR association appears to be keyed on the checkout's current branch name alone. Any PR whose head is a shared long-lived branch gets attached to every thread bound to it, and PR-state transitions then propagate settle/unsettle to all of them. A per-thread binding (PR created from within the thread, or explicitly attached) would fix all three facets.

This may also explain #5476 (thread on dev auto-settling after every turn — likely tracking a merged PR from the same shared branch rather than the one the agent created).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in apps/web by reproducing the dev-to-main release PR scenario and tracing how thread↔PR associations use the shared branch. Compare the behavior with issues #4970, #4752, and #5476. Done means historical settled threads remain settled and are not assigned the new PR unless explicitly associated.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.