Context
After #173, the geodataset classes no longer need the GeoPackage for routing or training — flowpath attributes come from the adjacency zarr. The GeoPackage is only needed for:
- Plotting — visualization notebooks use geometry to draw river networks
- Legacy workflows — users who prefer the current gpkg-based setup
Currently, geospatial_fabric_gpkg is a required Path field in DataSources (validation/configs.py:47).
Proposal
Make geospatial_fabric_gpkg optional:
geospatial_fabric_gpkg: Path | None = Field(
default=None,
description="Path to the geospatial fabric geopackage (only required for plotting)"
)
Downstream changes
- Any code that accesses
cfg.data_sources.geospatial_fabric_gpkg must handle None
- Plotting utilities should raise a clear error: "GeoPackage path not set. Provide geospatial_fabric_gpkg in your config to enable plotting."
- Config templates for routing should omit or comment out the gpkg field
Files to modify
src/ddr/validation/configs.py — make field optional
src/ddr/validation/plots.py — guard against missing gpkg
config/templates/*.yaml — comment out gpkg for routing templates
- Example configs — remove gpkg requirement
Acceptance criteria
Depends on
Context
After #173, the geodataset classes no longer need the GeoPackage for routing or training — flowpath attributes come from the adjacency zarr. The GeoPackage is only needed for:
Currently,
geospatial_fabric_gpkgis a requiredPathfield inDataSources(validation/configs.py:47).Proposal
Make
geospatial_fabric_gpkgoptional:Downstream changes
cfg.data_sources.geospatial_fabric_gpkgmust handleNoneFiles to modify
src/ddr/validation/configs.py— make field optionalsrc/ddr/validation/plots.py— guard against missing gpkgconfig/templates/*.yaml— comment out gpkg for routing templatesAcceptance criteria
ddr routeworks withoutgeospatial_fabric_gpkgin configddr trainworks withoutgeospatial_fabric_gpkgin configDepends on