mapbox / mapbox/mapbox-search-ios

Bug: localFavoritesProvider needs a SearchEngine to work

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

Nobody has claimed this yet.

Dominant language
Swift
Stars
28
Forks
28
PR merge metrics
No merged PRs in 30d

Description

Trying to access `MapboxSearch.ServiceProvider.shared.localFavoritesProvider` will not return any favorites by default. For some weird reason, you need to define a `SearchEngine()` for it to work. The SearchEngine is not used or referenced at all, but removing it breaks the favoritesProvider. This needs to be fixed because it makes no sense.

Contributor guide

Open the contributing guide

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

Start at ServiceProvider.shared.localFavoritesProvider and compare its behavior with and without an explicitly created SearchEngine(). Trace the initialization dependency, then verify that localFavoritesProvider returns default favorites without requiring an unused SearchEngine; add or update coverage if the repository provides a relevant test location.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
mobile
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.