Skip to content

ci: auto-update drivers on main instead of blocking PRs#3294

Open
Fishbowler wants to merge 2 commits into
mainfrom
improve-drivers-in-ci
Open

ci: auto-update drivers on main instead of blocking PRs#3294
Fishbowler wants to merge 2 commits into
mainfrom
improve-drivers-in-ci

Conversation

@Fishbowler

@Fishbowler Fishbowler commented May 15, 2026

Copy link
Copy Markdown
Contributor

What

Replaces check-drivers.yaml with a new update-drivers.yaml workflow that automatically builds and commits fresh drivers to main after every merge that touches driver source — and adds explicit driver build steps to the E2E test workflow.

Why this is better

The old approach required contributors to pre-build drivers locally and commit them as part of their PR. This was friction-heavy and error-prone: easy to forget, the iOS driver comparison logic was fragile, and it blocked PRs on a manual step that CI could just do itself. Either people forgot and it caused problems, or people added the wrong ones and it caused problems.

The new approach:

  • E2E tests build drivers locally. Explicit "Build Android drivers" and "Build iOS drivers" steps in test-e2e.yaml ensure E2E runs always exercise the freshest local build.
  • No manual driver commits on PRs. Contributors change source; CI keeps the committed artefacts in sync automatically.
  • Drivers stay fresh on main. The workflow triggers on push to main with path filters, builds the relevant drivers, and commits them back with [skip ci] to avoid recursive runs.
  • Self-healing artefacts. Artefact file paths are included in the path triggers and changes filter. If a contributor with a different local toolchain commits driver artefacts directly, CI immediately rebuilds them with the canonical toolchain and uses them for e2e. When you reach main they're rebuilt and committed. No PR gate needed — the wrong thing is just corrected automatically.
  • Manual trigger available. workflow_dispatch rebuilds both drivers unconditionally — useful after toolchain upgrades (e.g. Xcode version, GitHub runner change) or to unstick a broken state.

Changes

  • .github/workflows/check-drivers.yamlupdate-drivers.yaml — new trigger (push: main + artefact paths), jobs that build and commit artefacts, contents: write permissions, concurrency group, workflow_dispatch support
  • .github/workflows/test-e2e.yaml — adds "Build Android drivers" step (and renames "Build xctest-runner" → "Build iOS drivers")

Follow-up

maestro-client's checkAndroidApksFresh Gradle task and the maestro-android-source.sha256 sentinel file are now vestigial — they enforced the old "contributors must commit fresh APKs" contract. A follow-up PR will remove them.

🤖 Generated with Claude Code

@Fishbowler

Copy link
Copy Markdown
Contributor Author

Does this need to touch a non-workflow file in order to trigger workflows or something?

Comment thread .github/workflows/update-drivers.yaml Outdated
Comment thread .github/workflows/update-drivers.yaml
Comment thread .github/workflows/update-drivers.yaml
Fishbowler and others added 2 commits May 19, 2026 14:00
Replace the "Check Drivers Up-to-Date" PR gate with an "Update Drivers"
workflow that builds and commits fresh drivers automatically after every
merge to main that touches driver source or committed artefacts.

update-drivers.yaml (replaces check-drivers.yaml):
- Triggers on push to main with path filters covering both source and
  artefact files; if wrong artefacts land on main via any route (e.g. a
  contributor with a different local toolchain), CI rebuilds and overwrites
  them with canonical versions
- Builds Android and iOS drivers and commits the artefacts back with
  [skip ci] to prevent re-triggering
- Concurrency group with cancel-in-progress: false serialises runs so no
  update is lost if two merges land close together
- workflow_dispatch rebuilds everything unconditionally
- changes job short-circuits on workflow_dispatch to avoid running
  paths-filter unnecessarily; downstream jobs stay simple with no
  always() gymnastics

test-e2e.yaml:
- Add explicit "Build Android drivers" and "Build iOS drivers" steps
  (renamed from "Build xctest-runner") so E2E runs always exercise
  freshly-built local drivers

Note: maestro-client's checkAndroidApksFresh Gradle task and the
maestro-android-source.sha256 sentinel file are now vestigial — they
enforced the old "contributors must commit fresh APKs" contract that CI
now handles automatically. Cleanup is a follow-up PR.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Fishbowler Fishbowler force-pushed the improve-drivers-in-ci branch from 40cc0e0 to 38b9b05 Compare May 19, 2026 13: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