Bug in Cutechess?

Discussion of chess software programming and technical issues.

Moderators: Harvey Williamson, Dann Corbit, hgm

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
JohnWoe
Posts: 258
Joined: Sat Mar 02, 2013 10:31 pm

Bug in Cutechess?

Post by JohnWoe » Tue Sep 29, 2020 1:58 pm

Is this bug in my engine or Cutechess?

To me it looks like it sent a checkmate position to Sapeli.
Which correctly responds "0000"

Code: Select all

26786 >Sapeli 1.911(0): position fen rkbrnbqn/pppppppp/8/8/8/8/PPPPPPPP/RKBRNBQN w DAda - 0 1 moves h1g3 h8g6 e1f3 e8f6 d2d4 d7d5 a2a3 c8g4 h2h3 g4d7 c1g5 a7a6 e2e3 h7h6 g5f6 e7f6 f1d3 f8d6 g1e1 d8e8 e1a5 d6g3 f2g3 e8e3 a5d5 d7c6 d5c5 c6f3 g2f3 e3f3 d1g1 g8e8 b1a1 e8e3
26786 >Sapeli 1.911(0): isready
26787 <Sapeli 1.911(0): readyok
26787 >Sapeli 1.911(0): go wtime 83 btime 85
26787 <Sapeli 1.911(0): info depth 1 nodes 45 time 0 nps 45000 score cp -43 pv c1b1
26787 <Sapeli 1.911(0): info depth 2 nodes 202 time 0 nps 202000 score cp -118 pv c1b1
26788 <Sapeli 1.911(0): info depth 3 nodes 1130 time 1 nps 565000 score cp -118 pv c1b1
26788 <Sapeli 1.911(0): info depth 4 nodes 1130 time 1 nps 565000 score cp -118 pv c1b1
26788 <Sapeli 1.911(0): bestmove c1b1
26788 >Sapeli 1.91(1): position fen rkbrnbqn/pppppppp/8/8/8/8/PPPPPPPP/RKBRNBQN w DAda - 0 1 moves h1g3 h8g6 e1f3 e8f6 d2d4 d7d5 a2a3 c8g4 h2h3 g4d7 c1g5 a7a6 e2e3 h7h6 g5f6 e7f6 f1d3 f8d6 g1e1 d8e8 e1a5 d6g3 f2g3 e8e3 a5d5 d7c6 d5c5 c6f3 g2f3 e3f3 d1g1 g8e8 b1a1 e8e3 c1b1
26788 >Sapeli 1.91(1): isready
26788 <Sapeli 1.91(1): readyok
26788 >Sapeli 1.91(1): go wtime 82 btime 85
26789 <Sapeli 1.91(1): info depth 1 nodes 125 time 1 nps 62500 score cp 118 pv f3g3
26789 <Sapeli 1.91(1): info depth 2 nodes 486 time 1 nps 243000 score cp 118 pv f3g3
26789 <Sapeli 1.91(1): info depth 3 nodes 486 time 1 nps 243000 score cp 118 pv f3g3
26789 <Sapeli 1.91(1): bestmove f3g3
26789 >Sapeli 1.911(0): position fen rkbrnbqn/pppppppp/8/8/8/8/PPPPPPPP/RKBRNBQN w DAda - 0 1 moves h1g3 h8g6 e1f3 e8f6 d2d4 d7d5 a2a3 c8g4 h2h3 g4d7 c1g5 a7a6 e2e3 h7h6 g5f6 e7f6 f1d3 f8d6 g1e1 d8e8 e1a5 d6g3 f2g3 e8e3 a5d5 d7c6 d5c5 c6f3 g2f3 e3f3 d1g1 g8e8 b1a1 e8e3 c1b1 f3g3
26789 >Sapeli 1.911(0): isready
26790 <Sapeli 1.911(0): readyok
26790 >Sapeli 1.911(0): go wtime 82 btime 85
26790 <Sapeli 1.911(0): info depth 1 nodes 121 time 0 nps 121000 score cp -118 pv g1g3
26791 <Sapeli 1.911(0): info depth 2 nodes 1031 time 1 nps 515500 score cp -114 pv g1e1
26791 <Sapeli 1.911(0): info depth 3 nodes 1212 time 1 nps 606000 score cp -114 pv g1e1
26791 <Sapeli 1.911(0): info depth 4 nodes 1212 time 1 nps 606000 score cp -114 pv g1e1
26791 <Sapeli 1.911(0): bestmove g1e1
26791 >Sapeli 1.91(1): position fen rkbrnbqn/pppppppp/8/8/8/8/PPPPPPPP/RKBRNBQN w DAda - 0 1 moves h1g3 h8g6 e1f3 e8f6 d2d4 d7d5 a2a3 c8g4 h2h3 g4d7 c1g5 a7a6 e2e3 h7h6 g5f6 e7f6 f1d3 f8d6 g1e1 d8e8 e1a5 d6g3 f2g3 e8e3 a5d5 d7c6 d5c5 c6f3 g2f3 e3f3 d1g1 g8e8 b1a1 e8e3 c1b1 f3g3 g1e1
26791 >Sapeli 1.91(1): isready
26792 <Sapeli 1.91(1): readyok
26792 >Sapeli 1.91(1): go wtime 81 btime 85
26792 <Sapeli 1.91(1): info depth 1 nodes 227 time 0 nps 227000 score cp 114 pv e3f4
26793 <Sapeli 1.91(1): info depth 2 nodes 1067 time 1 nps 533500 score cp 89 pv e3f4
26793 <Sapeli 1.91(1): info depth 3 nodes 1464 time 1 nps 732000 score cp 89 pv e3f4
26793 <Sapeli 1.91(1): info depth 4 nodes 1464 time 1 nps 732000 score cp 89 pv e3f4
26793 <Sapeli 1.91(1): bestmove e3f4
26793 >Sapeli 1.911(0): position fen rkbrnbqn/pppppppp/8/8/8/8/PPPPPPPP/RKBRNBQN w DAda - 0 1 moves h1g3 h8g6 e1f3 e8f6 d2d4 d7d5 a2a3 c8g4 h2h3 g4d7 c1g5 a7a6 e2e3 h7h6 g5f6 e7f6 f1d3 f8d6 g1e1 d8e8 e1a5 d6g3 f2g3 e8e3 a5d5 d7c6 d5c5 c6f3 g2f3 e3f3 d1g1 g8e8 b1a1 e8e3 c1b1 f3g3 g1e1 e3f4
26793 >Sapeli 1.911(0): isready
26794 <Sapeli 1.911(0): readyok
26794 >Sapeli 1.911(0): go wtime 81 btime 84
26794 <Sapeli 1.911(0): info depth 1 nodes 104 time 0 nps 104000 score cp -89 pv e1e8
26795 <Sapeli 1.911(0): info depth 2 nodes 545 time 1 nps 272500 score cp 10485 pv e1e8
26795 <Sapeli 1.911(0): info depth 3 nodes 545 time 1 nps 272500 score cp 10485 pv e1e8
26795 <Sapeli 1.911(0): bestmove e1e8
26795 >Sapeli 1.91(1): position fen rkbrnbqn/pppppppp/8/8/8/8/PPPPPPPP/RKBRNBQN w DAda - 0 1 moves h1g3 h8g6 e1f3 e8f6 d2d4 d7d5 a2a3 c8g4 h2h3 g4d7 c1g5 a7a6 e2e3 h7h6 g5f6 e7f6 f1d3 f8d6 g1e1 d8e8 e1a5 d6g3 f2g3 e8e3 a5d5 d7c6 d5c5 c6f3 g2f3 e3f3 d1g1 g8e8 b1a1 e8e3 c1b1 f3g3 g1e1 e3f4 e1e8
26795 >Sapeli 1.91(1): isready
26796 <Sapeli 1.91(1): readyok
26796 >Sapeli 1.91(1): go wtime 81 btime 84
26796 <Sapeli 1.91(1): info depth 1 nodes 0 time 0 nps 0 score cp 0 pv b8c8
26796 <Sapeli 1.91(1): bestmove 0000
26796 >Sapeli 1.911(0): isready
26796 >Sapeli 1.91(1): isready
26796 <Sapeli 1.911(0): readyok
26796 <Sapeli 1.91(1): readyok
Finished game 133 (Sapeli 1.911 vs Sapeli 1.91): 1-0 {Black makes an illegal move: 0000}

Guenther
Posts: 3577
Joined: Wed Oct 01, 2008 4:33 am
Location: Regensburg, Germany
Full name: Guenther Simon
Contact:

Re: Bug in Cutechess?

Post by Guenther » Wed Sep 30, 2020 6:19 am

JohnWoe wrote:
Tue Sep 29, 2020 1:58 pm
Is this bug in my engine or Cutechess?

To me it looks like it sent a checkmate position to Sapeli.
Which correctly responds "0000"

Code: Select all

...
26795 <Sapeli 1.911(0): bestmove e1e8
26795 >Sapeli 1.91(1): position fen rkbrnbqn/pppppppp/8/8/8/8/PPPPPPPP/RKBRNBQN w DAda - 0 1 moves h1g3 h8g6 e1f3 e8f6 d2d4 d7d5 a2a3 c8g4 h2h3 g4d7 c1g5 a7a6 e2e3 h7h6 g5f6 e7f6 f1d3 f8d6 g1e1 d8e8 e1a5 d6g3 f2g3 e8e3 a5d5 d7c6 d5c5 c6f3 g2f3 e3f3 d1g1 g8e8 b1a1 e8e3 c1b1 f3g3 g1e1 e3f4 e1e8
26795 >Sapeli 1.91(1): isready
26796 <Sapeli 1.91(1): readyok
26796 >Sapeli 1.91(1): go wtime 81 btime 84
26796 <Sapeli 1.91(1): info depth 1 nodes 0 time 0 nps 0 score cp 0 pv b8c8
26796 <Sapeli 1.91(1): bestmove 0000
26796 >Sapeli 1.911(0): isready
26796 >Sapeli 1.91(1): isready
26796 <Sapeli 1.911(0): readyok
26796 <Sapeli 1.91(1): readyok
Finished game 133 (Sapeli 1.911 vs Sapeli 1.91): 1-0 {Black makes an illegal move: 0000}






To me it looks the same, Re8# should have ended the game. I would file an issue at cutechess github for FRC.
(maybe it thought castling out of check would be allowed to avoid checkmate, which is my only explanation w/o checking the source??)

In non-standard chess variations there still can lurk some bugs in cute.
Andrew just found a massive one in FRC a few weeks ago.
https://github.com/cutechess/cutechess/issues/616

AndrewGrant
Posts: 876
Joined: Tue Apr 19, 2016 4:08 am
Location: U.S.A
Full name: Andrew Grant
Contact:

Re: Bug in Cutechess?

Post by AndrewGrant » Wed Sep 30, 2020 7:00 am

This is the same bug that I pointed out. Cutechess thinks Black can castle out of check.

A solution was written, its just not been merged yet.

Guenther
Posts: 3577
Joined: Wed Oct 01, 2008 4:33 am
Location: Regensburg, Germany
Full name: Guenther Simon
Contact:

Re: Bug in Cutechess?

Post by Guenther » Wed Sep 30, 2020 8:08 am

AndrewGrant wrote:
Wed Sep 30, 2020 7:00 am
This is the same bug that I pointed out. Cutechess thinks Black can castle out of check.

A solution was written, its just not been merged yet.
Great! I didn't read your full report, but you are right and it is already fixed and I have already compiled it
thanks to alweys fork with the EXPER-1 branch, which is always active and adds things before being approved
for the cutechess repo.

The bug is gone, see below.

Image

If someone wants the current one with lots of new features/user settings I can upload it, but I have only compiled WIN binaries.

Image

User avatar
Roland Chastain
Posts: 443
Joined: Sat Jun 08, 2013 8:07 am
Location: France
Full name: Roland Chastain
Contact:

Re: Bug in Cutechess?

Post by Roland Chastain » Wed Sep 30, 2020 12:15 pm

Guenther wrote:
Wed Sep 30, 2020 8:08 am
If someone wants the current one with lots of new features/user settings I can upload it, but I have only compiled WIN binaries.
For me, I am looking for a Windows 32-bits binary of cutechess-cli, in a ZIP file. I would like to use it on an old computer where I don't have rights to install something. If ever you have the possibility to do that...

Regards.

Roland
Qui trop embrasse mal étreint.

Guenther
Posts: 3577
Joined: Wed Oct 01, 2008 4:33 am
Location: Regensburg, Germany
Full name: Guenther Simon
Contact:

Re: Bug in Cutechess?

Post by Guenther » Wed Sep 30, 2020 2:17 pm

Roland Chastain wrote:
Wed Sep 30, 2020 12:15 pm
Guenther wrote:
Wed Sep 30, 2020 8:08 am
If someone wants the current one with lots of new features/user settings I can upload it, but I have only compiled WIN binaries.
For me, I am looking for a Windows 32-bits binary of cutechess-cli, in a ZIP file. I would like to use it on an old computer where I don't have rights to install something. If ever you have the possibility to do that...

Regards.

Roland
Try this - w/o warranty. (src + help.txt included)
https://rwbc-chess.de/Downloads\cutechess-cli_x86.zip

User avatar
Roland Chastain
Posts: 443
Joined: Sat Jun 08, 2013 8:07 am
Location: France
Full name: Roland Chastain
Contact:

Re: Bug in Cutechess?

Post by Roland Chastain » Wed Sep 30, 2020 3:16 pm

Guenther wrote:
Wed Sep 30, 2020 2:17 pm
Try this - w/o warranty. (src + help.txt included)
https://rwbc-chess.de/Downloads/cutechess-cli_x86.zip
Thank you very much. I will try it tomorrow.

(I had to replace a "\" with a "/" in the link that you gave.)
Qui trop embrasse mal étreint.

Modern Times
Posts: 2618
Joined: Thu Jun 07, 2012 9:02 pm

Re: Bug in Cutechess?

Post by Modern Times » Wed Sep 30, 2020 5:59 pm

Guenther wrote:
Wed Sep 30, 2020 8:08 am
If someone wants the current one with lots of new features/user settings I can upload it, but I have only compiled WIN binaries.
I would like this, thanks. Is it just a matter of overwriting the existing cutechess.exe or is there more involved than that ?

I currently have x64, Version 1.1.0 (noted as 2019-01-18 dev build)
.

Opinions expressed here are my own, and not necessarily those of the CCRL Group.

Guenther
Posts: 3577
Joined: Wed Oct 01, 2008 4:33 am
Location: Regensburg, Germany
Full name: Guenther Simon
Contact:

Re: Bug in Cutechess?

Post by Guenther » Thu Oct 01, 2020 7:14 am

Modern Times wrote:
Wed Sep 30, 2020 5:59 pm
Guenther wrote:
Wed Sep 30, 2020 8:08 am
If someone wants the current one with lots of new features/user settings I can upload it, but I have only compiled WIN binaries.
I would like this, thanks. Is it just a matter of overwriting the existing cutechess.exe or is there more involved than that ?

I currently have x64, Version 1.1.0 (noted as 2019-01-18 dev build)
Here is a download from my site containing current cli and gui from current alweys test branch (EXPER1).
https://rwbc-chess.de/Downloads/cutechess-win64.7z

This is an overview about already incorporated changes in this branch:
https://github.com/alwey/cutechess/comm ... ojects/gui

Note that I still have done two tiny changes myself, adapted evalhistory to my board design and
changed time precision for pgn saving to at least 2 digits precision (in most cases except very long tc).

For your question, yes you can just overwrite your old gui.exe and it should change your your
cutechess.ini at the usual place after the first start, as it has now much more settings
which can be set there.

Below an example of mine now:
C:\Users\USERNAME\AppData\Roaming\cutechess\cutechess.ini

Code: Select all

[games]
default_pgn_output_file=test.pgn
draw_adjudication\move_count=10
draw_adjudication\move_number=80
draw_adjudication\score=15
game_length\max_moves=200
resign_adjudication\move_count=10
resign_adjudication\score=1200
resign_adjudication\two_sided=true
time_control\moves_per_tc=40
time_control\time_per_tc=40000
time_control\time_per_move=0
time_control\increment=0
time_control\ply_limit=0
time_control\node_limit=0
time_control\expiry_margin=0
time_control\infinite=false
time_control\hourglass=false
second_time_control\time_control\moves_per_tc=40
second_time_control\time_control\time_per_tc=40000
second_time_control\time_control\time_per_move=0
second_time_control\time_control\increment=0
second_time_control\time_control\ply_limit=0
second_time_control\time_control\node_limit=0
second_time_control\time_control\expiry_margin=0
second_time_control\time_control\infinite=false
second_time_control\time_control\hourglass=false
opening_suite\depth=6
opening_suite\file=C:/Program Files (x86)/cutechess/3M_rand.pgn
opening_suite\random_order=true
use_tb=true

[pgn]
site=RWBC-CAPPUCCINO

[tournament]
games_per_encounter=2
recover=true
repeats=2
result_format="Rank,Name,Elo,Points,Games,Score"
rounds=100
wait=1

[ui]
board\border_color=#844f23
board\coord_text_color=#ffffff
board\dark_square_color=#bb8156
board\light_square_color=#eccba2
board\piece_size_factor=70
display_players_sides_on_clocks=true
mainwindow\geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\xff\xff\xff\xf8\xff\xff\xff\xf8\0\0\a\x87\0\0\x4?\0\0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d2\0\0\x2\xfa\0\0\0\x4\0\0\0\x4\0\0\0\b\0\0\0\b\xfc\0\0\0\x1\0\0\0\x2\0\0\0\x1\0\0\0\x10\0G\0\x61\0m\0\x65\0T\0\x61\0\x62\0s\0\0\0\0\0\xff\xff\xff\xff\0\0\0\0\0\0\0\0)

User avatar
Roland Chastain
Posts: 443
Joined: Sat Jun 08, 2013 8:07 am
Location: France
Full name: Roland Chastain
Contact:

Re: Bug in Cutechess?

Post by Roland Chastain » Thu Oct 01, 2020 5:45 pm

Guenther wrote:
Wed Sep 30, 2020 2:17 pm
Try this - w/o warranty. (src + help.txt included)
https://rwbc-chess.de/Downloads/cutechess-cli_x86.zip
Works perfectly. Thank you.
Qui trop embrasse mal étreint.

Post Reply