Trebor-Huang / vscode-forester

VSCode support for Forester
https://marketplace.visualstudio.com/items?itemName=treborhuang.vscode-forester
19 stars 1 forks source link

link suggestions don't find all links #1

Closed jonsterling closed 9 months ago

jonsterling commented 9 months ago

I am finding that only a small fraction of my trees are being presented as link suggestions. I have verified that I am querying the correct directories in the extension settings. Please let me know if there's anything I can do to help reproduce this issue.

Trebor-Huang commented 9 months ago

Hmm, does the json dump contain the entries you want? If so it's probably some suggestion number cap of VSCode. I'll dig the documentation and see if there's anything..

jonsterling commented 9 months ago

Yes, when I run the command forester query command that the extension is configured with, all the trees are dumped. What I am finding is that almost none of my trees except the bibliographic ones are being suggested by the extension, however.

Trebor-Huang commented 9 months ago

I can't reproduce this even with 10000 trees. Could you provide the dumped json with sensitive information removed? A reproducing trees directory is even better.

jonsterling commented 9 months ago

I will double check when I get a chance, but it should be possible to reproduce this with my public forest: http://github.com/jonsterling/forest .

Trebor-Huang commented 9 months ago

OK I can reproduce consistently, but not in the debug environment?? Maybe there is a VSCode behavior change in debug mode

Trebor-Huang commented 9 months ago

Found it. There is an untitled tree that happens to sit at the 101st position! VSCode deals with a null entry by truncating the list there. This was such a whole number that I thought it is a fixed upper bound in length, and by fixing this the problem is gone. Typescript didn't catch that because there isn't a JSON scheme ready :(

Trebor-Huang commented 9 months ago

I'll publish a patch version, please let me know whether the problem persists!

jonsterling commented 9 months ago

It's working well for me now, thanks!!