Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Fix wrong error message in #11919#11930
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
Seems reasonable, but I'm not sure about the test failure. |
The test case for You have to add a new entry in REGEXP for the exception text you are generating in that case. |
mcolors.to_rgba_array
function (called in try...except block).davidleejy commentedAug 27, 2018 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Appreciate the advice. Amended failing test. Reasoning behind amendment: exceptions raised by called functions should be tested at the level of these called functions. For e.g., if an exception is expected from
Feel free to comment@afvincent if you're free :) |
Sorry this fell through the cracks. This needs a rebase, but I think the basic idea, at least, is good. |
joseortiz3 commentedJun 24, 2019 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Hello. I'm probably the thousandth person to see this nonsense error message:
Please support the PR! (sorry I can't right now) |
This was fixed in#13959. |
Case 1was incorrect and is fixed on master now, by#17245. So I believe all 3 cases are now fixed. Sorry this got stuck@davidleejy, but I'm going to close this now as unneeded. |
Uh oh!
There was an error while loading.Please reload this page.
PR Summary
Fixes issue#11919 .
This PR chains (appropriate) exceptions raised by
mcolors.to_rgba_array()
to additional exceptions raised by its callerscatter()
. Now, the exception raised bymcolors.to_rgba_array()
is visible if color values are outside of 0 to 1 range.Prior to this PR, exceptions are not chained - see commite3a8004. Exceptions raised by
mcolors.to_rgba_array()
were suppressed by exceptions of its callerscatter()
.This PR applies exception chaining solely on
scatter
function. Author is open to helping chain other exceptions.PEP 3134 advises on Exception Chaining. Example use:https://stackoverflow.com/questions/16414744/python-exception-chaining
Outcome
Case 1: color values outside 0 to 1 range
Case 2: color array is wrong shape
Case 3: color is 'jaune'
PR Checklist