Hi all! I am trying to compile my julia project using PackageCompiler
v. 2.1.0. My julia version is 1.8.2, Plots
is v. 1.35.8, PyCall
1.94.1 and, PyPlot
2.11.0. Compilation works, at least it doesn’t error in the middle. But when I start my compiled program, I get the following warning:
Warning: Error requiring `PyPlot` from `Plots`
│ exception =
│ LoadError: ArgumentError: ref of NULL PyObject
│ Stacktrace:
│ [1] _getproperty(o::PyCall.PyObject, s::String)
│ @ PyCall ~/.julia/packages/PyCall/ygXW2/src/PyCall.jl:299
│ [2] __getproperty
│ @ ~/.julia/packages/PyCall/ygXW2/src/PyCall.jl:312 [inlined]
│ [3] getproperty(o::PyCall.PyObject, s::String)
│ @ PyCall ~/.julia/packages/PyCall/ygXW2/src/PyCall.jl:317
│ [4] top-level scope
│ @ ~/.julia/packages/Plots/qgrW8/src/backends/pyplot.jl:25
│ [5] include(mod::Module, _path::RelocatableFolders.Path)
│ @ Base ./Base.jl:419
│ [6] include(x::RelocatableFolders.Path)
│ @ Plots ~/.julia/packages/Plots/qgrW8/src/Plots.jl:1
│ [7] top-level scope
│ @ ~/.julia/packages/Plots/qgrW8/src/init.jl:96
│ [8] eval
│ @ ./boot.jl:368 [inlined]
│ [9] eval
│ @ ~/.julia/packages/Plots/qgrW8/src/Plots.jl:1 [inlined]
│ [10] (::Plots.var"#378#423")()
│ @ Plots ~/.julia/packages/Requires/Z8rfN/src/require.jl:101
│ [11] macro expansion
│ @ ./timing.jl:382 [inlined]
│ [12] err(f::Any, listener::Module, modname::String, file::String, line::Any)
│ @ Requires ~/.julia/packages/Requires/Z8rfN/src/require.jl:47
│ [13] (::Plots.var"#377#422")()
│ @ Plots ~/.julia/packages/Requires/Z8rfN/src/require.jl:100
│ [14] withpath(f::Any, path::String)
│ @ Requires ~/.julia/packages/Requires/Z8rfN/src/require.jl:37
│ [15] (::Plots.var"#376#421")()
│ @ Plots ~/.julia/packages/Requires/Z8rfN/src/require.jl:99
│ [16] listenpkg(f::Any, pkg::Base.PkgId)
│ @ Requires ~/.julia/packages/Requires/Z8rfN/src/require.jl:20
│ [17] macro expansion
│ @ ~/.julia/packages/Requires/Z8rfN/src/require.jl:98 [inlined]
│ [18] __init__()
│ @ Plots ~/.julia/packages/Plots/qgrW8/src/init.jl:95
│ in expression starting at /home/clara/.julia/packages/Plots/qgrW8/src/backends/pyplot.jl:25
└ @ Requires ~/.julia/packages/Requires/Z8rfN/src/require.jl:51
It is still possible to call the help menu of my program though. But does anyone know how to avoid the warning shown above? Thanks a lot!