-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
[Bug]: Tick class instantiation returns an error when labelcolor is a tuple #26588
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
Comments
Thank you for the report @jpdehollain. Could you provide a minimal code example that reproduces the problem? Also, did this work with previous Matplotlib versions? |
Seems like we should just use cbook._str_equal here. |
Thanks for looking into it @rcomer... here's a minimal example:
I run it as a code cell in an interactive python session... The odd thing is that if I first just run up to the two plot commands, it displays the plot and then if I run the rest it'll modify the tick label colours with no errors. I only get the error when I run the whole code block in one go. Here's the full error trace:
|
I think the ticks are instantiated when the figure is first drawn. So if you only display right at the end then the ticks are instantiated with the options you put in |
Bug summary
I have a function that uses custom colouring of different plot axes. When Matplotlib tries to render the figure, I am getting the following error shown below
Code for reproduction
Actual outcome
Expected outcome
Plot with custom tick-label colors.
Additional information
No response
Operating system
Windows
Matplotlib Version
3.7.2
Matplotlib Backend
Have tried with inline and qt
Python version
No response
Jupyter version
3.10.12
Installation
pip
The text was updated successfully, but these errors were encountered: