diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 53595f9..b3bb199 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -95,6 +95,7 @@ jobs: python3 setup.py install pip3 install --upgrade numpy elasticsearch pip3 install --upgrade numpy "sqlalchemy<2" + pip3 install --upgrade flake8 pip3 install --global-option=build_ext --global-option="-I/usr/include/gdal" GDAL==`gdal-config --version` #pip3 install --upgrade rasterio==1.1.8 - name: setup test data ⚙️ diff --git a/pygeoapi/provider/xarray_.py b/pygeoapi/provider/xarray_.py index 48eec09..f9751db 100644 --- a/pygeoapi/provider/xarray_.py +++ b/pygeoapi/provider/xarray_.py @@ -62,7 +62,12 @@ class XarrayProvider(BaseProvider): if provider_def['data'].endswith('.zarr'): open_func = xarray.open_zarr else: - open_func = xarray.open_dataset + if '*' in self.data: + LOGGER.debug('Detected multi file dataset') + open_func = xarray.open_mfdataset + else: + open_func = xarray.open_dataset + self._data = open_func(self.data) self._data = _convert_float32_to_float64(self._data) self._coverage_properties = self._get_coverage_properties()