Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MapBox lookup] Ommited result #1676

Open
CarlosUvaSilva opened this issue Dec 19, 2024 · 3 comments
Open

[MapBox lookup] Ommited result #1676

CarlosUvaSilva opened this issue Dec 19, 2024 · 3 comments

Comments

@CarlosUvaSilva
Copy link

Expected behavior

Using Mapbox as the lookup API I'm getting some ommited results
e.g -> "geometry"=>{"type"=>"Point", "coordinates"=>[X, Y], "interpolated"=>true, "omitted"=>true}

I want to accept these results as valid instead of ignoring and using the next one in the array.

Actual behavior

Geocoder actually ignores ommited: true results instead of using them

Steps to reproduce

Geocoder.search("Rua Egas Moniz 8, 1900-218, Lisboa")

Environment info

  • Geocoder version: 1.8.3
  • Rails version: 8.0.1
  • Database (if applicable):
  • Lookup (if applicable): mapbox
@alexreisner
Copy link
Owner

I'm not sure I understand this issue. Some of the results returned by Geocoder have omitted: true and some don't. Are you saying Geocoder should be handling these results differently?

@CarlosUvaSilva
Copy link
Author

CarlosUvaSilva commented Dec 19, 2024

@alexreisner if the first result is ommited is ignored, the second one is used.
I'd like a way to override this behaviour. To use the first value even if it's ommited

@alexreisner
Copy link
Owner

Hmm, I think I need more context. Can you share some code that shows the result being ignored?

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

No branches or pull requests

2 participants