File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,7 +21,13 @@ Upcoming Release
2121* Add ``aggregate_time={"sum", "mean", None} `` to ``convert_and_aggregate `` for temporal
2222 aggregation with and without spatial aggregation, and deprecate ``capacity_factor ``/``capacity_factor_timeseries ``
2323 in favor of it
24-
24+
25+ **Bug fixes **
26+
27+ * Fix regression when ``ExclusionContainer `` encounters a raster with an invalid CRS
28+ (https://github.com/PyPSA/atlite/pull/500).
29+
30+
2531`v0.5.0 <https://github.com/PyPSA/atlite/releases/tag/v0.5.0 >`__ (13th March 2026)
2632=======================================================================================
2733
Original file line number Diff line number Diff line change @@ -479,11 +479,14 @@ def open_files(self):
479479 assert isinstance (raster , rio .DatasetReader )
480480
481481 # Check if the raster has a valid CRS
482- if not raster .crs :
482+ if not ( raster .crs . is_geographic or raster . crs . is_projected ) :
483483 if d ["crs" ]:
484484 raster ._crs = CRS (d ["crs" ])
485485 else :
486- raise ValueError (f"CRS of { raster } is invalid, please provide it." )
486+ raise ValueError (
487+ f"CRS of { raster } is neither geographic nor projected, "
488+ f"please provide it manually:\n { raster .crs } "
489+ )
487490 d ["raster" ] = raster
488491
489492 for d in self .geometries :
You can’t perform that action at this time.
0 commit comments