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

Scala intellisense in Scala paragraphs + general latency issues #12

Open
zzhu8192 opened this issue Apr 7, 2024 · 4 comments
Open

Scala intellisense in Scala paragraphs + general latency issues #12

zzhu8192 opened this issue Apr 7, 2024 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@zzhu8192
Copy link

zzhu8192 commented Apr 7, 2024

Really fantastic project! There's not a whole lot of support for Zeppelin out there these days, so it's really great to see someone working on this

A couple of things I'm seeing:

  • For Scala based paragraphs, even when I select "Scala" as the Language at the lower right, intellisense doesn't seem to work. Not sure if that's the intent? (I do have Metals installed, and on Scala projects, intellisense does work). This works for Python based paragraphs, which is really nice.

  • In general, the response gets back to VSCode on the average about 5 seconds after running the paragraph. I can see that on the Zeppelin server side, the result was rendered in well under 1 second. Why is there such a long delay? I'm running zeppelin locally so there's little to no network latency at all.

@allen-li1231
Copy link
Owner

allen-li1231 commented Apr 7, 2024

Hi, @zzhu8192

  • For Scala based paragraphs, even when I select "Scala" as the Language at the lower right, intellisense doesn't seem to work. Not sure if that's the intent?

From my end, the Scala intellisense looks just fine, I tried some example code:
Screenshot 2024-04-07 at 11 31 53 AM
Would you like to be more specific to the problem you've encountered?

  • In general, the response gets back to VSCode on the average about 5 seconds after running the paragraph.

I did notice the same 5 seconds delay from my end. In short, the extension is built upon Zeppelin REST API. The delay is not caused by extension, It is the server side that blocks the request when calling paragraph execution asynchronously.
However, the latency seems to go away when I tested the synchronous execution API to execute paragraphs. The extension applies the asynchronous one by default, you may switch between the two APIs in settings:
Screenshot 2024-04-07 at 12 14 36 PM

@zzhu8192
Copy link
Author

zzhu8192 commented Apr 8, 2024

Thanks for the response @allen-li1231 !
I tried the sequential access setting, and that works great!

In terms of the scala intellisense, here's a screenshot of what I'm seeing.
Note that, Zeppelin by default doesn't support %scala paragraph, so I'm using %spark, which is supported by default.
But the intellisense I'm getting is not the same that I'd get in Metals on a proper SBT/Maven project.
image

@allen-li1231 allen-li1231 self-assigned this Apr 8, 2024
@allen-li1231 allen-li1231 added the bug Something isn't working label Apr 8, 2024
@allen-li1231
Copy link
Owner

allen-li1231 commented Apr 8, 2024

Confirmed the discrepancy. I will look into that, by far I cannot tell whether the extension is responsible for this, it is possible that the language server simply does not work with codes in cell, thanks for the screenshot!

@allen-li1231
Copy link
Owner

It seems that metals support for notebook has bee halted, related PR: scalameta/metals#4253
So the metals currently do not officially support notebook, and the team is putting this in feature request: scalameta/metals#707
I am currently looking for workaround.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants