From 9e0ad87343a888682bd9efd20db3fb9ee5f81afd Mon Sep 17 00:00:00 2001 From: Jack Green Date: Tue, 18 Feb 2025 23:14:58 +0000 Subject: [PATCH] Improve GitHub Actions `hazelcast` membership check We restrict actions' execution to members of the `hazelcast` organisation using `hazelcast/hazelcast-tpm/membership`, passing in the user derviced from `github.event.pull_request.head.repo.owner.login`. This is the owner of the repository, _not_ the user itself. In the case of a non-fork PR - i.e. one in the `hazelcast` original repo - the `owner` will be `hazelcast` (which _isn't_ a GitHub user, and _isn't_ a member of the `hazelcast` organisation) and will fail. This nuance prevented https://github.com/hazelcast/hazelcast-python-client/pull/720 from being merged. Instead we should query `github.actor` as [already used in the C++ client](https://github.com/hazelcast/hazelcast-cpp-client/blame/b63e40748aa8e06f790510d86e1eae87cc36925a/.github/workflows/build-pr.yml#L50). --- .github/workflows/coverage_runner.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/coverage_runner.yaml b/.github/workflows/coverage_runner.yaml index a9ee816e7..65264c389 100644 --- a/.github/workflows/coverage_runner.yaml +++ b/.github/workflows/coverage_runner.yaml @@ -23,7 +23,7 @@ jobs: uses: hazelcast/hazelcast-tpm/membership@main with: organization-name: 'hazelcast' - member-name: ${{ github.event.pull_request.head.repo.owner.login }} + member-name: ${{ github.actor }} token: ${{ secrets.PAT }} test_client: