EnergySystemsModellingLab / MUSE_OS

Welcome to the MUSE-OS repository
https://muse-os.readthedocs.io/en/latest/
GNU General Public License v3.0
22 stars 9 forks source link

Incompatible with Numpy 2.1.0 #459

Open tsmbland opened 1 month ago

tsmbland commented 1 month ago

Using Numpy 2.1.0 I get the following error repeated many times throughout the tests

DeprecationWarning: __array__ implementation doesn't accept a copy keyword, so passing copy=False failed. __array__ must implement 'dtype' and 'copy' keyword arguments.

MUSE is still able to run just fine, but this error is causing the the tests to fail

tsmbland commented 3 weeks ago

@dalonsoa Turns out Numpy 2.1 drops support for Python 3.9, so we're stuck with 2.0 unless we want to stop supporting Python 3.9 https://numpy.org/devdocs/release/2.1.0-notes.html

dalonsoa commented 3 weeks ago

Up to you and @ahawkes . In principle, 3.9 will receive security updates for one more year, then it's over. So, from October next year, I don't think we should support it. For this year... depends on how many users we have. Maybe add a deprecation warning if the user is using 3.9 saying something like:

"MUSE support for Python 3.9 will be dropped in December 2024. Please, transition to a more modern version of Python."

or something along these lines.