Not seeing auto import in quick fix prompt since v1.32.0.
megri opened this issue · comments
Note: To me this only happens in mill-bsp mode; Bloop seems to work as expected.
Activating auto complete or clicking the lightbulb for a quick fix in versions v1.31.0 and below will offer to add an import statement for a class if it's in the index and currently not imported.
From v.1.32.0+ this prompt will not display auto import.
To Reproduce Steps to reproduce the behavior:
I can reproduce this with the following setup
- Mill, version 0.11.7 (in
.mill-version
file) def scalaVersion = "3.4.1"
- Run the
Metals: Attempt to generate bsp config for build tool.
action — this puts vscode-metals into mill-bsp mode.
After this step a very simple program can be constructed:
@main def App() =
val x = ListBuffer
Attempting to quick-fix the ListBuffer symbol will trigger the behaviour.
![image](https://private-user-images.githubusercontent.com/1839427/331540259-9794445c-533b-4a35-a336-cebeb6866256.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjIzNzA2NDMsIm5iZiI6MTcyMjM3MDM0MywicGF0aCI6Ii8xODM5NDI3LzMzMTU0MDI1OS05Nzk0NDQ1Yy01MzNiLTRhMzUtYTMzNi1jZWJlYjY4NjYyNTYucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDczMCUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA3MzBUMjAxMjIzWiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MTFhYjM0OGI1MzM3M2MxNDlmZjIyMTYzYTViOTdkNjQ4MzFjNDgxMDZmZDVhZjFiMzE2YzRiNjEzMTk4MTdjNSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.DU0hIYB7XpKr5BJCKm6_EM91iEEqRx4OQ0rbBG9neWg)
Installation:
- Operating system: macOS
- VSCode version: 1.89.1
- VSCode extension version: 1.32.0+
- Metals version: default/not changed by me, but seems to be set to 1.3.0 rather than 1.3.1 🤔
Additional context
Search terms
mill bsp quick fix auto import
Looks like a change in Metals exposed an issue in Mill BSP. We can easily work around it, but in the long run I think it would be worth solving com-lihaoyi/mill#3165