print macros do not lock stdout or stderr
withoutboats opened this issue · comments
If a println gets separated into multiple writes, it could be interleaved with the printing of other tasks. This should be fixed at some point.
The way to do this is to use an async around Stdout
and StdErr
and then lock those. its not enough to use StdoutLock
directly without an async mutex because then you will have deadlocks between different tasks using an async print.