Skip to content

Commit 315385c

Browse files
authored
TYPE: Fix to_rasterio_dataset return signature (#897)
1 parent fbec560 commit 315385c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

rioxarray/raster_array.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
import copy
1414
import os
15-
from collections.abc import Hashable, Iterable, Mapping
15+
from collections.abc import Generator, Hashable, Iterable, Mapping
1616
from contextlib import contextmanager
1717
from pathlib import Path
1818
from typing import Any, Literal, Optional, Union
@@ -1078,7 +1078,7 @@ def to_raster(
10781078
)
10791079

10801080
@contextmanager
1081-
def to_rasterio_dataset(self) -> DatasetReader:
1081+
def to_rasterio_dataset(self) -> Generator[DatasetReader, None, None]:
10821082
"""
10831083
Return the xarray.Dataset or xarray.DataArray as a rasterio.Dataset.
10841084

0 commit comments

Comments
 (0)