-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable auto-adding brackets/parentheses on completion #14307
Comments
Hi @TBSenseo I think to prevent that you will need to uncheck the |
Thanks @dalthviz. This seems to have solved my problem. I understand "snippets" as being prepared code blocks that can be inserted quickly and then filled with in-situ variable names, etc, like the insertion of "if <condition> <code> else <else code>" snippets in Visual Studio. Maybe rename the configuration item to "Append function prototype parameters to completed terms". What is your thought of my suggestion? |
Hi guys! Happy to join the discussion! Thanks! |
Hey @la-foglia, yes, there is a way to do that (and we consider the current behavior a bug). We'll try to fix it in a future release. |
I am using Spyder 4.2.0 in Python 3.7.8 on Windows installed via pip without Kite and such the default completion configuration (upgraded to most recent versions) with the python language server (0.36.1) and Rope (0.18.0) enabled (options "Enable code completion", "Show completion details", "Show completions on the fly", "Enable code snippets" enabled in the Completion and linting section in the Preferences.
When I choose any suggestion from the auto-completion list, the editor always adds brackets and the required parameters after the completed term independent on in if it is a variable, a function or a class. This is annoying since I kind of always delete the brackets and parameters afterwards due to various reasons (brackets after variables are not allowed, for function calls and class constructor calls I like to type the opening bracket myself and then add the various arguments myself following the displayed calltips from the Introspection feature and for type hints (": ") brackets are not allowed, too).
Can you please either disable auto-adding the brackets and required parameters for term completion or add an option to disable/enable it like it was before in Spyder 3.
This ticket seems to be related to what we had in issue #2602, but this was for the old version and it seems the code has changed a lot since then.
The text was updated successfully, but these errors were encountered: