Repository navigation
Add custom ExecError - #5184
Merged
Merged
Add custom ExecError#5184
Conversation
sipsma
reviewed
May 24, 2023
helderco
force-pushed
the
helder/dag-290-error-types
branch
from
May 24, 2023 13:03
12f13ab to
5485505
Compare
helderco
marked this pull request as ready for review
May 24, 2023 15:57
helderco
force-pushed
the
helder/dag-290-error-types
branch
from
May 24, 2023 17:33
f4603c9 to
d0f09f9
Compare
Contributor
|
Also cc @matiasinsaurralde, you mentioned recently that it might be nice to have more structured errors like this |
Contributor
|
The rust sdk should work fine once generated with this new error type. Will have to test it out though |
sipsma
reviewed
May 24, 2023
Signed-off-by: Helder Correia <[email protected]>
Signed-off-by: Helder Correia <[email protected]>
Signed-off-by: Helder Correia <[email protected]>
Signed-off-by: Helder Correia <[email protected]>
Signed-off-by: Helder Correia <[email protected]>
Signed-off-by: Helder Correia <[email protected]>
helderco
force-pushed
the
helder/dag-290-error-types
branch
from
May 24, 2023 23:25
ba9db00 to
624e214
Compare
sipsma
approved these changes
May 25, 2023
This was referenced May 25, 2023
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #4700
This adds a custom
ExecErrorthat allows you to access properties of an command execution error directly, without having to parse them using regex or similar, from the error message.The old message format is still used, with included stdout and stderr when printing the error for visibility.
Examples
Use case: Handle a command execution error in a specific way, but let other kinds of errors bubble up.
Go
Reference
Python
Node.js
Reference
\cc @sipsma @kjuulh