fsmosca / chess-artist

A python script that can annotate chess games in pgn file with static evaluation or search score of an engine, can annotate an epd file with acd, acs, bm, and ce opcodes, can test engine with epd test suite and can generate chess puzzles.
GNU General Public License v3.0
69 stars 18 forks source link

crashes always #33

Closed ghost closed 7 years ago

ghost commented 7 years ago

09:24:39 1d folkert@belle:~/t/chess-artist↥ master* ± python chess-artist.py -infile r.pgn -outfile out_r.pgn -eng ./Embla.sh -eval search -movetime 60000 -movestart 1 -engoptions "Hash value 4096, Threads value 1" Chess Artist 0.2.0

Analyzing engine: Emblatrunk Annotating game 1... Warning, there is error in pvLine pvLine: ['c8b7', 'o-o', 'b8d7', 'e5d7', 'd8d7'] Traceback (most recent call last): File "chess-artist.py", line 1805, in main(sys.argv[1:]) File "chess-artist.py", line 1798, in main g.AnnotatePgn() File "chess-artist.py", line 1462, in AnnotatePgn side) File "chess-artist.py", line 1010, in GetSearchScoreBeforeMove return bestMove, scoreP, complexityNumber, moveChanges, pvLineSan UnboundLocalError: local variable 'pvLineSan' referenced before assignment

fsmosca commented 7 years ago

On this,

pvLine: ['c8b7', 'o-o', 'b8d7', 'e5d7', 'd8d7']

That o-o is not a format expected from a uci engine. It should be e1g1 for white or e8g8 for black. The python-chess module does not accept such move notation when reading uci moves.