Skip to content

Commit

Permalink
Depreciation warning when importing TVTK is suppressed now.
Browse files Browse the repository at this point in the history
  • Loading branch information
LutzGross committed Sep 28, 2024
1 parent 8da6bbd commit 5624390
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion weipa/py_src/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,13 @@
__nodocorecursion=['weipacpp']

import numpy as np
import warnings

try:
from tvtk.api import tvtk
# to suppress some warnings when importing VTK
with warnings.catch_warnings():
warnings.filterwarnings("ignore", category=DeprecationWarning)
from tvtk.api import tvtk
HAVE_TVTK = True
except:
HAVE_TVTK = False
Expand Down

0 comments on commit 5624390

Please sign in to comment.