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

Bazel import failure: java.util.NoSuchElementException: next on empty iterator #6756

Open
susliko opened this issue Sep 4, 2024 · 1 comment
Labels
bazel bug Something that is making a piece of functionality unusable

Comments

@susliko
Copy link
Contributor

susliko commented Sep 4, 2024

Describe the bug

An attempt to import a build of https://github.com/bazelbuild/rules_scala fails with

Sep 04, 2024 12:24:28 PM scala.meta.internal.pc.CompilerAccess handleError
SEVERE: A severe compiler error occurred, full details of the error can be found in the error report /.../rules_scala/.metals/.reports/metals-full/2024-09-04/r_compiler-error_12-24-28-596.md

Here's a gist with compiler-report.

Doctor output:

### Workspace: /home/.../rules_scala
 - Build definition is coming from bazel.
 - Build server currently being used is bazelbsp v3.2.0-20240629-e3d8bdf-NIGHTLY.

## Error Reports

### compiler-error
- timestamp: 1725442519218
- uri: file:///home/.../rules_scala/.metals/.reports/metals-full/2024-09-04/r_compiler-error_12-35-19-218.md
- error type: metals-full

#### Summary
java.util.NoSuchElementException: next on empty iterator

### compiler-error
- timestamp: 1725442520387
- uri: file:///home/.../rules_scala/.metals/.reports/metals-full/2024-09-04/r_compiler-error_12-35-20-387.md
- error type: metals-full

#### Summary
java.util.NoSuchElementException: next on empty iterator

... more similar blocks

Expected behavior

Either import build of the project (at least scala targets) or give a user-friendly message on why it could not be imported.

Operating system

Linux

Editor/Extension

Nvim (nvim-metals)

Version of Metals

v1.3.5

Extra context or search terms

No response

@tgodzik
Copy link
Contributor

tgodzik commented Sep 4, 2024

Thanks for reporting! I think the build itself doesn't import, the exception doesn't seem to be actually related, but I am having issues getting it to build with the bazel bsp aspect.

@tgodzik tgodzik added bug Something that is making a piece of functionality unusable bazel labels Sep 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bazel bug Something that is making a piece of functionality unusable
Projects
Status: Triage
Development

No branches or pull requests

2 participants