livery.workshop._store_tasks¶
livery.workshop._store_tasks ¶
fm store.ls and fm store.show: the state store, read by hand.
Every row the workshop keeps is a declared series of the state store
(livery.git), gathered in one place
(livery.workshop._series). store.ls names each series and
family with its scope (local, or remote and mirrored by a sync, or
remote and fetched on read), its window, and what it holds; store.show
prints a series' rows newest first through the same reader the
verdicts use, so what a person reads is what the gate judged. Both
only read: the gate's verbs write, and the janitor bounds.
Functions:
| Name | Description |
|---|---|
ls_flow |
One line per declared series or family: scope, window, and what it holds. |
show_flow |
A series' rows newest first, a single row in full, or the rows as JSON. |
store_ls |
List every series the workshop keeps: its scope, its window, what it holds. |
store_show |
Print a series' rows newest first, through the reader the verdicts use. |
Attributes:
| Name | Type | Description |
|---|---|---|
store |
|
ls_flow ¶
One line per declared series or family: scope, window, and what it holds.
One listing of the remote namespace and one fetch of what the checkout lacks serve every series, so the call costs two round trips whatever the store holds.
Source code in packages/workshop/src/livery/workshop/_store_tasks.py
show_flow ¶
show_flow(root: Path, name: str, *, key: str = '', row: str = '', run: str = '', item: str = '', differences: bool = False, flaky: bool = False, escapes: bool = False, limit: int = 0, as_json: bool = False) -> list[str]
A series' rows newest first, a single row in full, or the rows as JSON.
Refuses an unknown name (naming the known ones), a negative
limit, combining row and limit, a family without its key
(listing the keys it holds, unless run, item or differences
inspects the proved family), a key of the wrong shape, an unknown
or ambiguous row, and a series the store cannot read (with the
store's reason). Local series read directly from the checkout's git
directory; remote series go through one listing of the remote
namespace.
Source code in packages/workshop/src/livery/workshop/_store_tasks.py
114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 | |
store_ls ¶
List every series the workshop keeps: its scope, its window, what it holds.
A remote series is read from origin, a local one from this checkout's git directory; a series that cannot be read prints the store's reason in its place.
Source code in packages/workshop/src/livery/workshop/_store_tasks.py
store_show ¶
store_show(series: Annotated[str, doc("the series' name, as store.ls lists it")], key: Annotated[str, doc("a family's key, its parts comma-separated")] = '', row: Annotated[str, doc('one row by name or unique prefix, printed in full')] = '', run: Annotated[str, doc('filter proved rows to one forge run id')] = '', item: Annotated[str, doc('show recorded reads for one proved test item path')] = '', differences: Annotated[bool, doc('list shadow comparison differences for the proved family')] = False, flaky: Annotated[bool, doc('list units flagged flaky (both green and red on one fingerprint)')] = False, escapes: Annotated[bool, doc('list selection escapes caught on scheduled audit runs')] = False, limit: Annotated[int, doc('maximum number of newest rows to show (0 for all)')] = 0, json: Annotated[bool, doc('the rows as JSON, newest first')] = False) -> None
Print a series' rows newest first, through the reader the verdicts use.
Each row prints as its file name and stamp, then its fields on one
line with containers by size; --row prints one row in full as
JSON (by exact name or unique prefix, as the diagnostics: line
names it), --run lists every row written by one run in the
proved family, --item lists what one test item read in the
proved family, --differences lists shadow comparison
disagreements recorded for the proved family, --flaky lists
units flagged flaky in the proved family, --escapes lists
selection escapes recorded for the proved family, --limit
caps how many newest rows print, and --json prints every
selected row as JSON. A family (store.ls shows its key parts) is
shown one key at a time, and without --key lists the keys it
holds.