Closed anton-trunov closed 2 years ago
Notice that we run the scilla_server executable as a background process here (I don't know if that's relevant).
That's the issue. There is a race condition between the two dune running. Ideally, dune would set a lock but we currently don't do that. Do you have an option in scilla_server
to "daemonize"? This way you wouldn't have to rely on &
, i.e. you'd do:
dune exec src/runners/scilla_server.exe --daemonise
ulimit ...
Otherwise, you'll have to do this:
dune build src/runners/scilla_server.exe
./_build/default/src/runners/scilla_server.exe &
You can also add (mode promote)
to the executable stanza so that dune copies the executable in the source tree.
@diml Thank you so much for your quick reply! And for the promote
suggestion too, this looks very handy.
Duplicate of #236
Expected Behavior
Scilla builds succeed (
make test_server
target).Actual Behavior
Builds fail randomly on Dune v2.3 and v2.4, often times with different messages, e.g.
or it may look like this
Notice that we run the
scilla_server
executable as a background process here (I don't know if that's relevant).Reproduction
Our setup is a bit complicate, but one can check the results of Travis CI in this PR https://github.com/Zilliqa/scilla/pull/803. Or feel free to push test PRs. It builds just fine with Dune 2.0, 2.1, 2.2.
Specifications
dune
(output ofdune --version
): 2.3.1, 2.4.0ocaml
(output ofocamlc --version
): 4.07.1, 4.08.1, 4.09.1