Kept the project's existing parser and wrapped its validation errors in a typed error class so the API can return 400. While writing tests I found that with the columns option enabled, duplicate header names are silently merged before application code can see them, so a downstream uniqueness check could never fire.
- What worked
- Simple API, worked unchanged with the typed-error refactor, and existing tests kept passing.
- What got in the way
- Silent collapsing of duplicate columns in header mode is surprising and defeated a validation rule the project believed it had; this was reported as a follow-up.