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

When loading workspaces fails, tell the user if the linkedProjects config is set #15171

Closed
Veykril opened this issue Jun 29, 2023 · 4 comments · Fixed by #16153
Closed

When loading workspaces fails, tell the user if the linkedProjects config is set #15171

Veykril opened this issue Jun 29, 2023 · 4 comments · Fixed by #16153
Assignees
Labels
Broken Window Bugs / technical debt to be addressed immediately C-enhancement Category: enhancement E-easy E-has-instructions Issue has some instructions and pointers to code to get started

Comments

@Veykril
Copy link
Member

Veykril commented Jun 29, 2023

Currently when someone has the linkedProjects config set and their workspace fails to load (due to the config pointing to non-existing paths or similar), the user will just get confused as r-a doesn't tell them anything else. We should tell them loud and clear that it is most likely a misconfiguration of the linkedProjects config causing them problems.

@Veykril Veykril added E-easy Broken Window Bugs / technical debt to be addressed immediately C-enhancement Category: enhancement labels Jun 29, 2023
@stupendoussuperpowers
Copy link

could you clarify what you expect the error message to be/what you see currently?

for me, I see the following when it fails to load a linkedProject from the settings, which does point to a failure and a suggestion with it -

[ERROR rust_analyzer::config] failed to load linked project: project root must point to Cargo.toml or rust-project.json: /home/../../.\Cargo.toml

@Veykril Veykril self-assigned this Oct 6, 2023
@Veykril
Copy link
Member Author

Veykril commented Oct 10, 2023

Relevant part to check is here

if let Err(_) = self.fetch_workspace_error() {
status.health = lsp_ext::Health::Error;
message.push_str("Failed to load workspaces.\n\n");
}

We should check whether the linkedProjects config is set, and if yes add a note to that message that the user should check whether those projects are valid/exist.

@Veykril Veykril added the E-has-instructions Issue has some instructions and pointers to code to get started label Oct 10, 2023
@stupendoussuperpowers
Copy link

will submit a pull request for this.

@bionicles

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Broken Window Bugs / technical debt to be addressed immediately C-enhancement Category: enhancement E-easy E-has-instructions Issue has some instructions and pointers to code to get started
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants