-
Notifications
You must be signed in to change notification settings - Fork 10k
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
Change PartialEvaluator.handleColorN
to throw when no valid pattern is found
#10789
Conversation
… is found Currently `handleColorN` will fallback to add a completely unparsed/unvalidated operator when no valid pattern was found. This is unfortunate, since it could very easily lead to a couple of different errors: - `DataCloneError`s when attempting to send the data to the main-thread, e.g. when `args` is `Dict`/`Stream`. - Errors in `getShadingPatternFromIR` on the main-thread, unless `args` just happens to have the expected format. - Errors when actually attempting to render the pattern on the main-thread, since the `args` will most likely not have the expected format. Hence it probably makes sense to error in `PartialEvaluator.handleColorN`, and having invalid patterns fail gracefully via the existing `ignoreErrors` code-paths instead.
/botio lint |
From: Bot.io (Linux m4)ReceivedCommand cmd_lint from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.67.70.0:8877/d84f870ede0c1be/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_lint from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.215.176.217:8877/856bc9495a3327b/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.67.70.0:8877/d84f870ede0c1be/output.txt Total script time: 0.96 mins
|
From: Bot.io (Windows)SuccessFull output at http://54.215.176.217:8877/856bc9495a3327b/output.txt Total script time: 2.75 mins
|
/botio test |
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @timvandermeij received. Current queue size: 0 Live output at: http://54.67.70.0:8877/13863c1704a6043/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_test from @timvandermeij received. Current queue size: 0 Live output at: http://54.215.176.217:8877/65a8fb788287230/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.67.70.0:8877/13863c1704a6043/output.txt Total script time: 17.67 mins
|
From: Bot.io (Windows)FailedFull output at http://54.215.176.217:8877/65a8fb788287230/output.txt Total script time: 25.57 mins
Image differences available at: http://54.215.176.217:8877/65a8fb788287230/reftest-analyzer.html#web=eq.log |
Makes sense. Thank you! |
Currently
handleColorN
will fallback to add a completely unparsed/unvalidated operator when no valid pattern was found. This is unfortunate, since it could very easily lead to a couple of different errors:DataCloneError
s when attempting to send the data to the main-thread, e.g. whenargs
isDict
/Stream
.getShadingPatternFromIR
on the main-thread, unlessargs
just happens to have the expected format.args
will most likely not have the expected format.Hence it probably makes sense to error in
PartialEvaluator.handleColorN
, and having invalid patterns fail gracefully via the existingignoreErrors
code-paths instead.