Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

ValueError exception added to handle mix of {} and % string in colorbar format #27015

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

Merged
rcomer merged 1 commit into matplotlib:main from borgesaugusto:iss_27007
Oct 8, 2023

Conversation

Copy link
Contributor

@borgesaugusto borgesaugusto commented Oct 6, 2023

PR summary

Addresses issue #27007 . If the try/except is done inversely, the error happens in the other block, but the edge case is formatted correctly. Then, both exceptions (TypeError and ValueError) will use the StrMethodFormatter.
The test is created separetly from test_colorbar_format() (L615) to make it clearer.

PR checklist

Copy link
Member

QuLogic commented Oct 7, 2023

We do prefer rebases over merges, if you can do so.

borgesaugusto reacted with thumbs up emoji

Copy link
Member

rcomer commented Oct 8, 2023

Thanks @borgesaugusto and congratulations on your first PR merged into Matplotlib! Your other one should be merged soon (just waiting for the tests to pass). I hope we hear from you again.

borgesaugusto reacted with heart emoji

@borgesaugusto borgesaugusto deleted the iss_27007 branch October 8, 2023 10:29
rcomer added a commit that referenced this pull request Oct 8, 2023
...015-on-v3.8.x
Backport PR #27015 on branch v3.8.x (ValueError exception added to handle mix of {} and % string in colorbar format)
@ksunden ksunden mentioned this pull request Nov 2, 2023
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@timhoffm timhoffm timhoffm approved these changes

@rcomer rcomer rcomer approved these changes

Assignees
No one assigned
Projects
Milestone
v3.8.1
Development

Successfully merging this pull request may close these issues.

[Bug]: Colorbar format string kind guess could be made more robust

AltStyle によって変換されたページ (->オリジナル) /