Skip to content

Commit

Permalink
Merge pull request #1749 from girder/nd2-warnings
Browse files Browse the repository at this point in the history
Suppress a warning about nd2 files that we can't do anything about
  • Loading branch information
manthey authored Dec 31, 2024
2 parents 64afb30 + 6a18f32 commit ed42a2f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
- Add more color palettes ([#1746](../../pull/1746))
- Improve the list of extensions the bioformats source reports ([#1748](../../pull/1748))

### Changes

- Suppress a warning about nd2 files that we can't do anything about ([#1749](../../pull/1749))

## 1.30.5

### Improvements
Expand Down
4 changes: 4 additions & 0 deletions sources/nd2/large_image_source_nd2/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import math
import os
import threading
import warnings
from importlib.metadata import PackageNotFoundError
from importlib.metadata import version as _importlib_version

Expand Down Expand Up @@ -49,6 +50,9 @@ def _lazyImport():
except ImportError:
msg = 'nd2 module not found.'
raise TileSourceError(msg)
# the dask module emits a warning about an open handle even those we
# close file handles properly. Suppress them
warnings.filterwarnings('ignore', category=UserWarning, module='.*dask.*')


def namedtupleToDict(obj):
Expand Down

0 comments on commit ed42a2f

Please sign in to comment.