-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove
ProcfileParsingError::RegexError
as a user-facing error (#77)
There is currently only one error variant for `ProcfileParsingError`, an error that only occurs if it was not possible to compile the regex used to parse a `Procfile`. This regex is buildpack-supplied, so if such an error occurs, it's always an internal buildpack error. However previously a user-facing error message was shown, that told the user to check their `Procfile` was valid, which has no bearing on whether the regex will compile. Rather than just correct the error message, the error has been removed and instead `.expect()` used, since such regex errors will not happen in practice, given they will be caught by both the `invalid_regex` Clippy lint and the buildpack's tests. I believe part of the reason for this confusion over error messages is that the error message handling was split across multiple files due to the use of `thiserror` meaning that the display representation could be leant upon, without actually looking closely at what was being displayed. As such, I've removed `thiserror`, since I think the error handling is easier to reason about without it. Fixes #74. GUS-W-11318868.
- Loading branch information
Showing
6 changed files
with
36 additions
and
55 deletions.
There are no files selected for viewing
This file contains 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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