Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Description
Bug summary
Since the release of Matplotlib 3.9.1 I have been experiencing CI failures on ContourPy on Windows only that did not occur with Matplotlib 3.9.0. There is some info in my PRcontourpy/contourpy#406 that works around it by pinningmatplotlib<3.9.1
on Windows. I am not really sure what the problem is, but I now have a simple reproducer.
Code for reproduction
fromcontourpyimportcontour_generatorimportmatplotlib.pyplotaspltprint("START")cont_gen=contour_generator(z=[[0,1], [2,3]])try:cont_gen.filled(2.0,1.0)exceptExceptionase:print("EXCEPTION HANDLER",e)print("END")
Actual outcome
If you run the above code with matplotlib 3.9.1 and contourpy 1.2.1 (the latest releases) it works OK with correct output of
STARTEXCEPTION HANDLER upper_level must be larger than lower_levelEND
Note the code imports some of matplotlib but does not use it, and the contourpy code here does not use it either.
If you use matplotlib 3.9.1 or nightly wheel and contourpy nightly wheel then it silently crashes for me with just
START
But if you comment out theimport matplotlib...
line it works OK again. Use of matplotlib 3.9.0 and any contourpy (1.2.1 or nightly wheel) is always OK.
For my installations here I ampip install
ing into python-onlyconda
environments, i.e.
conda create -n temp python=3.12conda activate temppip install matplotlib contourpy
Expected outcome
See above.
Additional information
There is a relevant post by@BertJorissen on thepybind11 gitter which has some in-depth analysis and leads me to believe that this is not just a ContourPy problem.
Operating system
Windows only
Matplotlib Version
>= 3.9.1
Matplotlib Backend
No response
Python version
I see same results for python 3.8 to 3.12.
Jupyter version
No response
Installation
pip