Skip to content

ci: skip flags project board workflow for Dependabot PRs#652

Merged
turnipdabeets merged 2 commits into
mainfrom
fix/skip-flags-board-for-dependabot
Jun 4, 2026
Merged

ci: skip flags project board workflow for Dependabot PRs#652
turnipdabeets merged 2 commits into
mainfrom
fix/skip-flags-board-for-dependabot

Conversation

@turnipdabeets
Copy link
Copy Markdown
Contributor

@turnipdabeets turnipdabeets commented Jun 4, 2026

Problem

The call-flags-project / add-to-project-board check fails on every Dependabot PR, and has been doing so since ~2026-05-08. Currently-failing examples:

The reusable PostHog/.github flags-project-board workflow generates a GitHub App token as its first, unconditional step:

- name: Generate GitHub App Token
  uses: actions/create-github-app-token@...
  with:
      app-id: ${{ secrets.PROJECT_BOARD_BOT_APP_ID }}
      private-key: ${{ secrets.PROJECT_BOARD_BOT_PRIVATE_KEY }}

Dependabot-triggered workflow runs execute in a restricted secret context (GitHub deliberately withholds normal Actions/org secrets from Dependabot to limit supply-chain blast radius). So those secrets resolve to empty and the step hard-fails:

Error: The 'client-id' (or deprecated 'app-id') input must be set to a non-empty string.
Token is not set

This has been red on every dependency bump since the upstream 2025-09-09 "Migrate from PAT to GitHub App authentication" change.

Fix

Guard the job with github.actor != 'dependabot[bot]'.

  • Functionally safe: the board job only does anything when a Feature Flags team member is requested as a reviewer — dependency bumps never are. It's project-management automation, not a test/lint/correctness gate, so no coverage is lost.
  • Safer than the alternative: adding PROJECT_BOARD_BOT_APP_ID/PRIVATE_KEY to Dependabot secrets would also fix it, but would hand an org-write GitHub App key to the untrusted Dependabot context — exactly what GitHub's secret isolation protects against.
  • No branch-protection limbo: a job-level if reports the check as skipped, which branch protection treats as non-blocking (unlike a workflow-level paths/trigger filter, which can leave a check stuck "waiting for status").

The reusable PostHog/.github flags-project-board workflow generates a
GitHub App token as its first step. Dependabot-triggered runs execute in
a restricted secret context that has no access to the App credentials, so
that step hard-fails with "The 'client-id' (or deprecated 'app-id') input
must be set to a non-empty string" on every dependency-bump PR (failing
since the 2025-09-09 PAT -> GitHub App migration upstream).

Guard the job with github.actor != 'dependabot[bot]'. A job-level if
reports as skipped, which branch protection treats as non-blocking, so it
won't leave a "waiting for status" check. Adding the App secret to the
Dependabot context would also work but would hand an org-write key to the
untrusted Dependabot context, so the skip is the safer fix.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@turnipdabeets turnipdabeets requested a review from a team as a code owner June 4, 2026 18:19
@socket-security
Copy link
Copy Markdown

socket-security Bot commented Jun 4, 2026

No dependency changes detected. Learn more about Socket for GitHub.

👍 No dependency changes detected in pull request

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented Jun 4, 2026

Reviews (1): Last reviewed commit: "ci: skip flags project board workflow fo..." | Re-trigger Greptile

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 4, 2026

posthog-python Compliance Report

Date: 2026-06-04 19:59:07 UTC
Duration: 176127ms

✅ All Tests Passed!

45/45 tests passed


Capture Tests

29/29 tests passed

View Details
Test Status Duration
Format Validation.Event Has Required Fields 518ms
Format Validation.Event Has Uuid 1507ms
Format Validation.Event Has Lib Properties 1507ms
Format Validation.Distinct Id Is String 1507ms
Format Validation.Token Is Present 1507ms
Format Validation.Custom Properties Preserved 1507ms
Format Validation.Event Has Timestamp 1507ms
Retry Behavior.Retries On 503 9515ms
Retry Behavior.Does Not Retry On 400 3508ms
Retry Behavior.Does Not Retry On 401 3509ms
Retry Behavior.Respects Retry After Header 9514ms
Retry Behavior.Implements Backoff 23519ms
Retry Behavior.Retries On 500 7512ms
Retry Behavior.Retries On 502 7515ms
Retry Behavior.Retries On 504 7513ms
Retry Behavior.Max Retries Respected 23525ms
Deduplication.Generates Unique Uuids 1501ms
Deduplication.Preserves Uuid On Retry 7511ms
Deduplication.Preserves Uuid And Timestamp On Retry 14525ms
Deduplication.Preserves Uuid And Timestamp On Batch Retry 7506ms
Deduplication.No Duplicate Events In Batch 1506ms
Deduplication.Different Events Have Different Uuids 1507ms
Compression.Sends Gzip When Enabled 1508ms
Batch Format.Uses Proper Batch Structure 1507ms
Batch Format.Flush With No Events Sends Nothing 1005ms
Batch Format.Multiple Events Batched Together 1505ms
Error Handling.Does Not Retry On 403 3509ms
Error Handling.Does Not Retry On 413 3510ms
Error Handling.Retries On 408 7514ms

Feature_Flags Tests

16/16 tests passed

View Details
Test Status Duration
Request Payload.Request With Person Properties Device Id 1003ms
Request Payload.Flags Request Uses V2 Query Param 1007ms
Request Payload.Flags Request Hits Flags Path Not Decide 1007ms
Request Payload.Flags Request Omits Authorization Header 1006ms
Request Payload.Token In Flags Body Matches Init 1007ms
Request Payload.Groups Round Trip 1007ms
Request Payload.Groups Default To Empty Object 1006ms
Request Payload.Person Properties Distinct Id Auto Populated When Caller Omits It 1007ms
Request Payload.Disable Geoip False Propagates As Geoip Disable False 1007ms
Request Payload.Disable Geoip Omitted Defaults To False 1007ms
Request Payload.Flag Keys To Evaluate Contains Only Requested Key 1006ms
Request Lifecycle.No Flags Request On Init Alone 503ms
Request Lifecycle.No Flags Request On Normal Capture 1508ms
Request Lifecycle.Two Flag Calls Produce Two Remote Requests 1010ms
Request Lifecycle.Mock Response Value Is Returned To Caller 1003ms
Side Effect Events.Get Feature Flag Captures Feature Flag Called Event 1509ms

Comment thread .github/workflows/call-flags-project-board.yml Outdated
Co-authored-by: Dustin Byrne <dustin@posthog.com>
@turnipdabeets turnipdabeets merged commit 97c11ad into main Jun 4, 2026
28 checks passed
@turnipdabeets turnipdabeets deleted the fix/skip-flags-board-for-dependabot branch June 4, 2026 20:00
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.

2 participants