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
+9 -4
View File
@@ -62,8 +62,9 @@ A table view of everything in `orte.csv`.
Generated by `generate_map()`:
- Base layer: `CartoDB positron`, initial view centred on `[49.0, 9.0]`,
zoom 8 (roughly Baden-Württemberg).
- Base layer: **OpenStreetMap** standard tiles (`MAP_TILES`) no API key.
Initial view centred on `[49.0, 9.0]`, zoom 8 (roughly Baden-Württemberg);
the view auto-fits to the markers when there is more than one.
- One **`CircleMarker`** per unique `(city, lat, lon)` group. Radius scales
linearly with the visit count for that location
(`5 + count / max_count * 20` px), colour is DRK red (`#CC0000`).
@@ -72,8 +73,12 @@ Generated by `generate_map()`:
- If there are no usable coordinates at all, a dialog says so (and the status
bar shows a warning).
> The generated HTML pulls Leaflet, jQuery and Bootstrap from CDNs, so the map
> needs an internet connection to render even though the data is local.
> The generated HTML pulls Leaflet, jQuery and Bootstrap from CDNs, and the map
> tiles from `tile.openstreetmap.org`, so the map needs an internet connection to
> render even though the data is local. To change the look, set `MAP_TILES` near
> the top of `app.py` to another no-key provider Folium knows
> (`"OpenStreetMap"`, `"CartoDB positron"` *now needs a key*, or a custom
> `folium.TileLayer` URL such as OSM Germany / OSM France).
## Geocoding behaviour