Cannot access panel apps served on the same network

I created a new conda environment, upgraded to Bokeh 2.4.1 and Panel 0.12.4, served up an app like below.

panel serve myapp --allow-websocket-origin=192.168.1.3:5007 --port 5007

I can access the app from the same computer but I cannot access the same app from any other computer on the network (192.168.1.3:5007/myapp). I have another bokeh server (bokeh version 1.4.0 and panel version 0.8.1) running and I can access all the apps just fine. What could I be doing wrong?

I am having problem accessing panel apps served remotely (from AWS ec2) as well with Bokeh 2.4.1 and Panel 0.12.4.
nobody else having issues accessing panel apps over local or remote network?
any help to diagnose would be greatly appreciated.

Hi @kmallick2000

You need to specify the --address argument in the panel serve statement. Without it, the panel/bokeh server will be running on the localhost. I suspect if you look in the terminal log where you invoke the server, you will see something like the following indicating this.


2021-10-21 13:42:04,568 Bokeh app running at: http://localhost:5007/myapp

Thanks. I have tried that already. I am currently using:

panel serve myapp --allow-websocket-origin=192.168.1.3:5007 --port 5007 --address 192.168.1.3

But nothing is showing up in http://192.168.1.3:5007/myapp when I am trying to access it from anywhere away from the server. I am at a loss!

@kmallick2000

I run panel/bokeh servers locally and hosted on Heroku all the time. I have never experienced the problem you’re encountering. My current environment is python 3.9.7, bokeh 2.3.3, and panel 0.12.0, so that is a bit behind what you are using for the bokeh and panel releases.

Your latest statement seems syntactically correct. (I assume you’re running with the bokeh server directory structure in a folder named myapp with a main.py file in that directory?)

Do you have any errors in the Javascript console of the client’s browser? Perhaps there are resources it is unable to find or load that cause the behaviors you experience…

Otherwise, I think a complete minimal reproducible example will be necessary for the panel developers to comment more on possible sources of the issue.

1 Like

Thanks again. I appreciate your help.
I have also been running panel/bokeh servers on EC2 for online access and I have never run into this issue.

Yes, I have my main.py inside /bokeh/myapp folder.

I cannot seem to find anything glaring in JS console on client side, all I see is

‘‘Failed to get subsystem status for purpose {rejected: true, message: {…}}’’

For diagnostics, I just posted a very simple panel example on my EC2 instance under ‘myapp’ folder. I can see the app on my local desktop inside EC2 instance. However I cannot access the app on the public side. Let me know if you can see on your end.

http://52.38.160.125:5007/myapp

Here is a screenshot from the app working when I am accessing it locally on my EC2 node.

And here is a snip of my console where I am serving the panel app

On the off chance that you have state hanging around in your browser from your very old bokeh/panel setup, you might try clearing the browser cache.

I can see your app at the address provided. I am accessing from the latest version of Google Chrome on Mac OSX.

Thats strange. I cannot access that address from my work PC. I cleared all the cache and still no luck. I have tried switching between Chrome and Edge, no luck there either.

I come home and I can see it just fine. Now I feel like a dork.

What else can I check on my work PC or browser? There is no firewall issue that I know of.

The only thing I can think of is that perhaps your company network disallows websocket connections. The bokeh server – and by extension panel server – use the websocket protocol to synchronize info between the browser and the server.

1 Like

If your company thinks about security they might setup firewall rules etc. Report the problem to the network team. They also have skills and tools to investigate.

For example in my company I’m not allowed to view new websites. URLs have to be whitelisted for me to access them. But I normally get an error message in my browser.

Thank you all for the suggestions. I am reporting it to the network team at work. Hopefully its resolved. It definitely made me pull out all my hair!

1 Like