Goal
This is PR 5 of 6 under epic #2340 (GeoTIFF release contract and feature tiering). Make unsupported feature combinations fail loudly with an actionable error that names the feature, names the offending input, and points at the release contract tier.
The epic enumerates the following as unsupported for this release:
- Full GDAL VRT parity (any VRT feature beyond simple mosaic assembly).
- Warped / reprojection VRTs.
- Rotated / sheared GeoTIFF write.
- Silent mixed-metadata flattening across stacked sources.
Current Gaps
-
parse_vrt in xrspatial/geotiff/_vrt.py does not check the subClass attribute on <VRTDataset>. A subClass="VRTWarpedDataset" or "VRTPansharpenedDataset" is silently treated as a plain mosaic; the reader then processes whichever simple sources happen to be present, producing wrong output rather than a clear error.
-
parse_vrt silently skips unknown band children (<KernelFilteredSource>, <PansharpeningOptions>, <DerivedRasterBand>, etc.). The mosaic appears to read fine but the declared transform is no longer applied.
-
The VRT writer in _vrt.write_vrt enforces pixel size, dtype, band count, and CRS across sources, but silently picks first['nodata'] and ignores per-source skewed transforms. A caller mosaicing tiles with disagreeing nodata sentinels loses the disagreement without any signal.
-
The VRT writer does not check raster_type (Area vs Point) across sources. Mismatched pixel registration silently flattens to the writer default.
-
The eager writer already rejects rotated attrs['transform']; the parity check should be extended into the GeoTransform-tuple path (attrs['transform'] declared as a 6-tuple with non-zero b / d) which currently slips past at the entry point.
Scope
For each unsupported case:
- Detect it at the entry point (before any IO).
- Raise an error that names the feature, the offending input, and points at the
SUPPORTED_FEATURES tier map.
- Add a regression test under
xrspatial/geotiff/tests/ asserting the error type and the substring identifying the feature.
Out of scope: experimental opt-in plumbing (PR 4), docstrings (PR 3), SUPPORTED_FEATURES audit (PR 1), docs page (PR 2).
Acceptance Criteria
- Warped / pansharpened / processed / derived VRT subClass attributes are rejected at parse time with a clear error.
- Unknown VRT band children that would alter the read result are rejected (no silent skip).
- Mosaic writer rejects mixed per-source nodata sentinels and mixed raster_type rather than flattening.
- Mosaic writer rejects sources whose source transform has non-zero skew terms.
- Eager writer rejects a rotated 6-tuple
attrs['transform'] at the entry point.
- One regression test per case, asserting both the error type and the feature-naming substring.
Goal
This is PR 5 of 6 under epic #2340 (GeoTIFF release contract and feature tiering). Make unsupported feature combinations fail loudly with an actionable error that names the feature, names the offending input, and points at the release contract tier.
The epic enumerates the following as unsupported for this release:
Current Gaps
parse_vrtinxrspatial/geotiff/_vrt.pydoes not check thesubClassattribute on<VRTDataset>. AsubClass="VRTWarpedDataset"or"VRTPansharpenedDataset"is silently treated as a plain mosaic; the reader then processes whichever simple sources happen to be present, producing wrong output rather than a clear error.parse_vrtsilently skips unknown band children (<KernelFilteredSource>,<PansharpeningOptions>,<DerivedRasterBand>, etc.). The mosaic appears to read fine but the declared transform is no longer applied.The VRT writer in
_vrt.write_vrtenforces pixel size, dtype, band count, and CRS across sources, but silently picksfirst['nodata']and ignores per-source skewed transforms. A caller mosaicing tiles with disagreeing nodata sentinels loses the disagreement without any signal.The VRT writer does not check
raster_type(Area vs Point) across sources. Mismatched pixel registration silently flattens to the writer default.The eager writer already rejects rotated
attrs['transform']; the parity check should be extended into the GeoTransform-tuple path (attrs['transform']declared as a 6-tuple with non-zerob/d) which currently slips past at the entry point.Scope
For each unsupported case:
SUPPORTED_FEATUREStier map.xrspatial/geotiff/tests/asserting the error type and the substring identifying the feature.Out of scope: experimental opt-in plumbing (PR 4), docstrings (PR 3),
SUPPORTED_FEATURESaudit (PR 1), docs page (PR 2).Acceptance Criteria
attrs['transform']at the entry point.