Skip to content

Commit a2f9685

Browse files
committed
fix: catch ImportError for pillow_jxl module
1 parent 880c8ef commit a2f9685

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

tagstudio/src/qt/widgets/thumb_renderer.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
import cv2
1515
import numpy as np
16-
import pillow_jxl # noqa: F401
1716
import rawpy
1817
import structlog
1918
from mutagen import MutagenError, flac, id3, mp4
@@ -68,6 +67,11 @@
6867
register_heif_opener()
6968
register_avif_opener()
7069

70+
try:
71+
import pillow_jxl # noqa: F401
72+
except ImportError:
73+
logger.exception('[ThumbRenderer] Could not import the "pillow_jxl" module')
74+
7175

7276
class ThumbRenderer(QObject):
7377
"""A class for rendering image and file thumbnails."""

0 commit comments

Comments
 (0)