pya2l icon indicating copy to clipboard operation
pya2l copied to clipboard

Another invalid sequence at position error in A2lParser

Open digamma23 opened this issue 5 years ago • 2 comments

File "\pya2l-0.0.1\pya2l\parser\grammar\parser.py", line 174, in p_error raise A2lFormatException('invalid sequence at position ', p.lexpos, string=p.lexer.lexdata)

Here's the repeating part of the a2l file that I am using: /begin CHARACTERISTIC SFB_R_FFO_DE.Properties.1.Qly "" VALUE 36453 _UBYTE 0 NO_COMPU_METHOD 0 255 /begin ANNOTATION /begin ANNOTATION_TEXT "Factor 1.0" "Offset 0" /end ANNOTATION_TEXT ANNOTATION_LABEL "CalInPatcher Additional Attributes" /end ANNOTATION SYMBOL_LINK "SFB_R_FFO_DE.Properties.1.Qly" 0 /end CHARACTERISTIC

If I remove the line with SYMBOL_LINK, the error is gone.

Could you explain how to debug this?

digamma23 avatar May 15 '19 04:05 digamma23

Sorry for the delayed answer. Do you know which version of the A2L format specification you use? Because depending on it, either SYMBOL_LINK is a new keyword introduced after the specification I used to write the grammar and lexer. According to this document, you use a ASAP2 version >= 1.60

Sauci avatar May 22 '19 10:05 Sauci

I am also having same problem. What files need to be changed in source code to include SYMBOL_LINK?

vaasu070 avatar Oct 21 '20 13:10 vaasu070

Hello @digamma23, @vaasu070, after a major update of the package, the parser does not crash on SYMBOL_LINK anymore. It is not part of the tree as I don't have the specification for it, but you get all other information. You can have a look at the test test_issue_17 here. I will close this issue now. So if you want to give it a try, please install the latest version of the package.

Sauci avatar Jun 19 '23 18:06 Sauci

@digamma23 , @vaasu070 , the SYMBOL_LINK property is now properly handled (from version 0.1.1).

Sauci avatar Oct 01 '23 11:10 Sauci