livery.workshop._e2e_rows¶
livery.workshop._e2e_rows ¶
What the newborn's store says a run did: the rows the loop's proofs read.
A proof asks the rows the legs wrote, never a job's log: a run's
metrics row (each check leg's scope and the coverage section the gate
job left), the verified series (the tree a run proved and what it
rests on), a base's coverage record (which run measured each unit),
the coverage marks, and a platform leg's durations series (the seconds
per item a run's gate job recorded). A platform that ran as
shards has one check row, the fold's, keyed by the platform leg with
its shards listed under shard; the forge's rows of the shards
stand beside it with their times alone, and no proof reads them as
the leg. Every reader fails naming the series, the file and the run
when the row it needs is not there, so a proof that fails says what
the legs did not write.
The coverage rows are read by their ref and a few fields, since the loop lives in the base and the base imports no extension; their schema is the coverage extension's, and the loop leaves the base with phase 15 of the destination note.
Classes:
| Name | Description |
|---|---|
ShardFacts |
One shard of a folded check leg, as the fold listed it. |
FoldFacts |
The fold's record on a platform's check row: what its shards partitioned. |
LegFacts |
One job's half of a run's metrics row: what its gate ran. |
RunFacts |
A run's metrics row, read for a proof. |
DurationsRow |
What a platform leg's durations series holds for one run. |
UnitRow |
One unit of a base's coverage record: the run that measured it. |
MarkRow |
A package's current coverage mark: the newest row that set it. |
Functions:
| Name | Description |
|---|---|
run_facts |
The metrics row of run_id, fetched fresh from the newborn's origin. |
durations_row |
The durations row run_id's gate job wrote on leg's platform, fetched fresh. |
verified_by |
The verified row run_id stamped; fails naming the series when none did. |
verified_tree |
The verified row of tree; fails naming the series when the record lacks it. |
record_units |
base's coverage record on leg: the current row of each unit, by path. |
marks |
The current mark per package, the newest row each; fails when unreadable. |
Attributes:
| Name | Type | Description |
|---|---|---|
COVERAGE_RECORD |
|
|
COVERAGE_MARKS |
|
COVERAGE_MARKS
module-attribute
¶
ShardFacts
dataclass
¶
FoldFacts
dataclass
¶
The fold's record on a platform's check row: what its shards partitioned.
Attributes:
| Name | Type | Description |
|---|---|---|
count |
int
|
How many shards the platform ran as. |
digest |
str
|
The digest of the set the shards partitioned. |
rows |
tuple[str, ...]
|
The durations rows the shards partitioned by, newest first; empty when no row was there to read. |
shards |
tuple[ShardFacts, ...]
|
Each shard, in order. |
LegFacts
dataclass
¶
LegFacts(job: str, scope: str, packages: tuple[str, ...], base_tree: str, leg: str, tasks: tuple[str, ...], shard: str = '', fold: FoldFacts | None = None)
One job's half of a run's metrics row: what its gate ran.
Attributes:
| Name | Type | Description |
|---|---|---|
job |
str
|
The job's name, as the forge lists it. |
scope |
str
|
What the leg's gate ran: |
packages |
tuple[str, ...]
|
The suites a narrowed gate ran. |
base_tree |
str
|
The tree a narrowed gate measured from; empty otherwise. |
leg |
str
|
The leg's label, the key of its coverage record
( |
tasks |
tuple[str, ...]
|
The tasks the job ran, by the names its trace recorded: the top-level tasks and each task's steps. |
shard |
str
|
The shard whose own row this is ( |
fold |
FoldFacts | None
|
What the fold recorded on a platform's row; |
RunFacts
dataclass
¶
RunFacts(run: str, jobs: dict[str, LegFacts], coverage: dict[str, float], shard_jobs: tuple[str, ...] = ())
A run's metrics row, read for a proof.
Attributes:
| Name | Type | Description |
|---|---|---|
run |
str
|
The run's id. |
jobs |
dict[str, LegFacts]
|
Each job's facts, by the job's name; the forge's rows of a platform's shards are not among them. |
coverage |
dict[str, float]
|
The coverage section the gate job left: the percent each unit was judged at, by the unit's path; empty when the gate job judged nothing. |
shard_jobs |
tuple[str, ...]
|
The names of the forge's rows of a platform's shards, kept beside the fold's row with their times alone. |
Methods:
| Name | Description |
|---|---|
job |
The one job whose name starts with prefix; fails naming the row. |
job ¶
The one job whose name starts with prefix; fails naming the row.
The answer is the leg's own row: for a platform that ran as shards, the fold's, never the forge's row of a shard. A row that is one shard's own, or shard rows with no fold's row among them, say the gate job's fold did not run, and the answer fails naming them.
Source code in packages/workshop/src/livery/workshop/_e2e_rows.py
DurationsRow
dataclass
¶
What a platform leg's durations series holds for one run.
Attributes:
| Name | Type | Description |
|---|---|---|
ref |
str
|
The series' ref, |
name |
str
|
The row's file name, the run's. |
items |
dict[str, float] | None
|
The seconds per item the row holds; |
UnitRow
dataclass
¶
MarkRow
dataclass
¶
run_facts ¶
The metrics row of run_id, fetched fresh from the newborn's origin.
Fails naming the series and the file when the row is not there: the gate job's collect did not write it.
Source code in packages/workshop/src/livery/workshop/_e2e_rows.py
durations_row ¶
durations_row(root: Path, run_id: int | str, leg: str) -> DurationsRow
The durations row run_id's gate job wrote on leg's platform, fetched fresh.
The series is the platform leg's (livery.workshop.platform_leg),
so a shard's label reads its platform's. Fails naming the series
when it cannot be read; a series without the run's row answers
items as None.
Source code in packages/workshop/src/livery/workshop/_e2e_rows.py
verified_by ¶
The verified row run_id stamped; fails naming the series when none did.
Source code in packages/workshop/src/livery/workshop/_e2e_rows.py
verified_tree ¶
The verified row of tree; fails naming the series when the record lacks it.
Source code in packages/workshop/src/livery/workshop/_e2e_rows.py
record_units ¶
base's coverage record on leg: the current row of each unit, by path.
A current row is named by its unit's slug alone; a kept row, named
by its moment and closure as well, and a fixed-facts file under
facts/ are not units of the record. The rows are read raw and
four fields taken, so the loop carries neither the coverage
extension's schema number nor its parser. Fails naming the ref when
it cannot be read; an absent record is empty.
Source code in packages/workshop/src/livery/workshop/_e2e_rows.py
marks ¶
The current mark per package, the newest row each; fails when unreadable.