Closed
Description
Writes to the piped stdout and stderr are not interleaving correctly. Maybe need to join the streams but then how do we differentiate what should be written to stdout vs. stderr?
cargo run --example=printenv
Prints to stdout or stderr for every other line. Happens to be alphabetical in bash on ubuntu-22.04.
cargo run -- run -- cargo run --example=printenv
Prints lines in a random order. I was hoping that each of stdout and stderr would buffer - and perhaps they are - but the futures are completed non-chronologically. Will need to rethink how to handle this. Likely not async, which means back to the old LineWriter
idea.