digidem / digidem/comapeo-map-server

Add retry mechanism for default online style fetches that fail due to network errors

Open
#44 0 comments 0 reactions 0 assignees View on GitHub

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

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. 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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.