mapbox / mapbox/mapbox-gl-geocoder
Search hanging despite successful api call
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 388
- Forks
- 181
- PR merge metrics
- No merged PRs in 30d
Description
Mapbox version: 0.44.1
Geocoder version: 2.2.0
I'm attempting to get the geocoder to work, but it consistently hangs despite the network request returning successful:

Additionally I've tracked down that this then clause never gets called. I tried digging into the client to figure out why but didn't make much progress: https://github.com/mapbox/mapbox-gl-geocoder/blob/master/lib/index.js#L166. Any guidance would be helpful!
My setup is local and the code I'm using to call it is:
map.addControl(new MapboxGeocoder({
country: 'US',
accessToken: AccessToken,
}));
Contributor guide
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
Start by reproducing the reported setup with MapboxGeocoder, then inspect lib/index.js around line 166 where the unresolved then clause is mentioned. Trace why the successful request does not complete the search, and consider the issue done when the same configuration finishes instead of hanging.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100