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

we should not suggest code completions for dartdoc comments #34747

Closed
devoncarew opened this Issue Oct 10, 2018 · 5 comments

Comments

Projects
None yet
4 participants
@devoncarew
Member

devoncarew commented Oct 10, 2018

Currently, we suggest completions in dartdoc comments. We should change this to not suggest for general dartdoc (but should still offer suggestions for symbol references in dartdoc, like [FooClass]).

screen shot 2018-10-10 at 12 56 20 pm

@scheglov

This comment has been minimized.

Show comment
Hide comment
@scheglov

scheglov Oct 10, 2018

Contributor

Please provide a code sample where it happens.
I cannot reproduce it locally.

1539203266397 => {"id":"13995","method":"completion.getSuggestions","params":{"file":"/Users/scheglov/Source/Dart/sdk.git/sdk/pkg/analyzer/lib/src/dart/element/inheritance_manager2.dart","offset":525},"clientRequestTime":1539203266397}
1539203266397 <= {"id":"13995","result":{"id":"672"}}
1539203266397 <= {"event":"completion.results","params":{"id":"672","replacementOffset":525,"replacementLength":0,"results":[],"isLast":true}}

But IntelliJ shows when I press Ctrl+Space.
image

It might be either a different situation where IntelliJ does try to be helpful, or I just don't use good code sample.

Contributor

scheglov commented Oct 10, 2018

Please provide a code sample where it happens.
I cannot reproduce it locally.

1539203266397 => {"id":"13995","method":"completion.getSuggestions","params":{"file":"/Users/scheglov/Source/Dart/sdk.git/sdk/pkg/analyzer/lib/src/dart/element/inheritance_manager2.dart","offset":525},"clientRequestTime":1539203266397}
1539203266397 <= {"id":"13995","result":{"id":"672"}}
1539203266397 <= {"event":"completion.results","params":{"id":"672","replacementOffset":525,"replacementLength":0,"results":[],"isLast":true}}

But IntelliJ shows when I press Ctrl+Space.
image

It might be either a different situation where IntelliJ does try to be helpful, or I just don't use good code sample.

@devoncarew

This comment has been minimized.

Show comment
Hide comment
@devoncarew

devoncarew Oct 11, 2018

Member

OK, I think this is IntelliJ (and separately, VS Code) being helpful in completions. I'll investigate some more and see if we can (and want to disable) the IDE's code completion in dartdoc comments (cc @alexander-doroshko @DanTup).

Member

devoncarew commented Oct 11, 2018

OK, I think this is IntelliJ (and separately, VS Code) being helpful in completions. I'll investigate some more and see if we can (and want to disable) the IDE's code completion in dartdoc comments (cc @alexander-doroshko @DanTup).

@devoncarew devoncarew closed this Oct 11, 2018

@DanTup

This comment has been minimized.

Show comment
Hide comment
@DanTup

DanTup Oct 11, 2018

Member

VS Code has a setting editor.wordBasedSuggestions which causes things like this. It's on by default, but it really sucks. I have an incomplete "recommended settings" page for the Dart Code website I keep meaning to finish (basically a list of what I would consider bad defaults!).

If it was VS Code where you saw this, it'd be good to know if disabling this setting fixes it for you.

Member

DanTup commented Oct 11, 2018

VS Code has a setting editor.wordBasedSuggestions which causes things like this. It's on by default, but it really sucks. I have an incomplete "recommended settings" page for the Dart Code website I keep meaning to finish (basically a list of what I would consider bad defaults!).

If it was VS Code where you saw this, it'd be good to know if disabling this setting fixes it for you.

@devoncarew

This comment has been minimized.

Show comment
Hide comment
@devoncarew

devoncarew Oct 11, 2018

Member

Yup, that fixed it for VS Code. We should recommend that setting :)

Member

devoncarew commented Oct 11, 2018

Yup, that fixed it for VS Code. We should recommend that setting :)

@DanTup

This comment has been minimized.

Show comment
Hide comment
@DanTup

DanTup Oct 15, 2018

Member

Cool; I've fleshed out the Recommended Settings page a little and pushed it to a branch for input before I merge -> https://github.com/Dart-Code/Website/pull/2/files

Member

DanTup commented Oct 15, 2018

Cool; I've fleshed out the Recommended Settings page a little and pushed it to a branch for input before I merge -> https://github.com/Dart-Code/Website/pull/2/files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment