The pipe was renamed PipeEndpoint at https://github.com/JuliaLang/julia/pull/12739 , but the related documentation was not updated, and PipeEndpoint is now considered internal. However, creating the front of the pipe is still feasible:
pipe = Pipe()
Base.link_pipe(pipe)
redirect_stdout(pipe.in)
@async while !eof(pipe)
data = readavailable(pipe)
end
In addition, a version of these functions with no arguments already creates a pipe object, so the recommended way to do this is:
(rd,wr) = redirect_stdout()
@async while !eof(rd)
data = readavailable(rd)
end
However, all this is less clear than it could be, so I created a migration request to clear this API: https://github.com/JuliaLang/julia/pull/18253 . When this transfer request is combined, the call link_pipewill become unnecessary, or pipeyou can transfer it directly to redirect_stdout. In addition, the return value from the version with no arguments will become regular pipe.
source
share