-
Notifications
You must be signed in to change notification settings - Fork 12
Using WGLMakie remotely with Pluto.jl #90
Comments
I think @koehlerson figured out a running setup? |
This works for me using JSServe
external_ip = #yourip e.g. "192.158.1.38/"
port = #somefreeport e.g. "10000"
JSServe.JSSERVE_CONFIGURATION.listen_port[] = port
JSServe.JSSERVE_CONFIGURATION.external_url[] = "http://$(external_ip)$(port)/"
JSServe.JSSERVE_CONFIGURATION.content_delivery_url[] = JSServe.JSSERVE_CONFIGURATION.external_url[]
import WGLMakie
JSServe.Page(;external_url="http://$(external_ip)$(port)/",listen_port=port, content_delivery_url=JSServe.JSSERVE_CONFIGURATION.external_url[]) |
Cool :) I'm going to leave this issue open, since this should all be handled in a reasonable way by |
Which configuration do you have? For me it’s still not working. With the same configuration below, it does not even work locally. I tried that on a fresh environment, here the
|
What do you mean by that? That configuration can't work locally... |
Sorry, I did not explain it well. I tried what @koehlerson suggested running Pluto on a remote machine and it wasn’t working, so I wanted to try again if it works locally. I tried the following.
By the configuration I meant the environment configuration in Now locally I get these errors:
|
Can you try locally to set a different port for JSServe or Pluto? |
You mean change only the |
How long did you actually wait for the plot to show up? These warnings should be non fatal, and it may take a while for the first plot to compile and show up... |
Well I waited quite long I think. I tried now to follow one of the examples of JSServe using WGLMakie… This works fine, even if it takes a bit. |
So, do I understand it correctly that it works now? |
Sorry, no. I am trying different things to understand better how it works. I tried to reproduce one of the examples here, deploying an app in the browser. But, still, with Pluto no luck. |
With Pluto I end up with the errors I’ve shown you and a blank output. |
If you do that, please take note if it just stays blank but interactive (can execute Julia code), or stays blank and freezes the notebook... |
Ok I tried your example and it works fine now. Thank you very much for the trouble. I don’t really know what was happening. I am using Chrome, btw. I also tried to use Pluto remotely again and it works! The following should work fine, for real this time. ### A Pluto.jl notebook ###
# v0.14.7
using Markdown
using InteractiveUtils
# ╔═╡ c336266a-bfcd-11eb-2b45-5751c174f10d
begin
using WGLMakie, JSServe
external_ip = "..."
listen_port = 1235
external_url = "http://$(external_ip):$(listen_port)"
JSServe.Page(;external_url, listen_port, content_delivery_url=external_url)
end
# ╔═╡ cf2bea58-1451-4d35-9c59-f7f60e9dcede
begin
xs = LinRange(0,1,200)
ys = xs
f(x,y) = exp(-x^2-y^2)*sin(x+y)
zs = f.(xs, ys')
surface(xs, ys, zs)
end
# ╔═╡ Cell order:
# ╠═cf2bea58-1451-4d35-9c59-f7f60e9dcede
# ╠═c336266a-bfcd-11eb-2b45-5751c174f10d |
I guess you were on the wrong versions then ;) |
I tried a simple example to run a Pluto notebook with a WGLMakie interactive plot.
When Pluto is run locally, the plots show just fine. On the other hand, if the notebook is launched on a remote machine (connection through a ssh tunnel), the plots are just blank and I get the warning
What I tried is the following (Pluto cells delimited by
begin…end
blocks):Maybe I didn’t understand how to configure the server with JSServe.
Thanks for any help.
The text was updated successfully, but these errors were encountered: