-
Notifications
You must be signed in to change notification settings - Fork 39
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
Doesn't seem to update with treesitter playground #35
Comments
yeah, I haven't managed to get it to work properly in neovim yet. For me it produces lots of errors and has problems with newlines. Do you get any errors? Haven't tried it in a month, I'll investigate with the latest masters. |
No errors or anything like that I'm afraid. I'm happy to do any debugging, just let me know how! |
that's great, maybe these problems were fixed recently. import Foo.Bar
import Foo.Bar is the second line highlighted? or if you don't have highlighting, what's the tree displayed by playground? |
hm! it definitely looks better than previously. I will investigate. |
Thanks!
…On Thu, 27 May 2021, 11:53 pm Torsten Schmits, ***@***.***> wrote:
hm! it definitely looks better than previously. I will investigate.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGRJXF6W4DRPSVJY4PLSJTTPZTF5ANCNFSM45T2LRNQ>
.
|
so I gave it a try and it still suffers from the same problem I saw before, that when e.g. two import statements are in successive lines, the second one is skipped. Then I added some code below the imports, and none of that was highlighted/shown in the playground, until I deleted one of the imports, which triggered an update. So that might be similar behaviour to what you described. In any case, my guess is that this is still a problem with nvim, I think we'll need to wait for it to be stable, since the parsing itself works fine. Unfortunately, I haven't figured out how to reproduce these issues with the tree-sitter cli. |
Sounds good to me!
Is it worth opening an issue on neovim? (I don't think I understand what's
going on well enough to do that myself however)
…On Sat, 29 May 2021, 3:17 am Torsten Schmits, ***@***.***> wrote:
so I gave it a try and it still suffers from the same problem I saw
before, that when e.g. two import statements are in successive lines, the
second one is skipped.
Then I added some code below the imports, and none of that was
highlighted/shown in the playground, until I deleted one of the imports,
which triggered an update. So that might be similar behaviour to what you
described.
In any case, my guess is that this is still a problem with nvim, I think
we'll need to wait for it to be stable, since the parsing itself works
fine. Unfortunately, I haven't figured out how to reproduce these issues
with the tree-sitter cli.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGRJXHWHOXJ3PVYTQABRLDTP7ORHANCNFSM45T2LRNQ>
.
|
there's this issue nvim-treesitter/nvim-treesitter#1201 pertaining to a certain error reported by TS while editing which I also experience, and it seems likely to me that it's the cause of what's happening here (the error is "end_col out of range", which fits with the fact that consecutive lines are alternatingly not highlighted, something with the newlines). I suspect that in order for an issue on neovim to be successfully processed this might be too vague of a situation |
How are you seeing these error messages? I seem to get nothing printed from nvim. FWIW I tried with different line endings with no difference. |
Could the error message actually be legit and the parser is returning an
out of bounds character?
…On Sat, 29 May 2021, 8:15 pm Torsten Schmits, ***@***.***> wrote:
[image: image]
<https://user-images.githubusercontent.com/2632/120069809-1d06c400-c088-11eb-8ad3-221e80864433.png>
happens after doing a few edits.
I experimented with different newline chars as well in the tests.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#35 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGRJXF6SGOQMQ7CBY2UGV3TQDLEDANCNFSM45T2LRNQ>
.
|
I debugged this with the scanner in tests but haven't been able to find anything out. Anyway, since this exact error message is the topic of said issue, I hope its fix will improve this. |
@tek does this problem only happen with nvim or does it also happen with tree-sitter's wasm playground? |
@theHamsta I haven't seen that! Can you link me? |
I couldn't find the docs for it. Everytime I look for it I compile it by trial and error
|
thanks! I'll investigate the problem with that. |
It seems to miss the updates also with the web-ui |
guess that answers #32 (comment) as well, @maxbrunsfeld . Question is now, how do we create a minimal reproducer from this? Does the web ui provide some additional insights? |
I usually use tree-sitter CLI built from the master branch and found that there may be problems with starting the local playground due to collision of tree-sitter versions and if to be more concrete due to wasm components collision.
The tree-sitter CLI binary ships by itself another binary It seems the reason that local playground may fail to start is that I've thought before about proposals:
@maxbrunsfeld Could you tell what do you think about above thoughts? |
@ahlinc ... Nailed it. The issue I was having in #1155 was resolved by installing emscripten 2.0.11 and rebuilding the parser to wasm. Still have a few issues (such as errors not being displayed in the document), but that's more likely something with the extension and not tree-sitter itself. Thanks! |
This might be an issue with the playground. It only seems to update when `highlights.scm is present https://nvim-treesitter.zulipchat.com/#narrow/stream/252338-help/topic/Hot.20Reparsing.20with.20Custom.20Parsers/near/244874972 |
Seems to be fixed now, perhaps due to 9c1fd42? |
@expipiplus1 No, the bug is that the playground won't update when there are not highlighting queries. |
FYI my issues disappeared when nvim 0.5 was released. |
@expipiplus1 can this be closed? |
Yes! Thanks! |
Firstly: It's fantastic to see this working with Haskell!
I notice that with treesitter playground things don't seem to be updating (and I assume that this indicates a deeper problem)
Here's a recording of me editing a C file and a Haskell file, demonstrating the difference in experience:
https://asciinema.org/a/J38cw04yWrtdxFYfjWPwZXAvd
I'm using neovim master (as of today) and treesitter 0.19.5
The text was updated successfully, but these errors were encountered: