# Plots.GRBackend Error

**URL:** https://discourse.julialang.org/t/plots-grbackend-error/58758
**Category:** New to Julia
**Tags:** plotting, error, plots
**Created:** [April 7, 2021, 2:48pm UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758 "2021-04-07T14:48:38Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![MA22](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ma22/32/23733_2.png) [@MA22](https://discourse.julialang.org/u/MA22)
#### Post date: [April 7, 2021, 2:48pm UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758/1 "2021-04-07T14:48:38Z")

</div>

Hey everyone,

I’m working on this CFD code with its author:

[https://github.com/weymouth/WaterLily.jl](https://github.com/weymouth/WaterLily.jl)

When running an example like “TwoD\_Circle.jl”, I get the following error:

```julia
LoadError: MethodError: no method matching _as_gradient(::Array{RGBA{Float64},1})
Closest candidates are:
  _as_gradient(!Matched::ColorGradient) at /home/ma22ws/.julia/packages/Plots/8GUYs/src/utils.jl:136
  _as_gradient(!Matched::Colorant) at /home/ma22ws/.julia/packages/Plots/8GUYs/src/utils.jl:137
(...)

```

The author cannot reproduce the error and it seems to be a problem with GRBackend on my system.  
I have tried to purge Plots and rebuild it but to no avail.

For reference, I am running this from Juno, using its shipped 1.5.4 version binary on Linux x86\_64.  
_However_, if I run the code “manually” on the REPL using my system’s Julia (version 1.5.3), everything works fine.

Thank you all,

Miguel

---

<div class="post-metadata">

### Author: ![Salmon](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/salmon/32/22968_2.png) [@Salmon](https://discourse.julialang.org/u/Salmon)
#### Post date: [April 9, 2021, 10:23am UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758/2 "2021-04-09T10:23:33Z")

</div>

A quick idea: I had a similar problem recently. Does your editor maybe start the Julia process with any additional options such as --math-mode=fast? That was what was causing the issue for me at least, so maybe it helps to remove these.

---

<div class="post-metadata">

### Author: ![mkitti](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mkitti/32/12459_2.png) [@mkitti](https://discourse.julialang.org/u/mkitti)
#### Post date: [April 9, 2021, 12:54pm UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758/3 "2021-04-09T12:54:48Z")

</div>

> [@MA22](#):
>
> ```julia
> LoadError: MethodError: no method matching _as_gradient(::Array{RGBA{Float64},1})
> 
> ```

It looks like you need to at least have this commit from Plots.jl [v1.1.0](https://github.com/JuliaPlots/Plots.jl/releases/tag/v1.1.0)

> <https://github.com/JuliaPlots/Plots.jl/commit/e7f79e91441725d7608d3eb615a37696c6853e18>

What does `]st Plots` or ` using Pkg; Pkg.status("Plots")` evaluate to in Juno?

---

<div class="post-metadata">

### Author: ![MA22](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ma22/32/23733_2.png) [@MA22](https://discourse.julialang.org/u/MA22)
#### Post date: [April 9, 2021, 1:23pm UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758/4 "2021-04-09T13:23:35Z")

</div>

How can I check which flags are being passed during startup? I couldn’t find any signs of there being custom flags in the editor.  
Many functions in this code use @fastmath so I’m not sure that’s a viable solution.  
In any case, thanks!

---

<div class="post-metadata">

### Author: ![MA22](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ma22/32/23733_2.png) [@MA22](https://discourse.julialang.org/u/MA22)
#### Post date: [April 9, 2021, 1:28pm UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758/5 "2021-04-09T13:28:47Z")

</div>

Hi, that’s interesting…could explain why it works on my system version works but not with the Juno binary.

This is the output:

```julia
Project WaterLily v0.1.0
Status `~/Documents/WaterLily/WaterLily.jl-master/Project.toml`
  [91a5bcdd] Plots v1.0.14

```

Any ideas?

Thanks for your help.

---

<div class="post-metadata">

### Author: ![Salmon](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/salmon/32/22968_2.png) [@Salmon](https://discourse.julialang.org/u/Salmon)
#### Post date: [April 9, 2021, 2:01pm UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758/6 "2021-04-09T14:01:21Z")

</div>

In Atom there is a “Juno” section at the top of the window. Clicking there you should be able to find the settings at the bottom of the list.  
Although suppose these flags won’t be there unless you added them yourself. Anyway it was worth a shot i guess :D.

---

<div class="post-metadata">

### Author: ![MA22](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ma22/32/23733_2.png) [@MA22](https://discourse.julialang.org/u/MA22)
#### Post date: [April 9, 2021, 2:19pm UTC](https://discourse.julialang.org/t/plots-grbackend-error/58758/8 "2021-04-09T14:19:20Z")

</div>

I can confirm there’s nothing out ordinary there. But you’re right, the “devil” tends to be in the details.  
Oh well…let’s see if it’s a version issue…

Thanks!
