Skip to content

fix(ci): duplicate comments prevented via issue id deduplication#3449

Merged
FabianKramm merged 1 commit intomainfrom
ops-460/deduplicate-linear-issues
Jan 9, 2026
Merged

fix(ci): duplicate comments prevented via issue id deduplication#3449
FabianKramm merged 1 commit intomainfrom
ops-460/deduplicate-linear-issues

Conversation

@Piotr1215
Copy link
Contributor

@Piotr1215 Piotr1215 commented Jan 7, 2026

Closes OPS-460

Note

Prevents duplicate Linear updates by deduplicating issue IDs extracted from PRs before state transitions.

  • Adds deduplicateIssueIDs and applies it to collected releasedIssues prior to syncing
  • New tests in main_test.go validate deduplication (duplicates across PRs/body+branch, order preservation, empty/all-dup cases)
  • Logging now reports counts post-deduplication

Written by Cursor Bugbot for commit 03a300b. This will update automatically on new commits. Configure here.

Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460
@FabianKramm FabianKramm merged commit cfcf45a into main Jan 9, 2026
50 of 51 checks passed
@FabianKramm FabianKramm deleted the ops-460/deduplicate-linear-issues branch January 9, 2026 08:52
loft-bot pushed a commit that referenced this pull request Jan 9, 2026
Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)

# Conflicts:
#	hack/linear-sync/main.go
#	hack/linear-sync/main_test.go
loft-bot pushed a commit that referenced this pull request Jan 9, 2026
Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)

# Conflicts:
#	hack/linear-sync/main.go
#	hack/linear-sync/main_test.go
loft-bot pushed a commit that referenced this pull request Jan 9, 2026
Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)
loft-bot pushed a commit that referenced this pull request Jan 9, 2026
Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)
loft-bot pushed a commit that referenced this pull request Jan 9, 2026
Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)
@loft-bot
Copy link
Contributor

loft-bot commented Jan 9, 2026

💚 All backports created successfully

Status Branch Result
v0.26
v0.27
v0.28
v0.29
v0.30

Questions ?

Please refer to the Backport tool documentation and see the Github Action logs for details

Piotr1215 added a commit that referenced this pull request Jan 9, 2026
…) (#3455)

Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)

# Conflicts:
#	hack/linear-sync/main.go
#	hack/linear-sync/main_test.go

Co-authored-by: Piotr <piotr.zaniewski@loft.sh>
Piotr1215 added a commit that referenced this pull request Jan 9, 2026
…) (#3456)

Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)

# Conflicts:
#	hack/linear-sync/main.go
#	hack/linear-sync/main_test.go

Co-authored-by: Piotr <piotr.zaniewski@loft.sh>
Piotr1215 added a commit that referenced this pull request Jan 9, 2026
…) (#3457)

Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)

Co-authored-by: Piotr <piotr.zaniewski@loft.sh>
Piotr1215 added a commit that referenced this pull request Jan 9, 2026
…) (#3458)

Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)

Co-authored-by: Piotr <piotr.zaniewski@loft.sh>
Piotr1215 added a commit that referenced this pull request Jan 9, 2026
…) (#3459)

Linear sync created duplicate comments on issues when same ID appeared
in both PR body and branch name. Example: ENG-8061 got two identical
"Now available in stable release v0.30.4" comments 1 second apart.

Root cause: IssueIDs() extracted from both PR body AND branch name,
returning duplicates when both contained the same issue reference.
This was exposed by commit e480400 which added stable release comments
for already-released issues - before that, duplicates were silently
skipped because issue was already in "Released" state.

Resolves OPS-460

(cherry picked from commit cfcf45a)

Co-authored-by: Piotr <piotr.zaniewski@loft.sh>
Piotr1215 added a commit that referenced this pull request Jan 16, 2026
Conflict markers were accidentally merged into v0.27. Resolved by
keeping newer implementations:
- deduplicateIssueIDs function from #3449
- updated regex comment from #3469
Piotr1215 added a commit that referenced this pull request Jan 16, 2026
Conflict markers were accidentally merged into v0.26. Resolved by
keeping newer implementations:
- deduplicateIssueIDs function from #3449
- updated regex comment from #3469
Piotr1215 added a commit that referenced this pull request Jan 16, 2026
Conflict markers were accidentally merged into v0.27. Resolved by
keeping newer implementations:
- deduplicateIssueIDs function from #3449
- updated regex comment from #3469
Piotr1215 added a commit that referenced this pull request Jan 16, 2026
Conflict markers were accidentally merged into v0.26. Resolved by
keeping newer implementations:
- deduplicateIssueIDs function from #3449
- updated regex comment from #3469
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants