Skip to content

Commit

Permalink
Add matplotlib version
Browse files Browse the repository at this point in the history
  • Loading branch information
rocky committed Aug 7, 2024
1 parent 654b39c commit ea65708
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
7 changes: 6 additions & 1 deletion mathics/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
optional_software: Dict[str, str] = (
"cython",
"lxml",
"matplotlib",
"networkx",
"nltk",
"psutil",
Expand All @@ -40,7 +41,11 @@
for package in optional_software:
try:
mod = import_module(package)
package_version = mod.__dict__.get("__version__", "No version information")
package_version = (
mod.__version__
if hasattr(mod, "__version__")
else mod.__dict__.get("__version__", "No version information")
)
except ImportError:
package_version = "Not installed"

Expand Down
1 change: 1 addition & 0 deletions mathics/doc/latex/mathics.tex
Original file line number Diff line number Diff line change
Expand Up @@ -322,6 +322,7 @@ \part*{Appendices}
\item[Ghostscript] \hfill \GhostscriptVersion
\item[cython] \hfill \cython
\item[lxml] \hfill \lxml
\item[matplotlib] \hfill \matplotlib
\item[networkx] \hfill \networkx
\item[psutil] \hfill \psutil
\item[skimage] \hfill \skimage
Expand Down

0 comments on commit ea65708

Please sign in to comment.