Repository navigation
feat(smoke_timings): ingest per-script smoke timings onto the ⏱ board - #203
Merged
Merged
Conversation
…#202) The daily heart-health run now fetches each smoke-gate repo's newest smoke-timings-<py> artifact via the Actions API, parses the smoke_timings/1 dataset, and renders per-script rows next to the workflow-level gates: slowest scripts per repo, TIMEOUT rows as hard events with a /bug prompt, run-to-run slowdowns as advisory warn rows (2.0x AND >=5s, declared in config/repos.yaml). The previous observation is self-carried through the published board.json's performance.scripts block, keyed by run id so a re-render never compares a run against itself; durable history is phase 2 of the ci-timing-fast-tests epic. Readiness verdict and badge untouched. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0151gQm9fk3XGLi5f18Urdba
This was referenced Sep 5, 2026
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #202. Phase 1 of the
ci-timing-fast-testsepic (PyAutoMinddraft/feature/pyautoheart/ci_timing_fast_tests_epic.md); Plane B ofdocs/pyautoheart/test_performance_board_assessment.md.Summary
Every smoke-gate run across the workspace /
_test/ HowTo repos has uploaded asmoke-timings-<py>artifact (smoke_timings/1: one row per executed script with the runner's own measured seconds, the cap in force and the exit code) since PyAutoHands#265 / PyAutoHeart#167 — and nothing read it. This adds the ingester as a fifth cloud-safe check in the dailyheart-health.ymlrun, in theci_timingshape (shell leg → per-repo sidecar → aggregate rollup → board section +board.jsonblock):heart/checks/smoke_timings.{sh,py}— per smoke-gated repo (groupsworkspaces,workspaces_test,howto), list artifacts via the Actions API, select the newest non-expiredsmoke-timings-<py>per python leg, download + unzip, parse the dataset. Rows keep provenance (run id / URL / branch / leg).TIMEOUTrows are hard events with a/bug kill timer …prompt; a script that slowed against the previous observation is an advisorywarnrow with a/bug slow script …prompt.nullseconds (skipped / never ran) are never counted as a 0 s run. A failed listing or download is recorded as an honest error per repo/leg — never a quiet-looking empty result.ci_timing's history: the aggregate step re-reads the publishedboard.json's newperformance.scripts.rowsand compares each(repo, python, entry)against its last row only when the run id differs — a re-render of the same day never compares a run against itself. Durable committed history is phase 2 of the epic and is deliberately out of scope here.config/repos.yaml thresholds.smoke_timings):warniff ≥ 2.0× the previous observation AND ≥ 5 s slower. Own numbers becauseci_timing's 1.5×/120 s is sized for multi-minute gates; 2.0× is the profiling conductor's ratio and 5 s sits above the ~5–7 s import-floor jitter. Advisory — the readiness verdict andbadge.jsonare untouched.performance.scriptsblock emitted only when the slice was observed, so older snapshots render a byte-identical block. The Brain board ignores the new key; a headline row for it is a follow-up.actions: readpermission (artifact endpoints need it even for own artifacts) andGH_TOKEN: ${{ secrets.HEART_TIMINGS_TOKEN || secrets.GITHUB_TOKEN }}.Known risk — needs a human eye after the first scheduled run
The artifact
/zipendpoint may refuse the repo-scopedGITHUB_TOKENfor other repos' artifacts (actions/download-artifact documents cross-repo downloads as needingactions: readon that repo). If the 05:00 UTC run shows the ten workspace repos asN unavailableon the Smoke scripts row, the remedy is a fine-grained PAT (Actions: read on the PyAutoLabs workspace repos) stored as theHEART_TIMINGS_TOKENsecret — no code change. Heart's own artifacts ingest either way.API Changes
No public API change. New check module
heart.checks.smoke_timings; new snapshot keysmoke_timingsinheart.state.aggregate(); new optionalperformance.scriptskey inboard.json(schema v2 stays v2, purely additive).Test Plan
python3 -m pytest -q -n auto— 684 → 735 passed (34 new intests/test_smoke_timings.py, 13 intests/test_dashboard.py, 4 intests/test_heart_health_wiring.py, 2 shell tests intests/test_smoke_timings_script.pydrivingingest_one_repowith stubgh/unzip: one leg 403s, the sibling leg survives)bash -n heart/checks/smoke_timings.sh;yaml.safe_loadonheart-health.ymlandrepos.yamlRepoA,OwnerX,ci.invalid);repos_sync.py --checktenant gate OKheart-health.ymlrun: the Smoke scripts row appears on https://pyautolabs.github.io/PyAutoHeart/ andboard.jsoncarriesperformance.scripts; check theunavailablecount for the cross-repo 403 aboveGenerated by the PyAutoLabs agent workflow.
🤖 Generated with Claude Code
https://claude.ai/code/session_0151gQm9fk3XGLi5f18Urdba
Generated by Claude Code