From 25c5d99f8d9dcc16f7726c910a91b23999ce489d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Kore=C4=8Dek?= Date: Wed, 14 Sep 2022 19:51:19 +0200 Subject: [PATCH] =?UTF-8?q?Strategick=C3=A1:=20Oprava=20warning=C5=AF=20v?= =?UTF-8?q?=20klientovi?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- klient/client.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/klient/client.py b/klient/client.py index 8f1242e..5b125ba 100644 --- a/klient/client.py +++ b/klient/client.py @@ -73,10 +73,10 @@ def send_turn(turn: dict, round: int, args) -> bool: elif response["status"] == "error": logger.error(f"Turn error: {response['description']}") elif response["status"] == "warning": - member_errors = [ - f" {member}: {error}" - for member, error in response["errors"].items() + member_warns = [ + f" {member['id']}: {member['description']}" + for member in response["members"] ] - logger.error("Member errors:\n" + "\n".join(member_errors)) + logger.warn("Member warnings:\n" + "\n".join(member_warns)) return True