Enhance quick suggestions with inline completions#300371
Merged
Conversation
…ggering when inline provider returns no results
… completions are active
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adjusts the editor’s quick-suggest (“quickSuggestions”) behavior to cooperate better with inline completions: quick suggestions should not be permanently suppressed just because an inline completions provider exists, and should instead be suppressed only when inline completions are actually showing.
Changes:
- Update
SuggestModelto wait for inline completions to resolve (whenoffWhenInlineCompletionsis configured) and only trigger quick suggest if inline completions end up not showing. - Prevent inline completions from reacting to suggest-widget selection when
offWhenInlineCompletionsis active, to avoid feedback loops/conflicts. - Update configuration descriptions and expand test coverage for the new behavior.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| src/vs/editor/contrib/suggest/browser/suggestModel.ts | Implements “wait for inline completions, then decide” logic for offWhenInlineCompletions. |
| src/vs/editor/contrib/suggest/test/browser/suggestModel.test.ts | Updates existing tests and adds coverage using InlineCompletionsController scenarios. |
| src/vs/editor/contrib/inlineCompletions/browser/model/suggestWidgetAdapter.ts | Suppresses exposing selected suggest items to inline completions under offWhenInlineCompletions. |
| src/vs/editor/common/config/editorOptions.ts | Adjusts the user-facing descriptions for offWhenInlineCompletions. |
src/vs/editor/contrib/inlineCompletions/browser/model/suggestWidgetAdapter.ts
Show resolved
Hide resolved
src/vs/editor/contrib/suggest/test/browser/suggestModel.test.ts
Outdated
Show resolved
Hide resolved
justschen
approved these changes
Mar 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Improve the behavior of quick suggestions by allowing them to trigger only when inline completions are not active, and suppress suggestions when inline completions are being displayed. This change enhances the user experience by reducing unnecessary suggestions during inline completion scenarios.
Fixes #297224