Skip to content

feat: Improve geocoding for international locations with special characters (#488)#491

Merged
Orinks merged 3 commits intodevfrom
eli/issue-488-geocoding-unicode
Mar 19, 2026
Merged

feat: Improve geocoding for international locations with special characters (#488)#491
Orinks merged 3 commits intodevfrom
eli/issue-488-geocoding-unicode

Conversation

@Orinks
Copy link
Owner

@Orinks Orinks commented Mar 19, 2026

Summary

Fixes geocoding failures for international cities with special characters (ø, ü, é, ñ, etc.) when typed with ASCII equivalents.

Changes

  • When Open-Meteo geocoding returns zero results, retries with Unicode diacritics expansion
  • Common substitutions: o→ø/ö, u→ü, a→ä/å/á, e→é/è, n→ñ, etc.
  • 'Tromso' now finds 'Tromsø', 'Zurich' finds 'Zürich', 'Sao Paulo' finds 'São Paulo'
  • Added unidecode as optional dependency for normalization
  • Tests covering ASCII-to-Unicode matching

Closes #488

Orinks and others added 3 commits March 19, 2026 01:34
…acters (#488)

- Add Unicode diacritics expansion when search returns zero results
- Tries common substitutions: o→ø/ö, u→ü, a→ä/å/á, e→é/è, n→ñ, etc.
- 'Tromso' now finds 'Tromsø', 'Zurich' finds 'Zürich', etc.
- Added unidecode as optional dependency for normalization
The location dialog uses LocationManager.search_locations which made
direct API calls bypassing the OpenMeteoGeocodingClient fallback.
Now delegates to the client with Unicode variant expansion when the
direct search returns zero results.
@Orinks Orinks merged commit e6bad46 into dev Mar 19, 2026
3 checks passed
@Orinks Orinks deleted the eli/issue-488-geocoding-unicode branch March 19, 2026 02:11
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

Successfully merging this pull request may close these issues.

1 participant