WIP: Deutschland als zweite Datenquelle (gtfs.de)

- mehrere Quellen (ch, de) mit je eigenem Fahrplan und Echtzeit-Feed
- OSM CH+DE, mit osmium auf Schienennetz gefiltert, für pfaedle
- Landesgrenze CH gegen doppelte grenzüberschreitende Züge
- Import robust gegen andere Spaltenreihenfolge (gtfs.de)
- Kacheln für CH+DE (Zoom 14)

Noch nicht vollständig getestet (pfaedle auf Deutschland läuft).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01X48pE4bzjHej8w9HyZXCjb
This commit is contained in:
Claude
2026-10-21 21:27:54 +02:00
parent 2e3c10a6c4
commit 2a4962c379
11 changed files with 370 additions and 168 deletions
+5 -3
View File
@@ -34,8 +34,10 @@ def parse(data: bytes, known_trips: dict):
return version, out
def fetch() -> bytes:
r = httpx.get(C.RT_URL, follow_redirects=True, timeout=30, headers={
"Authorization": f"Bearer {C.RT_KEY}", "User-Agent": C.USER_AGENT})
def fetch(url: str, key: str = "") -> bytes:
headers = {"User-Agent": C.USER_AGENT}
if key:
headers["Authorization"] = f"Bearer {key}"
r = httpx.get(url, follow_redirects=True, timeout=30, headers=headers)
r.raise_for_status()
return r.content