GithubHelp home page GithubHelp logo

cutechess / cutechess Goto Github PK

View Code? Open in Web Editor NEW
563.0 33.0 143.0 8.7 MB

Cute Chess is a graphical user interface, command-line interface and a library for playing chess.

License: GNU General Public License v3.0

QMake 0.01% C++ 98.55% Python 0.46% CodeQL 0.17% C 0.06% CMake 0.75%
chess qt5 c-plus-plus

cutechess's Introduction

Cute Chess

GitHub CI

Cute Chess is a graphical user interface, command-line interface and a library for playing chess. Cute Chess is written in C++ using the Qt framework.

Installation

Binaries

See the Releases page.

Building from source

Cute Chess requires Qt 5.15 or greater, a compiler with C++11 support and cmake. Cute Chess depends on the following Qt 5 modules:

  • qt5-widgets
  • qt5-svg
  • qt5-concurrent
  • qt5-printsupport
  • qt5-testlib (optional: unit tests)

Run these commands:

$ mkdir build
$ cd build
$ cmake ..
$ make

Documentation is available as Unix manual pages in the docs/ directory.

For detailed build instruction for various operating systems, see the Building from source wiki page.

Running

The cutechess program is the graphical user interface of Cute Chess. It can be run either from command-line or from your desktop environment's application launcher.

The cutechess-cli program is the command-line interface for playing games between chess engines. For example, to play ten games between two Sloppy engines (assuming sloppy is in PATH) with a time control of 40 moves in 60 seconds:

$ cutechess-cli -engine cmd=sloppy -engine cmd=sloppy -each proto=xboard tc=40/60 -rounds 10

See cutechess-cli -help for descriptions of the supported options or manuals for full documentation.

License

Cute Chess is released under the GPLv3+ license except for the components in the projects/lib/components and projects/gui/components directories which are released under the MIT License.

Credits

Cute Chess was written by Ilari Pihlajisto, Arto Jonsson and contributors

cutechess's People

Contributors

alwey avatar artoj avatar basil00 avatar ddugovic avatar dependabot[bot] avatar erbsenzaehler avatar gvreuls avatar ianfab avatar ilaripih avatar jjoshua2 avatar kdave avatar kiudee avatar mortenlohne avatar prcuvu avatar queensgambit avatar rikardfalkeborn avatar rwst avatar sovaz1997 avatar tilps avatar vondele avatar zz4032 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cutechess's Issues

redirecting stderr of engines

is it possible to redirect the stderr of engines, with cutechess-cli ?

my problem is as follows:

  • my engine has lots of assert()
  • sometimes the debug version crashes, in ways that I cannot replicate manually. the non debug version never crashes, so it should be an assert().
  • I want to run a debug compile with cutechess-cli, in real tournament conditions, until it crashes, and see which assert() fired.

Analyze pgn with an engine with cutechess-cli

Is it possible to input a pgn file and as an output to get a pgn file with engine scores in the comments?

I apologize if this is not the place for posting such question, but there is a question tag available so I assume that it stands for something.

use std::chrono::high_resolution_clock

Cutechess uses QTime which uses the system clock. Resolution is very bad, typically 10 msec.

Could you use std::chrono::high_resolution_clock instead of QTime ?

Some bugs detected

  1. Castling should not be done by dragging king over rook, but by moving the king two squares towards a rook.
  2. Also please add some option in menu to disable the dots showing possible moves - it's kind of annoying...
  3. When adding engine using the "Add Engine" dialog and everything in "Basic" tab is empty, clicking on "Advanced" tab causes Cutechess to crash with http://pastebin.com/QXz5kKqq

Unnamed namespaces vs "static"

In an old commit from 2009 I switched from unnamed namespaces to "static" because the latter guarantees internal linkage in C++03: 60d84a7

But things have changed in C++11 - anything inside an unnamed namespace (even type definitions) have internal linkage. Since pretty much every C++ now supports C++11, I think think we can safely start using unnamed namespaces in the places where it makes sense.

copy/paste

A feature that would be very useful is the ability to copy/paste a position (Ctrl+C/Ctrl+V).
Copy would write the FEN string into the clipboard, and paste would set the board (of the current tab) to that position.

Engine output

First of all, congratulations on such a nice GUI, hope it keeps getting developed.

There's one thing that would be nice to have, if it's not too much work. The ability to show the engine output in an organized way, as it is done in arena, for example. To be able to switch between the current "Engine Debug", and the "pretty" and tabbed output, something like this:

depth time nodes score pv
9/17 0:05 23494 1.57 Ke4 d5 Ke4 d5 Ke4 d5 Ke4 d5 Ke4
8/15 0:03 6457 1.23 Ke4 d5 Ke4 d5 Ke4 d5 Ke4 d5

And show time, nps, tbhits, currmove, hash usage, etc in another row, maybe above the pvs.

return error code to indicate SPRT conclusion

I would like the cutechess-cli executable to return an error code, so it can be used in a shell script to automate chained SPRT tests.

Error code would indicate if we accept H0, H1, or if SPRT did not conclude (eg. user pressed Ctrl+C, an engine crashed, or max nb of games reached).

A typical use for me is to do a two step SPRT test to prefilter at fast TC and validate at longer TC, similar to what is done in the Stockfish framework.

Assert at line 164 in gui/src/movelist.cpp

When I run an engine tournament I hit the assert in movelist.cpp at line 164 after the first game finishes:

Q_ASSERT(moveNum >= 0 && moveNum < m_moveCount);

m_moveCount is 0 when this happens. I haven't debugged it to figure out exactly what's going on, but I suspect it's trying to select the last move of the previous game after it has already reset the position to SARTPOS for the next game.

To work around it I've added this before the assert:

if (m_moveCount <= 0)
return;

repeat option does not (with chess960, no book)

It is a nice feature that a random 960 game gets a random start position. However the repeat option does not do the expected, which would be using the same position with w/b. I used

./projects/cli/cutechess-cli -rounds 4 -engine cmd=stockfish -engine cmd=stockfish -pgnout results.pgn -each proto=uci option.Threads=4 tc=1+0.01 timemargin=1000 whitepov -variant fischerandom -repeat

but the result pgn had a new position with every game. This does not change when I add the option -games 2.

I'm happy to say that I can work around this by using a book with the 960 positions. repeat does repeat then.

does not alternate white/black with every game

Example:

./cutechess-cli -rounds 4 -engine name=stockfish cmd=stockfish option.Hash=1024 option.OwnBook=false -engine name=komodo cmd=komodo-9.4-linux option.Hash=1024 option.OwnBook=false -each proto=uci option.Threads=4 tc=10+0.1 -repeat
stockfish doesn't have option OwnBook
Started game 1 of 4 (stockfish vs komodo)
Finished game 1 (stockfish vs komodo): 1/2-1/2 {Draw by 3-fold repetition}
Score of stockfish vs komodo: 0 - 0 - 1  [0.500] 1
Started game 2 of 4 (stockfish vs komodo)
Finished game 2 (stockfish vs komodo): 0-1 {Black mates}
Score of stockfish vs komodo: 0 - 1 - 1  [0.250] 2
Started game 3 of 4 (komodo vs stockfish)
Finished game 3 (komodo vs stockfish): 1/2-1/2 {Draw by 3-fold repetition}
Score of stockfish vs komodo: 0 - 1 - 2  [0.333] 3
Started game 4 of 4 (komodo vs stockfish)
Finished game 4 (komodo vs stockfish): 0-1 {Black mates}
Score of stockfish vs komodo: 1 - 1 - 2  [0.500] 4
ELO difference: 0.00 +/- 295.91
Finished match

You can see that two games are played s-k and two k-s. That would be okay in total but if I use a book and give the -repeat option the same opening is played twice but the colors are not alternated, i.e. game 1 opening 1 s-k, game 2 opening 1 s-k, game 3 opening 2 k-s, game 4 opening 2 k-s. So two identical games will be played.

Cannot compile

Steps to reproduce:

  • OS = Lubuntu 15.10
  • sudo apt-get install qt5-default (Qt version 5.4.2)
  • qmake && make
[...]
/usr/lib/x86_64-linux-gnu/qt4/bin/qmake -config static -o Makefile cli.pro
g++ -c -m64 -pipe -O2 -Wall -W -D_REENTRANT -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++-64 -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4 -I../lib/src -I.moc -o .obj/main.o src/main.cpp
In file included from src/main.cpp:40:0:
src/cutechesscoreapp.h:40:15: error: ‘QMessageLogContext’ does not name a type
         const QMessageLogContext &context,
               ^

More diverse Mersenne seeds

The default seed for Mersenne is currently QTime(0,0,0).secsTo(QTime::currentTime()) which can only give 86400 different values. The seeds should use the full quint32 resolution.

Also, there's a bug in the -srand option: it must be in the command line before the -openings option; otherwise it won't affect PGN/EPD indexing.

ELO error margins

With every ELO score printed by cutechess would be useful to have also the ELO error margins.

Large EPD file indexing and other issues

I was using this large EPD file with 48k+ lines. I noticed that it just takes forever to index. Even a 400 line EPD takes a second or two. The equivalent PGN file with 48k+ games is indexed within 1 second without a problem. I'm using order=random and -repeat by the way.

I'm also wondering if the book moves from the opening PGN are having the increments added to the total time? Lets say a 10 move depth opening book would add (10 x inc) time to the total time allocated to the engine. This is a problem if the book move depth is not uniform for all book entries. Some of the games will therefore have more time than the others depending on book move depth.

Another thing. This is a request for a minor feature. It would be great to have the error bars printed along with the Elo when -ratinginterval is enabled. Maybe print the LOS and currently calculted SPRT variables too.

Update move comments in GUI

If an existing move's comment is updated, the GUI still shows the old comment. This is especially a problem when the game ends and the termination reason (eg. "black resigns") is not shown to the user.

OS X UI improvements

The current UI behavior on OS X is a mess. The following items should be improved:

  • Keyboard shortcuts such as Command+M and Command+W should work similarly to other OS X programs. For example Command+W should not close the active game tab if the game window is not active.
  • Active windows in the Window menu.
  • Minimize action in the Window menu.
  • Zoom action in the Window menu.
  • Behavior if no active windows exist.

More in the OS X Human Interface Guidelines.

SPRT DrawElo value

Ilari,

The value of drawelo, which is currently hardcoded at 97.3 would be best estimated on the sample. I did some experiment on the subject, and what comes out of it is that:

  • all things equal drawelo increases with the level of play: the stronger the programs the more draws they make
  • drawelo is much greater in self-play than against foreign opponents. obviously a program makes more draws against itself than against other engines of the same level.

To give you an idea, the drawelo I estimated for Stockfish in self-play is aroung 250 (and increases with time control, as longer games mean higher quality chess, hence more draws). For my own engine DiscoCheck, I get about drawelo=180 in my usual 10"+0.1" testing.

And the value of drawelo affects quite significantly the stopping algorithm, actually. What you can do is estimate it out of sample:

draw_elo = 200 * log10( (1-l)/l * (1-w)/w )

where 'w' and 'l' denote respectively the win and loss ratio (w = nb win / nb games, l = nb win / nb games).

This means having to recalculate everything after every game, so you can abandon the logic of updating the SPRT state incrementally.

Whenever a game is completed, you recalc everything. Noo need to embed it into a class. Just a simple function will be fine, since there's no notion of 'state' anymore:

  • calculate drawelo on the sample, as per above formula. you need to have 0 < w < 1 and 0 < l < 1 (otherwise div by zero or log of neg number). If these conditions are not verified, you simply do not stop (this can only happen in the first 'few' games).
  • calculate the probabilities under H0 and H1: pWin0, pLoss0, pDraw0, and pWin1, pLoss1, pDraw1.
  • calculate the log-likelyhood ratio
    LLR = nb_win_log(pWin1/pWin0) + nb_loss_log(pLoss1/pLoss0) + nb_loss*log(pDraw1/pDraw0)
  • compare it to the bounds etc.

No time increment for book moves

Book moves shouldn't add time to the player's clock. This should probably be the default setting.

Original suggestion from Edsel Apostol:

I'm also wondering if the book moves from the opening PGN are having the increments added to the total time? Lets say a 10 move depth opening book would add (10 x inc) time to the total time allocated to the engine. This is a problem if the book move depth is not uniform for all book entries. Some of the games will therefore have more time than the others depending on book move depth.

Chess960 castling bug

In this Chess960 game, cutechess-cli incorrectly declared e8h8 (KxR=castling) as illegal:

[White "./Engines/stockfish_dd"]
[Black "./Engines/stockfish_5.0"]
[Result "1-0"]
[FEN "nqrnbbkr/pppppppp/8/8/8/8/PPPPPPPP/NQRNBBKR w KQkq - 0 1"]
[PlyCount "29"]
[SetUp "1"]
[TimeControl "6+0.02"]
[Variant "fischerandom"]

1. d4 {+0.30/13 0.28s} d5 {-0.17/12 0.13s} 2. c4 {+0.26/12 0.14s}
dxc4 {-0.18/12 0.19s} 3. e4 {+0.10/13 0.20s} b5 {-0.21/12 0.12s}
4. Ne3 {+0.02/13 0.25s} c5 {-0.05/12 0.20s} 5. dxc5 {+0.12/13 0.15s}
e5 {-0.24/12 0.24s} 6. b4 {+0.20/14 0.14s} a5 {-0.15/13 0.081s}
7. bxa5 {+0.32/13 0.20s} Bxc5 {-0.32/11 0.13s} 8. a4 {+0.32/14 0.15s}
bxa4 {-0.46/13 0.30s} 9. Nac2 {+0.22/13 0.29s} Nc7 {-0.15/12 0.18s}
10. Bb4 {+0.24/12 0.19s} Bxb4 {-0.20/13 0.27s} 11. Nxb4 {+0.32/12 0.10s}
Qb5 {-0.42/13 0.23s} 12. Rxc4 {+0.18/12 0.12s} Qxa5 {-0.66/12 0.13s}
13. Nbd5 {+0.34/13 0.12s} Nxd5 {+0.17/13 0.071s} 14. Rxc8 {+0.04/14 0.32s}
Nxe3 {-0.13/12 0.14s}
15. fxe3 {+0.20/14 0.12s, Black makes an illegal move: g8h8} 1-0

The cutechess-cli command line was as follows:

./cutechess/projects/cli/cutechess-cli \
-each proto=uci tc=6+0.02 option.Hash=16 option."Emergency Base Time"=20 \
-variant 'fischerandom' \
-engine cmd=$1 name=$1 \
-engine cmd=$2 name=$2 \
-draw movenumber=40 movecount=8 score=40 \
-resign movecount=3 score=500 \
-rounds 10000 \
-concurrency 7 -repeat \
-pgnout $3

Colors not alternated in gauntlet tournament

If a gauntlet tournament has more than 2 players and the -games parameter isn't used, the first player will play all games as white. Cutechess-cli 0.7.3 plays gauntlets correctly.

ModelTest crashing EngineConfigurationDialog

Happens with a MSVC 2015 build.
Found and fixed by "thesmartwon" here: https://github.com/thesmartwon/OpenChess/commit/3f2d220bf8fc2a62c16be09ed5d5d3f28ae4b5c6

Stack trace:

    Qt5Cored.dll!qt_message_fatal(QtMsgType __formal, const QMessageLogContext & context, const QString & message) Line 1603    C++
    Qt5Cored.dll!QMessageLogger::fatal(const char * msg, ...) Line 784  C++
    Qt5Cored.dll!qt_assert_x(const char * where, const char * what, const char * file, int line) Line 3002  C++
>   cutechess.exe!QList<EngineOption * __ptr64>::at(int i) Line 531 C++
    cutechess.exe!EngineOptionModel::data(const QModelIndex & index, int role) Line 76  C++
    cutechess.exe!ModelTest::nonDestructiveBasicTest() Line 123 C++
    cutechess.exe!ModelTest::runAllTests() Line 106 C++
    cutechess.exe!ModelTest::ModelTest(QAbstractItemModel * _model, QObject * parent) Line 98   C++
    cutechess.exe!EngineConfigurationDialog::EngineConfigurationDialog(EngineConfigurationDialog::DialogMode mode, QWidget * parent) Line 46    C++
    cutechess.exe!EngineManagementDialog::configureEngine(const QModelIndex & index) Line 115   C++
    cutechess.exe!EngineManagementDialog::qt_static_metacall(QObject * _o, QMetaObject::Call _c, int _id, void * * _a) Line 91  C++
    Qt5Cored.dll!QMetaObject::activate(QObject * sender, int signalOffset, int local_signal_index, void * * argv) Line 3732 C++
    Qt5Cored.dll!QMetaObject::activate(QObject * sender, const QMetaObject * m, int local_signal_index, void * * argv) Line 3596    C++
    Qt5Widgetsd.dll!QAbstractItemView::doubleClicked(const QModelIndex & _t1) Line 647  C++
    Qt5Widgetsd.dll!QAbstractItemView::mouseDoubleClickEvent(QMouseEvent * event) Line 1893 C++
    Qt5Widgetsd.dll!QWidget::event(QEvent * event) Line 8748    C++
    Qt5Widgetsd.dll!QFrame::event(QEvent * e) Line 544  C++
    Qt5Widgetsd.dll!QAbstractScrollArea::viewportEvent(QEvent * e) Line 1206    C++
    Qt5Widgetsd.dll!QAbstractItemView::viewportEvent(QEvent * event) Line 1686  C++
    Qt5Widgetsd.dll!QAbstractScrollAreaPrivate::viewportEvent(QEvent * event) Line 105  C++
    Qt5Widgetsd.dll!QAbstractScrollAreaFilter::eventFilter(QObject * o, QEvent * e) Line 121    C++
    Qt5Cored.dll!QCoreApplicationPrivate::sendThroughObjectEventFilters(QObject * receiver, QEvent * event) Line 1126   C++
    Qt5Widgetsd.dll!QApplicationPrivate::notify_helper(QObject * receiver, QEvent * e) Line 3710    C++
    Qt5Widgetsd.dll!QApplication::notify(QObject * receiver, QEvent * e) Line 3272  C++
    Qt5Cored.dll!QCoreApplication::notifyInternal2(QObject * receiver, QEvent * event) Line 1015    C++
    Qt5Cored.dll!QCoreApplication::sendSpontaneousEvent(QObject * receiver, QEvent * event) Line 230    C++
    Qt5Widgetsd.dll!QApplicationPrivate::sendMouseEvent(QWidget * receiver, QMouseEvent * event, QWidget * alienWidget, QWidget * nativeWidget, QWidget * * buttonDown, QPointer<QWidget> & lastMouseReceiver, bool spontaneous) Line 2767  C++
    Qt5Widgetsd.dll!QWidgetWindow::handleMouseEvent(QMouseEvent * event) Line 555   C++
    Qt5Widgetsd.dll!QWidgetWindow::event(QEvent * event) Line 211   C++
    Qt5Widgetsd.dll!QApplicationPrivate::notify_helper(QObject * receiver, QEvent * e) Line 3714    C++
    Qt5Widgetsd.dll!QApplication::notify(QObject * receiver, QEvent * e) Line 3157  C++
    Qt5Cored.dll!QCoreApplication::notifyInternal2(QObject * receiver, QEvent * event) Line 1015    C++
    Qt5Cored.dll!QCoreApplication::sendSpontaneousEvent(QObject * receiver, QEvent * event) Line 230    C++
    Qt5Guid.dll!QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent * e) Line 1912  C++
    Qt5Guid.dll!QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent * e) Line 1653    C++
    Qt5Guid.dll!QWindowSystemInterface::sendWindowSystemEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 651   C++
    qwindowsd.dll!QWindowsGuiEventDispatcher::sendPostedEvents() Line 77    C++
    Qt5Cored.dll!qt_internal_proc(HWND__ * hwnd, unsigned int message, unsigned __int64 wp, __int64 lp) Line 431    C++
    [External Code] 
    Qt5Cored.dll!QEventDispatcherWin32::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 829    C++
    qwindowsd.dll!QWindowsGuiEventDispatcher::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 68   C++
    Qt5Cored.dll!QEventLoop::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 129   C++
    Qt5Cored.dll!QEventLoop::exec(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 204    C++
    Qt5Widgetsd.dll!QDialog::exec() Line 542    C++
    cutechess.exe!MainWindow::manageEngines() Line 601  C++
    cutechess.exe!MainWindow::qt_static_metacall(QObject * _o, QMetaObject::Call _c, int _id, void * * _a) Line 135 C++
    Qt5Cored.dll!QMetaObject::activate(QObject * sender, int signalOffset, int local_signal_index, void * * argv) Line 3732 C++
    Qt5Cored.dll!QMetaObject::activate(QObject * sender, const QMetaObject * m, int local_signal_index, void * * argv) Line 3596    C++
    Qt5Widgetsd.dll!QAction::triggered(bool _t1) Line 370   C++
    Qt5Widgetsd.dll!QAction::activate(QAction::ActionEvent event) Line 1164 C++
    Qt5Widgetsd.dll!QMenuPrivate::activateCausedStack(const QVector<QPointer<QWidget> > & causedStack, QAction * action, QAction::ActionEvent action_e, bool self) Line 1132    C++
    Qt5Widgetsd.dll!QMenuPrivate::activateAction(QAction * action, QAction::ActionEvent action_e, bool self) Line 1210  C++
    Qt5Widgetsd.dll!QMenu::mouseReleaseEvent(QMouseEvent * e) Line 2635 C++
    Qt5Widgetsd.dll!QWidget::event(QEvent * event) Line 8744    C++
    Qt5Widgetsd.dll!QMenu::event(QEvent * e) Line 2749  C++
    Qt5Widgetsd.dll!QApplicationPrivate::notify_helper(QObject * receiver, QEvent * e) Line 3714    C++
    Qt5Widgetsd.dll!QApplication::notify(QObject * receiver, QEvent * e) Line 3272  C++
    Qt5Cored.dll!QCoreApplication::notifyInternal2(QObject * receiver, QEvent * event) Line 1015    C++
    Qt5Cored.dll!QCoreApplication::sendSpontaneousEvent(QObject * receiver, QEvent * event) Line 230    C++
    Qt5Widgetsd.dll!QApplicationPrivate::sendMouseEvent(QWidget * receiver, QMouseEvent * event, QWidget * alienWidget, QWidget * nativeWidget, QWidget * * buttonDown, QPointer<QWidget> & lastMouseReceiver, bool spontaneous) Line 2767  C++
    Qt5Widgetsd.dll!QWidgetWindow::handleMouseEvent(QMouseEvent * event) Line 453   C++
    Qt5Widgetsd.dll!QWidgetWindow::event(QEvent * event) Line 211   C++
    Qt5Widgetsd.dll!QApplicationPrivate::notify_helper(QObject * receiver, QEvent * e) Line 3714    C++
    Qt5Widgetsd.dll!QApplication::notify(QObject * receiver, QEvent * e) Line 3157  C++
    Qt5Cored.dll!QCoreApplication::notifyInternal2(QObject * receiver, QEvent * event) Line 1015    C++
    Qt5Cored.dll!QCoreApplication::sendSpontaneousEvent(QObject * receiver, QEvent * event) Line 230    C++
    Qt5Guid.dll!QGuiApplicationPrivate::processMouseEvent(QWindowSystemInterfacePrivate::MouseEvent * e) Line 1869  C++
    Qt5Guid.dll!QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent * e) Line 1653    C++
    Qt5Guid.dll!QWindowSystemInterface::sendWindowSystemEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 651   C++
    qwindowsd.dll!QWindowsGuiEventDispatcher::sendPostedEvents() Line 77    C++
    Qt5Cored.dll!qt_internal_proc(HWND__ * hwnd, unsigned int message, unsigned __int64 wp, __int64 lp) Line 431    C++
    [External Code] 
    Qt5Cored.dll!QEventDispatcherWin32::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 829    C++
    qwindowsd.dll!QWindowsGuiEventDispatcher::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 68   C++
    Qt5Cored.dll!QEventLoop::processEvents(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 129   C++
    Qt5Cored.dll!QEventLoop::exec(QFlags<enum QEventLoop::ProcessEventsFlag> flags) Line 204    C++
    Qt5Cored.dll!QCoreApplication::exec() Line 1285 C++
    Qt5Guid.dll!QGuiApplication::exec() Line 1599   C++
    Qt5Widgetsd.dll!QApplication::exec() Line 2974  C++
    cutechess.exe!main(int argc, char * * argv) Line 64 C++
    [External Code] 

GUI tournament options incomplete

At the moment there seems no way to specify arbitrary options for a new tournament. The dialog for example does not allow specification of a tournament book. This could be resolved by a field that enables textual input of any supported option. An alternative would be to have a text file with default UCI config options (for both gui/cli) or global GUI data field with such content.

hangs

Hi,

Sometimes cutechess-cli hangs. That may be caused by engines getting stuck. I would like to suggest a timeout or so so that those processes are terminated after a bit.

bug in whitepov option and adjudication

Hello,

Bug in whitepov option and adjudication, the games are not properly adjudicated. See the two examples below. one is with the option and one without.
Look at the third and last example shows the adjudication was late

cutechess_0.6.0 command used is this:

cutechess-cli.exe ^
-engine name="%basename%" cmd="%baseexe%" whitepov ^
-engine name="%oppname%" cmd="%oppexe%" whitepov ^
-repeat ^
-event "%event%" ^
-rounds 20 ^
-tournament gauntlet ^
-pgnout games.pgn ^
-resign movecount=3 score=400 ^
-draw movenumber=34 movecount=8 score=20 ^
-concurrency 4 ^
-openings file=8moves_v3.pgn format=pgn order=random plies=16 ^
-each proto=uci option.Threads=1 option.OwnBook=false option.Hash=16 restart=on tc=5+0.05
[Event "cutechess_0.6.0+whitepov"]
[Site "?"]
[Date "2014.03.09"]
[Round "7"]
[White "base"]
[Black "new"]
[Result "1-0"]
[ECO "B10"]
[PlyCount "106"]
[EventDate "2014.??.??"]
[TimeControl "3"]

1. e4 {book} c6 {book} 2. Nc3 {book} d5 {book} 3. Nf3 {book} Nf6 {book} 4. e5 {
book} Ne4 {book} 5. Be2 {book} e6 {book} 6. O-O {book} Be7 {book} 7. Nb1 {book}
O-O {book} 8. d3 {book} Nc5 {book} 9. c3 {0.41/12 0.14s} Ncd7 {0.30/13 0.15s}
10. Be3 {0.23/13 0.12s} f6 {0.21/14 0.18s} 11. exf6 {0.31/14 0.12s} Nxf6 {0.21/
15 0.090s} 12. Ne5 {0.36/14 0.49s} Nfd7 {0.15/13 0.15s} 13. f4 {0.36/15 0.15s}
c5 {0.00/13 0.080s} 14. Nd2 {0.36/14 0.070s} Nxe5 {0.32/13 0.30s} 15. fxe5 {0.
42/14 0.39s} Nc6 {0.25/14 0.080s} 16. Rxf8+ {0.36/14 0.070s} Bxf8 {0.25/15 0.
10s} 17. Nf3 {0.29/14 0.33s} Bd7 {0.17/13 0.080s} 18. d4 {0.13/12 0.23s} Qb6 {
0.23/13 0.19s} 19. b3 {0.13/12 0.060s} Be7 {0.02/12 0.19s} 20. Qb1 {0.00/13 0.
16s} cxd4 {0.00/14 0.10s} 21. cxd4 {0.00/13 0.060s} Be8 {0.00/16 0.080s} 22.
Bd3 {0.00/15 0.060s} g6 {0.00/17 0.080s} 23. a3 {0.00/16 0.080s} Na5 {0.00/17
0.080s} 24. Bc2 {0.00/16 0.070s} Rc8 {0.00/19 0.090s} 25. Kh1 {0.00/14 0.070s}
Qc6 {0.00/15 0.18s} 26. Ra2 {0.00/16 0.080s} Qb6 {0.00/16 0.080s} 27. Bd2 {0.
08/14 0.070s} Bf7 {0.00/15 0.080s} 28. Qb2 {0.00/12 0.090s} Be8 {0.00/14 0.080s
} 29. Ra1 {0.00/14 0.070s} Nc4 {-0.58/14 0.11s} 30. Qc3 {-0.84/13 0.10s} Nd6 {
-0.58/14 0.080s} 31. Qb2 {-1.05/14 0.11s} Ne4 {-0.81/14 0.080s} 32. Bxe4 {-1.
05/14 0.070s} dxe4 {-0.98/13 0.10s} 33. Ng5 {-1.03/13 0.090s} Qa6 {-1.15/14 0.
080s} 34. Nxe4 {-1.37/14 0.28s} Qd3 {-1.37/13 0.11s} 35. Nf2 {-1.37/14 0.060s}
Qe2 {-1.37/15 0.12s} 36. Nh3 {-0.82/13 0.19s} Bxa3 {-1.52/16 0.070s} 37. Qxa3 {
-1.32/13 0.070s} Bc6 {-1.46/16 0.18s} 38. d5 {-1.13/14 0.10s} Bxd5 {-1.52/16 0.
10s} 39. Nf4 {-1.14/16 0.23s} Qxd2 {-1.52/16 0.070s} 40. Nxd5 {-1.25/16 0.070s}
Qxd5 {-1.52/16 0.070s} 41. Qxa7 {-1.37/16 0.23s} Qxe5 {-1.52/16 0.070s} 42. Rd1
{-1.48/17 0.12s} Qd5 {-1.75/16 0.090s} 43. Rxd5 {-1.66/17 0.060s} Rc1+ {-1.79/
17 0.080s} 44. Qg1 {-1.87/18 0.19s} Rxg1+ {-1.95/16 0.070s} 45. Kxg1 {-1.87/1 0
} exd5 {-2.12/16 0.070s} 46. Kf2 {-1.87/18 0.040s} Kf7 {-2.31/17 0.22s} 47. Ke3
{-2.31/16 0.15s} Ke6 {-2.31/17 0.060s} 48. Kd4 {-2.26/15 0.090s} g5 {-2.89/17
0.23s} 49. h3 {-2.55/15 0.080s} h5 {-2.97/17 0.060s} 50. g3 {-3.01/14 0.060s}
Kd6 {-3.70/16 0.090s} 51. Kc3 {-3.36/14 0.050s} Ke5 {-4.47/15 0.070s} 52. Kd3 {
-4.30/14 0.050s} d4 {-5.16/16 0.060s} 53. Kd2 {-5.12/14 0.050s} Ke4 {-6.88/16
0.090s, White wins by adjudication} 1-0
[Event "?"]
[Site "?"]
[Date "2014.03.08"]
[Round "2"]
[White "new"]
[Black "base"]
[Result "0-1"]
[ECO "A43"]
[PlyCount "67"]
[EventDate "2014.??.??"]
[TimeControl "5"]

1. d4 {book} c5 {book} 2. d5 {book} f5 {book} 3. g3 {book} Nf6 {book} 4. Bg2 {
book} g6 {book} 5. b3 {book} Bg7 {book} 6. Bb2 {book} O-O {book} 7. Nf3 {book}
d6 {book} 8. O-O {book} b5 {book} 9. a4 {0.18/13 0.21s} b4 {0.00/13 0.16s} 10.
c4 {0.03/15 0.29s} bxc3 {-0.03/15 0.23s} 11. Nxc3 {0.07/16 0.11s} Na6 {-0.03/
16 0.11s} 12. Nd2 {0.03/14 0.18s} Nb4 {-0.03/15 0.11s} 13. Nc4 {0.10/14 0.14s}
Bb7 {-0.03/14 0.11s} 14. Qd2 {0.08/14 0.11s} Rb8 {-0.09/14 0.23s} 15. Rfd1 {0.
08/13 0.16s} Ba6 {-0.01/13 0.11s} 16. Rab1 {0.00/14 0.32s} Nd7 {0.00/15 0.24s}
17. e3 {0.08/13 0.10s} Qe8 {0.00/14 0.11s} 18. Bf1 {0.00/13 0.22s} Qf7 {0.00/
14 0.11s} 19. Rbc1 {0.00/13 0.12s} Bxc4 {0.73/13 0.12s} 20. Bxc4 {-0.62/14 0.
15s} Ne5 {0.73/15 0.23s} 21. Qe2 {-0.56/15 0.19s} Nxc4 {0.70/16 0.11s} 22. Qxc4
{-0.59/16 0.44s} g5 {0.70/16 0.11s} 23. f3 {-0.59/16 0.10s} f4 {0.84/14 0.18s}
24. exf4 {-0.94/16 0.74s} gxf4 {0.83/15 0.54s} 25. g4 {-1.22/14 0.38s} h5 {1.
00/15 0.10s} 26. gxh5 {-1.57/15 0.57s} Qxh5 {1.29/13 0.14s} 27. Qe4 {-1.67/14
0.14s} Bd4+ {1.37/12 0.10s} 28. Rxd4 {-1.33/12 0.22s} cxd4 {1.36/12 0.22s} 29.
Nb5 {-1.17/12 0.070s} Nxd5 {1.65/12 0.10s} 30. Bxd4 {-1.36/12 0.27s} a6 {2.25/
13 0.25s} 31. Nc7 {-2.09/12 0.19s} Rbc8 {5.36/14 0.42s} 32. Rc5 {-4.84/13 0.24s
} dxc5 {5.36/14 0.090s} 33. Nxd5 {-4.89/13 0.17s} cxd4 {5.53/13 0.090s} 34.
Nxe7+ {-4.98/11 0.16s, Black wins by adjudication} 0-1
[Event "cutechess_0.6.0+whitepov"]
[Site "?"]
[Date "2014.03.09"]
[Round "8"]
[White "new"]
[Black "base"]
[Result "1-0"]
[ECO "D82"]
[PlyCount "118"]
[EventDate "2014.??.??"]
[TimeControl "3"]

1. d4 {book} Nf6 {book} 2. c4 {book} g6 {book} 3. Nc3 {book} d5 {book} 4. Bf4 {
book} Bg7 {book} 5. Rc1 {book} Nh5 {book} 6. Bg5 {book} h6 {book} 7. Bh4 {book}
dxc4 {book} 8. e3 {book} Be6 {book} 9. Nf3 {0.22/12 0.25s} c5 {-0.05/11 0.24s}
10. Qa4+ {0.10/13 0.47s} Nd7 {0.38/11 0.16s} 11. Bxc4 {0.10/14 0.21s} Bxc4 {0.
14/13 0.10s} 12. Qxc4 {0.09/14 0.44s} Rc8 {0.08/13 0.21s} 13. Qa4 {0.09/14 0.
070s} cxd4 {0.08/12 0.19s} 14. Nxd4 {0.52/11 0.090s} O-O {0.27/12 0.10s} 15.
Rd1 {0.86/13 0.46s} Nc5 {0.12/12 0.080s} 16. Qxa7 {0.45/13 0.23s} Nf4 {0.38/13
0.10s} 17. exf4 {0.55/14 0.060s} Bxd4 {0.59/14 0.14s} 18. Qa3 {1.02/13 0.060s}
Ra8 {0.44/14 0.13s} 19. Qb4 {0.85/13 0.11s} Bxc3+ {0.44/14 0.080s} 20. Qxc3 {
1.05/14 0.13s} Qc7 {0.45/13 0.14s} 21. O-O {1.13/14 0.060s} Rxa2 {1.29/13 0.30s
} 22. Rfe1 {1.50/13 0.19s} Qxf4 {0.86/13 0.19s} 23. g3 {3.41/13 0.14s} Na4 {3.
51/13 0.12s} 24. gxf4 {3.69/13 0.070s} Nxc3 {3.64/14 0.10s} 25. bxc3 {3.83/14
0.060s} e6 {3.73/14 0.11s} 26. Bf6 {3.95/14 0.26s} b5 {3.73/14 0.070s} 27. Rd7
{4.16/14 0.050s} Rfa8 {4.32/13 0.23s} 28. Rb7 {4.26/12 0.060s} Kf8 {4.54/14 0.
33s} 29. Rxb5 {4.63/13 0.15s} Ke8 {4.63/15 0.16s} 30. Rb7 {4.66/14 0.050s} R2a7
{4.70/14 0.10s} 31. Reb1 {4.92/15 0.080s} Rxb7 {5.06/14 0.10s} 32. Rxb7 {4.92/
15 0.050s} Rc8 {5.57/15 0.29s} 33. Kg2 {5.04/16 0.050s} h5 {5.95/16 0.25s} 34.
Kf3 {5.85/15 0.11s} h4 {6.10/15 0.060s} 35. Re7+ {6.21/14 0.080s} Kf8 {6.10/16
0.060s} 36. Ra7 {6.20/18 0.050s} Ke8 {6.33/16 0.080s} 37. Kg4 {6.28/18 0.050s}
Rc5 {6.50/17 0.10s} 38. Re7+ {6.33/17 0.050s} Kf8 {6.36/19 0.050s} 39. Rd7 {6.
49/17 0.050s} Rc8 {6.92/18 0.070s} 40. Kxh4 {7.58/16 0.16s} Ke8 {6.84/19 0.12s}
41. Re7+ {7.74/15 0.050s} Kf8 {7.00/19 0.060s} 42. Ra7 {8.09/14 0.060s} Ke8 {
7.08/18 0.14s} 43. Be5 {8.43/13 0.060s} Rd8 {8.64/14 0.16s} 44. Kg5 {8.82/14 0.
050s} Rd2 {9.19/14 0.11s} 45. Kf6 {9.39/14 0.050s} Rxf2 {9.76/14 0.080s} 46.
Re7+ {10.30/14 0.050s} Kd8 {10.93/15 0.060s} 47. Rxf7 {11.69/15 0.050s} Kc8 {
11.67/15 0.050s} 48. Kxe6 {12.10/15 0.050s} Ra2 {11.93/14 0.050s} 49. Rc7+ {14.
87/14 0.060s} Kb8 {13.95/14 0.050s} 50. Rg7+ {16.63/14 0.050s} Ka8 {15.46/14 0.
050s} 51. Rxg6 {19.35/14 0.090s} Ra6+ {18.14/13 0.050s} 52. Bd6 {20.50/13 0.12s
} Kb7 {19.06/12 0.050s} 53. f5 {60.03/16 0.060s} Rc6 {19.84/11 0.050s} 54. f6 {
75.08/18 0.21s} Rxc3 {20.59/11 0.050s} 55. f7 {141.20/13 0.14s} Rf3 {63.40/16
0.050s} 56. f8=Q {#29/11 0.050s} Rxf8 {133.33/15 0.050s} 57. Bxf8 {#19/16 0.
060s} Kc6 {-#18/16 0.050s} 58. Rg5 {#15/17 0.040s} Kc7 {-#14/18 0.030s} 59.
Rc5+ {#13/19 0.050s} Kb6 {-#12/18 0.030s, White wins by adjudication} 1-0

Include halfmove clock and fullmove number in FEN

If an EPD file is used as an opening suite and the FEN strings don't have the halfmove clock and fullmove number fields, cutechess should add them to conform to the PGN standard.

This was originally suggested by Ferdinand Mosca.

libcutechess.dylib (and .so) not correctly linked

I cloned the git repo.

Qmake and make worked fine.

On Mac OS X, I then got the following problem:

Dyld Error Message:
Library not loaded: libcutechess.1.dylib
Referenced from: /Users/USER/*/cutechess.app/Contents/MacOS/cutechess
Reason: image not found

I copied libcutechess.* from cutechess/projects/lib to cutechess/projects/gui/cutechess.app/Contents/MacOS to make it work. Same issue was resolved on linux by copying libcutechess.so to the executable's folder.

I assume the Makefile should point to the correct library path?

Error building cutechess-cli with Qt 5.5.1 and Visual Studio 2015.

Here's the log.

21:08:51: Running steps for project cli...
21:08:51: Configuration unchanged, skipping qmake step.
21:08:51: Starting: "C:\Qt\Tools\QtCreator\bin\jom.exe" 
    C:\Qt\Tools\QtCreator\bin\jom.exe -f Makefile.Release
    cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -O2 -MT -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -I..\cli -I. -I..\lib\src -IC:\Qt\5.5\msvc2015_static\include -IC:\Qt\5.5\msvc2015_static\include\QtCore -I.moc -IC:\Qt\5.5\msvc2015_static\mkspecs\win32-msvc2015 -Fo.obj\ @C:\Users\Prcuvu\AppData\Local\Temp\main.obj.6484.16.jom
main.cpp
    cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -O2 -MT -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -I..\cli -I. -I..\lib\src -IC:\Qt\5.5\msvc2015_static\include -IC:\Qt\5.5\msvc2015_static\include\QtCore -I.moc -IC:\Qt\5.5\msvc2015_static\mkspecs\win32-msvc2015 -Fo.obj\ @C:\Users\Prcuvu\AppData\Local\Temp\cutechesscoreapp.obj.6484.32.jom
cutechesscoreapp.cpp
    cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -O2 -MT -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -I..\cli -I. -I..\lib\src -IC:\Qt\5.5\msvc2015_static\include -IC:\Qt\5.5\msvc2015_static\include\QtCore -I.moc -IC:\Qt\5.5\msvc2015_static\mkspecs\win32-msvc2015 -Fo.obj\ @C:\Users\Prcuvu\AppData\Local\Temp\enginematch.obj.6484.32.jom
enginematch.cpp
    C:\Qt\5.5\msvc2015_static\bin\rcc.exe -name doc ..\cli\res\doc\doc.qrc -o .rcc\qrc_doc.cpp
    cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -O2 -MT -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -I..\cli -I. -I..\lib\src -IC:\Qt\5.5\msvc2015_static\include -IC:\Qt\5.5\msvc2015_static\include\QtCore -I.moc -IC:\Qt\5.5\msvc2015_static\mkspecs\win32-msvc2015 -Fo.obj\ @C:\Users\Prcuvu\AppData\Local\Temp\matchparser.obj.6484.47.jom
matchparser.cpp
    C:\Qt\5.5\msvc2015_static\bin\moc.exe -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -D_MSC_VER=1900 -D_WIN32 -IC:/Qt/5.5/msvc2015_static/mkspecs/win32-msvc2015 -IC:/Users/Prcuvu/Source/Repos/cutechess/projects/cli -IC:/Users/Prcuvu/Source/Repos/cutechess/projects/lib/src -IC:/Qt/5.5/msvc2015_static/include -IC:/Qt/5.5/msvc2015_static/include/QtCore -I. ..\cli\src\cutechesscoreapp.h -o .moc\moc_cutechesscoreapp.cpp
    C:\Qt\5.5\msvc2015_static\bin\moc.exe -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -D_MSC_VER=1900 -D_WIN32 -IC:/Qt/5.5/msvc2015_static/mkspecs/win32-msvc2015 -IC:/Users/Prcuvu/Source/Repos/cutechess/projects/cli -IC:/Users/Prcuvu/Source/Repos/cutechess/projects/lib/src -IC:/Qt/5.5/msvc2015_static/include -IC:/Qt/5.5/msvc2015_static/include/QtCore -I. ..\cli\src\enginematch.h -o .moc\moc_enginematch.cpp
    cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -O2 -MT -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -I..\cli -I. -I..\lib\src -IC:\Qt\5.5\msvc2015_static\include -IC:\Qt\5.5\msvc2015_static\include\QtCore -I.moc -IC:\Qt\5.5\msvc2015_static\mkspecs\win32-msvc2015 -Fo.obj\ @C:\Users\Prcuvu\AppData\Local\Temp\qrc_doc.obj.6484.2438.jom
qrc_doc.cpp
    cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -O2 -MT -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -I..\cli -I. -I..\lib\src -IC:\Qt\5.5\msvc2015_static\include -IC:\Qt\5.5\msvc2015_static\include\QtCore -I.moc -IC:\Qt\5.5\msvc2015_static\mkspecs\win32-msvc2015 -Fo.obj\ @C:\Users\Prcuvu\AppData\Local\Temp\moc_cutechesscoreapp.obj.6484.2547.jom
moc_cutechesscoreapp.cpp
    cl -c -nologo -Zc:wchar_t -FS -Zc:strictStrings -Zc:throwingNew -O2 -MT -GR -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -EHsc -DUNICODE -DWIN32 -DLIB_EXPORT= -DCUTECHESS_CLI_VERSION=\"0.7.2\" -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -I..\cli -I. -I..\lib\src -IC:\Qt\5.5\msvc2015_static\include -IC:\Qt\5.5\msvc2015_static\include\QtCore -I.moc -IC:\Qt\5.5\msvc2015_static\mkspecs\win32-msvc2015 -Fo.obj\ @C:\Users\Prcuvu\AppData\Local\Temp\moc_enginematch.obj.6484.2563.jom
moc_enginematch.cpp
      /OUT:..\cli\cutechess-cli.exe @C:\Users\Prcuvu\AppData\Local\Temp\cutechess-cli.exe.6484.3719.jom
The filename, directory name, or volume label syntax is incorrect.
jom: C:\Users\Prcuvu\Source\Repos\cutechess\projects\build-cli-Qt_5_5_1_msvc2015_static-Release\Makefile.Release [..\cli\cutechess-cli.exe] Error 1
jom: C:\Users\Prcuvu\Source\Repos\cutechess\projects\build-cli-Qt_5_5_1_msvc2015_static-Release\Makefile [release] Error 2
21:08:55: The process "C:\Qt\Tools\QtCreator\bin\jom.exe" exited with code 2.
Error while building/deploying project cli (kit: Qt 5.5.1 (msvc2015_static))
When executing step "Make"
21:08:55: Elapsed time: 00:04.

Global Settings dialog

GUI needs a Settings dialog where the user can set the following options:

  • Concurrency for tournament games. It should always be possible to manually start a new game.
  • Default folder for chess engines
  • Enable/disable the black&white dots showing legal moves

Progress of default game and tournament settings can be followed in separate issues #82 and #83.

Pondering in GUI

Apparently the Init String field in the GUI cannot be used to set ponder.

Previous description:
How is ponder supposed to work? In a game with stockfish and ponder set, top shows only the current engine taking CPU/memory. If there is a misunderstanding, the documentation should clarify better. If stockfish does not support ponder (anymore) it should be clarified there.

Qt 5 support

Qt 5 is aiming for Q2 2012 release. Cute Chess needs to be updated to support Qt 5 (while retaining support for Qt 4).

Things that need fixing or review include:

  • #include files need to be updated (fixqt4headers.pl in Qt 5 can do this)
  • project files need revised version checks and new module definitions
  • documentation that both Qt 4 and Qt 5 are supported

polyglot limitation

If the bin books selected, exceed 500Mb combined, cutechess-cli will fail to start the match.

Pondering

Feature request: add pondering support.

For engine vs engine it is the latest 'big' feature missing.

PGN output doesn't support Shredder FEN

When "variant fischerandom" is activated, FEN string is stored wrong in the pgn output. The notation KQkq is always used (as in normal chess) instead of what should be GCgc in the example below.

When "-debug" is activated it can be seen that the fen string given to the engine is correct, also the castling moves work in the game, only the FEN string from the starting position saved in the pgn file is wrong (bold line).

In cutechess-cli 0.7.2 the bug does not occur.

[Event "?"]
[Site "?"]
[Date "2016.05.15"]
[Round "3"]
[White "stockfish_16051421_x64_modern"]
[Black "stockfish_16051421_x64_modern_copy"]
[Result "0-1"]
[FEN "bbrknnrq/pppppppp/8/8/8/8/PPPPPPPP/BBRKNNRQ w KQkq - 0 1"]
[PlyCount "55"]
[SetUp "1"]
[Termination "adjudication"]
[TimeControl "2.4+0.01"]
[Variant "fischerandom"]

  1. b4 {book} b5 {book} 2. d4 {book} d5 {book} 3. c3 {+0.16/13 0.074s}
    Nd6 {-0.33/12 0.072s} 4. Nd3 {+0.21/13 0.026s} Ne6 {-0.24/12 0.047s}
  2. Ne3 {+0.13/13 0.084s} O-O {-0.15/13 0.064s} 6. O-O {+0.06/13 0.062s}
    Nc4 {-0.18/13 0.048s}

Used version of cutechess is http://ilaripih.mbnet.fi/bin/cutechess-cli-linux64.tar.gz (binary download).

"About" dialog

CuteChess gui should have an "About CuteChess" dialog, just a simple one with the authors, copyrights and version numbers (CuteChess version and Qt version), and a clickable link to the cutechess Github page, perhaps also to cutechess.com.

Cannot compile

Two obvious fixes:

  • replace Q_UNREACHABLE() by Q_ASSERT(false). Q_UNREACHABLE and Q_ASSUME are not defined on my Qt 5 installation. I'm just using the normal Qt5 Ubuntu package.
  • knockouttournament.cpp line 299: return lines.join("\n"); use double quotes instead of single quotes (invalid conversion from char to const char *).

But even after fixing that, it still doesn't compiles. Next error:

qmake -config static && make -j 8
[...]
g++ -c -m64 -pipe -O2 -Wall -W -D_REENTRANT -DLIB_EXPORT= -DCUTECHESS_VERSION=\"unknown\" -DQT_NO_DEBUG -DQT_TESTLIB_LIB -DQT_SVG_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++-64 -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtSvg -I/usr/include/qt4/QtTest -I/usr/include/qt4 -I../lib/src -I3rdparty/modeltest -I.moc -Isrc -o .obj/enginemanagementdlg.o src/enginemanagementdlg.cpp
[...]
src/enginemanagementdlg.cpp: In member function ‘void EngineManagementDialog::removeEngine()’:
src/enginemanagementdlg.cpp:138:2: warning: lambda expressions only available with -std=c++11 or -std=gnu++11
  });
  ^
src/enginemanagementdlg.cpp:138:3: error: no matching function for call to ‘sort(QList<QModelIndex>::iterator, QList<QModelIndex>::iterator, EngineManagementDialog::removeEngine()::<lambda(const QModelIndex&, const QModelIndex&)>)’
  });
   ^

looks like you need to correct the makefile to enable c++11. I have no idea how the Qt compilation system works (seems very complicated), so I have no idea where to fix that.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.