You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The chess server will complain with the following PHP notices after trying to load foo as a FEN string:
$ php cli/ws-server.php
Welcome to PHP Chess Server
Commands available:
/accept {"id":"id"} Accepts a friend request to play a game.
/ascii Prints the ASCII representation of the game.
/castling Gets the castling status.
/captures Gets the pieces captured by both players.
/fen Prints the FEN string representation of the game.
/heuristicpicture Takes a balanced heuristic picture of the current game.
/history The current game's history.
/ischeck Finds out if the game is in check.
/ismate Finds out if the game is over.
/piece {"position":"string"} Gets a piece by its position on the board.
/pieces {"color":["w","b"]} Gets the pieces on the board by color.
/playfen {"fen":"string"} Plays a chess move in shortened FEN format.
/quit Quits a game.
/start {"mode":["analysis","loadfen","playfriend"],"fen":"string","color":["w","b"],"min":"int"} Starts a new game.
/status The current game status.
Listening to commands...
PHP Notice: Undefined offset: 2 in /home/standard/projects/chess-server/vendor/chesslablab/php-chess/src/FEN/StringToBoard.php on line 89
PHP Notice: Undefined offset: 2 in /home/standard/projects/chess-server/vendor/chesslablab/php-chess/src/FEN/StringToBoard.php on line 95
PHP Notice: Undefined offset: 2 in /home/standard/projects/chess-server/vendor/chesslablab/php-chess/src/FEN/StringToBoard.php on line 95
PHP Notice: Undefined offset: 1 in /home/standard/projects/chess-server/vendor/chesslablab/php-chess/src/FEN/StringToBoard.php on line 52
PHP Notice: Undefined offset: 2 in /home/standard/projects/chess-server/vendor/chesslablab/php-chess/src/FEN/StringToBoard.php on line 52
PHP Notice: Undefined offset: 3 in /home/standard/projects/chess-server/vendor/chesslablab/php-chess/src/FEN/StringToBoard.php on line 52
The text was updated successfully, but these errors were encountered:
programarivm
changed the title
Fix the notices that are thrown when loading an invalid FEN string
Fix the notices that are thrown when loading an invalid FEN
Sep 18, 2021
The chess server will complain with the following PHP notices after trying to load
foo
as a FEN string:The text was updated successfully, but these errors were encountered: