Skip to content
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

ParsingError.incompleteMessage should be internal (return nil instead) #63

Closed
weissi opened this issue Apr 20, 2020 · 2 comments · Fixed by #135
Closed

ParsingError.incompleteMessage should be internal (return nil instead) #63

weissi opened this issue Apr 20, 2020 · 2 comments · Fixed by #135

Comments

@weissi
Copy link
Member

weissi commented Apr 20, 2020

ParsingError.incompleteMessage must be internal. It's an implementation detail of the parser that must never leave its module.

@weissi weissi added the imap label Apr 20, 2020
@Davidde94
Copy link
Collaborator

I'm not sure I agree. If someone is using our parser manually, as they're entitled to, then surely it's sensible to tell them if a message is incomplete?

@Davidde94 Davidde94 changed the title ParsingError.incompleteMessage should be internal ParsingError.incompleteMessage should be internal (return nil instead) Apr 20, 2020
@Davidde94
Copy link
Collaborator

Discussed in person. To address my concern we'll return nil if there isn't enough data to parse. The end user can turn nil into an error if they want.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants