Skip to content

feat(manifest): stop writing distinct_counts on v3 manifests #1001

@laskoviymishka

Description

@laskoviymishka

Parent: #589

The v3 spec deprecates distinct_counts on data_file (Java precedent: apache/iceberg#12182). iceberg-go still writes the field unconditionally — DataFileBuilder.DistinctValueCounts always sets distinct counts on the underlying Avro record, regardless of format version.

Gate the write so v3 manifests omit the field while v2 still emits it. The struct field can stay (Avro tolerates absent optional fields); the change is on the writer side.

Round-trip test: write a v3 manifest with distinct counts supplied, read it back through ReadManifest, assert the distinct counts are absent; same test on v2 should still see the values present.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions