digidem / digidem/comapeo-map-server
Add retry mechanism for default online style fetches that fail due to network errors
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 4
- Forks
- 1
- Avg merge
- 2h 18m
- Merged PRs (30d)
- 7
Description
We have some application code that attempts to update the displayed map from the offline fallback to the online style when the network is connected again. However, network being "connected" does not necessarily mean that internet access is available and getting that information can be limited based on which APIs you have access to. For example, desktop uses the window online event, which only reflects when you regain access to a network but makes no guarantees about access to the internet.
To my knowledge, fetch calls that fail due to lack of internet connection do so immediately i.e. no configurable timeout to wait for. Given this, I think it would make sense to set up a retry for the online style if that kind of failure does occur.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the application code that updates the displayed map from the offline fallback to the online style, then inspect how the desktop window online event triggers the fetch. Add retry behavior for online-style fetches that fail from unavailable internet access, and verify that a failed fetch is retried when connectivity is actually restored.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 50/100