corrosion: could not find `Cargo.toml` in `/` or any parent directory
This error is popping up randomly when ctrl+clicking on symbols resolving to a .cargo lib

- I do have
.cargoimported as a project in the workspaces. - Most of the time, the operation correctly loads the source file in
.cargoand does not produce an error
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 44 (43 by maintainers)
Commits related to this issue
- [Bug 549758] Do not start LS from '/' if possible Partial fix for https://github.com/eclipse/corrosion/issues/233 If a workspace root is not available for an editor file, because the file does not be... — committed to itadinanta/lsp4e by norru 5 years ago
- [Bug 549758] Do not start LS from '/' if possible Partial fix for https://github.com/eclipse/corrosion/issues/233 If a workspace root is not available for an editor file, because the file does not be... — committed to itadinanta/lsp4e by norru 5 years ago
- [Bug 549758] Do not start LS from '/' if possible Partial fix for https://github.com/eclipse/corrosion/issues/233 If a workspace root is not available for an editor file, because the file does not be... — committed to itadinanta/lsp4e by norru 5 years ago
- [Bug 549758] Do not start LS from '/' if possible Partial fix for https://github.com/eclipse/corrosion/issues/233 If a workspace root is not available for an editor file, because the file does not be... — committed to itadinanta/lsp4e by norru 5 years ago
- [Bug 549758] Do not start LS from '/' if possible Partial fix for https://github.com/eclipse/corrosion/issues/233 If a workspace root is not available for an editor file, because the file does not be... — committed to itadinanta/lsp4e by norru 5 years ago
đ If you get other questions/issues.with Gerrit,feel free to ask for assistance (on the LSP4E bugs preferably)
Thanks for the reports and the Git attempt. Unfortunately, defaut Git is in trouble today, I suggest you use the URLs fir Gerrit instead, that seems to still work well, ar least the SSH one. See https://git.eclipse.org/r/#/admin/projects/lsp4e/lsp4e for the remote URLs
đ Iâm hearing you as an echo of myself some years ago when I have similar opinion.
The truth is that both the project and the reviewer donât really need to know nor store your work history, it needs to keep an history of meaningful commits for easier tracking in the future, whether you made a commit to fix a typo or a minor bug in your patch is actually more noise than value from project perspective (by project I mean current and future contributors). Youâre free to push multiple successive commits with Gerrit if that makes sense for the reviewer and the project, they will just be multiple Gerrit reviews (instead of a single PR in GitHub world). For your first experiment, just accept losing your local fine grain history and embrace the Gerrit way even if you donât like it at first, and then youâll progressively adhere to Gerrit workflow and realize how better it is than GitHub ones đ
Thanks for your investigation and the Corrosion <-> RLS shuttle.
LSP4E decides when to start a new LS or not. Itâs expected that a LS supporting
workspaceFolderscapability can be reused for multiple projects. If the workspaceFolders capability is not set, then one LS instance is started for each project. Itâs an implementation choice made by LSP4E as the spec is very weak on that topic. But it seems to work for most existing LS. There is one and only oneinitializerequest for each LS instance.Thatâs also my thought, this requirement for RLS is not compatible with the idea of the spec IMO and should be improved in RLS to benefit to the LS and most adopters.
Itâs something we implemented to allow hover in the .cargo files. Maybe itâs not relevant anymore and this could be removed with better results (so could be the addition of the .cargo folder since LSP4E improved support for external files), but itâs a bit hard to follow RLS on that topic as RLS seems to change a lot its assumptions and requirements without really evaluating conformance to spec or most adopters. Maybe you can give a try to the following scenario: delete the
.cargoproject in the Eclipse IDE, and then start using your project and Ctrl+Click to navigate to libraries in.cargofolder. Those files would be open externallyUnfortunately, there isnât such possibility in LSP4E at the moment, because all other supported LS can be started in a âstatelessâ way (independently of the project itâs going to support) and then use the rootURI and similar to build the state. I think RLS should try to build the same simple and efficient approach instead of piling a set of specific requirements that donât seem to provide added-value over conventions used by other LSs.