Skip to content Skip to sidebar Skip to footer

Regex Parse Error By Parsley Python

I have made a simple parser for simple queries, to fetch data from a datastore. The operands I have used are <,<=,>,>=,==,!= The Parser works fine for every operand exc

Solution 1:

The problem with this regEx was how I handled the value regEx.

value = ws parens | neq | eq | lte | lt | gte |gt ws

Here I have added whitespace before and after all the possible options, thus instead of whitespace being optional it was being enforced. So rather than using ws here at value, I used ws where I was using the value token for searching , and changed value to

value = parens | neq | eq | lte | lt | gte |gt

This Solved my problem.

Post a Comment for "Regex Parse Error By Parsley Python"