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

Non-termination regression with scala-cli starting with 1.0.0-M2 #540

Closed
lbialy opened this issue Jun 21, 2022 · 5 comments · Fixed by #606
Closed

Non-termination regression with scala-cli starting with 1.0.0-M2 #540

lbialy opened this issue Jun 21, 2022 · 5 comments · Fixed by #606

Comments

@lbialy
Copy link

lbialy commented Jun 21, 2022

Hi,

I have tried using latest munit versions with scala-cli and found out that termination does not occur if all tests pass since 1.0.0-M2 (M1 works just fine, as all the 0.7.x versions). I have a repro repo here:

https://github.com/lbialy/munit-nonterm-issue

Just run scala-cli test . in this directory and it should hang after printing that all tests passed.

My scala-cli version is 0.1.8.

@tgodzik
Copy link
Contributor

tgodzik commented Jun 21, 2022

Testing it out this only seems to happen when running from ScalaCLI weirdly enough.

@armanbilge
Copy link
Contributor

Seems the issue was introduced in literally the first PR after 1.0.0-M1 :)

//> using lib "org.scalameta::munit::1.0.0-M1+1-11ee9d1c-SNAPSHOT"
//> using repository "https://oss.sonatype.org/content/repositories/snapshots/"
class SanityTest extends munit.FunSuite:
  test("sanity") {
    assert(2 + 2 == 4)
  }

@bishabosha
Copy link

I tested this again recently with scala-cli 0.1.17

@alexarchambault
Copy link
Contributor

alexarchambault commented Nov 17, 2022

munit should create daemon threads around here to fix this, I think. See how Scala CLI does for example. Currently, it creates a non-daemon thread, that prevents the JVM from exiting. Hence the hanging out you're seeing here.

@SethTisue
Copy link
Contributor

anybody here have any insight on VirtusLab/scala-cli#2623 ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants