-
Notifications
You must be signed in to change notification settings - Fork 229
Introduce Cursor/VS Code support #655
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
base: asf-site
Are you sure you want to change the base?
Conversation
pan3793
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having never experienced VS Code for Scala/Java projects previously, I have successfully used VS Code to import the Spark project by following the instructions, and confirmed that basic functionalities like code jump work as expected.
| - *Confirm Build Server*: Metals defaults to using Bloop as the build server. Do not change this setting, as Bloop provides the fastest compilation and best integration for local development. Open the Command Palette (Cmd+Shift+P or Ctrl+Shift+P), run `Metals: Run doctor`, and verify the status dashboard. Ensure it shows: `Build definition is coming from sbt` and `Build server currently being used is Bloop`. | ||
|
|
||
| If you encounter compilation errors or the IDE fails to recognize symbols, follow these steps to perform a clean import: | ||
| 1. *Stop Bloop Server*: Run the following command in your terminal to stop the bloop server: `pkill -f "bloop.BloopServer"`. If you have installed bloop CLI you can run `bloop exit` instead. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this equivalent to Metals: Restart server?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
metals server is different from bloop server.
|
|
||
| If you encounter compilation errors or the IDE fails to recognize symbols, follow these steps to perform a clean import: | ||
| 1. *Stop Bloop Server*: Run the following command in your terminal to stop the bloop server: `pkill -f "bloop.BloopServer"`. If you have installed bloop CLI you can run `bloop exit` instead. | ||
| 2. *Clean Workspace*: Run the following command in your terminal to remove cached build metadata: `rm -rf .bloop/ .metals/ .bsp/`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we need to rm ./project/.bloop too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't remove it and there is no issue. I checked a bit and this .bloop is only for building the sbt build definition, which is simply the SparkBuild.scala. It's unlikely to cause issues.
Cursor/VS Code is well supported now after apache/spark#53621 . This PR introduces the steps to use Cursor/VS Code.