Skip to content

Where people and agents ship software together. The open-source git platform for the whole job: issues, agents, checks and deploys to the edge.

Iteration speed: affected-only CI, faster deploys, PR previews, GitHub's runner labels; the merge queue lands reliably #377

Mergedsyntaqx merged 373-iteration-speed into main
syntaqxopened this pull request

Closes #373. Closes #371. One batch, one deploy.

CI checks only what a change reaches

  • TypeScript CI runs only what a change affects:
    • Type checks and tests run only for the npm workspaces a change reaches, through their dependency graph, two at a time (scripts/deploy/ci-workspaces.mjs).
    • The install covers only those workspaces.
    • The deploy, conformance, ops, manifest and plugin checks run only when their inputs change.
    • The site's build runs only when a site or the deploy tool changes.
  • A push to main is unchanged: a direct push runs everything, and a push the queue landed only warms caches.
  • Rust tests: six parts instead of three (~60k lines each), with CARGO_BUILD_JOBS=2 and RUST_TEST_THREADS=2 for 2 vCPU / 8 GiB.
  • Desktop: its test build carries no debug info and its cache has a new key, so it fits 2 vCPU. A link once died with a bus error there.
  • Expected time: a web-only PR in about 2 minutes, down from about 7.5.

Deploys

  • Stages wait only for what really calls them, through service bindings and tail consumers. The API and the runner image no longer gate the site.
  • Prebuilt sites install only Wrangler.
  • Web assets are archived 16 at a time instead of 6.
  • Rust Workers are built one or two to a job, sized for 2 vCPU.
  • Expected time: a web-only change in about 4 to 4.5 minutes, a full deploy in about 10 to 11, down from 18.
  • This merge redeploys every unit once (deploy inputs changed). It's the first run of the new pipeline.

Previews for pull requests

.g1t/workflows/preview.yml builds the site with no secrets, for same-repo PRs only. It uploads it as a Workers version under the alias pr-<N>, at https://pr-<N>-g1t.syntaqx.workers.dev, and links it from the PR as preview / web. It uses the repository's deploy token. Sign-in on a preview is by password, and a preview uses production data.

GitHub's runner labels

  • Every repository, public or private, gets GitHub's private-repository sizes:
    • ubuntu-slim: a new 1-vCPU, 6 GiB machine (SandboxSlim), at $0.003 a minute.
    • ubuntu-latest, the Ubuntu versions and the arm labels (which run on x64): 2 vCPU, 8 GiB.
    • Windows and macOS: refused with a clear message unless the job asks for a self-hosted runner.
  • g1t-2core and g1t-4core are gone. Their names get the standard machine. Their classes are deleted (migration v6).
  • The 4-core machine stays only to price and report past minutes.
  • Larger runners will follow GitHub's model (#376).

The merge queue lands reliably

  • Why it stuck: the first landing ran inside the job report of the CI run that passed it. That request was cancelled after the landing intent was taken, and nothing ever retried it.
  • The fix:
    • Landing now runs in the queue consumer's own pass.
    • A failed or cut-off landing is recorded with a reason and swept again.
    • A PR that merged or closed outside the queue leaves it without landing a stale tested state. The database refuses that too.

#371: a killed step says so

A step stopped by a signal exits 128+signal, names the signal, and says when the machine ran out of memory. CI #599's "lost output" was a build killed mid-way, reported as exit code 1. Log the runner couldn't send is now noted in the job log instead of dropped.

Also

Clicking the workspace at the top of its menu opens g1t.sh/<workspace>.

Checks run locally

  • cargo test with -D warnings:
    • contracts 373, actions workflows 24, actions-service 139, billing 312, work 346, runner 273
    • repos 419, plus the integration test files
  • npm run test:deploy (152), plus the preview, ci-workspaces and ci-affected tests (35)
  • runner service: tests (119) and tsc
  • contracts tsc
  • web: typecheck (both configs) and lib tests (1206)
  • production web build: all 309 routes load, and the deploy check passes
  • deploy.mjs manifest --check
  • prettier

After deploy

  • Delete the orphaned container apps g1t-runner-sandbox2core and g1t-runner-sandbox4core.
  • Turn the merge queue back on.
syntaqxturned on auto-merge (merge commit)·
syntaqxmerged this·
syntaqxdeleted the 373-iteration-speed branch·

All checks have passed

3 passed · on c05ff2f

Workflows

CI / pull_request — CI passedDetails
Dependency review — No dependency changesDetails
Preview / pull_request — Preview passedDetails

373-iteration-speed was deleted

It can be made again at c05ff2f, where it was.

Sign in to comment.