-
Notifications
You must be signed in to change notification settings - Fork 29k
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
If there is a suggestions widget driven inline completion along with brackets and the user accepts it by hitting Tab, only the suggestions widget selection is accepted and the inline completion disappears #140176
Comments
cc @hediet |
Thanks for reporting this!
Can you log the requests to your inline completion provider and what it sends back?
With which extension? |
Hi Henning, I've included the text and range for each of the scenarios below. Scenario 1 and 3 are the same except 1 is in Python and 3 is in Typescript; 1 doesn't work correctly but 3 does. Do these text and range look right to you? This is with IntelliCode extension. Scenario 1 Scenario 2 Scenario 3 |
This I don't full understand. With prediction range you mean the range that is to be replaced? In that example, you are replacing 22 characters (56 - 34), but I think due to the complexity of this, I can help you better in a quick meeting. |
Adding discussions from our meeting last week so this issue is reopened by the bot. The current line is If the range to replace is set to char 34 - char 35, then the prediction does not show in grey text. If the range to replace is set to char 34 - char 34, then the prediction shows up but the brackets don't match |
Let's track that issue here: #141550 |
Sounds good! |
Does this issue occur when all extensions are disabled?: Yes
Version: 1.64.0-insider (user setup)
Commit: 9930557
Date: 2022-01-03T12:05:41.799Z
Electron: 13.5.2
Chromium: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Windows_NT x64 10.0.22000
Steps to Reproduce:
pandas_sample.txt
notnull
would be accepted and the(x)
would disappear.I suspect this has something to do with how the diff is calculated when brackets are present/autoclosed.
In Python, when the inline completion contains a paren and when the paren is autoclosed by VS Code, this is the behavior. Notice that first the brackets get matched with the inline completion and THEN the inline completion disappears.
If I delete the closing paren, the inline completion stays and works as expected including the Tab Tab behavior.
However, I don't see the same issue in TypeScript always, for example
The prediction stays even if the bracket is autoclosed by VS Code. What's different here is that there is a semi-colon at the end of the prediction so there is text after the closing bracket.
The text was updated successfully, but these errors were encountered: