fix(ci): every step named, every wait says why, the test parts pass on a 10-core runner, uploads off Cloudflare #2568
No reviewers
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/mods
area/renderer
area/saves
area/tooling
area/upscaling
beanstalk: approved
beanstalk: failed
beanstalk: needs approval
beanstalk: running
beanstalk: tested
ci: approved
good first issue
gpu/amd
gpu/igpu
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
needs measurements
platform/linux
platform/macos
platform/steam-deck
platform/windows
preview
priority
critical
priority
high
priority
low
regression
risk
high
risk
low
risk
medium
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
ci: approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot!2568
Loading…
Reference in a new issue
No description provided.
Delete branch "HumanBean/Longshot:push-vmnrpnsvpltt"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
The follow-up to #2557, which merged before this commit landed on it.
Every step of every workflow has a
name:. Forgejo shows an unnamed step by its first script line: release.yml's version step read "git fetch -q --tags origin main ref=$(git rev-parse HEAD)". Now it is "The version's name (on a push to main, a wait of 5 minutes for more merges first)". Checkouts say what they check out (the commit, main's code, the base's scripts, the CI images' inputs), cache steps what they restore or save (main's tree, the registry crates' builds, the release's downloads, the shipped builder's compiled Rust, llvm-mingw's archive, the compiler cache). Step ids are kept; no test matched an unnamed step.Every deliberate wait says why first, and a long one shows progress each minute: the version job's 5 minutes for more merges (
::notice::waiting 5 minutes for more merges before naming the nightly (main is still at <sha>)), preview-wait's wait for CI'swebsite-dist-<sha>(scripts/ci_website_dist.py), the Windows build's wait for the background Wine install, and the package-install retries in build-linux.yml, tools.yml and ci_setup.sh.docs/dev/reference/ci.md has a section on the website preview:
preview-wait(quick, no secrets) andpreview-upload(deploy), what each does, and that the upload never runs the pull request's code.The game-free checks' parts pass on a 10-core runner too (second commit). #2557's merged run had part 1/2 fail on a 10-core runner (part 2/2: 182 s on a 24-core one):
test_camera_speed.pytimed out at 900 s, because it and 49 other site-hook checks runcargo run -p longshot-builder(tests/sitehooks.py), which built the developer builder cold behind cargo's lock beside the other checks: each part now builds it first.test_recorder_sync.pytook over 900 s there (445 s on CircleCI): 1200 s a check.test_prepare_stall.py's busy-compile case stopped at 4 s because its two spinning threads fell below the watchdog's half a CPU beside 9 other checks: four threads now, the watchdog unchanged.tests/run_all_times.jsonhad no times for most checks, so part 1 got all the heavy ones: it holds that run's times now.The build jobs' artifacts uploaded through the server's own address first (third commit). Release run 54507's Linux job hit
ssl3_read_bytes: tls alert bad record macuploading the 306 MBlongshot-builder-linuxartifact through git.magicbean.dev (Cloudflare); ci-image.yml's first run on main failed its upload with a 524. build-linux.yml, build-windows.yml and ci-image.yml now first runupload-artifactwithACTIONS_RESULTS_URLset toRELEASE_UPLOAD_API's host (the server on the runners' network); when that fails or the variable is unset, the usual way, then once more as before. The publish job already downloads through that address (release.py artifacts). Not verified: whether Forgejo 17 answers that call with upload addresses under the host asked or under itsROOT_URL; in the second case the bytes still go through Cloudflare and nothing is gained (nothing lost either). If so, the server-side fix would be Forgejo building the artifact upload URLs from the request's host (newer Gitea'sPUBLIC_URL_DETECTION=auto), or the release runner resolving git.magicbean.dev to the server itself, with TLS there; I changed nothing on the server.The checks that measure time or CPU run alone (fourth commit). This PR's first run failed four checks on 10-core runners with 10 checks at once:
test_recorder_sync.py(past 1200 s; 445 s alone on CircleCI),test_prepare_stall.py(its watchdog saw no busy CPU),test_sampler_admission.py's concurrent case andtest_game_phases.py's running-frames count. A test may declareRUN_ALL_ALONE = True: run_all.py runs those one at a time after the parallel ones. The four declare it; no check changed.Three tests that failed on a loaded runner fixed (fourth to sixth commits):
build-core'sa_second_build_is_refused_until_the_first_lets_gofound the lock busy right after letting it go, because a test of the same process that starts a program holds the file from its fork to its exec. The re-takes now try for up to 5 s, and the refusal is asserted as before.test_job_queue.py's exclusive check asked whether b started before a ended, also true when b reached the queue first on a loaded runner: it now asks whether the two spans overlap. The duplicateimport sysintest_sampler_admission.pyis gone (ruff, once the file was touched).Read
.forgejo/workflows/release.yml(the version step),scripts/ci_website_dist.py(wait),docs/dev/reference/ci.md(The website's preview).Testing
Tested: CI on
369d69f6: every job green, both test parts on 10-core runners (part 1/2 14m24, part 2/2 29m04). Linux (CachyOS):test_prepare_stall.pypasses; actionlint, ShellCheck, ruff; the tests that read the workflows (test_release_workflow,test_windows_on_linux,test_checks_container,test_check_pr_description) and the byte-compile pass. This PR's CI runs every workflow file's checks.Still to test:
Measurements
Verdict: both test parts pass on the 10-core runner: part 1/2 took 11m42 in the run on
a0fa091a(it failed at 38m37 on #2557's head).The runner-minutes on #2557's pull requests with the CI images (the run on
a0fa091a: these inputs changed, so the jobs used the fallback,ci_setup.shfirst, a minute or two each):4a0da5ca(#2553's run, 16 jobs)a0fa091a(9 jobs)The After column is this PR's own run on main @
fd68f82c, so it already includes everything on main since the Before run; there is nothing to measure again.Lint with the pushed
liteimage should take about a minute: pre-commit's hooks are fetched in the image, and the fallback'ssystem-lite,python,node,toolsandhooksparts are what took 1.5 to 2.5 minutes of a 3- to 4-minute lint here.Risks
Log lines and names only; no step's work changed. A revert is enough.
Checklist
Ready for review
main; the title is a Conventional Commit.mise run testpasses (any failure that also fails onmainis named). (this PR's CI ran every game-free check, both parts green on369d69f6; the tests that read the workflows passed locally)main, or Measurements says why there is nothing to measure.third_party/untouched; nothing GPL-incompatible.When it applies
tests/that reads changed source is updated, not weakened. (test_checks_container, test_release_workflow and the others that read the workflows pass; the three flaky tests keep every assertion)Assisted-by:/Co-Authored-By:trailers.Ready to merge
main, measured again or a comment says why the numbers still hold.🤖 Generated with Claude Code
https://claude.ai/code/session_017vw8e1RP1VgcWpgA7Kq6ec
WIP: ci: every workflow step named, every wait says why, and the website preview's jobs documentedto WIP: fix(ci): every step named, every wait says why, and the test parts pass on a 10-core runnerWIP: fix(ci): every step named, every wait says why, and the test parts pass on a 10-core runnerto WIP: fix(ci): every step named, every wait says why, the test parts pass on a 10-core runner, uploads off Cloudflare6613f5fb23a0fa091a57WIP: fix(ci): every step named, every wait says why, the test parts pass on a 10-core runner, uploads off Cloudflareto fix(ci): every step named, every wait says why, the test parts pass on a 10-core runner, uploads off Cloudflare369d69f6b42e44e12e99