-
Notifications
You must be signed in to change notification settings - Fork 116
Description
Implement auto-completion support
Plan
At time of writing (2025-05-02), the plan below represents my best effort guess as to how we want to proceed here. The first few items are meant to correspond to lower hanging fruit.
One thing that is not really captured by the plan here, but I think may require some effort, is figuring out how best to identify what the current context is. I suspect there may be an easy way to start for specific cases, but the extent to which that works more generally is not totally clear to me yet.
- Add built-ins to code completions.
- Return all names from scopes in current module. ref
- Identify current scope and return names from just that scope.
- Identify a
Object.<typing>
context and return attributes onObject
. - Identify a
from module import <typing>
context and return items frommodule
. - Identify
import <typing>
andimport module.<typing>
contexts and return available modules. - [BETA] Identify function call sites and offer keyword based completions (if available).
- [BETA] Add type signatures to completion suggestions
- [BETA] For scope based completions, offer unimported symbols as suggestions. (And upon selection, add the required import.)
- Offer string literals based on type context.
- Offer string literals based on
TypedDict
context. - Offer contextual language keywords in completions (e.g.,
def
andmatch
). - Offer completions for cases in
match
statements.
groig, xbjfk, godalming123, FelipeCybis, smalash and 24 moreWayenVan and sdieboltgodalming123, lithammer, anstadnik, moucha19, orishamir and 2 more
Sub-issues
Metadata
Metadata
Assignees
Labels
serverRelated to the LSP serverRelated to the LSP server