-
Notifications
You must be signed in to change notification settings - Fork 24
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
Error in pgn with "old notation" #18
Comments
As far as I know the PGN specs have always required the '=' symbol to denote a promotion; "b8Q" is sometimes seen in books and publications (the classic Chess Informat volumes, for example, have typically used a very shortened algebraic notation), but strictly speaking i don't think it was ever accepted in PGN standard, even if many common softwares gloss over it |
Hi Oscar, hi Luca. I think the parser should be as forgiving as possible. If there are databases that denote the promotion in the abbreviated form, then there should be no error as long as it does not introduce any ambiguities. I'll look into that. Thanks for reporting! |
Oscar, do you have a link to source where such moves are listed? |
Never mind. I found it in the FIDE rules:
https://www.fide.com/component/handbook/?id=124&view=article So this is official and needs to be fixed. |
Unfortunatelly there is an ambiguity. It conflicts with the SAN annotation "Theoretical Novelty", which is Of course the latter is much more probable, but the formal grammar would still be ambiguous... |
@iigorr I apologize for taking too long to answer. I did not receive any notification :( I believe that any game downloaded from the official FIDE's website would have that notation. For instance: https://ratings.fide.com/view_games.phtml?id=1503014&name=%22Carlsen__Magnus(NOR)%22 |
@osotorrio, thanks for your feedback. Ok. I will drop the SAN for "Theoretical Notation". FIDE games should be supported of course. :) |
Hi,
First of all, thank you very much for your work. Great job!!
I have a PGN file from and when I try to read it with pgn.net it throws an exception:
Error in pgn: Ln: 318 Col: 34
35.Kc3 f3 36.b6 e4 37.b7 e3 38.b8Q Rxb8 39.Bxb8 Rxh2 40.Bxh2 1-0
Expecting: Comment ( {...} or ;... ), Game termination marker (1/2-1/2 or 1-0
or 0-1 or *), Move (e.g. Qc4 or e2e4 or 0-0-0 etc.), Move annotation (e.g. ! or
??), Move number indicator (e.g. 5. or 13...), NAG ($ e.g. $6 or $32), RAV
e.g. "(6. Bd3)", Tag (e.g [Date "2013.10.02"]), end of input, '#', '+', '++',
'ch', 'dbl ch', '†', '††' or '‡'
As you can see the notation of the white move 38. b8Q is a bit weird. I guess it should be 38. b8=Q
Is the notation b8Q some kind of "old style"?. If so, why to throw an exception?...maybe it could support backward compatibility.
Thanks again!!
The text was updated successfully, but these errors were encountered: