scalacenter/bloop

FailedToStartServerException: Server didn't start possibly due to SocketException: Unix domain path too long

i10416 opened this issue · 2 comments

here's log for scala-cli -v -v -v -v bloop start

Checking for a running Bloop server at /nix/store/xw9rv0lq8m577rfwxr5s86pgjj8qajcp-0.1.0-SNAPSHOT/Library/Caches/ScalaCli/bloop/daemon ...
Attempting to connect to Bloop server /nix/store/xw9rv0lq8m577rfwxr5s86pgjj8qajcp-0.1.0-SNAPSHOT/Library/Caches/ScalaCli/bloop/daemon ...
Connection attempt result: None
Exception in thread "main" java.net.SocketException: Unix domain path too long
        at java.base/sun.nio.ch.UnixDomainSockets.bind0(Native Method)
        at java.base/sun.nio.ch.UnixDomainSockets.bind(UnixDomainSockets.java:113)
        at java.base/sun.nio.ch.ServerSocketChannelImpl.unixBind(ServerSocketChannelImpl.java:319)
        at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:292)
        at java.base/java.nio.channels.ServerSocketChannel.bind(ServerSocketChannel.java:224)
        at libdaemonjvm.internal.Java16SocketHandler$.server(Java16SocketHandler.scala:41)
        at libdaemonjvm.internal.SocketHandler$.server(SocketHandler.scala:20)
        at bloop.Bloop$.$anonfun$startServer$1(Bloop.scala:167)
        at scala.util.Either.map(Either.scala:353)
        at bloop.Bloop$.startServer(Bloop.scala:165)
        at bloop.Bloop$.$anonfun$main$4(Bloop.scala:89)
        at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
        at libdaemonjvm.server.Lock$.unsafeWritePidAndSetup$1(Lock.scala:32)
        at libdaemonjvm.server.Lock$.$anonfun$tryAcquire$3(Lock.scala:52)
        at scala.util.Either.flatMap(Either.scala:341)
        at libdaemonjvm.server.Lock$.$anonfun$tryAcquire$2(Lock.scala:51)
        at scala.util.Either.flatMap(Either.scala:341)
        at libdaemonjvm.server.Lock$.unsafeCleanUpAndSetup$1(Lock.scala:50)
        at libdaemonjvm.server.Lock$.$anonfun$tryAcquire$9(Lock.scala:100)
        at libdaemonjvm.LockFiles.withLock(LockFiles.scala:37)
        at libdaemonjvm.server.Lock$.tryAcquire(Lock.scala:97)
        at bloop.Bloop$.main(Bloop.scala:89)
        at bloop.Bloop.main(Bloop.scala)

Thanks for reporting! I wonder if it's only an issue with the current Bloop fork used in ScalaCLI or Bloop itself also. Sockets is the main difference between the two.

@alexarchambault any idea how we can work around this?