GeezerVison is showing github.com — UserWarning: The browser you selected might not be installed on your system · Issue #44 · webui-dev/python-webui
UserWarning: The browser you selected might not be installed on your system #44
Description
Bug:
I have a minimal script on Linux with Python 3.14.2 and webui2 2.5.7
Example script
from webui import webui
from webui.webui import Browser
my_window = webui.Window()
my_window.show_browser("http://localhost:8080/", Browser.Firefox)
webui.wait()
Expected behaviour
Firefox based web UI opens and webui.wait() blocks the script.
Actual behaviour
With Firefox installed. The Firefox window correctly displays without the decorations, but the script exits with:
/home/aiden/Workspace/python-webui-test/.venv/lib64/python3.14/site-packages/webui/webui.py:827: UserWarning: The browser you selected might not be installed on your system. if not success: warnings.warn("The browser you selected might not be installed on your system.")
Shortly after a timeout. The Firefox window stays open and displays the correct content.
Activity
AlbertShown commented on Mar 5, 2026
I think that's because WebUI waits for the WebSocket connection but it never come in. Can you double check that your HTML is including webui.js ?
Since you chose to use your own web server instead of WebUI web server, then you may need this:
Python Script:
# Set the port that WebUI should use. This means `webui.js` will be available at:
# http://localhost:YOUR_PORT_NUMBER/webui.js
my_window.set_port(7070)
HTML:
<script src="http://localhost:7070/webui.js"></script>
AlbertShown commented on Mar 5, 2026
Just to let you know, in case you chose to use WebUI web server instead, then script will be something like this:
from webui import webui
from webui.webui import Browser
my_window = webui.Window()
my_window.set_root_folder("/home/Foo/Bar/MyWebSiteExample/")
my_window.show_browser("index.html", Browser.Firefox)
webui.wait()
HTML:
<script src="webui.js"></script>
aidenbell commented on Mar 5, 2026
Ah this doesn't seem clear from the docs (own issue) that webui.js needs to be required in the browser instance. I was pointing it at a pre-existing Django application that spawned its own webserver.
I added <script src="webui.js"></script> to the backend's HTML output but the issue persists. Am I right in assuming that webui.js is resolved by some magic, rather than being an actual file needed to be included? I can't find it in the repo.
aidenbell commented on Mar 5, 2026
Edit, I got it working using the FQ localhost pointing to the webui webserver as suggested above.
I feel like this could be better documented when "bringing your own webserver" that the webui lib has a webserver spawned for comms with the browser instance. I like the setup though.
AlbertShown commented on Mar 6, 2026
Ah this doesn't seem clear from the docs
We have C own server examples, but not in Python yet, I will create one soon.
assuming that webui.js is resolved by some magic
The webui.js is a virtual file get generated by WebUI at runtime to get bindings list securely.
Metadata
Metadata
Development
No branches or pull requestsIssue actions