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

LSP automatically should insert required imports when completing #1809

Closed
gak opened this issue Jun 17, 2024 · 1 comment
Closed

LSP automatically should insert required imports when completing #1809

gak opened this issue Jun 17, 2024 · 1 comment
Labels
duplicate This issue or pull request already exists extension Issues related to our VSCode extension triage Issue needs triaging

Comments

@gak
Copy link
Contributor

gak commented Jun 17, 2024

eg when there are no imports in the file, and you complete a verb, an import ( "context" ) would be added. Similar to ftl/builtin and "github.com/TBD54566975/ftl/go-runtime/ftl", and correctly appending imports to existing blocks.

I think this is possible with additionalTextEdits.

@gak gak added the extension Issues related to our VSCode extension label Jun 17, 2024
@github-actions github-actions bot added the triage Issue needs triaging label Jun 17, 2024
@ftl-robot ftl-robot mentioned this issue Jun 17, 2024
@alecthomas alecthomas added the duplicate This issue or pull request already exists label Jun 17, 2024
@alecthomas
Copy link
Collaborator

This is a bug and will be solved by #1662. Once that's done, the Go LSP will do the correct thing.

@alecthomas alecthomas closed this as not planned Won't fix, can't repro, duplicate, stale Jun 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists extension Issues related to our VSCode extension triage Issue needs triaging
Projects
None yet
Development

No branches or pull requests

2 participants