Format 4xx/5xx status codes and return error code #2
Closed
david-pershouse wants to merge 5 commits intobinarylane:mainfrom
Closed
Format 4xx/5xx status codes and return error code #2david-pershouse wants to merge 5 commits intobinarylane:mainfrom
david-pershouse wants to merge 5 commits intobinarylane:mainfrom
Conversation
Add error option to printer and refactor base printer to be in charge of out outputting to stderr/out exit with -1 for all error status codes
8c6821d to
e77c21f
Compare
supress action warning for error responses
Contributor
Author
|
This has now been changed to obey the To avoid passing output file down to each subclass of printer, the printer sub-classes now just return string. I tried to use the built in "title" property of |
Contributor
Author
|
The bulk of this was addressed in #10 |
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.
When a request receives a response with 4xx or 5xx status codes, it is now treated as an error and
blwill return error level of -1.This MR also applies custom formatting to the ProblemDetails and ValidationProblemDetails objects that are common in the error response.
ProblemDetails (usually with 5xx errors) is just rendered as
ERROR: {title} - {detail}where detail is optionaleg for a 404
ValidationProblemDetails (4xx validation errors) is similar to problem details, but includes the
errorsproperty as a table