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
The oft-cited third-party Svelte library is the Crown Framework, but it is unmaintained.
Hooking into window.onerror and window.onunhandledrejection seems like one valid option.
window.onerror=(msg,url,line,col,error)=>{// capture error & emit telemetry// show a full error page};window.onunhandledrejection=(event)=>{// capture error & emit telemetry// show a full error page};
Sentry implies their Svelte SDK captures runtime errors
For recording stacktraces in telemetry:
Let's use Sentry
Ideally we proxy the requests through our backend
The text was updated successfully, but these errors were encountered:
Capture more information for the "unknown error" case. It's happening frequently. Here's some code from ChatGPT that might be helpful:
if(!error.response){if(error.code==='ECONNABORTED'){console.log('Request timed out');}elseif(error.message.includes('Network Error')){console.log('Network error - the request was made but no response was received');}elseif(error.message==='Request aborted'){console.log('Request was aborted');}else{console.log('Unknown error occurred');}}
Capture the full page route. This will inform us of the environment dev/test/stage/prod, the specific dashboard, and any query parameters.
There were some challenges to get this working locally and not have a lot of spam. Especially when actively modelling there are a lot of errors for the resource API when the model is not valid.
For capturing runtime errors:
window.onerror
andwindow.onunhandledrejection
seems like one valid option.For recording stacktraces in telemetry:
The text was updated successfully, but these errors were encountered: