Skip to content

Commit

Permalink
Fix final issues with CI
Browse files Browse the repository at this point in the history
  • Loading branch information
SorooshMani-NOAA committed Nov 18, 2023
1 parent 5d0049b commit a98fa90
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/functional_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
gdalwarp -tr 0.0005 0.0005 -r average -overwrite /tmp/fullsize_dem.tif /tmp/test_dem.tif
- name: Export Conda environment
shell: bash -l {0}
shell: bash -el {0}
run: conda list > environment_py${{ matrix.python-version }}.yml

- name: 'Upload conda environment'
Expand Down Expand Up @@ -112,5 +112,5 @@ jobs:
retention-days: 7

- name: Run Python API tests
shell: bash -l {0}
shell: bash -el {0}
run: python -m unittest discover tests/api -p "*.py"
8 changes: 5 additions & 3 deletions ocsmesh/raster.py
Original file line number Diff line number Diff line change
Expand Up @@ -395,6 +395,7 @@ def modifying_raster(
"""

no_except = False
tmpfd = None
try:
# pylint: disable=R1732
# tmpfile = tempfile.NamedTemporaryFile(prefix=tmpdir, mode='w')
Expand All @@ -420,7 +421,8 @@ def modifying_raster(
# We don't need to keep the descriptor open, we kept it
# open # so that there's no race condition on the temp
# file up to now
os.close(tmpfd)
if tmpfd is not None:
os.close(tmpfd)



Expand Down Expand Up @@ -964,7 +966,7 @@ def average_filter(
# modifying the raster (e.g. hfun add_contour is affected)

if platform.system() == 'Windows':
raise ImplementationError('Not supported on Windows!')
raise NotImplementedError('Not supported on Windows!')
bands = apply_on_bands
if bands is None:
bands = range(1, self.src.count + 1)
Expand Down Expand Up @@ -1024,7 +1026,7 @@ def generic_filter(self, function, **kwargs: Any) -> None:
"""

if platform.system() == 'Windows':
raise ImplementationError('Not supported on Windows!')
raise NotImplementedError('Not supported on Windows!')

# TODO: Don't overwrite; add additoinal bands for filtered values

Expand Down

0 comments on commit a98fa90

Please sign in to comment.