mvcisback / py-aiger

py-aiger: A python library for manipulating sequential and combinatorial circuits encoded using `and` & `inverter` gates (AIGs).
MIT License
41 stars 9 forks source link

Issue parsing aag file #128

Closed masinag closed 1 year ago

masinag commented 1 year ago

Hi, the function https://github.com/mvcisback/py-aiger/blob/1f1d95265c9744c605011fd80e2c139745a78e5e/aiger/aig.py#L283

fails to parse some aag files, such as https://raw.githubusercontent.com/arminbiere/dualiza/master/aigs/0001.aag

I think the issue is on line https://github.com/mvcisback/py-aiger/blob/1f1d95265c9744c605011fd80e2c139745a78e5e/aiger/parser.py#L245

since these files do not contain a symbol table (which should be optional) and the parser at that point is still parse_and.

mvcisback commented 1 year ago

Thanks! I will try reproducing tonight.

masinag commented 1 year ago

Hi, I added a failing test showing the issue.

mvcisback commented 1 year ago

Thank you! Fixed in 241a6000ef654d3449c2b53f8f3f5d1005f69919

mvcisback commented 1 year ago

Released in v6.2.0