Closed coffeeDev98 closed 1 year ago
The reason is not the whitespace, but the missing arrows or circles. I may make the grammar more robust to allow that as well (should not be too complicated), but it is of course not necessary to have empty color fields or arrows.
Moved the issue to the parser, and will fix it there in the next version.
Provided the fix and a new version 1.4.6 including tests.
Hey @mliebelt , I've noticed some issue when parsing PGN which contains Circle and Arrow annotations even though the format is the same as the one generated when using annotations within the package.
This is the PGN used:
[%cal ]
} ) Nc6 7. O-O Qc7 8. Bb3 {[%csl ]
[%cal Gc7c4]} Nge7 9. f4 Ng6 10. f5 Nge5 {[%csl Ge5][%cal ]
} 11. fxe6 dxe6 12. Nf4 Bd6 13. Nfd5 Qb8 ( 13... exd5 ) 14. Nb6 Bc5+ 15. Kh1 Bxb6 16. Bf4 Bc7 17. Rc1 O-O 18. Qh5 Nd4 19. Nd5 exd5 20. Bxd5 Be6 0-1This seems to be happening because of the empty space after
%cal
or%csl
(The occurrences in the above PGN to highlighted)