aodn / imos-toolbox

Graphical tool for QC'ing and NetCDF'ing oceanographic datasets
GNU General Public License v3.0
46 stars 31 forks source link

Possible issue with missing mcc_path in build.py #746

Closed sspagnol closed 3 years ago

sspagnol commented 3 years ago

Just wanted to check if anyone get this message when using build.py

C:\Projects\aims-gitlab\imos-toolbox>python build.py --arch=win64 --matlab_path="C:\Program Files\MATLAB\R2018b"\bin\matlab
build.py:454: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if rstatus.returncode is not 0:
Traceback (most recent call last):
  File "build.py", line 400, in <module>
    root_path, dist_path, matlab_root_path, mcc_path, arch, build_java = get_args(args)
  File "build.py", line 374, in get_args
    if not mcc_path.exists():
UnboundLocalError: local variable 'mcc_path' referenced before assignment
ocehugo commented 3 years ago

Definetely a bug, but you may overcome this by not using --matlab_path. I did some upgrades to the build script for automatic detection but didn't had time to update the wiki yet :)

Just calling build.py from the cmd should be enough now.

build.py
ocehugo commented 3 years ago

For the record, this is a typo in the docstring, where <mccpath> should be <matlabpath> instead. The fix is in https://github.com/aodn/imos-toolbox/pull/747

sspagnol commented 3 years ago

Thanks Hugo. Confirm that build.py works ok.