# Unable to use Plots

**URL:** <https://discourse.julialang.org/t/unable-to-use-plots/63812>\
**Category:** Tooling\
**Tags:** package, plotting\
**Created:** [June 30, 2021, 9:36am UTC](https://discourse.julialang.org/t/unable-to-use-plots/63812 "2021-06-30T09:36:33Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![development\_mentor](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/development_mentor/32/26533_2.png) [@development\_mentor](https://discourse.julialang.org/u/development_mentor)\
**Post date:** [June 30, 2021, 9:36am UTC](https://discourse.julialang.org/t/unable-to-use-plots/63812/1 "2021-06-30T09:36:33Z")

</div>

I tried downloading Plots package. But during installation, it stopped so I exited. Then when I wanted to repeat the installation it succeeded. But when I want to use Plots it gives me errors like that:

```julia
The following package names could not be resolved:
 * gr (not found in project, manifest or registry)

Stacktrace:
  [1] pkgerror(msg::String)
    @ Pkg.Types C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Types.jl:55
  [2] ensure_resolved(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}; registry::Bool)
    @ Pkg.Types C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Types.jl:866
  [3] add(ctx::Pkg.Types.Context, pkgs::Vector{Pkg.Types.PackageSpec}; preserve::Pkg.Types.PreserveLevel, platform::Base.BinaryPlatforms.Platform, kwargs::Base.Iterators.Pairs{Symbol, Base.TTY, Tuple{Symbol}, NamedTuple{(:io,), Tuple{Base.TTY}}})
    @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:192
  [4] add(pkgs::Vector{Pkg.Types.PackageSpec}; io::Base.TTY, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
    @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:79
  [5] add(pkgs::Vector{Pkg.Types.PackageSpec})
    @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:77
  [6] #add#23
    @ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:75 [inlined]
  [7] add
    @ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:75 [inlined]
  [8] #add#22
    @ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:74 [inlined]
  [9] add(pkg::String)
    @ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:74
 [10] top-level scope
    @ In[41]:2
 [11] eval
    @ .\boot.jl:360 [inlined]
 [12] include_string(mapexpr::typeof(REPL.softscope), mod::Module, code::String, filename::String)
    @ Base .\loading.jl:1094

```

and

```julia
┌ Info: Precompiling Plots [91a5bcdd-55d7-5caf-9e0b-520d859cae80]
└ @ Base loading.jl:1317
Your GR installation is incomplete. Rerunning build step for GR package.
ERROR: LoadError: LoadError: InitError: Evaluation into the closed module `GR` breaks incremental compilation because the side effects will not be permanent. This is likely due to some other module mutating `GR` with `eval` during precompilation - don't do this.
Stacktrace:
  [1] eval
    @ .\boot.jl:360 [inlined]
  [2] __init__ ()
    @ GR C:\Users\Uporabnik\.julia\packages\GR\4DHy8\src\GR.jl:351
  [3] _include_from_serialized(path::String, depmods::Vector{Any})
    @ Base .\loading.jl:674
  [4] _require_search_from_serialized(pkg::Base.PkgId, sourcepath::String)
    @ Base .\loading.jl:760
  [5] _require(pkg::Base.PkgId)
    @ Base .\loading.jl:998
  [6] require(uuidkey::Base.PkgId)
    @ Base .\loading.jl:914
  [7] require(into::Module, mod::Symbol)
    @ Base .\loading.jl:901
  [8] include(mod::Module, _path::String)
    @ Base .\Base.jl:386
  [9] include(x::String)
    @ Plots C:\Users\Uporabnik\.julia\packages\Plots\YVapH\src\Plots.jl:1
 [10] top-level scope
    @ C:\Users\Uporabnik\.julia\packages\Plots\YVapH\src\Plots.jl:218
 [11] include
    @ .\Base.jl:386 [inlined]
 [12] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt64}}, source::Nothing)
    @ Base .\loading.jl:1213
 [13] top-level scope
    @ none:1
 [14] eval
    @ .\boot.jl:360 [inlined]
 [15] eval(x::Expr)
    @ Base.MainInclude .\client.jl:446
 [16] top-level scope
    @ none:1
during initialization of module GR
in expression starting at C:\Users\Uporabnik\.julia\packages\Plots\YVapH\src\backends\gr.jl:6
in expression starting at C:\Users\Uporabnik\.julia\packages\Plots\YVapH\src\Plots.jl:1
Failed to precompile Plots [91a5bcdd-55d7-5caf-9e0b-520d859cae80] to C:\Users\Uporabnik\.julia\compiled\v1.6\Plots\jl_EBC9.tmp.

Stacktrace:
 [1] error(s::String)
   @ Base .\error.jl:33
 [2] compilecache(pkg::Base.PkgId, path::String, internal_stderr::IJulia.IJuliaStdio{Base.PipeEndpoint}, internal_stdout::IJulia.IJuliaStdio{Base.PipeEndpoint})
   @ Base .\loading.jl:1360
 [3] compilecache(pkg::Base.PkgId, path::String)
   @ Base .\loading.jl:1306
 [4] _require(pkg::Base.PkgId)
   @ Base .\loading.jl:1021
 [5] require(uuidkey::Base.PkgId)
   @ Base .\loading.jl:914
 [6] require(into::Module, mod::Symbol)
   @ Base .\loading.jl:901
 [7] eval
   @ .\boot.jl:360 [inlined]
 [8] include_string(mapexpr::typeof(REPL.softscope), mod::Module, code::String, filename::String)
   @ Base .\loading.jl:1094

```

---

<div class="post-metadata">

**Author:** ![nilshg](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nilshg/32/2283_2.png) [@nilshg](https://discourse.julialang.org/u/nilshg)\
**Post date:** [June 30, 2021, 9:50am UTC](https://discourse.julialang.org/t/unable-to-use-plots/63812/2 "2021-06-30T09:50:23Z")

</div>

What happens when you do `] build GR` as the error message says?

---

<div class="post-metadata">

**Author:** ![development\_mentor](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/development_mentor/32/26533_2.png) [@development\_mentor](https://discourse.julialang.org/u/development_mentor)\
**Post date:** [June 30, 2021, 11:00am UTC](https://discourse.julialang.org/t/unable-to-use-plots/63812/3 "2021-06-30T11:00:36Z")

</div>

@nilshg It says `Building GR → C:\Users\Uporabnik\.julia\scratchspaces\44cfe95a-1eb2-52ea-b672-e2afdf69b78f\b83e3125048a9c3158cbb7ca423790c7b1b57bea\build.log.` So is that good? What would the next thing to do be?  
I tried running `using Plots`, but got` Info: Precompiling Plots [91a5bcdd-55d7-5caf-9e0b-520d859cae80] @ Base loading.jl:1317`

---

<div class="post-metadata">

**Author:** ![nilshg](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nilshg/32/2283_2.png) [@nilshg](https://discourse.julialang.org/u/nilshg)\
**Post date:** [June 30, 2021, 11:20am UTC](https://discourse.julialang.org/t/unable-to-use-plots/63812/4 "2021-06-30T11:20:58Z")

</div>

And what if you now do `using Plots` in a fresh REPL session?

---

<div class="post-metadata">

**Author:** ![development\_mentor](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/development_mentor/32/26533_2.png) [@development\_mentor](https://discourse.julialang.org/u/development_mentor)\
**Post date:** [June 30, 2021, 11:28am UTC](https://discourse.julialang.org/t/unable-to-use-plots/63812/5 "2021-06-30T11:28:42Z")

</div>

Thanks @nilshg it helped
