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

fix(server): penalize null geodata fields when searching places #8408

Merged
merged 1 commit into from Mar 31, 2024

Conversation

mertalev
Copy link
Contributor

Description

The test for /search/places was recently made stricter by checking that the top result is the most relevant. However, it's actually not guaranteed to be the first result as Paris and Paris Leona are tied in score. The reason for this is that the latter has null for admin2Name, which gets coalesced to 0 (a perfect match). This PR sets null values to have a score of 0.1 to avoid rewarding a lack of data.

How Has This Been Tested?

Tested that the order for this is now deterministic and the test does not flake.

@mertalev mertalev merged commit 5bc9158 into main Mar 31, 2024
24 of 25 checks passed
@mertalev mertalev deleted the fix/server-flaky-search-test branch March 31, 2024 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants