-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Stack overflow in ImportSuggestions#distinctRefs #12876
Comments
|
For the sbt hang issue, jstack output is as below:
|
Thanks smarter for the suggestions. When I passed in the -Ximport-suggestion-timeout 0 argument, the compiler hangs as well even in Maven. Call stack from jstack as below:
|
That hanging issue seems unrelated to the stackoverflow, so you'll need to open a separate issue for that, but there's not much we can do without a way to reproduce the problem ourselves (even a git branch of a project with instructions on how to reproduce the issue would be helpful). |
Thanks smarter. I've raised Issue #12878 and added details for sample project to reproduce the issue. |
@chrislailee I can't see your repo to reproduce this bug anymore, is it fixed in Scala 3.0.1? |
Regardless of whether we can reproduce, I think it wouldn't be a bad idea to rewrite |
I can't reproduce the stack overflow issue with Scala 3.0.1 anymore. However, the compiler hanging issue #12878 is still there with 3.0.1 using Azul Zulu 11.0.11. It still hangs when compiling with Maven or sbt. |
And I agree with smarter that it's worthwhile to make distinctRefs stack safe, as we don't know when next it could run into stack overflow problem. |
Bit of good news: the hanging issue reported above as with #12878 is not there anymore when I upgrade the JDK to Azul Zulu 11.0.12 (still using Scala 3.0.1). So the issue seems sensitive to version of JDK used together with Scala version. |
Possible regression with version 3.0.2. The stack overflow issue comes back when compiling with 3.0.2. The issue went away when compiled with 3.0.1. |
Fixes scala#12876 (hopefully)
Fixes scala#12876 (hopefully)
Scala version: 3.0.0
CATS library: 2.6.1
JDK: Azul Zulu 11.0.11
SBT: 1.5.4
Compile under Maven, it throws the following exception. The error message does not pinpoint a specific source file that caused the issue so I can't be more specific than this.
When compile under sbt, it reports a number of errors. The last of which is the following. Then the console hangs at compile incremental with the timer keeps ticking:
The text was updated successfully, but these errors were encountered: