Open winapiadmin opened 3 months ago
Expected: crashes
"Crashing" is definitely not the correct behavior to have here. Erroring out would be a possibility, FEN sanitizing has been a long-time discussion in issues, and a PR is currently open that addresses this: https://github.com/official-stockfish/Stockfish/pull/4563
Expected: crashes
"Crashing" is definitely not the correct behavior to have here. Erroring out would be a possibility, FEN sanitizing has been a long-time discussion in issues, and a PR is currently open that addresses this: #4563
So now the problem is in searching algorithm, exactly generating legal moves.
This is not a matter of search (nor move generation), by definition you can't have legal moves in an illegal position, especially one without pieces, the correct solution as already pointed out would be to refuse to parse the fen, long before the movegen or the search get called.
This has nothing to do with the search algorithm. The UCI protocol assumes that every position/move sent by the GUI is valid, and the PR I mentioned earlier fixes this by not accepting illegal positions. The search isn't at fault here, the UCI handler is the one responsible.
Describe the issue
d
command shows information about tablebases at that positiongo
command still showbestmove a1a2 ponder a1b1
Expected behavior
Expected: crashes
Steps to reproduce
Anything else?
Stockfish 16:
Operating system
Windows
Stockfish version
Stockfish 16.1