Switch map tiles from CartoDB positron to OpenStreetMap (no API key)

CartoDB's positron basemap now renders an "API KEY REQUIRED" watermark.
Use tiles="OpenStreetMap" via a new MAP_TILES constant instead.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-09-07 19:08:09 +02:00
parent caecc60c7b
commit e3bbd4d264
6 changed files with 43 additions and 11 deletions
+14
View File
@@ -36,6 +36,20 @@ Numeric parsing is deliberately deferred to `get_map_data` (`pd.to_numeric(...,
errors="coerce")`). Don't "fix" columns to float on load — blank coordinates and
leading-zero PLZ both depend on the string representation.
## CartoDB "positron" tiles now require an API key (2026-09-07)
The original `folium.Map(tiles="CartoDB positron")` started rendering an
"API KEY REQUIRED / carto.com/basemaps/apikey" watermark Carto moved its
basemaps behind a key. Switched to `tiles="OpenStreetMap"` (constant
`MAP_TILES`), which needs no key. Trade-off: OSM standard tiles are more
colourful than positron's muted grey. Other no-key options if a lighter look is
wanted: OSM Germany (`tile.openstreetmap.de`), OSM France Hot
(`{s}.tile.openstreetmap.fr/hot`) both still colourful. Truly muted
key-free basemaps are hard to find now.
Don't assume a "free" third-party tile source stays free pin the provider in
one constant so swapping it is a one-line change.
## Nominatim query order matters
`geocode_city` returns the **first** hit, trying PLZ-qualified first, then each