Wails version family
v2
Operating System
Windows
Description
Every time a browser client loads the page under wails dev, two error lines show up in the terminal:
ERR | process message error: runtime:ready -> Unknown message from front end: runtime:ready
ERR | Unknown message from front end: runtime:ready
Nothing actually breaks, but the wording cost me a while: "Unknown message from front end" sounds like my own frontend sent something malformed. It didn't. runtime:ready comes from the runtime Wails injects.
The desktop window doesn't trigger it. Only browser clients do.
To Reproduce
wails init -n testbed -t vanilla
cd testbed && wails dev
- Wait for the
navigate to: http://localhost:34115 line. Terminal is still clean at this point.
- Open
http://localhost:34115 in a browser.
- Two
ERR lines appear, and two more on every refresh.
Expected behaviour
The dev server should swallow runtime:ready the way the desktop frontends already do, and log nothing. It's a runtime control message, not application traffic.
Screenshots
No response
Attempted Fixes
Traced it through the code:
- The injected runtime always ends init with
WailsInvoke("runtime:ready") (v2/internal/frontend/runtime/desktop/main.js).
- In dev mode the asset server picks the IPC shim by User-Agent (
v2/pkg/assetserver/assetserver_dev.go), so the desktop webview and a browser end up on different transports.
- windows/darwin/linux all consume
runtime:ready before dispatching. The dev server's websocket loop only special-cases drag, so it reaches dispatcher.ProcessMessage, which routes on the first byte and has no case for r.
Two lines rather than one because the dispatcher logs it in a deferred handler and the dev server then logs the returned error again.
Searched the tracker for "Unknown message from front end" and "process message error", nothing existing. (runtime:ready itself isn't searchable, GitHub splits on the colon.)
I have a fix, PR to follow.
System Details
# Wails
Version | v2.12.0
# System
| OS | Windows 10 Home China |
| Version | 2009 (Build: 26200) |
| ID | 25H2 |
| Go Version | go1.26.4 |
| Platform | windows |
| Architecture | amd64 |
| CPU | Intel(R) Core(TM) i7-14700HX |
| GPU 1 | NVIDIA GeForce RTX 4070 Laptop GPU (NVIDIA) - Driver: 32.0.15.8088 |
| GPU 2 | Intel(R) UHD Graphics (Intel Corporation) - Driver: 32.0.101.6790 |
| Memory | 16GB |
# Dependencies
| Dependency | Package Name | Status | Version |
| WebView2 | N/A | Installed | 150.0.4078.83 |
| Nodejs | N/A | Installed | 22.15.1 |
| npm | N/A | Installed | 10.9.2 |
| *upx | N/A | Available | |
| *nsis | N/A | Available | |
Additional context
Only affects wails dev with a browser client, since the message only reaches the dispatcher over the websocket transport.
Terminal output from the steps above, trimmed to the first two loads:
Using DevServer URL: http://localhost:34115
Using Frontend DevServer URL: http://localhost:5173/
INF | Serving assets from frontend DevServer URL: http://localhost:5173/
Watching (sub)/directory: C:\Users...\testbed
[WebView2] Environment created successfully
To develop in the browser and call your bound Go methods from Javascript, navigate to: http://localhost:34115
ERR | process message error: runtime:ready -> Unknown message from front end: runtime:ready
ERR | Unknown message from front end: runtime:ready
ERR | process message error: runtime:ready -> Unknown message from front end: runtime:ready
ERR | Unknown message from front end: runtime:ready
The desktop window had already loaded before navigate to printed, and logged nothing of its own. Everything above appeared only once the browser connected.
Wails version family
v2
Operating System
Windows
Description
Every time a browser client loads the page under
wails dev, two error lines show up in the terminal:ERR | process message error: runtime:ready -> Unknown message from front end: runtime:ready
ERR | Unknown message from front end: runtime:ready
Nothing actually breaks, but the wording cost me a while: "Unknown message from front end" sounds like my own frontend sent something malformed. It didn't.
runtime:readycomes from the runtime Wails injects.The desktop window doesn't trigger it. Only browser clients do.
To Reproduce
wails init -n testbed -t vanillacd testbed && wails devnavigate to: http://localhost:34115line. Terminal is still clean at this point.http://localhost:34115in a browser.ERRlines appear, and two more on every refresh.Expected behaviour
The dev server should swallow
runtime:readythe way the desktop frontends already do, and log nothing. It's a runtime control message, not application traffic.Screenshots
No response
Attempted Fixes
Traced it through the code:
WailsInvoke("runtime:ready")(v2/internal/frontend/runtime/desktop/main.js).v2/pkg/assetserver/assetserver_dev.go), so the desktop webview and a browser end up on different transports.runtime:readybefore dispatching. The dev server's websocket loop only special-casesdrag, so it reachesdispatcher.ProcessMessage, which routes on the first byte and has no case forr.Two lines rather than one because the dispatcher logs it in a deferred handler and the dev server then logs the returned error again.
Searched the tracker for "Unknown message from front end" and "process message error", nothing existing. (
runtime:readyitself isn't searchable, GitHub splits on the colon.)I have a fix, PR to follow.
System Details
Additional context
Only affects
wails devwith a browser client, since the message only reaches the dispatcher over the websocket transport.Terminal output from the steps above, trimmed to the first two loads:
Using DevServer URL: http://localhost:34115
Using Frontend DevServer URL: http://localhost:5173/
INF | Serving assets from frontend DevServer URL: http://localhost:5173/
Watching (sub)/directory: C:\Users...\testbed
[WebView2] Environment created successfully
To develop in the browser and call your bound Go methods from Javascript, navigate to: http://localhost:34115
ERR | process message error: runtime:ready -> Unknown message from front end: runtime:ready
ERR | Unknown message from front end: runtime:ready
ERR | process message error: runtime:ready -> Unknown message from front end: runtime:ready
ERR | Unknown message from front end: runtime:ready
The desktop window had already loaded before
navigate toprinted, and logged nothing of its own. Everything above appeared only once the browser connected.