Move deferred and out-of-scope items to todo.md
Tests / vet + fmt + tests (pull_request) Successful in 1m38s
Tests / vet + fmt + tests (pull_request) Successful in 1m38s
This commit is contained in:
@@ -8,18 +8,3 @@
|
||||
- A standing choice a reader would relitigate goes under Decisions in the README, not in a comment.
|
||||
- A README example is a `json` block that loads and renders as a category; `readme_test.go` runs every one.
|
||||
- Cyclomatic complexity is gated at 14: the table-shaped dispatches (`eachToken`, `calc.factor`, `walkPath`) sit at 13–14 and stay whole; anything else that reaches 14 is decomposed.
|
||||
|
||||
# Deferred
|
||||
|
||||
- **A record cannot ask for an independent reference draw (2026-09-04).** Within
|
||||
one record every tailed reference to a category is one draw, and a bare
|
||||
`{/cat}` renders the whole category, so a column wanting its own draw of
|
||||
`{/cat.field}` has no spelling for it. Left until a use case names which columns
|
||||
should disagree; premise: a record is one coherent row, which is what columns
|
||||
are for. Not raised in review before that.
|
||||
|
||||
- **Shipped-data de-duplication (2026-09-02).** `email.json`'s `local` is a
|
||||
drifted copy of `username.json`, and no shipped file yet uses a held path, an
|
||||
operand or a reference. Fixed in the data fill before the first tag, when the
|
||||
shipped set is rewritten anyway; premise: nothing depends on the shipped data's
|
||||
shape until then. Not raised in review before that.
|
||||
|
||||
@@ -82,8 +82,8 @@ For structured output a record writes the row for you.
|
||||
|
||||
A record is a template seen as columns: its fields are the columns, its `format`
|
||||
the whole. `--format json|ndjson|csv|sql` writes the records; the library's
|
||||
`Record` (below) hands back the columns. Every column is a string — this is the
|
||||
out-of-scope of typed scalars, see [Decisions](#decisions). Save
|
||||
`Record` (below) hands back the columns. Every column is a string — typed scalars
|
||||
are on the release checklist, see [`todo.md`](todo.md). Save
|
||||
`mydata/users.json`:
|
||||
|
||||
```json
|
||||
@@ -532,12 +532,6 @@ tokens add cost in proportion to the output.
|
||||
field `Fake` renders by dotted path. The `format` is inert to a record — a
|
||||
record-only template writes `"format": ""` — but it is compiled and fenced, so
|
||||
a template that loads renders as whichever shape is asked for.
|
||||
- **Records emit text; typed scalars are out.** Every value fejkdata yields is a
|
||||
string, so JSON, CSV and SQL each quote a column as text (`"42"`, `'42'`) rather
|
||||
than guess a number or a boolean. Emitting unquoted numbers or booleans would
|
||||
need a per-column `kind`, a parallel scalar system in a format whose promise is
|
||||
"text means what it says". A column's check digit, number or id is still
|
||||
valid-by-construction through a builtin; it is serialized as text.
|
||||
- **A record shares one reference draw per category.** Two columns that reference
|
||||
one category — `{/currency.code}` beside `{/currency.symbol}` — read one draw of
|
||||
it, so a record's facts agree the way a template's [correlated
|
||||
@@ -563,11 +557,6 @@ tokens add cost in proportion to the output.
|
||||
row — would vary per draw. A fixed column set is what the CSV and `INSERT`
|
||||
contracts rest on, so the restriction holds even where a particular choice would
|
||||
happen to agree.
|
||||
- **Filling a Go struct is out of scope.** `Record.Columns()` returns the columns a
|
||||
caller maps onto a struct themselves, casting each string to the field's type.
|
||||
gofakeit's `fake:"{firstname}"` tags reflect over an arbitrary struct type and
|
||||
cast into its fields — a different concern from "data lives in JSON", and one
|
||||
whose typed casting fejkdata leaves to the caller rather than owning.
|
||||
- **The performance gate asserts allocations, not wall-clock time.** `AllocsPerRun`
|
||||
is deterministic across machines, so a ±10% ceiling does not flake under CI load,
|
||||
while time varies with the machine and its neighbours. A rendering slowdown
|
||||
|
||||
Reference in New Issue
Block a user