v1 · 48 printed rows · wrong on purpose
A print studio's lot list, built by hand, with twelve kinds of error planted in it. I planted them, so I know the answers, which is the whole reason it is worth testing a checker against it.
A real catalogue cannot be used for this. Its errors are the ones nobody noticed, so nobody knows what the right count is either. A constructed one has a key, and a key can be wrong in only one place: against the file. So the key below was computed by reading this CSV back, not by reading my intentions.
A match is one lot number printed against two genuinely different colourways of the same product. Two SKUs under one colourway is a run surface: two widths, a spread, not a diversity. It is not a match and it must not be counted as one.
feed.csv · sha256 c8e63907461790406b21fb9a3fdc4519eaa955a34532168d9ab0a211decce71d
| column | what it holds |
|---|---|
page | the page of the source document this row was read from |
product_code | three products, P-101 to P-103 |
product_name | the same three, spelled out |
lot | the printed lot number, as printed |
colourway | the printed colourway, as printed |
sku | the printed SKU, as printed |
units | printed quantity; carry it, do not sum it |
“As printed” is load bearing. Nothing in that column has been cleaned.
Classes and row counts. Not locations. Finding them is the test.
| class | size | what a screen must do |
|---|---|---|
| exact duplicate row, re-scraped on a second page | 1 row | collapse on content, not on page |
| one lot printed three ways (trailing space, clean, lower case) | 3 rows | trim and fold case before joining |
| one SKU printed three ways (case, surrounding spaces) | 3 rows | normalise before counting distinct SKUs |
lot continuation, printed (cont.) on a later page | 1 row | join the continuation, do not cut the lot in half |
placeholder lots: "", 0, TBC | 7 rows | never join on a placeholder; report those rows unplaced |
| colourway missing on every row of a lot | 3 lots | return unresolved, not resolved either way |
| one lot, two or more SKUs, one colourway | 5 lots | run surface; separate count from matches |
| lot number prefix collision | 2 rows | exact lot key; no truncation, no prefix match |
| colourway spelling one edit apart | 1 lot | flag for a human; do not decide |
| one SKU claimed by two colourways | 2 rows | conflict; exclude from both counts |
| one lot claimed by two products | 2 rows | conflict; a lot belongs to one product |
| one SKU printed under two lots (a reprint) | 4 SKUs | legal, and it must not merge the two lots |
Per lot, one line: the count, the fields that count was computed on, written beside it, and the product it belongs to. A match count and a run count are two numbers, never one. Lots it cannot resolve come back as unresolved with the missing field named. Nothing comes back as a single figure that a reader has to guess the meaning of.
I hold it, and it is computed, not remembered. It is not on this page, because a fixture you can read the answers to from the same page tests nothing. Run your screen against feed.csv, send the result, and the key comes back with the diff.
Because I made the mistake it is built to catch, in a reading of someone else's register: a run count wearing the label of a match count, and a diversity claim that was a spread. The correction is not a better number. It is printing the fields beside the number.