Skip to content

CSV export renders unsigned integers as signed — silent value corruption (U8 132 → -124) #208

Closed

Description

@dfa1

Found by the Raincloud conformance harness (#205) on uci-wine (written by vortex-data==0.69.0): column magnesium has dtype U8?; row 34 holds 132 in the Parquet oracle but vortex-java exports -124 (= 132 − 256). This is silent data corruption, not a crash — the scan succeeds and every value ≤ 127 is correct, so synthetic fixtures never caught it.

Cause: CsvExporter.cellValue formats by array class only (ByteArray → Byte.toString, ShortArray → Short.toString, …) and never consults the dtype's signedness. U8/U16/U32/U64 columns all render their high-half values wrong.

Scope check needed beyond CSV export: any consumer that stringifies or widens typed getters without masking (cli view/stats/filter, jdbc, calcite) likely shares the blindness.

Note: kepler-exoplanet-search-results, palmer-…-penguin-data, and uci-bike-sharing-dataset currently fail earlier on #206 (lazy dict U8/U16 values); once that lands they will likely expose this bug too — the conformance matrix entries should flip together only if both are fixed.

Repro: hydrate uci-wine via Raincloud, vortex-cli export uci-wine.vortex -, compare row 35 column 5 against the parquet sibling.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions