ocaml/dune

Flush output buffers on SIGTERM

Aperta

#3882 aperta il 21 ott 2020

 (12 commenti) (0 reazioni) (2 assegnatari)OCaml (478 fork)github user discovery
good first issue

Metriche repository

Star
 (1882 stelle)
Metriche merge PR
 (Merge medio 1g 20h) (345 PR mergiate in 30 g)

Descrizione

We're currently using dune runtest in OCaml-CI as the standard way of running tests for a package. If some of the tests for a package get stuck in a deadlock, the CI job will kill the process after 60 minutes. Unfortunately, this means that the logs of the stalled test run are lost.

We could switch to using dune runtest --no-buffer in the CI, but this creates less readable (interleaved) test output. One possible alternative would be for Dune to flush its output buffers before responding to SIGTERM (probably keeping the old behaviour for SIGKILL). What do you think?

Guida contributor