Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Raises ValueError on unequal lengths of labels and handles input#24063
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
@QuLogic, please review the changes... |
The failing tests are not related to your PR. However, your PR would need a test that checks that the exception is raised. This should probably go intohttps://github.com/matplotlib/matplotlib/blob/main/lib/matplotlib/tests/test_legend.py Here is a similar test to see how to check for an exception: matplotlib/lib/matplotlib/tests/test_legend.py Lines 255 to 260 infd5cf5c
(Also, note that#24061 solves the same issue.) |
I'll close this as a duplicate. We can reopen if the other PR does not go through. Feel free to contribute to the ongoing PR |
@jklymak I tried adding a test for raising a ValueError, do open this if the other one does not go through 👍 |
Uh oh!
There was an error while loading.Please reload this page.
…_args
PR Summary
Verifying that the inputs are of a consistent length in _parse_legend_args.
Number of elements in handles and labels should be equal, addressing the issue#24050 .
PR Checklist
Tests and Styling
pytest
passes).flake8-docstrings
and runflake8 --docstring-convention=all
).Documentation
doc/users/next_whats_new/
(follow instructions in README.rst there).doc/api/next_api_changes/
(follow instructions in README.rst there).