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

Partial object members not completed correctly in WIP sequence #6796

Open
Willem-J-an opened this issue Dec 24, 2024 · 1 comment
Open

Partial object members not completed correctly in WIP sequence #6796

Willem-J-an opened this issue Dec 24, 2024 · 1 comment
Assignees
Labels
bug Something isn't working needs repro Issue has not been reproduced yet

Comments

@Willem-J-an
Copy link

Completion of partial object members does not work when editing a sequence, see below example.

from enum import Enum


class X(Enum):
    my_enum_member = 0

(
    X. # << Completion here shows my_enum_member
    "something else"
)
(
    X.my_enu # << Completion here shows nothing
    "something else"
)
(
    X.my_enu, # << Completion before comma shows my_enum_member
    "something else"
)

I understand that if there's no comma written, the syntax is not valid, but when replacing something in a sequence it may occur that the new separator is not written until after writing the member. Additionally, it does work for the full completion, when there is no partial member name written yet. It seems inconsistent that it works for full completion, but not partial. A typical workflow for me would be to type until the completion is correct, and that workflow does not work in this case.

@Willem-J-an Willem-J-an added the bug Something isn't working label Dec 24, 2024
@erictraut
Copy link
Contributor

The logic for completion suggestions within pyright is owned and maintained by the Microsoft pylance team.

Could someone from the pylance team please transfer this issue to the pylance-release project and triage / prioritize it as you see fit? Thanks! @rchiodo, @debonte

@debonte debonte transferred this issue from microsoft/pyright Dec 24, 2024
@github-actions github-actions bot added the needs repro Issue has not been reproduced yet label Dec 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs repro Issue has not been reproduced yet
Projects
None yet
Development

No branches or pull requests

3 participants