-
Notifications
You must be signed in to change notification settings - Fork 156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stop using deprecated/removed np.float/np.int #163
base: 5.x
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything looks good from here.
We need this merged ASAP as these types have been dropped from Numpy.
Hi all! Is this change going to be merged? |
There are some other changes that need to be merged, such as Matplotlib's and some others, but As of last week, I was thinking that nobody would use Python v2.7 anymore and I ended up compiling some of our research code to validate something unrelated to NURBS-Python. This also justifies to me that in the research industry, Python v2.7 could still be used. Of course, it shouldn't be used, but we could say the same things for several other things. Another thing is that the core Due to the design principle as mentioned, the visualizer package can be moved outside of To answer @FooBarrior question, I am afraid to say that |
Does this PR not work on Python 2.7? I would have thought that replacing I understand that Python 2.7 is limiting, and that this does not touch the “core,” but I’m not sure I understand why it shouldn’t be fixed. It seems like it would be easy to work around any compatibility problems that might exist in this PR rather than waiting on architectural changes and a new major version. |
I believe numpy dropped support for Python v2.7 years ago. It makes sense as Py2 is EOL. The backwards compatibility needs to be investigated and that might also limit the minimum version of numpy used.
This PR only fixes one single issue, but there will be more issues to fix due to updates in the dependent libraries and that's going to take some time to test. I have to update the automated CI checks for sure, I am guessing some of the hooks are gone. It comes to time and it is a more limiting factor to me nowadays. As I mentioned in my previous comment, visualizers are easy to modify and extend as they are not part of the core. There is also an option to use the older version of numpy just for a while, if your code is not dependent on the latest updates. From the maintenance perspective, it is not a good idea to change dependencies or minimum requirements with the minor or patch level upgrades. It is a very annoying change when you are on a strict deadline or very busy to follow the release notes. It makes sense to create an intermediate version, say |
See: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations