spawn() and readandwrite() are documented as being variants of run() which do not block the command line. yet in an @async, run() seems to yield to other tasks. to wit:
# bar prints first because it's the first task julia> @sync begin @async println("bar") @async (run(`sleep 10`);println("foo")) end bar foo Task (done) @0x00007f87c088fba0 # but why does bar print first here? julia> @sync begin @async (run(`sleep 10`);println("foo")) @async println("bar") end bar foo Task (done) @0x00007f87c08b3f60 note that the behavior is the same if i replace the `sleep 10` with a `touch foo`.