Possible Refactor For Parser Error Messages - #165
Draft
ianjosephwilson wants to merge 4 commits into
Draft
Conversation
Contributor
|
Thanks @ianjosephwilson -- plan to look at this soon! Will consider #164 vs #165 along the way. |
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.
@davepeck This is a possible refactor of the other branch ( #164 ) where we pull out all the non-essential error handling into a helper class. Sorry I had sent the other PR yesterday from what I've been rebasing/rehashing but I got restless and started fiddling with it again.
The
TemplateParserstill decides which exceptions to raise but theParsingErrorHelperdoes all the noisy (awful, tedious, etc.) stuff. I'm not committed to this separation but the parser is drowning in methods already.A good sign I think is that the actual source extraction and that "weird" value check both only are triggered from the helper class.