mdsplus icon indicating copy to clipboard operation
mdsplus copied to clipboard

windows python install incompatible with recent numpy versions

Open ryanalbosta opened this issue 2 years ago • 3 comments

UW Madison graduate student working at DIII-D national fusion facility

Version(s) Affected 7.132-0 windows .exe python install

Platform windows 10, windows 11

Describe the bug Incompatibility with numpy v 1.20+, MDSplus/python/MDSplus/mdsscalar.py error on line 422: numpy.str is deprecated and returns an error. Can replace "_N.str" with "str" to fix.

To Reproduce install MDSplus on windows 10 or 11 using the .exe version mentioned. Install for python, add to python path. attempt to write to mdsplus (or read? not sure) after installing most recent versions of numpy using a python script.

Expected behavior program will throw an error and not complete the write. The error states that numpy.str is deprecated and was an old way to reference the python str class. can be replaced by just str.

Additional context I swapped _N.str with str in my program files folder and it fixed the problem.

ryanalbosta avatar Jun 20 '23 17:06 ryanalbosta

Hi @ryanalbosta -- Thanks for submitting this issue. It is related to Issue #2589. I will soon submit a PR to fix both issues.

mwinkel-dev avatar Jun 27 '23 00:06 mwinkel-dev

Was able to reproduce this bug using Ubuntu 20.04 running the "stable" branch of MDSplus, with python 3.8.10 and numpy 1.24.3. Interesting though that the bug does not occur in the "alpha" branch. Implies that a PR made for "alpha" should also be pushed to "stable".

mwinkel-dev avatar Jun 27 '23 18:06 mwinkel-dev

This is a duplicate of Issue #2532 and was fixed in the "alpha" branch by PR #2537.

That PR also needs to be merged into the "stable" branch.

mwinkel-dev avatar Jun 27 '23 19:06 mwinkel-dev

This issue should be closed.

This issue was fixed on the "stable" branch by PR https://github.com/MDSplus/mdsplus/pull/2730. AKA Release: 7.140.68 which updated the "stable" branch to "alpha" branch version 7.140.68 https://github.com/MDSplus/mdsplus/commit/a4dd26c67d82c9f7643f02eb84c4057087fabaa9 @mwinkel-dev

ConnorCastleberry avatar May 24 '24 18:05 ConnorCastleberry

Hi @ConnorCastleberry,

You are correct. The PR #2537 fix for the "alpha" branch was indeed included when the "stable" branch was updated by PR #2730. Therefore, closing this Issue as per your suggestion.

mwinkel-dev avatar May 24 '24 21:05 mwinkel-dev