exlab_wizard.window.pywebview_app#
pywebview-driven native window. Backend Spec §15.3.2.
Opens a single pywebview window pointed at
http://127.0.0.1:<port> from the handshake. Window title, size, and
icon are hard-coded here per §15.3.2; devtools are gated by the
EXLAB_DEBUG env var so release artifacts never enable them.
The actual webview import is deferred and isolated behind helper
functions so unit tests on a headless host can exercise URL building,
debug flag detection, and the assembly path without booting a real
webview backend.
Functions
|
Return the URL the window points at. |
True when |
|
|
Open a single pywebview window pointed at the handshake's port. |
- exlab_wizard.window.pywebview_app.build_window_url(handshake)[source]#
Return the URL the window points at.
Always loopback (Backend §4.1: “binds to
127.0.0.1only”); the handshake’s port is mandatory.- Parameters:
handshake (
ServerHandshake)- Return type:
- exlab_wizard.window.pywebview_app.is_debug_enabled()[source]#
True when
EXLAB_DEBUGis set to a truthy string. Backend §15.3.2.- Return type:
- exlab_wizard.window.pywebview_app.run_window(handshake, *, create_window=None, start=None)[source]#
Open a single pywebview window pointed at the handshake’s port.
create_windowandstartare dependency-injection hooks for tests; production code defers towebview.create_windowandwebview.start. Returns 0 on clean exit.