From 8d2a08637cadd1ba3402970edf83145c097c35dd Mon Sep 17 00:00:00 2001 From: Thibault Duplessis Date: Sun, 29 Apr 2018 03:55:59 +0200 Subject: [PATCH] Revert "Revert "ignore #0 at ceval client level"" This reverts commit 603f5d91447ad02d0fcad5c416a3ef3e3c6d2b18. https://lichess.org/forum/lichess-feedback/mate-in-zero --- ui/ceval/src/stockfishProtocol.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ui/ceval/src/stockfishProtocol.ts b/ui/ceval/src/stockfishProtocol.ts index d4d5c56d28..8cd8d66fd7 100644 --- a/ui/ceval/src/stockfishProtocol.ts +++ b/ui/ceval/src/stockfishProtocol.ts @@ -64,6 +64,9 @@ export default class Protocol { elapsedMs: number = parseInt(matches[7]), moves = matches[8].split(' '); + // Sometimes we get #0. Let's just skip it. + if (isMate && !ev) return; + // Track max pv index to determine when pv prints are done. if (this.expectedPvs < multiPv) this.expectedPvs = multiPv;