slawekjaranowski commented on code in PR #331:
URL: 
https://github.com/apache/maven-gh-actions-shared/pull/331#discussion_r4179096998


##########
.github/workflows/pr-check.yml:
##########
@@ -30,33 +30,18 @@ jobs:
   # - Missing       -> adds ONE comment and fails.
   # - Fixed         -> hides the comment as outdated and passes.
   # - Removed again -> unhides the same comment (no duplicates).
+  # - Bot or org member/committer -> skips silently (success).
   license-declaration:
     permissions:
       pull-requests: write
       issues: write # PR comments are "issue comments" in the API
     runs-on: ubuntu-slim
-    # Skip (a skipped job counts as successful, so a required check doesn't 
block the merge):
-    # - PRs opened by bots (Dependabot, Renovate, other GitHub Apps),
-    # - PRs opened by members/committers of the organization owning the 
repository (apache).
-    #   MEMBER       = org member with public membership (PMC member)
-    #   OWNER        = org owner
-    #   COLLABORATOR = committer whose org membership is private (covers most 
Apache committers)
-    if: >-
-      github.event.pull_request.user.type != 'Bot' &&
-      !contains(fromJSON('["OWNER", "MEMBER", "COLLABORATOR"]'), 
github.event.pull_request.author_association)
     # Prevents races (e.g. opened + edited in quick succession => two 
comments).
     # Do NOT define the same concurrency group in the caller – it would 
deadlock.
     concurrency:
       group: license-declaration-check-${{ github.repository }}-${{ 
github.event.pull_request.number }}
       cancel-in-progress: false
     steps:
-      - name: Debug context
-        uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # 
v9.0.0
-        with:
-          script: |
-            core.info('author_association: ' + 
github.event.pull_request?.author_association);

Review Comment:
   probably `context.payload.pull_request` should be used in script



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to