Skip to content

ci: move sync-fork-dev off pull_request_target before GitHub blocks it on 2026-12-02 #43

Closed

Description

@alexbj75

Problem

.github/workflows/sync-fork-dev.yml fires on pull_request_target (lines 4 to 7). This repo is public, and GitHub blocks pull_request_target by default on public repositories from 2026-12-02, with test brownouts on 2026-11-09 and 2026-11-16, 16:00 to 18:00 UTC (https://github.blog/changelog/2026-11-02-pull_request_target-blocked-by-default-december-2).

If the event is blocked, merging a PR to main no longer syncs the dev fork or remakes the runner in OSC dev. We could not read the org event policy, so it may already be allowed at org level.

Proposed fix

Requested by Jonas Birmé in #ceo-cto-agents on 2026-11-09 (Slack ts 1794260382.680709): change the trigger to push on main.

Two edits are needed in the same change:

  1. Replace the pull_request_target block (lines 4 to 7) with:

    push:
      branches:
        - main
  2. Update the job condition on line 17. It is github.event_name == 'workflow_dispatch' || github.event.pull_request.merged == true. On a push event github.event.pull_request is empty, so with the trigger changed alone the job would be skipped on every merge. Remove the condition, or use github.event_name == 'workflow_dispatch' || github.event_name == 'push'.

workflow_dispatch stays, and it can recover a missed sync.

Acceptance criteria

  • sync-fork-dev.yml no longer references pull_request_target.
  • A merge to main runs the job and it completes the sync and remake in dev.

Actionability

  • Who can act: OSC Dev Team
  • Work type: CI workflow change
  • Estimated effort: under 1 hour
  • Date: before the 2026-12-02 default block, ideally before the 2026-11-16 brownout

Activity

  1. birme commented on Nov 10, 2026

    @birme
    Contributor

    Architect Triage

    Classification: Ready for implementation
    Storage layer: none. The change is GitHub Actions workflow YAML in Eyevinn/python-runner; the job calls the maker-manager HTTP API (POST /sync-fork, GET /maker), which is not touched. No model or field is added.
    Existing test coverage: None found. Grepped sync-fork in the repo (gh search code: only the two workflow files match), the repo's tests/ (eight shell scripts for docker-entrypoint.sh, none reads a workflow file; tree from gh api .../git/trees/main?recursive=1), and sync-fork-dev|Sync fork in dev|python-runner in osaas-e2e-tests/tests and utils (fetched OK this pass, no hit at all).
    Guard tests lifted: None, grepped sync-fork in python-runner tests (no match). In the team repo .claude/scripts/tests/as-developer-wrappers.test.sh uses "Sync fork in dev" and "sync-fork-dev.yml" only as refusal inputs; it stays green because name and file name do not change. adr/0066-github-app-for-osaas-maker.md:120 names "runner sync-fork-dev.yml runs green" as a dev check; AC2 below is the same check.
    Contract gate: not applicable, no shipped endpoint changes (maker-manager status codes, body, timing and failure modes are untouched).
    Root-cause gate: not applicable. The cause is GitHub's policy change, read on https://github.blog/changelog/2026-11-02-pull_request_target-blocked-by-default-december-2 this pass: pull_request_target is blocked by default in all public repositories from 2026-12-02 unless an applicable Actions event policy allows it; brownouts 2026-11-09 and 2026-11-16, 16:00 to 18:00 UTC, in which blocked runs fail with an annotation; private and internal repos are not affected. Eyevinn/python-runner is PUBLIC (gh api repos/Eyevinn/python-runner: private: false). The org event policy was not read; the change below does not depend on it.

    Premises verified for this repo (main head 4e01bf2, via gh api .../contents/.github/workflows/sync-fork-dev.yml?ref=main; the file is identical to web-runner's):

    Implementation directions (one file: .github/workflows/sync-fork-dev.yml):

    1. Replace lines 4-7 with push: / branches: / - main, keeping workflow_dispatch: directly below it.
    2. Delete the line 17 if: condition. The remaining triggers are push on main and workflow_dispatch, and both should run the job; github.event_name == 'push' would be a tautology.
    3. Leave everything else byte-for-byte: name: Sync fork in dev (line 1), the file name, the concurrency group sync-fork-dev (queues bursts as today), env, all three steps. The name is load-bearing: .claude/scripts/actions-as-developer.sh:26-35 (ALLOWED_PAIRS) dispatches by the exact name "Sync fork in dev" for Eyevinn/python-runner and five sibling runner repos.
    4. Add no paths, paths-ignore or tag filter (parity with today: every merged PR triggered the job). branches: [main] does not match tag pushes.
    5. No new action, no new dependency (policy check: the job stays inline curl and jq).
    6. Before committing, confirm the file parses as YAML with whatever parser the clone has (for example python3 -c 'import yaml'), and grep -n pull_request_target .github/workflows/sync-fork-dev.yml prints nothing. Do not add actionlint or any tool to the repo.
    7. PR body: Closes #43, a ## Impact on existing consumers section (the table below, with "none" where it applies), ## Lessons, and the What a human does next statement (Nothing.; the merge of this PR is the test, see AC2).

    Compliance regression review (justified by a GitHub policy, so each dependent of today's behaviour is classified):

    Dependent of pull_request_target closed+merged Status Evidence
    Job runs once per merged PR, at merge time Preserved push on main fires at the merge commit, the same instant as closed
    Job skipped for closed-unmerged PRs Preserved (no longer a case) push never fires for an unmerged PR; today such a run is "skipped" (run 2026-11-04T10:15:26Z, branch non-root-user)
    Direct commits to main (not via PR) Knowingly widened: they now also start a dev sync and remake dev-only, same job and secret, harmless; no version-bump commit flow exists in this repo; tag pushes do not match branches: [main]
    OSC_DEV_MAKER_API_KEY availability Preserved repo Actions secret, read by the same env line; the 4 merge-triggered pull_request_target runs of 2026-11-03 to 2026-11-08 all succeeded with it (the fifth, 2026-11-04T10:15Z, was the skipped closed-unmerged run)
    workflow_dispatch recovery path and actions-as-developer.sh dispatch by name Preserved workflow_dispatch: kept, name: untouched (last dispatch run 2026-11-02 succeeded)
    Prod flow (release: published) Unaffected separate file, separate concurrency group
    Docs describing the old trigger: docs/repo-patterns-ai-infra.md:29, docs/repo-patterns.md:240 (team repo) Migrated by the team in one docs edit covering all six runner repos; not part of this PR the runner repos are listed in actions-as-developer.sh:27-35

    Checklist (the ticket's 2 acceptance criteria and 2 proposed edits, none reworded):

    • AC1: sync-fork-dev.yml no longer references pull_request_target.
    • AC2: a merge to main runs the job and it completes the sync and remake in dev. Checkable after the merge by an agent, no human hands: gh run list --repo Eyevinn/python-runner --workflow sync-fork-dev.yml --event push --limit 1 --json conclusion,headSha shows success for the merge commit.
    • Edit 1: the pull_request_target block (lines 4-7) is replaced by the push on main block (with workflow_dispatch kept).
    • Edit 2: the line 17 job condition is removed.

    E2E Impact

    Verdict: None
    Grepped sync-fork-dev, Sync fork in dev, python-runner in osaas-e2e-tests/tests and utils (checkout fetched this pass): no hit. There is no UI or MCP surface that reaches a GitHub Actions trigger in this repo.

    Necessity test

    Split decision: not split. One issue, 4 checklist items (2 of 2 acceptance criteria and 2 of 2 proposed edits are checklist items; no ADR or epic is linked, 0 of 0 requirements). None of the four reasons holds: one file and about 6 lines (repo-pr-size-p90.sh returns thin: true with 7 merged PRs in 30 days, so p90 is null; the change is well inside one agent run), one repo and one deploy unit, no ordering constraint or human-only step, no separate risk class (dev-only CI trigger).

    Scope reductions

    None.

    Automated triage by architect agent

  2. eyevinn-developer commented on Nov 10, 2026

    @eyevinn-developer
    Contributor

    Implementation blocked: the developer App cannot push workflow files

    An implementation agent prepared the change as specified in the architect triage (premises re-verified on main: lines 4-7 and the line-17 if: match). The push of branch ci/sync-fork-dev-push-trigger was refused:

    refusing to allow a GitHub App to create or update workflow .github/workflows/sync-fork-dev.yml without workflows permission

    The eyevinn-developer App has no workflows permission, so no agent can land any change under .github/workflows/. The agent did not retry with another identity. Same blocker applies to the sibling tickets #43, Eyevinn/php-runner#26 and Eyevinn/wasm-runner#41.

    The change (apply by hand, or grant the App workflows and re-run)

     on:
    -  pull_request_target:
    -    types: [closed]
    +  push:
         branches:
           - main
       workflow_dispatch:
    @@
         name: Sync fork and remake in dev
    -    if: github.event_name == 'workflow_dispatch' || github.event.pull_request.merged == true
         runs-on: ubuntu-latest

    What a human does next: either grant the eyevinn-developer App the workflows permission (org or these four repos) so the next focus run picks the tickets up, or apply the diff above. Deadline: GitHub's brownout is 2026-11-16, default block 2026-12-02.

    Automated report from daily-focus-work

    Co-Authored-By: Claude noreply@anthropic.com

  3. added
    Human Needed
    on Nov 10, 2026
  4. birme commented on Nov 11, 2026

    @birme
    Contributor

    birme decided on 2026-11-11 (human-needed triage): workflow-file changes are pushed by birme by hand. The eyevinn-developer App stays without the workflows permission and no ruleset bypass is added. The architect triage on this ticket holds the design and the diff; the implementer checkpoint holds a ready patch. Keeping Human Needed because the only remaining step is birme pushing the workflow edit.

    Cause category: missing permission/credential (deliberately kept).
    Prevent next time: .claude/skills/daily-triage.md now classifies tickets whose files all sit under .github/workflows/ as NEEDS_HUMAN at triage with the design written, and splits non-workflow files into an agent-doable sub-ticket.
    Owner of that change: done in the team repo.

    Deadline: GitHub blocks pull_request_target by default on public repos from 2026-12-02 (changelog 2026-11-02). Checkable precondition for done: sync-fork-dev.yml on main has no pull_request_target and the latest 'Sync fork in dev' run has event=push, conclusion=success.

  5. removed
    Human Needed
    on Nov 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions