-
Notifications
You must be signed in to change notification settings - Fork 26
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
Weird missing numpy error on windows. #900
Comments
Found the issue. It is in the user config which is of course system and user specific. The PC has...
I was testing with numpy 2.0.0 just before I went away. I assume that the experiment altitudes need to be forced into a string before being saved in order to prevent this. |
So removing the np.float lines prevents the error, so this is definitely the cause. My next question is why does --no-config-files still load the user config? Should we change the behaviour so it isn't loaded with this flag? I will work on a fix for the cause of the error. |
See #577 . Yes, this is confusing but I'm not sure how to go about fixing this. |
Ok, good point. As you say not sure what the best thing about loading the config.py is. As to fixing the issue it doesn't seem to be trivial.
The config saving routine uses pprint.PrettyPrinter.pformat to format the output. |
I guess we could cast the value to a python float when adding to the list which seems to be handled properly by the PrettyPrinter routines. |
Yes. From looking at it, I think something like this:
But did |
Exactly my fix, just tested and it works. It might have always been a numpy float but with numpy2 the prettyprint routines don't know how to print it. |
In macroStageBase.py we have
So yes it always seemed to have been a numpy array. |
I have an error on cockpit startup but only on windows. Even with a "--no-config-file" flag the system produces the following error.
I don't understand what is trying to call np where it isn't defined.
This is with a fresh clone of upstream/master. The same code appears to be working fine on my mac, with no startup troubles.
The text was updated successfully, but these errors were encountered: