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

Improve the checking of results from the NSI matcher.. #8828

Merged
merged 2 commits into from
Nov 30, 2021

Conversation

bhousel
Copy link
Member

@bhousel bhousel commented Nov 29, 2021

(fixes: osmlab/name-suggestion-index#5693)

Previously the code would accept the first useful match, however this match
might be an "alternate" match. Now we keep iterating until we find a "primary"
match.

This bug could cause the validator to suggest upgrading well-tagged features to
a less wanted feature type. For example a "Tesla Supercharger" would flip to
a "Tesla Destination Charger" if it had "Tesla" anywhere in its list of tags
(because short_name=Tesla is an "alternate" match for both destination
chargers and super chargers)

(fixes: osmlab/name-suggestion-index#5693)

Previously the code would accept the first useful match, however this match
might be an "alternate" match.  Now we keep iterating until we find a "primary"
match.

This bug could cause the validator to suggest upgrading well-tagged features to
a less wanted feature type.  For example a "Tesla Supercharger" would flip to
a "Tesla Destination Charger" if it had "Tesla" anywhere in its list of tags
(because `short_name=Tesla` is an "alternate" match for both destination
chargers and super chargers)
@tyrasd tyrasd added bug A bug - let's fix this! preset An issue with an OpenStreetMap preset or tag validation An issue with the validation or Q/A code labels Nov 30, 2021
@tyrasd tyrasd merged commit 344a903 into develop Nov 30, 2021
@tyrasd tyrasd deleted the nsi_primary_match branch November 30, 2021 12:17
@bhousel
Copy link
Member Author

bhousel commented Nov 30, 2021

whoa thanks for the quick merge!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A bug - let's fix this! preset An issue with an OpenStreetMap preset or tag validation An issue with the validation or Q/A code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Superchargers want to flip over to destination chargers
2 participants