BYU-Bazel / bazel-ls

A Bazel language server prototype
Apache License 2.0
10 stars 0 forks source link

As a developer, i want to be aware of Bazel parsing errors that cause the extension to break. #133

Closed jasonxris closed 3 years ago

jasonxris commented 3 years ago

00:45:50.801 [pool-2-thread-1] INFO server.bazel.cli.Bazel - Getting BuildTargets... 00:45:51.072 [pool-2-thread-1] INFO server.bazel.cli.Bazel - Parsing Error 00:45:51.072 [pool-2-thread-1] INFO server.workspace.Workspace - ERROR: /workspaces/dev/playground/examples/intellij/BUILD:54:11: Label '//javascript:integration_tests' is duplicated in the 'tests' attribute of rule 'ijwb_ue_tests'

In this case there was an error the build file that causes the parsing to break and for the Workspace tree to not be populated correctly. Breaking many of our features.

There should be a notification to the user about the parsing error allowing the user to

  1. Navigate to the broken BUILD file,
  2. Restart the language server when fixed
josiahsrc commented 3 years ago

I don't know if restarting the language server would be good. May re-querying would suffice?

jasonxris commented 3 years ago

Yeah re-querying would be better.

I only suggested restarting the server since it is the only was we currently have of triggering the re-query.