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

Print useful error message for Sequence blocks #103

Closed
typon opened this issue Nov 28, 2016 · 2 comments
Closed

Print useful error message for Sequence blocks #103

typon opened this issue Nov 28, 2016 · 2 comments

Comments

@typon
Copy link

typon commented Nov 28, 2016

Hi,

I'm trying to use parsimonious to parse a file structure that looks like a series of independent blocks. I have posted my issue in detail on StackOverflow, so I'm posting here in case someone here is more knowledgeable (like Erik).

http://stackoverflow.com/questions/40853040/get-parsimonious-to-print-useful-error-message-for-sequence-blocks

Thank you

@erikrose
Copy link
Owner

erikrose commented Dec 1, 2016

Parsimonious's error reporting, as you have discovered, is not very good at the moment. So the error message you are getting is the result of the grammar encountering the invalid "!bar", then rewinding a bit to look for alternatives. Finding none, it gives up and warns that the text beginning with "block block_name_1" was in fact not a block after all.

@lonnen
Copy link
Collaborator

lonnen commented Mar 27, 2022

closing this out. Erik's response should explain what was going on in your example

@lonnen lonnen closed this as completed Mar 27, 2022
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

No branches or pull requests

3 participants