From 829021aa0f0a706c6301a825eb3057ce34a3a0c2 Mon Sep 17 00:00:00 2001 From: Alicia Sykes Date: Tue, 29 Mar 2022 15:38:30 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=93=9D=20Troubleshooting:=20fix=20widget?= =?UTF-8?q?=20timeout=20err=20(#581)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/troubleshooting.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/troubleshooting.md b/docs/troubleshooting.md index b98ca4b3..ffa5c0f8 100644 --- a/docs/troubleshooting.md +++ b/docs/troubleshooting.md @@ -278,12 +278,19 @@ If you're serving Dashy though a CDN, instead of using the Node server or Docker ## Widget Errors +#### Find Error Message If an error occurs when fetching or rendering results, you will see a short message in the UI. If that message doesn't addequatley explain the problem, then you can [open the browser console](/docs/troubleshooting.md#how-to-open-browser-console) to see more details. +#### Check Config Before proceeding, ensure that if the widget requires auth your API is correct, and for custom widgets, double check that the URL and protocol is correct. +#### Timeout Error +If the error message in the console includes: `Error: timeout of 500ms exceeded`, then your Glances endpoint is slower to respond than expected. You can fix this by [setting timeout](https://github.com/Lissy93/dashy/blob/master/docs/widgets.md#setting-timeout) to a larger value. This is done on each widget, with the `timeout` attribute, and is specified in ms. E.g. `timeout: 5000` would only fail if no response is returned within 5 seconds. + +#### CORS error If the console message mentions to corss-origin blocking, then this is a CORS error, see: [Fixing Widget CORS Errors](#widget-cors-errors) +#### More Info If you're able to, you can find more information about why the request may be failing in the Dev Tools under the Network tab, and you can ensure your endpoint is correct and working using a tool like Postman. ---