SpinW / spinw

SpinW Matlab library for spin wave calculation
http://www.spinw.org
GNU General Public License v3.0
35 stars 15 forks source link

Unclear documentation of dependencies #168

Open Artemkth opened 6 months ago

Artemkth commented 6 months ago

A fact that pyspinw requires additionally 'matlab compiler SDK' component should be stated clearly somewhere, I've spent too much time tracking down the error because https://github.com/SpinW/spinw/blob/ce8dd434e75017d565b1d39e98b7975703730092/python/pyspinw/__init__.py#L54 discards the exception message. I would propose also to change it to something like this:

except RuntimeError as e:
                print(f'A fatal error occured while initialising Matlab version {matlab_version} at {matlab_path}:\n {str(e)}')
                pass   

to make it more informative!

mducle commented 5 months ago

Ah yes, sorry. I assumed that people would be using the MCR, and that if they had a Matlab license would just be using the Matlab version and not Python.

I'll make a change to the error message saying that if you have a full Matlab installation you also need to install the Compiler SDK toolbox.