From bd27feade2c8e70893b2ad09441bdb03964921e8 Mon Sep 17 00:00:00 2001 From: Ben Hearsum Date: Fri, 6 Dec 2024 11:13:19 -0500 Subject: [PATCH 1/2] fix: use base repo for project name in github .taskcluster.yml template project name is mainly used in routes, which require specific scopes to be set. Because of this, we should always use the `base` version of this. In cases where the `head` repository has a different name this ends up breaking things like actions in PRs. --- template/{{cookiecutter.project_name}}/taskcluster.github.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/template/{{cookiecutter.project_name}}/taskcluster.github.yml b/template/{{cookiecutter.project_name}}/taskcluster.github.yml index 1eb297773..3076f953b 100644 --- a/template/{{cookiecutter.project_name}}/taskcluster.github.yml +++ b/template/{{cookiecutter.project_name}}/taskcluster.github.yml @@ -32,7 +32,7 @@ tasks: project: $switch: 'tasks_for in ["github-push", "github-release"]': '${event.repository.name}' - 'tasks_for[:19] == "github-pull-request"': '${event.pull_request.head.repo.name}' + 'tasks_for[:19] == "github-pull-request"': '${event.pull_request.base.repo.name}' 'tasks_for in ["cron", "action", "pr-action"]': '${repository.project}' head_branch: $switch: From b4be67da84746246d3b29f71b4a83b5bb5e310e5 Mon Sep 17 00:00:00 2001 From: Ben Hearsum Date: Fri, 6 Dec 2024 11:18:44 -0500 Subject: [PATCH 2/2] fix: update project to use base repo name in PRs in this repo --- .taskcluster.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.taskcluster.yml b/.taskcluster.yml index de7bcccb0..09c55abdb 100644 --- a/.taskcluster.yml +++ b/.taskcluster.yml @@ -34,7 +34,7 @@ tasks: project: $switch: 'tasks_for in ["github-push", "github-release"]': '${event.repository.name}' - 'tasks_for[:19] == "github-pull-request"': '${event.pull_request.head.repo.name}' + 'tasks_for[:19] == "github-pull-request"': '${event.pull_request.base.repo.name}' 'tasks_for in ["cron", "action", "pr-action"]': '${repository.project}' head_branch: $switch: