Fistron docs

fistron.io

Get your CI’s answer sooner

A change pushed today should not wait until tomorrow for its first failure. Fistron measures how long your team waits for its CI, proposes test tiers (fast checks on every push, the tests a change needs on a pull or merge request, the full suite at night), tells you which of a tier’s tests a change needs, and proposes the change of your CI files. Your team decides the tiers and who owns each; your CI runs them; Fistron never claims a speed-up before your own history shows one.

Before you start

1. Measure the loop

Run feedback-loop on the history (Operations, or fistron feedback-loop --history history.json). Open the record feedback_loop under Documents: until the first result, the first failure and the complete evidence, median and 90th percentile, and the longest waits for a failure. Keep it: given as the next run’s baseline, it shows whether the loop got shorter, and Fištrónek’s status report says so.

2. Have the tiers proposed

Run fistron tiers propose --history history.json (add --suite-map for an end-to-end suite, --path for your team’s policy). Open tiers_proposal under Documents:

Then propose it as your tiers: run fistron propose tiers --record tiers-proposal.json (or propose-tiers on Work, with the record). It waits under Proposed changes of Repository settings. Review it with your team; a manager clicks Confirm, then sets who owns each tier and moves what you know better in the setting tiers.

Each test’s level is shown with what it rests on. Where your own tools or names say a level Fistron does not read, say it once in the policy’s [levels], the first that matches deciding:

[levels]
"@smoke-api" = "api"          # a tag
"tests/contract/**" = "api"   # a path
"*IT::*" = "api"              # a test's name, classname::name

Your [levels] come before everything Fistron reads itself (the suite map, the framework’s marks such as Maven Failsafe’s *IT classes, the test’s names). A test nothing names stays in the end-to-end tiers; its reason says when its speed looks like a unit test, so you can name it. fistron tiers check validates it, and fistron tiers export --tier fast --format cucumber-tags (or junit-groups, pytest-markers, job-list) gives a tier to a tool you wire yourself. The tests the proposal assigned to a tier export with cucumber-names, junit-tests or pytest-nodes, one per line; each export says which assigned tests it leaves out.

3. Select a change’s tests within a tier

Run fistron tiers select --tier pull-request --diff change.diff --history history.json --head <sha>. Open tier_selection: how many of the tier’s tests the change needs and why each is selected or omitted. This is shadow mode: your CI still runs the whole tier. With --head, the full run of that change shows whether the selection would have missed a failure: a red Missed failures says it did. Run it on every change for a while; the status report counts the misses. Only when they stay at none is it worth running the selection instead of the whole tier.

4. Replay your history under the tiers

Run fistron tiers replay --history history.json. Open tiers_replay: for each change that failed, when its first failure came and when it would have come under your tiers, which test would have caught it in which tier, and, in red, the failures no tier catches before a release (put their tests in a tier). It is an estimate from the history’s medians: your own CI’s runs under the tiers, measured in step 1, show the real effect.

5. Have the CI change proposed

Run fistron tiers propose-ci --repository <owner/name> in a working copy of the repository. Open ci_proposal: the changes of your CI files with their reasons (each tier job’s timeout and the events it runs on), the jobs left as they are and why (deployment jobs, reusable workflows, jobs with their own GitLab rules), what to add by hand, and the checks to make required in the repository’s settings. The proposed files, their patch and their validation are beside it. A Jenkinsfile’s declarative stages get the same: their timeout and a when with the tier’s events; set lint_pipelines = true under [acquisition.jenkins] to have your Jenkins check the pipeline before the request is opened.

Then fistron tiers open-ci --proposal fistron-ci-proposal/ci-proposal.json --repository <owner/name> --dry-run says what would be written; without --dry-run it opens the pull or merge request with the CI token. A person reviews and merges it; your CI runs the tiers on the request itself.

Troubleshooting

You see Cause and fix
the tier proposal needs fistron-core The proposal, the selection and the CI change are the closed core’s; the measurement, check and export work without it.
Many tests “of unknown level”, all in the nightly tier Their names say no level. Say it in the policy’s [levels] (a tag, a path or a name), tag them, or assign them in .fistron/tiers.toml.
No shift_left proposal, and a note to map the suite again The suite map was built before it recorded what each step definition reaches: map the suite again.
The whole tier runs for every change A changed file is one nothing maps: no per-test coverage, feature, step definition or function’s source. Add coverage, or list the file in the policy’s ignore when its change never matters.
needs ci_token_env in the group Name the CI token’s variable in the actions group; Fistron never uses its usual write token for CI files.
actionlint: not run Install actionlint where Fistron runs: a change of a workflow is never opened unvalidated.
changed on main since the proposal The CI files moved on: run fistron tiers propose-ci again.

Details: feedback-loop.md.