livebook-dev/livebook

Starting a standalone Elixir runtime fails on Windows 10

howard0su opened this issue · 7 comments

Environment

  • Elixir & Erlang/OTP versions (elixir --version):
    Erlang/OTP 24 [erts-12.2.1] [source] [64-bit] [smp:20:20] [ds:20:20:10] [async-threads:1] [jit]

Elixir 1.13.2 (compiled with Erlang/OTP 22)

  • Operating system: Windows 10
  • How have you started Livebook (mix phx.server, livebook CLI, Docker, etc): mix phx.server
  • Livebook version (use git rev-parse HEAD if running with mix): 6b78258
  • Browsers that reproduce this bug (the more the merrier): Edge
  • Include what is logged in the browser console:
  • Include what is logged to the server console:

Current behavior

F:\livebook>elixir --cookie "COOKIEFORTESTS" -S mix test
Compiling 4 files (.ex)
.......................................................................

  1. test init/1 loads necessary modules and starts manager process (Livebook.Runtime.ElixirStandaloneTest)
    test/livebook/runtime/elixir_standalone_test.exs:23
    match (=) failed
    code: assert {:ok, %{node: node} = runtime} = Runtime.ElixirStandalone.init()
    left: {:ok, %{node: node} = runtime}
    right: {:error, "Elixir process terminated unexpectedly"}
    stacktrace:
    test/livebook/runtime/elixir_standalone_test.exs:24: (test)

Expected behavior

the test should pass.

I hit the same problem if i am using browser to use livebook. When I click evaluate, i got the same error:
Elixir process terminated unexpectedly

This has the same error as #194

Did you try the steps in #194? Also please try the steps here: #777 :)

No. the steps didn't fix my problem. I am thinking if my locale causes it.

Original reporter of #194 here. Probably not going to help much, but I can confirm that running the latest Livebook on the same commit you referenced works for me on Windows 10.

Per your point on locale, my locale as printed by Get-Host on PowerShell is:

CurrentCulture   : fi-FI
CurrentUICulture : en-GB

As for the point on tests failing, I'm actually seeing some tests fail, but those don't seem to be related the issue at hand.

Gist of output here: https://gist.github.com/juhalehtonen/5f45c55940d3583514b733fd5f09c5be . It's worth noting that I don't typically develop on Windows, and so it might be I should be configuring something in my environment that I'm currently not doing. In either case, probably not relevant here :).

I reverted back to en-us. No lucky.

I tried to start a new iex process in command and use "Attach to Node". It works for me. Looks like some issue during process startup.

I reinstall erlang and elixir fixed the problem, although I still don't know root cause.