Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to show WGLMakie plot #779

Closed
grero opened this issue Dec 14, 2020 · 8 comments
Closed

Failed to show WGLMakie plot #779

grero opened this issue Dec 14, 2020 · 8 comments
Labels
other packages Integration with other Julia packages

Comments

@grero
Copy link

grero commented Dec 14, 2020

After updating to the latest Pluto version ( v0.12.17) I am longer able to show figures created using WGLMakie. The following notebook illustrates the problem

### A Pluto.jl notebook ###
# v0.12.17

using Markdown
using InteractiveUtils

# ╔═╡ e28395e8-3dfa-11eb-18e0-118bbb139623
begin
	using Pkg
	Pkg.activate(dirname(@__FILE__))
	Pkg.add("AbstractPlotting")
	Pkg.add("WGLMakie")
end

# ╔═╡ 21d26c38-3dfb-11eb-13b4-51e233cd1805
begin
	using AbstractPlotting
	using WGLMakie
end

# ╔═╡ 291d5746-3dfb-11eb-164a-8bc00a9860e5
let
	scene,layout = layoutscene(resolution=(500,500))
	la = layout[1,1] = LAxis(scene)
	x,y = rand(10), rand(10)
	scatter!(la, x, y, markersize=5px)
	scene
end

# ╔═╡ Cell order:
# ╠═e28395e8-3dfa-11eb-18e0-118bbb139623
# ╠═21d26c38-3dfb-11eb-13b4-51e233cd1805
# ╠═291d5746-3dfb-11eb-164a-8bc00a9860e5

Running the notebook results in the following error:

Failed to show value:

ArgumentError: collection must be non-empty

first@abstractarray.jl:342[inlined]
|>(::Base.Iterators.Filter{Main.PlutoRunner.var"#30#31"{AbstractPlotting.Scene},Array{MIME,1}}, ::typeof(first))@operators.jl:834
show_richest(::IOContext{Base.GenericIOBuffer{Array{UInt8,1}}}, ::Any)@PlutoRunner.jl:585
#sprint_withreturned#29(::IOContext{Base.DevNull}, ::Int64, ::typeof(Main.PlutoRunner.sprint_withreturned), ::Function, ::AbstractPlotting.Scene)@PlutoRunner.jl:549
#format_output_default#17(::Pair{Symbol,Dict{Tuple{UInt64,Int64},Int64}}, ::typeof(Main.PlutoRunner.format_output_default), ::Any)@PlutoRunner.jl:474
#format_output#18(::Pair{Symbol,Dict{Tuple{UInt64,Int64},Int64}}, ::typeof(Main.PlutoRunner.format_output), ::AbstractPlotting.Scene)@PlutoRunner.jl:491
formatted_result_of(::Base.UUID, ::Bool, ::Nothing)@PlutoRunner.jl:416
top-level scope@none:1
@fonsp
Copy link
Owner

fonsp commented Dec 14, 2020

try #155 (comment)

@grero
Copy link
Author

grero commented Dec 14, 2020

Hm, doesn't that comment refer to the fact that things like sliders don't have a display method? It is not clear to me how that comment addresses showing the actual plots. Plots showed up just fine until I did an upgrade to the latest versions of Pluto and WGLMakie, so something must have changed somewhere.

@fonsp
Copy link
Owner

fonsp commented Dec 14, 2020

Can you try to narrow down which of the two upgrades caused the problem?

@grero
Copy link
Author

grero commented Dec 15, 2020

It seems that the issue must be with Pluto, since I can plot with WGLMakie outside of Pluto.

@fonsp
Copy link
Owner

fonsp commented Dec 15, 2020

The issue is with the combination of the two packages. Can you downgrade both packages, one by one, to narrow down which upgrade caused the problem? That info would make it much easier to fix.

@fonsp fonsp added the other packages Integration with other Julia packages label Dec 17, 2020
@gszep
Copy link

gszep commented Dec 19, 2020

I think the examples with WGLMakie.jl break when
WGLMakie v0.2.9 ⇒ v0.2.10

@gszep
Copy link

gszep commented Dec 19, 2020

@grero this closes your issue I think JuliaPlots/WGLMakie.jl#75 (comment)

@fonsp
Copy link
Owner

fonsp commented Dec 20, 2020

Thanks for tracking down the problem @gszep !

@fonsp fonsp closed this as completed Dec 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
other packages Integration with other Julia packages
Projects
None yet
Development

No branches or pull requests

3 participants