Skip to content

Dependabot: auto-merge green pip updates through their own GitHub App, after a cooldown #740

Closed
3 of 3 issues completed

Description

@brunogbv

What

Auto-merge Dependabot's pip PRs once they are green, as marola-merge-bot, from one scheduled workflow in this repo. Decided with the maintainer (2026-10-10), identity per MIP-0086 (#787, task 13):

  • pip only; GitHub Actions bumps stay manual (just deps-merge, as today). Today that is marola-ml alone; marola and marola-app have only github-actions, and site, corpus, oods and the devkit have no Dependabot config.
  • The token has no Workflows permission. marola-merge-bot holds Workflows write for the devkit bumps, so this job mints its token without permission-workflows: GitHub then refuses to merge a PR that touches .github/workflows/ through it (MIP-0086 §5.5). deps-merge --unattended refuses such a PR first anyway.
  • A cooldown first. A hijacked PyPI release (ultralytics, December 2024) would otherwise land on main the day it is published. marola-ml's Dependabot waits 7 days (Dependabot waits 7 days before it proposes an update (cooldown) marola-ml#80, merged).

Done so far: the cooldown (marola-dev/marola-ml#80) and deps-merge --repo OWNER/REPO --unattended (marola-dev/marola-devkit#150, released in devkit v0.18.0). That mode merges a PR only when Dependabot authored it and every commit, it has no hold label, it changes only Python manifests, every version moves by a patch or minor (read from the diff; a 0.x minor counts as major), and every check is green; the merge is pinned to the checked head commit.

Built in this repo (#878):

  • .github/workflows/deps-merge.yml: on a schedule (daily, off :00) and workflow_dispatch. One job: exits early on vars.AUTO_MERGE == 'false'; mints a marola-merge-bot token with marola-dev/marola-devkit/.github/actions/bot-token@v0.18.0 (MERGE_BOT_APP_ID / MERGE_BOT_KEY), repositories: marola-ml, Contents and Pull requests write, Checks and Commit statuses read, no Workflows; clones marola-devkit at v0.18.0 (git clone -b, a pin bump-consumers moves) and runs scripts/deps-merge.sh --repo marola-dev/<repo> --unattended for each repo in a list in the file (marola-ml today).
  • The file is added to .github/merge-key-allowlist and passes merge-key-check: no nix, installs, curl or third-party actions in the job holding the key. gh and jq come with the runner.
  • The bypass comes from the devkit's @consumers extra (MIP-0086 task 3: ruleset-sync's @consumers extra gives marola-merge-bot its bypass marola-devkit#100), so there is no per-repo bypass entry.

The first scheduled runs refused marola-dev/marola-ml#90 (pip only, every version a minor, its newest checks green) for two faults in deps-merge --unattended (devkit v0.20.2):

Left, in marola-devkit (scripts/deps-merge.sh, both modes):

  • Judge a PR by the newest run of each check only: per workflow and check name, the entry with the highest job id in its detailsUrl (a re-run gets a new job id too). A status context keeps its newest startedAt.
  • On UNKNOWN, read mergeable again (a few tries, a few seconds apart) before it refuses.
  • Self-test cases for both: Bump docker/setup-buildx-action from 3 to 4 #90's real rollup, and an UNKNOWN that becomes MERGEABLE (a stub gh on PATH).
  • Then a devkit release; bump-consumers moves deps-merge.yml's pin, and a dispatch or the next daily run merges Bump docker/setup-buildx-action from 3 to 4 #90.

Acceptance criteria

Named test

merge-key-check and actionlint on .github/workflows/deps-merge.yml (in just quality); deps-merge.sh --self-test in marola-devkit v0.18.0 and in the release with the fix; the dispatch run's link and the live merge's link.

Docs, AGENTS.md's pointer and NEW-REPO's day-one setup: #741.

Activity

  1. added
    area/dev-toolingClaude Code / OpenCode / agentic-tooling dev workflow, not the product
    layer/infra.github/, scripts/, justfile, flake.nix, .githooks/, .claude/
    size/MRoughly 100-400 changed lines
    on Oct 9, 2026
  2. brunogbv commented on Oct 10, 2026

    @brunogbv
    CollaboratorAuthor

    Identity decided by MIP-0086 (#787, task 13): deps-merge mints as marola-merge-bot, not a dedicated marola-deps-merge App, from the umbrella's key (MERGE_BOT_APP_ID / MERGE_BOT_KEY). That App holds Workflows write for the devkit bumps, so #740's guarantee moves into the token: mint without permission-workflows, and GitHub still refuses to merge a PR that touches .github/workflows/ (MIP-0086 §5.5). Its workflow goes in .github/merge-key-allowlist and must pass merge-key-check (no nix, installs or third-party actions in the job holding the key); it exits early on vars.AUTO_MERGE == 'false' and skips a PR labelled hold (§5.8). The bypass comes from the devkit's @consumers extra (marola-dev/marola-devkit#100), so no per-repo extras entry. Superseded in the body above: the "Its own App" bullet, the App bullet under Design, and the second acceptance criterion. Blocked by marola-dev/marola-devkit#100 and #766.

  3. self-assigned this
    on Oct 10, 2026
  4. 2 remaining items

  5. added
    size/SUnder ~100 changed lines
    agent-readyPasses the five-rule Definition of Ready — an agent may begin work on it (MIP-0063 §5.4)
    and removed
    size/MRoughly 100-400 changed lines
    agent-readyPasses the five-rule Definition of Ready — an agent may begin work on it (MIP-0063 §5.4)
    on Oct 17, 2026
  6. moved this from Backlog to In progress in Marolaon Oct 17, 2026
  7. brunogbv commented on Oct 17, 2026

    @brunogbv
    CollaboratorAuthor

    #878 merged (47304c4; CI 8 success, 6 skipped). The first workflow_dispatch run passed: https://github.com/marola-dev/marola/actions/runs/39066498995. It minted the marola-merge-bot token for marola-ml only, gh auth status worked with that installation token, and deps-merge refused marola-dev/marola-ml#78 (checks not green (CANCELLED)) and merged nothing. The last open criterion is one live auto-merge, after the 7-day cooldown.

  8. added
    agent-readyPasses the five-rule Definition of Ready — an agent may begin work on it (MIP-0063 §5.4)
    on Oct 20, 2026
  9. moved this from In progress to Done in Marolaon Oct 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

agent-readyPasses the five-rule Definition of Ready — an agent may begin work on it (MIP-0063 §5.4)area/dev-toolingClaude Code / OpenCode / agentic-tooling dev workflow, not the productlayer/infra.github/, scripts/, justfile, flake.nix, .githooks/, .claude/size/SUnder ~100 changed lines

Type

No type

Projects

  • Status
    Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions