Repository navigation
feat: add step facts for named values and links - #17
Merged
Merged
Conversation
A step can declare facts: a label with a value, an http(s) link, or both, evaluated after the step runs with self in scope. They are redacted, recorded on the step report, printed under the step by lest run and shown with the step's artifacts in the app.
Member
Author
|
Review of the diff (self-review; a separate review agent was not available in this run), with dispositions:
|
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.
What
A step can declare
facts: named values and links that tell the reader what the step created or touched, such as a record id and a link to it in another app.facts: [{label, value?, href?}]on any step. A fact needs a value, an href, or both. Templates may useself, likeartifacts.finish_stepafter the step runs, whatever its result, and skipped with the step. Values and links are redacted. A link that resolves to anything other than http or https is dropped with a warning while the value is kept.selfin scope. A literal href that is not http or https is an error.factslist on the step report.artifactsstays file-only, solest bundleand other file consumers are unchanged. Bothlest schema flowandlest schema reportinclude it.lest runprintslabel: value hrefunder the finished step.rel="noopener noreferrer". Steps that declare only facts now appear in the side panel.Why a separate field instead of value artifacts
Making
artifactsentries polymorphic (path or value or link) would make the report'sArtifactfields optional and every file consumer (bundle, the artifact grid, demo video lookup) would need to branch. A separatefactslist keeps both shapes strict.Testing
make check: lint, typecheck, UI tests (43) and build pass. In the fullcargo test,parallel_group_runs_concurrentlyandcancel_stops_steps_but_runs_finally_and_cleanupfail when the machine is under heavy load (load average 15 to 20 during this run). They fail the same way on unmodifiedmainunder that load and pass when run alone on this branch.lest runprintedOrder: 42 https://shop.example.com/orders/42and the report carried the fact.