PyCharm 2023.3.2 editor completion insanely aggressive
After a recent upgrade (perhaps just before this 2023.3.2?) the autocompletion became so aggressive that I have had to completely disable it (via Settings > Editor > General > Code Completion and then deselecting “Show suggestions as you type”).
As an example, if I open up a Python console, I can type “1+1”, hit Return, and get 2; but I can't type “‘foo' in bar” because the editor autocompletes ‘in’ to ‘int’. It was either throw the abovementioned knife switch for suggestions so that they entirely went away, or typing something like “'foo' qin bar<left arrow><left arrow><left arrow><left arrow><left arrow><left arrow><backspace>" so that at no time is there any autocompletion for what I am typing.
It didn't used to be this way.
I've turned off all the “AI-Powered” [sic] plugins. The only plugins I've manually activated are .ignore and Protocol Buffers.
Is there a way to get back to where I can have even a little completion? As in, I am typing a long variable name and I'm presented with alternatives but if I just keep typing, and there are no matches, they go away without my ever having to have changed my flow of work? And that if there *IS* a match, that I can either Tab or <down Arrow> some number of times, then Tab, to go with that match?
请先登录再写评论。
When I press the space key, it accepts the topmost offered completion, rather than rejecting it. For example, if I am at the prompt, and I type an ‘x’ and a space, as fast as I can (so, let's say, under 100ms), I am left with ‘exec ’ (note trailing space).
Is there some way in which it could be interpreting a space as a tab for the purposes of completion, but not in other contexts? That's what it acts like.
I did find another workaround, which is to hit ESC ESC every time I type something that is a left substring of any possible completion.
Would there be any configuration file that I might send you that would help identify the source of this issue?
Thank you.
I just created a new project, and by default, spacebar-completion is NOT checked. That is good (at least, it is for me).
I really do not remember ever going to that preference settings group and clicking that checkbox. Of course, I could have done it and completely forgotten, but: is there any key combination I could have mis-typed at any point that would result in that checkbox being checked? In particular is there anything I could have typed when presented with an alternative completion that would have resulted in that checkbox being checked?
And I do appreciate your rapid turnaround on this thread as a support issue.
It would be nice to disable “Return” as accepting the suggestion. “Tab” is already assigned to it. The best would be to have a modifiable keybinding instead of click box. The idea to remove “space” and “return" and possibly even “tab” is that those are commonly used while typing code.
I would personally map it to ctrl+space or ctrl+tab, or ctrl+enter. Logically, there is no reason why a single key press should be the solution here, especially since IntelliJ is lightinging fast (good job there).
Clearly those are not the keybinding being applied:
THIS!!! I've been using PyCharm since 2014 and the autocompletions are just totally insane now. I used to LOVE them! But it seems unusable now… I'm just hitting ESC the entire time I type, or shutting it off completely. They appear so fast that I can't even finish the thought I'm having--I have to look at the suggestion, process that it's wrong, hit ESC and keep going. I did the trial of the AI assistant and it's ok, but I would never have it on all the time. Tried Copilot, too, but don't want it on all the time either.
The standard suggestions from a few months ago were great but I guess those are gone forever…
I agree the code completions are out of hand. Most of its suggestions are wrong, but the worst part is that the default key for accepting a suggestion is Tab, which is regularly used in coding. This leads to accepting LOTS of bad suggestions.
This appears to be from Editor→General→Code Completion→Machine Learning-Assisted Completion→Enable Full Line Suggestions (note that this feature is only present in PyCharm Pro, not CE).
Disabling the feature helped, & it reverted back to simple code-completion suggestions for me (like finishing a partially-typed variable name). For those that like the feature, I'd recommend at least changing the keybinding from Tab to something less commonly used (in settings search “Insert Inline Proposal”, right-click→remove Tab, right-click→Add Keyboard Shortcut).
Same here running 2023.3.5. Ever since I upgraded to this version, the code auto completion is super aggressive and annoying. Manytimes I had to completely undo and restart my code blocks as it completely changed my code. I just cant hit tab for any auto suggestion as it picks a completely unrelated auto suggestion. I am going to disable it.
Thank you @Mwilmanski !!!
This was driving me crazy. Autofilling on a tab on a new blank line is not helpful, ughh!
I have a related problem: PyCharm looks in the whole project to potential candidates and it leads to a very high number of matches which is kind of useless, for instance if we type df, which is quite comment when doing machine learning, I get df_list a dozen times, yet, it's just a subset of the full set of matches. Is there a way to turn this off, it is really useless. I disabled otherwise the machine learning one.