Since today I receive the following error message whenever I try to plot something using PGFPlotsX:
ERROR: LoadError: UndefVarError: PGFPlotsX not defined
Stacktrace:
[1] top-level scope
@ util.jl:500
Revise evaluation error at C:\Users\USER\Code\util.jl:500
Stacktrace:
[1] methods_by_execution!(recurse::Any, methodinfo::Revise.CodeTrackingMethodInfo, docexprs::Dict{Module, Vector{Expr}}, mod::Module, ex::Expr; mode::Symbol, disablebp::Bool, always_rethrow::Bool, kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\lowered.jl:232
[2] #eval_with_signatures#92
@ C:\Users\USER\.julia\packages\Revise\WHZdV\src\packagedef.jl:470 [inlined]
[3] instantiate_sigs!(modexsigs::OrderedCollections.OrderedDict{Module, OrderedCollections.OrderedDict{Revise.RelocatableExpr, Union{Nothing, Vector{Any}}}}; mode::Symbol, kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\packagedef.jl:478
[4] #invokelatest#2
@ .\essentials.jl:718 [inlined]
[5] maybe_add_includes_to_pkgdata!(pkgdata::Revise.PkgData, file::String, includes::Vector{Pair{Module, String}}; eval_now::Bool)
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\pkgs.jl:174
[6] eval_require_now(pkgdata::Revise.PkgData, fileidx::Int64, filekey::String, sourcefile::String, modcaller::Module, expr::Expr)
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\pkgs.jl:288
[7] #invokelatest#2
@ .\essentials.jl:716 [inlined]
[8] invokelatest
@ .\essentials.jl:714 [inlined]
[9] add_require(sourcefile::String, modcaller::Module, idmod::String, modname::String, expr::Expr)
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\pkgs.jl:233
[10] withnotifications(::Any, ::Vararg{Any})
@ Requires C:\Users\USER\.julia\packages\Requires\7Ncym\src\require.jl:68
[11] (::Plots.var"#308#344")()
@ Plots C:\Users\USER\.julia\packages\Requires\7Ncym\src\require.jl:96
[12] #invokelatest#2
@ .\essentials.jl:716 [inlined]
[13] invokelatest
@ .\essentials.jl:714 [inlined]
[14] foreach(f::typeof(Base.invokelatest), itr::Vector{Function})
@ Base .\abstractarray.jl:2694
[15] loadpkg(pkg::Base.PkgId)
@ Requires C:\Users\USER\.julia\packages\Requires\7Ncym\src\require.jl:27
[16] #invokelatest#2
@ .\essentials.jl:716 [inlined]
[17] invokelatest
@ .\essentials.jl:714 [inlined]
[18] require(uuidkey::Base.PkgId)
@ Base .\loading.jl:1019
[19] require(into::Module, mod::Symbol)
@ Base .\loading.jl:997
[20] top-level scope
@ C:\Users\USER\.julia\packages\Plots\FCM0H\src\backends.jl:301
in expression starting at c:\Users\USER\Dropbox\RoxanaIlya_Sustainable_Innovation\Code\Model\Scripts\main_simple.jl:3
caused by: UndefVarError: PGFPlotsX not defined
Stacktrace:
[1] collect_args(frame::JuliaInterpreter.Frame, call_expr::Expr; isfc::Bool)
@ JuliaInterpreter C:\Users\USER\.julia\packages\JuliaInterpreter\4B89D\src\interpret.jl:60
[2] collect_args
@ C:\Users\USER\.julia\packages\JuliaInterpreter\4B89D\src\interpret.jl:134 [inlined]
[3] evaluate_call_recurse!(recurse::Any, frame::JuliaInterpreter.Frame, call_expr::Expr; enter_generated::Bool)
@ JuliaInterpreter C:\Users\USER\.julia\packages\JuliaInterpreter\4B89D\src\interpret.jl:207
[4] evaluate_call_recurse!
@ C:\Users\USER\.julia\packages\JuliaInterpreter\4B89D\src\interpret.jl:201 [inlined]
[5] eval_rhs(recurse::Any, frame::JuliaInterpreter.Frame, node::Expr)
@ JuliaInterpreter C:\Users\USER\.julia\packages\JuliaInterpreter\4B89D\src\interpret.jl:400
[6] step_expr!(recurse::Any, frame::JuliaInterpreter.Frame, node::Any, istoplevel::Bool)
@ JuliaInterpreter C:\Users\USER\.julia\packages\JuliaInterpreter\4B89D\src\interpret.jl:556
[7] methods_by_execution!(recurse::Any, methodinfo::Revise.CodeTrackingMethodInfo, docexprs::Dict{Module, Vector{Expr}}, frame::JuliaInterpreter.Frame, isrequired::Vector{Bool}; mode::Symbol, skip_include::Bool)
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\lowered.jl:441
[8] methods_by_execution!(recurse::Any, methodinfo::Revise.CodeTrackingMethodInfo, docexprs::Dict{Module, Vector{Expr}}, mod::Module, ex::Expr; mode::Symbol, disablebp::Bool, always_rethrow::Bool, kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\lowered.jl:222
[9] #eval_with_signatures#92
@ C:\Users\USER\.julia\packages\Revise\WHZdV\src\packagedef.jl:470 [inlined]
[10] instantiate_sigs!(modexsigs::OrderedCollections.OrderedDict{Module, OrderedCollections.OrderedDict{Revise.RelocatableExpr, Union{Nothing, Vector{Any}}}}; mode::Symbol, kwargs::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\packagedef.jl:478
[11] #invokelatest#2
@ .\essentials.jl:718 [inlined]
[12] maybe_add_includes_to_pkgdata!(pkgdata::Revise.PkgData, file::String, includes::Vector{Pair{Module, String}}; eval_now::Bool)
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\pkgs.jl:174
[13] eval_require_now(pkgdata::Revise.PkgData, fileidx::Int64, filekey::String, sourcefile::String, modcaller::Module, expr::Expr)
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\pkgs.jl:288
[14] #invokelatest#2
@ .\essentials.jl:716 [inlined]
[15] invokelatest
@ .\essentials.jl:714 [inlined]
[16] add_require(sourcefile::String, modcaller::Module, idmod::String, modname::String, expr::Expr)
@ Revise C:\Users\USER\.julia\packages\Revise\WHZdV\src\pkgs.jl:233
[17] withnotifications(::Any, ::Vararg{Any})
@ Requires C:\Users\USER\.julia\packages\Requires\7Ncym\src\require.jl:68
[18] (::Plots.var"#308#344")()
@ Plots C:\Users\USER\.julia\packages\Requires\7Ncym\src\require.jl:96
[19] #invokelatest#2
@ .\essentials.jl:716 [inlined]
[20] invokelatest
@ .\essentials.jl:714 [inlined]
[21] foreach(f::typeof(Base.invokelatest), itr::Vector{Function})
@ Base .\abstractarray.jl:2694
[22] loadpkg(pkg::Base.PkgId)
@ Requires C:\Users\USER\.julia\packages\Requires\7Ncym\src\require.jl:27
[23] #invokelatest#2
@ .\essentials.jl:716 [inlined]
[24] invokelatest
@ .\essentials.jl:714 [inlined]
[25] require(uuidkey::Base.PkgId)
@ Base .\loading.jl:1019
[26] require(into::Module, mod::Symbol)
@ Base .\loading.jl:997
[27] top-level scope
@ C:\Users\USER\.julia\packages\Plots\FCM0H\src\backends.jl:301
Does anyone have an idea what might be causing this? I already tried removing and reinstalling Plots.jl and PGFPlotsX.jl, but it did not help.
It seems to be a problem with Revise.jl, as PyPlot also does not work.
Yep, that was it. Pinning Revise to 3.1.20 solved the problem! Created an issue for Revise.jl