-
Notifications
You must be signed in to change notification settings - Fork 149
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
Improve the statusbar indicator #85
Comments
Really awesome stuff! I'll take a closer look at the nuts and bolts when I get a chance. Some things that jump out at me:
|
Also, we need to check if the virtual document/connection is still open, as when opening a notebook initially it has "plain" mimetype and only after kernel is loaded it changes (thus we get two virtual documents - the plain one sticks up there for some time and due to my policy of not destroying websockets/virtual documents immediately to keep overhead low for users having interspersed python and R cells - which would end up in a disaster once they start refactoring). Here is the problem captured: Re icons and design stuff: all great ideas; i would go for two indicators as you suggest - one for overall LSP condition and second one for the LSP features - those could be two icons + some text; those could even have separate pop-ups/click actions. Stacking languages vertically in the pop-up is certainly a good idea. Do you think that someone from the core JupyterLab team would be interested to take a look at what we are doing in here and provide some guidance? |
Also, we need to check if the virtual document/connection is still open,
as when opening a notebook initially it has "plain" mimetype and only after
kernel is loaded it changes (thus we get two virtual documents - the plain
one sticks up there for some time and due to my policy of not destroying
websockets/virtual documents immediately to keep overhead low for users
having interspersed python and R cells - which would end up in a disaster
once they start refactoring).
To the earlier point, I think we just want zero to one websocket per
language, which opens when asked for and stays open until closed
explicitly, with the server staying up even after browser closing, similar
to how kernels work.
Here is the problem captured:
[image: Screenshot from 2019-10-31 13-39-49]
<https://user-images.githubusercontent.com/5832902/67953302-c359c180-fbe6-11e9-828f-61e07cfda394.png>
.
Re icons and design stuff: all great ideas; i would go for two indicators
as you suggest - one for overall LSP condition and second one for the LSP
features - those could be two icons + some text; those could even have
separate pop-ups/click actions.
I think one number, one icon, and the language words are about all the real
estate we can take... And that's a lot. It's going to end up like the old
notebook toolbar down there, if everyone takes that much, so we have to
deliver a lot of value.
We could even cut down on words with language icons: there are some
consistent language icons coming down the pipe on some other work, though,
so it's probably best to stick with words for now.
Do you think that someone from the core JupyterLab team would be
interested to take a look at what we are doing in here and provide some
guidance?
For what it's worth, I have commit rights over there, and a fair number of
contributions in. The steps in #76 are what I consider the bare minimum
before we should even propose the work to the broader developer community
(e.g warm up the JEP). At that point, we could likely get it added to the
lab org, which would be good marketing.
Luckily, in this community, code wins: if it looks like core, is
documented, tested, extensible, and generally useful to the whole range of
users, there's no reason we shouldn't be able to get it in. The biggest
strike against it is the undesirable externality of requiring more things
we can't control (language servers) but there's many developer years locked
up in all those servers that the jupyter community won't have the time to
reproduce: if you can't beat them, integrate them!
This work would almost certainly have to land at a major release, and it is
unlikely we will be able to have this be bullet-proof, production ready by
2.0 (dec-jan). We could start maintaining/testing a branch against the lab
2.0 branch, but again, that won't be in anyone's hands for some time.
So continuing
to mature the code as an extension is a very good path indeed.
… |
Current design for the popoverI was thinking about listing connections grouped by LSP servers (this usually makes sense) like this:
where:
In addition, specific features will be able to:
For example:
where
having the linters messages summary in the status bar makes sense:
|
Looking good, thanks for taking the time to make some ASCII art! It's very therapeutic. My general guidance (with an eye towards getting this into lab) is we should try:
Specifics: popovers: running: status bar: gutters: packaging:
installation: |
@ellisonbg, @tgeorgeux - I've tried to do some ASCII design for JupyterLab-LSP statusbar. We have some interesting discussion here - if you are interested in chiming in you are more than welcome! |
Here's a self-contained, awful example, which nonetheless could be implemented (much better) in react... or d3... or...
My point about all the APIs and interfaces and packages is, if someone wanted to make I'm not suggesting a full refactor of everything (well, I am, eventually on #76), merely starting new features (like #98) as new packages if they will have worth to a downstream.
Ha, despite working in lab most of the time (at least on certain projects), because I don't use the status bar, I didn't know that! I'm just saying, it is hard to test them, and they are completely unreachable with the keyboard. Anyhoo... in the language picker case, it is like a traditional menu (you pick a thing from many, it goes away). The ascii mockup has multi-level, collapsible tree control of potentially tens of items, and a number of icons close to the edge of the box.
I know, right?
That (finally) got promoted to a user-level choice (right click ->
there's always something we won't have thought of that will make it worse. |
Another use case for quick "disable lsp for this document" button (in addition to slow node indexing): I get to work with some scripts written years ago which are full of yellow/red underlines due to the use of python2, two spaces for indent and other things from before pep8. |
Follow up on #78:
The text was updated successfully, but these errors were encountered: