Skip to content

Commit 8a6d5f1

Browse files
committed
tidy up
1 parent 43e018b commit 8a6d5f1

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

pymathics/vectorizedplot/__init__.py

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,22 @@
2424

2525
from pymathics.vectorizedplot.version import __version__
2626

27+
# The try block is needed because at installation time, dependencies are not
28+
# available. After the installation is successfull, we want to make this availabe.
2729
try:
2830
from pymathics.vectorizedplot.plot_plot3d import (
2931
ContourPlot3D,
3032
ParametricPlot3D,
3133
SphericalPlot3D,
3234
)
33-
except ModuleNotFoundError as e:
34-
print("failed to load the module", e)
35+
36+
_BUILTINS_ = (
37+
"ContourPlot3D",
38+
"ParametricPlot3D",
39+
"SphericalPlot3D",
40+
)
41+
except ModuleNotFoundError:
42+
_BUILTINS_ = tuple()
3543

3644

3745
# To be recognized as an external mathics module, the following variable
@@ -47,10 +55,7 @@
4755
sort_order = "mathics.builtin.plotting-graphing-and-drawing"
4856

4957

50-
__all__ = (
51-
"ContourPlot3D",
52-
"ParametricPlot3D",
53-
"SphericalPlot3D",
58+
__all__ = tuple(_BUILTINS_) + (
5459
"__version__",
5560
"pymathics_version_data",
5661
)

0 commit comments

Comments
 (0)