From 6653d2c9ce3ce4bff707c98cea96faf02092112d Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Wed, 18 Sep 2024 16:59:51 -0400 Subject: [PATCH] Allow '.' in print expressions --- src/chatdbg/native_util/safety.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/chatdbg/native_util/safety.py b/src/chatdbg/native_util/safety.py index 66ae922..cfb70cb 100644 --- a/src/chatdbg/native_util/safety.py +++ b/src/chatdbg/native_util/safety.py @@ -28,6 +28,6 @@ def command_is_safe(cmd: str) -> bool: # Allowed conditionally. if command_name in ["p", "print"]: - return re.fullmatch(r"[a-zA-Z0-9_ *]*", cmd) is not None + return re.fullmatch(r"[a-zA-Z0-9_ *\.]*", cmd) is not None return False