-
Notifications
You must be signed in to change notification settings - Fork 9
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
Web interface partially working when executed through vscode server port forward #52
Comments
The problem is that the visualization code might be hardcoded to have the URL path as localhost:port/ instead of localhost:port/more/stuff, and needs fixing. |
Just wondering if you have tested forwarding the new experimental visualization framework via Solara: https://github.com/projectmesa/mesa-examples/tree/main/examples/boltzmann_wealth_model_experimental. |
There are still more / prefixes at mesa-viz-tornado/mesa_viz_tornado/ModularVisualization.py Lines 290 to 301 in 8ef4748
|
Unfortunatley, this does not work I tried your two suggestions ;
I do not see how to make any progress on this; |
If you want to inspect the mesa-viz-tornado, you might want to try adding As a fallback, for the Solara option, I wonder if any of the options in https://solara.dev/docs/deploying/self-hosted is viable for your current use case. |
Describe the bug
I'm running a mesa simulation on a remote machine. I'm programming on the remote with vscode server; The issue comes with the visualisation.
Running, for example
mesa runserver examples/wolf_sheep
, vscode correctly detects the server being created on port 8521 and sets up a port forward fromremote:8521 to http://localhost:8080/proxy/8521/
The
proxy/8521/
that appears in the URL seems to be causing trouble to mesa-viz-tornado.Here is what I get :
Then, opening the developper console, I noticed a lot of messages complaining about the inability to get various files , for example
I then edited your
modular_template.html
, replacing all the/static/
and/local/
to respectivelystatic/
andlocal/
removing the leading/
; Then , the visualization gets more elements but I'm not yet there;As you can see, there are some remaining "Unexpected token" errors . It seems to me also that :
Do you have any idea of how to fix this ? On the vscode side, I did not find any way to change the forwarded port prefix, to remove the
proxy/8521/
prefix; My hope is to adapt your html production code to prevent the ressource loading to go back to the root of the site;The text was updated successfully, but these errors were encountered: