From 0f78a451f2107037aa341e630b9945ee38e106ed Mon Sep 17 00:00:00 2001 From: PPawlowski Date: Fri, 12 Jun 2026 12:57:35 +0200 Subject: [PATCH] fix: exact-match dedupe check in recurring sprint issue workflow The open-issue job trusted search total_count, but GitHub's issue search is fuzzy and strips punctuation, so a different sprint's open issue (e.g. Sprint 1) matched the query for the next sprint (Sprint 2) and the job bailed without creating the issue. Filter results to an exact title match before treating it as a duplicate, mirroring the close-previous-issue job. --- .github/workflows/recurring_sprint_issue.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/recurring_sprint_issue.yml b/.github/workflows/recurring_sprint_issue.yml index 88e8af3..750c611 100644 --- a/.github/workflows/recurring_sprint_issue.yml +++ b/.github/workflows/recurring_sprint_issue.yml @@ -158,8 +158,9 @@ jobs: const existing = await github.rest.search.issuesAndPullRequests({ q: `repo:${owner}/${repo} is:issue is:open in:title "${title}"` }); - if (existing.data.total_count > 0) { - core.info(`Issue already exists: ${title}`); + const duplicate = existing.data.items.find((i) => i.title === title); + if (duplicate) { + core.info(`Issue already exists: #${duplicate.number} ${title}`); return; }