I have a code that throws me some warnings.
...\matplotlib\axes\_base.py:3045: UserWarning: Attempting to set identical bottom==top results
in singular transformations; automatically expanding.
...\matplotlib\axes\_axes.py:519: UserWarning: No labelled objects found. Use label='...' kwarg on individual plots.
warnings.warn("No labelled objects found. "
The second warning is not critical but the first one worries me, so I want to investigate why they are happening.
The problem is that since they are only warnings and not exceptions, I don't get a traceback, so I don't know which part of my code called the matplotlib\axes\_base.py
.
Being a matplotlib\axes
I can manually check my calls to matplotlib functions inside my code, put breakpoints and debug it, but it's manual digging and time consuming.
So my question is: Is there a way of forcing warnings to make the program throw and exception and therefore have a traceback of the functions that generated that warning?