From ada4c54d4266102746cdb6c75ffef0bca3ffa54b Mon Sep 17 00:00:00 2001 From: matttrach Date: Wed, 20 Aug 2025 12:51:27 -0500 Subject: [PATCH 1/2] fix: remove console line Signed-off-by: matttrach --- .github/workflows/backport-prs.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/backport-prs.yml b/.github/workflows/backport-prs.yml index 4f29843..fcaf0b7 100644 --- a/.github/workflows/backport-prs.yml +++ b/.github/workflows/backport-prs.yml @@ -51,7 +51,6 @@ jobs: 'X-GitHub-Api-Version': '2022-11-28' } }); - core.info(`Search results: ${searchResults}`) if (searchResults.data.total_count === 0) { core.info(`No 'internal/main' issue found for PR #${pr.number}. Exiting.`); return; From e11273954d3c26ef3b22044731c2e6b163817d4c Mon Sep 17 00:00:00 2001 From: matttrach Date: Wed, 20 Aug 2025 13:06:38 -0500 Subject: [PATCH 2/2] fix: assign to me Signed-off-by: matttrach --- .github/workflows/backport.yml | 10 ++-------- .github/workflows/main-issue.yml | 10 ++-------- 2 files changed, 4 insertions(+), 16 deletions(-) diff --git a/.github/workflows/backport.yml b/.github/workflows/backport.yml index 9bf76a9..79469a8 100644 --- a/.github/workflows/backport.yml +++ b/.github/workflows/backport.yml @@ -19,13 +19,7 @@ jobs: const repo = context.repo.repo; const owner = context.repo.owner; - // Get terraform-maintainers team - const { data: teamMembers } = await github.rest.teams.listMembersInOrg({ - org: "rancher", - team_slug: "terraform-maintainers" - }); - const newAssignees = teamMembers.map(member => member.login); - + // Note: can't get terraform-maintainers team, the default token can't access org level objects // Create the sub-issue const newIssue = await github.rest.issues.create({ owner: owner, @@ -33,7 +27,7 @@ jobs: title: "Backport #" + parentIssueNumber + " to release/v0", body: "Backport #" + parentIssueNumber + " to release/v0", labels: ['release/v0'], - assignees: newAssignees // assign terraform-maintainers to sub-issue + assignees: ['matttrach'] }); const subIssueId = newIssue.data.id; diff --git a/.github/workflows/main-issue.yml b/.github/workflows/main-issue.yml index 12c0d0a..701b50c 100644 --- a/.github/workflows/main-issue.yml +++ b/.github/workflows/main-issue.yml @@ -24,13 +24,7 @@ jobs: const versionLabel = releaseLabel.name.replace('release/', 'version/'); newLabels.push(versionLabel); } - // Get terraform-maintainers team - const { data: teamMembers } = await github.rest.teams.listMembersInOrg({ - org: "rancher", - team_slug: "terraform-maintainers" - }); - const newAssignees = teamMembers.map(member => member.login); - + // Note: can't get terraform-maintainers team, the default token can't access org level objects // Create the main issue // https://docs.github.com/en/rest/issues/issues?apiVersion=2022-11-28#create-an-issue // Note: issues can't have teams assigned to them @@ -43,5 +37,5 @@ jobs: "Please add comments for user issues which this issue addresses. \n\n" + "Description copied from PR: \n" + pr.body, labels: newLabels, - assignees: newAssignees // assign terraform-maintainers to issue + assignees: ['matttrach'] });