Skip to content

Tracking: cng-datasets tooling roadmap (hex-write, ingest hardening, scale) #114

Description

@cboettig

Canonical roadmap for the remaining cng-datasets tooling/source work. This is the durable source of truth for sequencing and cross-issue dependencies — individual issues hold their own detail. Keep all work generic (this repo is the engine + workflow generators; dataset-specific pipelines live in data-workflows).

Last updated: 2026-06-24.

Recently completed (context)

Closed via #109 (#108), #110 (#87/#79/#35), #111 (#77), #113 (#104); #66/#68 verified already-fixed in #74; CI network flakiness fixed in #112.
Then #115 (#102 + #103), #116 (#43 — parquet-input path; ST_Read path was already done), #117 (#61 — parquet-input BLOB→GEOMETRY cast; ST_Read path was already done in #75).
v0.2.0 released (#118) — first tagged release.
Then #120 (#119 — clear error for unsupported geometry encodings on the parquet-input path), #121 (#107 — oversized per-feature H3 cell-array guardrail).
Then #135 (#106 — row-group byte cap workaround; #136 tracks the upstream revisit), #137 (#134 duckdb 1.5.4 bump + #130 GDB-in-zip/generic-s3 + #131 non-EPSG SRS), #138 (#122 ST_MakeValid at convert time), #139 (#133 bounded PMTiles max zoom).

Open work, grouped

A. Hex-write & H3 indexing (correctness + query perf)

B. Geometry ingest hardening

B2. Dependency / upstream tracking

C. Raster

D. Scale / backends

E. PMTiles publish metadata

Recommended sequence & dependencies

  1. Assert all physical H3 index columns are UBIGINT after hex build (h0 exempt) #102 + Hex write: ORDER BY _cng_fid within each h0 partition for row-group pruning #103 ✅ done (fix(#102,#103): UBIGINT hex-column assertion + intra-partition _cng_fid ordering #115) — hex-write assertion + intra-partition _cng_fid ordering.
  2. Always create _cng_fid: source fid columns are not reliably unique #43 ✅ done (fix(#43): always synthesize _cng_fid on the parquet-input convert path #116) — parquet-input path now always synthesizes _cng_fid.
  3. cng-convert-to-parquet writes BLOB instead of GEOMETRY for MULTIPOINT sources — breaks PMTiles step #61 ✅ done (fix(#61): cast BLOB WKB geometry to GEOMETRY on the parquet-input convert path #117); convert_to_parquet silently passes geoarrow-native/WKT geometry through as a non-GEOMETRY column (no error, no GeoParquet metadata) #119 ✅ done (fix(#119): clear error for unsupported geometry encodings on the parquet-input path #120) — convert-step geometry-encoding hardening.
  4. Oversized-geometry safety guardrail for the 2 GB Arrow/parquet-page limit (graceful, not a C++ assertion) #107 ✅ done (fix(#107): graceful guardrail for oversized per-feature H3 cell arrays #121). Hardened geometry ingest/rebuild: route through GDAL/WKB (not DuckDB COPY) + make_valid/antimeridian/CRS84 — kill the stoi landmine #106 is blocked on an MRE (see above) — do not implement without a reproducer.
  5. Adaptive variable-resolution H3 polyfill for very large polygons (fine edges, coarse interior, no OOM/page-size) #98 ✅ Plan A done (feat(#98): adaptive variable-resolution H3 polyfill via --resolution-by-area #123): --resolution-by-area + per-feature Oversized-geometry safety guardrail for the 2 GB Arrow/parquet-page limit (graceful, not a C++ assertion) #107 back-off. Remaining Adaptive variable-resolution H3 polyfill for very large polygons (fine edges, coarse interior, no OOM/page-size) #98 scope tracked in Auto-scale hex chunk-size by feature size (cells-per-chunk budget) #124 (cells-per-chunk auto-scaling) and Recursive classify-and-descend H3 polyfill for single oversized features #125 (recursive classify-and-descend).
  6. PMTiles step OOMs on disk for very large vector datasets (~38M features); add chunked-PMTiles backend #83 / Hybrid workflow orchestrator: support Armada backend for hex step #39 / Optional: guardrail + convenience for density (Mg/ha) rasters (mean already works; sum is the trap) #105 / cng-convert-to-parquet: support CSV with lat/lon columns as point geometry input #78 — larger or independent; schedule as needed.

Note: #43 and #61 were both half-landed — their ST_Read convert paths were already fixed, and the recent PRs closed the matching gap on the parquet-input path (process_parquet_input). #119 was a third instance of the same ST_Read-vs-parquet asymmetry. Worth auditing remaining convert-step features for it.

Checkboxes here track high-level status; detail and decisions go in each linked issue and its PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions