Skip to content

Add default timeout to network calls - #1280

Merged
kevinherdez merged 1 commit into
NWACus:mainfrom
kevinherdez:kevinherdez/timeoutOnNetworkCalls
Nov 19, 2026
Merged

kevinherdez merged 1 commit into
NWACus:mainfrom
kevinherdez:kevinherdez/timeoutOnNetworkCalls

Conversation

@kevinherdez

@kevinherdez kevinherdez commented Nov 19, 2026 •

Copy link
Copy Markdown
Collaborator

@rustynwac is consistently hitting an issue where the Forecast map, weather tab, and avalanche selector screen are showing an infinite spinner. There's no timeout set on Axios so the default is to wait forever until the call returns.

This adds a 20 second timeout which will result in a "no response" error if the API doesn't give a response. Axios will retry the call 3 times before erroring out and the user sees an error message.

A condition in safeFetch is also added to report each timeout to Sentry.


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

@kevinherdez
kevinherdez added this pull request to the merge queue Nov 19, 2026
Merged via the queue into NWACus:main with commit 76f92ed Nov 19, 2026
6 checks passed
@kevinherdez
kevinherdez deleted the kevinherdez/timeoutOnNetworkCalls branch November 19, 2026 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant