Conversation
|
Well it looks like mypy is probably passing but Stubtest is not: @kkollsga any ideas on that one? |
| with open_dataset(tmp_file) as ds: | ||
| expected = create_masked_and_scaled_data(np.dtype(dtype)) | ||
| assert_identical(expected, ds) | ||
| assert_identical(create_masked_and_scaled_data(np.dtype(dtype)), ds) |
There was a problem hiding this comment.
mypy hates reassigning a new value to an existing var. We can get around this by typing expected more loosely, by not using the word expected (like I'm doing here), or by just not type checking the tests.
|
superseded by #11211 |
Hi, With #11211 this is resolved now, with the The reason this works is that numpy 2.4+ defines If this comes up again in the future (e.g. a new module imports
|
|
Thank you for explaining @kkollsga! That will definitely be useful knowledge in the future. |
This should get mypy tests passing on CI