run workflow (drgrib/dotmap)
The run workflow from drgrib/dotmap, explained and optimized by Latchkey.
A
CI health: A - excellent
Point runs-on at Latchkey and get run de-duplication, self-healing for flaky steps, and up to 58% lower cost, applied automatically.
What it does
This is the run workflow from the drgrib/dotmap repository, a real project running GitHub Actions. It is shown here with attribution under its MIT license.
Below, Latchkey shows a faster, safer version produced by its optimization engine.
The workflow
workflow (.yml)
name: run
on: [push, pull_request]
jobs:
tests:
runs-on: ubuntu-latest
container: ${{ matrix.container }}
strategy:
matrix:
container:
- python:3.6
- python:3.7
- python:3.8
- python:3.9
- python:3.10
- python:3.11
- python:3.12
- python:3.13
- python:3.14
- pypy:3.8
- pypy:3.9
- pypy:3.10
- pypy:3.11
timeout-minutes: 10
steps:
- uses: actions/checkout@v6
- run: |
python3 -m unittest
The same workflow, on Latchkey
Removes redundant runs and caps runaway jobs. Added and changed lines are highlighted.
name: run on: [push, pull_request] concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true jobs: tests: runs-on: latchkey-small container: ${{ matrix.container }} strategy: matrix: container: - python:3.6 - python:3.7 - python:3.8 - python:3.9 - python:3.10 - python:3.11 - python:3.12 - python:3.13 - python:3.14 - pypy:3.8 - pypy:3.9 - pypy:3.10 - pypy:3.11 timeout-minutes: 10 steps: - uses: actions/checkout@v6 - run: | python3 -m unittest
What changed
- Run on Latchkey managed runners with one line (
runs-on), which apply the fixes below automatically and self-heal transient failures. This example useslatchkey-small; pick the runner size that fits the job. - Cancel superseded runs when a branch or PR gets a newer push.
This workflow runs 1 job (13 with the matrix expanded) per trigger. On Latchkey the same minutes cost up to 58% less than GitHub-hosted, with zero queue time.