IOContext not properly set for stdout
, disables ANSI colors
#2823
Labels
backend
Concerning the julia server and runtime
enhancement
New feature or request
good first issue
Good for newcomers
help welcome
If you are experienced in this topic - let us know!
Since #2148 the
stdout
capture window supports ANSI terminal colors, and:color => true
is set indefault_stdout_iocontext
as seen here:Pluto.jl/src/runner/PlutoRunner/src/PlutoRunner.jl
Lines 1007 to 1012 in 216451c
However, when querying
stdout
in a Pluto cell,:color
is set tofalse
, so well-behaved Julia code will not print colors. MWE:printstyled("hello"; color=:red)
. A workaround is to wrapstdout
in your ownIOContext
and set:color => true
, but this should not be necessary.(Please take this screenshot in place of a video. Nothing dynamic here.)
Notebook file: https://gist.github.com/danielwe/0663e49fbfb2219b2230d3fe2092c097
Using Pluto 0.19.39 on Julia 1.10.1
The text was updated successfully, but these errors were encountered: