From 5d3ddf7060c35e4174e4c03b1660729db71ec9b2 Mon Sep 17 00:00:00 2001 From: dalthviz Date: Mon, 19 Dec 2022 14:34:11 -0500 Subject: [PATCH] Prevent Python variable validation to get current word and position when doing completions --- spyder/widgets/mixins.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spyder/widgets/mixins.py b/spyder/widgets/mixins.py index ee968ec2295..5b537a0f623 100644 --- a/spyder/widgets/mixins.py +++ b/spyder/widgets/mixins.py @@ -1083,7 +1083,7 @@ def is_special_character(move): startpos = cursor.selectionStart() # Find a valid Python variable name - if valid_python_variable: + if valid_python_variable and not completion: match = re.findall(r'([^\d\W]\w*)', text, re.UNICODE) if not match: # This is assumed in several places of our codebase,