You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to access TileBoard from outside of Hassio shows a blank screen and the following error in the console:
DOMException: An invalid or illegal string was specified Possibly unhandled rejection: {}
This error seems to be an issue with the web sockets failing to connect. Debugging the code it appears that the window.WS_URL_OVERRIDE is set to null/api/websocket and will ignore any wsUrl value provided in the config file.
Steps to Reproduce
Install the TileBoard Addon
In the Configuration section, under Network add a valid port
Access the TileBoard using <hassio-ip-or-url>:<port-from-step-3>
Notes
When looking at the page source it seems there is a line in the index.html file that is setting the url override: window.WS_URL_OVERRIDE = "null/api/websocket"; but looking at the TileBoard source this should be window.WS_URL_OVERRIDE = null;. If I put a breakpoint in the JS and change the override URL to null the page loads correctly.
Searching through this repository there is the direct.gtpl file that seems like it's supposed to handle the direct connection to TileBoard (as opposed to the ingress connection). In this file there is this chunk of code which seems like the culprit:
{{ if .websocket_url }}
sub_filter 'WS_URL_OVERRIDE = null' 'WS_URL_OVERRIDE = "{{ .websocket_url }}/api/websocket"';
{{ end }}
But it seems like this shouldn't be executing as I haven't set .websocket_url as far as I know.
Environment
Below are my settings and the config I'm trying to get loading on my device.
I don't have time to figure this one out. Ideally we should figure out if HA API provides some way to auto-detect it (like it did back when this was implemented).
Description
Trying to access TileBoard from outside of Hassio shows a blank screen and the following error in the console:
This error seems to be an issue with the web sockets failing to connect. Debugging the code it appears that the
window.WS_URL_OVERRIDE
is set tonull/api/websocket
and will ignore anywsUrl
value provided in the config file.Steps to Reproduce
<hassio-ip-or-url>:<port-from-step-3>
Notes
When looking at the page source it seems there is a line in the
index.html
file that is setting the url override:window.WS_URL_OVERRIDE = "null/api/websocket";
but looking at the TileBoard source this should bewindow.WS_URL_OVERRIDE = null;
. If I put a breakpoint in the JS and change the override URL tonull
the page loads correctly.Searching through this repository there is the direct.gtpl file that seems like it's supposed to handle the direct connection to TileBoard (as opposed to the ingress connection). In this file there is this chunk of code which seems like the culprit:
But it seems like this shouldn't be executing as I haven't set
.websocket_url
as far as I know.Environment
Below are my settings and the config I'm trying to get loading on my device.
config.js
Addon Settings
The text was updated successfully, but these errors were encountered: