mathworks / MATLAB-extension-for-vscode

This extension provides support for editing MATLAB® code in Visual Studio® Code and includes features such as syntax highlighting, code analysis, navigation support, and more.
https://marketplace.visualstudio.com/items?itemName=MathWorks.language-matlab
MIT License
234 stars 15 forks source link

Stuck on establishing connection (mlint) #82

Closed Div12345 closed 8 months ago

Div12345 commented 8 months ago

Describe the bug Extension stuck on MATLAB:Establishing Connection

To Reproduce Steps to reproduce the behavior:

  1. Start VSCode and this extension

Expected behavior Should be able to use MATLAB functionalities.

Screenshots If applicable, add screenshots to help explain your problem. MATLAB is stuck on this screen - image

Output -> MATLAB Language Server shows error in finding mlint executable

(18:34:32) matlabls: Launching MATLAB...
[Error - 6:34:32 PM] (18:34:32) matlabls - ERROR: Error finding mlint executable in C:\Program Files\MATLAB\R2023b\bin
[Error - 6:34:32 PM] (18:34:32) matlabls - ERROR: Error finding mlint executable in C:\Program Files\MATLAB\R2023b\bin

Useful Information

Additional context I searched for the mlint executable and found it in ..\bin\win64 Installed MATLAB is fully functional and works standalone.

dklilley commented 8 months ago

Hi @Div12345, it appears that the primary issue here is that MATLAB is attempting to launch the New Desktop experience. Unfortunately, the VS Code extension currently does not work with MATLAB when the New Desktop is enabled. The only workaround at this time is to disable the New Desktop. We are actively working to resolve this issue, and plan to release that in a future update. (This is tracked by #24)

The issue with mlint is a separate known issue where the mlint executable cannot be found on Windows. This is also something we are working to resolve in an upcoming release of the extension. I have created #83 to track this. Once the New Desktop has been disabled, you should have access to linting when MATLAB is connected - this issue only exists when MATLAB is not connected.