GNOME Bugzilla – Bug 691031
gnome-chess ignores args specified in engines.conf - completely breaks gnuchess (PATCH)
Last modified: 2013-04-15 04:13:05 UTC
We don't pass --xboard to the gnuchess process, which means it sends non-CECP messages to gnome-chess until we send it the 'xboard' command. This means that its first messages will royally confuse gnome-chess, and the AI will never make its first move. So gnome-chess is currently completely broken when using the gnuchess engine. But if the AI somehow gets past that first move - say, by moving its piece for it, or by using the back and then forward buttons on the bottom of the screen, the game will continue to play fine. (Pressing 'forward' when the last move in the game was played by you sends the 'go' CECP command, forcing the AI to send a different move.) This argument is specified in engines.conf, so it used to work, but gnome-chess is now ignoring it.
Created attachment 232557 [details] [review] Proposed patch Proposed patch
It'd be great if this could be looked into, since gnome-chess is completely broken when using the gnuchess engine (tested with gnuchess v5.08) and my proposed patch is very short. Thanks :-)
Created attachment 237074 [details] [review] allow gnome-chess to use gnuchess Fix a whitespace error in the patch
Updated status to Blocker -- it's not reasonable to release gnome-chess again without gnuchess support. Tested on Fedora 17, Fedora 18 (gnuchess 5.08) and openSUSE 12.2 (gnuchess 6.0.1). Also added a link to the downstream bug
Created attachment 238163 [details] [review] Patch: properly pass extra-args to gnuchess (or other external engines) Thanks for the patch, I believe that vargs should still be NULL terminated after adding the args, so: + string[] argv = { binary, args }; In the patch should be: + string[] argv = { binary, args, null }; I'm attaching a new version with this fixed. A note to the upstream gnome-games / glchess maintainers. I've added this patch to the Fedora packages of gnome-games as this bug is making glchess unusable in single player mode, please apply it upstream.
Good catch Hans, thanks!
Well I noticed today that GNOME Chess worked fine with GNU Chess in openSUSE 12.3. So I did a bit more investigation, wrote a short report, and accidentally deleted it (apparently Google Drive's awesome autosave doesn't work unless you first save it manually). So here's the very short version of the report: * GNOME Chess with GNU Chess was broken on openSUSE 12.2 due to a bug in GNU Chess 6.0.1, which is not our fault or concern. * GNOME Chess with GNU Chess was broken on Fedora 18 due to this bug, as discussed above. * You'll only hit this bug if you're using GNU Chess 5.08, as in Fedora 18. Due to changes in GNU Chess's output, v5.07 (Ubuntu 12.04) and v6.0.2 (Ubuntu 12.10, openSUSE 12.3) aren't affected. * We still need to integrate the patch, but I'm dropping the severity accordingly.
Review of attachment 238163 [details] [review]: LGTM