-
Notifications
You must be signed in to change notification settings - Fork 43
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
System.InvalidOperationException: state #44
Comments
Thank you for reporting this! Project Fare turns Regular Expressions into Automatons by applying the algorithms of dk.brics.automaton and xeger. Unfortunately, I don't have an answer to your question, as Project Fare is really a port of the above Java projects. – We'd have to try
in Java and compare the results. You may use a different pattern or use a different engine to reverse the Regular Expression into an Automaton. As an example, you can use the Rex engine. |
The problem is this part: Xeger interprets Change it to |
@gukoff, thank you. PRs more than welcome. (In this case, I think a possible PR would be a test-case demonstrating this, but still, it can be valuable.) |
The current behaviour is correct, see the docs:
Let me check if I could improve the error message. |
Xeger throws System.InvalidOperationException: state when trying to generate a string for this regular expression for emails:
^(?=.{6,50}$)([\w-.]+)@(([[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}.)|(([\w-]+.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(]?)$
The text was updated successfully, but these errors were encountered: