From a0171573bb72552bcdf2eddaeb60b1e5260de34c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edouard=20Choini=C3=A8re?= <27212526+echoix@users.noreply.github.com> Date: Mon, 23 Dec 2024 15:08:13 +0000 Subject: [PATCH] LiteralString is only available since Python 3.11, so use str instead --- gui/wxpython/core/gcmd.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gui/wxpython/core/gcmd.py b/gui/wxpython/core/gcmd.py index d6a7dda96c1..f7e3c3ab698 100644 --- a/gui/wxpython/core/gcmd.py +++ b/gui/wxpython/core/gcmd.py @@ -36,7 +36,7 @@ import time import traceback from threading import Thread -from typing import TYPE_CHECKING, LiteralString, TextIO +from typing import TYPE_CHECKING, TextIO import wx from core.debug import Debug @@ -313,7 +313,7 @@ def _recv(self, which, maxsize): message = "Other end disconnected!" -def recv_some(p, t=0.1, e=1, tr=5, stderr=0) -> LiteralString: +def recv_some(p, t=0.1, e=1, tr=5, stderr=0) -> str: # TODO: use LiteralString on 3.11+ tr = max(tr, 1) x = time.time() + t y = []