Skip to content
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

Tab autocomplete while indenting #2987

Open
3 tasks done
seliquity opened this issue Nov 19, 2024 · 1 comment
Open
3 tasks done

Tab autocomplete while indenting #2987

seliquity opened this issue Nov 19, 2024 · 1 comment
Assignees
Labels
area:autocomplete Relates to the auto complete feature ide:vscode Relates specifically to VS Code extension kind:bug Indicates an unexpected problem or unintended behavior "needs-triage"

Comments

@seliquity
Copy link

Before submitting your bug report

Relevant environment info

- OS: macOS
- Continue version: v0.8.5
- IDE version: VSCode 1.95.2 
- Model: Codestral

Description

The tab button generates autocompletes, but often conflicts when I'm trying to indent. A simple example would be if I had the following line:

result = example->model()->bunch()->of()->calls();

But I'm refactoring to make it look like this:

result = example->model()
    ->bunch()
    ->of()
    ->calls();

If I move my cursor to the end of "model()" on the original line and hit enter, then it'll look like this:

result = example->model()
->bunch()->of()>calls();

In this state, Continue will often generate an autocomplete, which is immediately applied when I hit tab to indent that second line. This feels like a footgun, since it's applying suggestions I don't want and I have to be on guard to prevent them.

I don't think Continue should generate an autocomplete if both of the following are true:

  1. there is only whitespace before the cursor
  2. There is a character immediately after the cursor

I think those two rules definitely identify an indent scenario, although to be honest I'm not sure why you'd want a suggestion if there's text immediately after the cursor in any situation.

To reproduce

No response

Log output

No response

@dosubot dosubot bot added area:autocomplete Relates to the auto complete feature ide:vscode Relates specifically to VS Code extension kind:bug Indicates an unexpected problem or unintended behavior labels Nov 19, 2024
@Patrick-Erichsen
Copy link
Contributor

Appreciate the feedback here @seliquity ! @tomasz-stefaniak has been making a ton of improvements to autocomplete recently, cc'ing him here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:autocomplete Relates to the auto complete feature ide:vscode Relates specifically to VS Code extension kind:bug Indicates an unexpected problem or unintended behavior "needs-triage"
Projects
None yet
Development

No branches or pull requests

2 participants