Skip to content

CLA nudge: never prompt Snowplow staff (org membership check) - #9

Merged
Greg Thomson (gthomson31) merged 2 commits into
mainfrom
cla-nudge-skip-org-members
Oct 29, 2026
Merged

Greg Thomson (gthomson31) merged 2 commits into
mainfrom
cla-nudge-skip-org-members

Conversation

@gthomson31

@gthomson31 Greg Thomson (gthomson31) commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Why

The CLA nudge must never prompt Snowplow staff. author_association reports private org members as NONE, and a commit email is not a reliable staff signal, so both let staff through.

What

Before commenting, the workflow checks whether the PR author belongs to Snowplow:

  1. Repo collaborator: GET /repos/{repo}/collaborators/{author}. This covers members of the repo's own org through base read access, plus invited collaborators.
  2. Member of any Snowplow org: for snowplow, snowplow-incubator, snowplow-product, snowplow-devops and snowplow-referer-parser, it mints an installation token from the snowplow-cla-nudge GitHub App (Organization Members: read only) with actions/create-github-app-token, pinned to the v3.3.0 SHA, and calls GET /orgs/{org}/members/{author}. App tokens can see private memberships.

It stays silent unless it's certain. It comments only when every lookup confirms the author is not a member. A missing token, a missing install or an API error means no comment. Token steps use continue-on-error, so the required check never fails.

The commit email check is removed.

Requires

  • The snowplow-cla-nudge app installed on all 5 orgs.
  • Org Actions secrets CLA_NUDGE_APP_ID and CLA_NUDGE_APP_PRIVATE_KEY (visibility: all) in each org.

Until both exist, the workflow stays silent. It never prompts by mistake.

@gthomson31 Greg Thomson (gthomson31) changed the title CLA nudge: skip org members, including private memberships CLA nudge: never prompt Snowplow staff (org membership check) Oct 29, 2026
@gthomson31
Greg Thomson (gthomson31) merged commit 5c4f596 into main Oct 29, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant