niklasf/python-chess

Is this expected or simply a bug?

djokester opened this issue · 1 comments

Expected.

For board.is_legal(move) and similar methods, move needs to be legal in the position of board. But it has already been played/pushed, and playing it again would not be legal. Instead, do any checks before pushing.

It could be argued that this should at least throw an exception, but always double-checking legality would have a substantial performance cost.