Unable to display plot using the REPL. GKS errors

I tried both of these settings but they give me an error:

ERROR: LoadError: SystemError: opening file "/tmp/jl_CdHheQ.png": No such file or directory
Stacktrace:
 [1] systemerror(::String, ::Int32; extrainfo::Nothing) at ./error.jl:168
 [2] #systemerror#50 at ./error.jl:167 [inlined]
 [3] systemerror at ./error.jl:167 [inlined]
 [4] open(::String; read::Nothing, write::Nothing, create::Nothing, truncate::Nothing, append::Nothing) at ./iostream.jl:254
 [5] open at ./iostream.jl:246 [inlined]
 [6] open(::Base.var"#279#280"{String}, ::String; kwargs::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}) at ./io.jl:296
 [7] open at ./io.jl:296 [inlined]
 [8] read at ./io.jl:381 [inlined]
 [9] _show(::IOStream, ::MIME{Symbol("image/png")}, ::Plots.Plot{Plots.GRBackend}) at /home/skainswo/.julia/packages/Plots/VA7Vx/src/backends/gr.jl:1970
 [10] show at /home/skainswo/.julia/packages/Plots/VA7Vx/src/output.jl:215 [inlined]
 [11] png(::Plots.Plot{Plots.GRBackend}, ::String) at /home/skainswo/.julia/packages/Plots/VA7Vx/src/output.jl:7
 [12] frame(::Plots.Animation, ::Plots.Plot{Plots.GRBackend}) at /home/skainswo/.julia/packages/Plots/VA7Vx/src/animation.jl:20
 [13] frame(::Plots.Animation) at /home/skainswo/.julia/packages/Plots/VA7Vx/src/animation.jl:18
 [14] top-level scope at /home/skainswo/dev/research/julia/odecontrol/diffdrive/train.jl:89
 [15] include(::Module, ::String) at ./Base.jl:377
 [16] exec_options(::Base.JLOptions) at ./client.jl:288
 [17] _start() at ./client.jl:484
in expression starting at /home/skainswo/dev/research/julia/odecontrol/diffdrive/train.jl:48

Also, is there documentation for this somewhere?

EDIT: Tried a value of 140 as suggested in https://github.com/JuliaPlots/Plots.jl/issues/1612 and that worked :man_shrugging: Magic numbers galore!