From a083c5d4dd6c6effcc1d7487fb690a7073389cdc Mon Sep 17 00:00:00 2001 From: Sandro Date: Wed, 25 Jun 2025 17:55:44 +0200 Subject: [PATCH] Adapt conditional for Python 3.14 As of Python 3.14 `ast` will lack `_const_node_type_names`. --- rope/base/ast.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rope/base/ast.py b/rope/base/ast.py index eeed6fe84..16c44da4a 100644 --- a/rope/base/ast.py +++ b/rope/base/ast.py @@ -9,7 +9,7 @@ from ast import _const_node_type_names # type:ignore except ImportError: # backported from stdlib `ast` - assert sys.version_info < (3, 8) + assert sys.version_info < (3, 8) or sys.version_info >= (3, 14) _const_node_type_names = { bool: "NameConstant", # should be before int type(None): "NameConstant",