-
Notifications
You must be signed in to change notification settings - Fork 20
Using grammar parser for variables #97
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
base: main
Are you sure you want to change the base?
Conversation
Added new grammar logic for variable. Replaced the regex with Lark implementation.
Run CI on PR for main too
|
Could you add some testing in https://github.com/tbarbette/npf/blob/main/integration/test_unittest.py? Also can you rebase so the tests will run? Thanks! |
Added new grammar logic for variable. Replaced the regex with Lark implementation.
Added unit tests and rebased the PR.
|
The tests do not seem to actually test the parsing, does it? |
|
The test checks for the substitution which involves parsing. Should I add tests just for the parsing? |
Added new grammar logic for variable. Replaced the regex with Lark implementation.
Added unit tests and rebased the PR.
Also merge tbarbette#97 Advances on tbarbette#96
|
Hi! I pushed a rebase on PRtests and highlighted a problematic case. Could you look into it? Basically $(( )) should not be replaced as it is evaluated using asteval. However, what's inside it should be parsed. Please rebase / start again on top of PRtests. Thanks |
I have rebased from the PRTest branch and updated the code to handle the $((..)) case. I also found another issue, "Hello $foo.", was not being parsed. I have fixed this too. In the test cases you have added, for test_complex_01, should echo be removed after parsing?
Added new grammar logic for variable.
Replaced the regex with Lark implementation.