MarkusH / bvg-grabber

Querying the upcoming public transport departures in Berlin
BSD 3-Clause "New" or "Revised" License
28 stars 6 forks source link

new info feature messing up departure matching #18

Closed bh closed 4 years ago

bh commented 4 years ago
from bvggrabber.api.scheduleddeparture import ScheduledDepartureQueryApi, Vehicle

query = ScheduledDepartureQueryApi("S Schulzendorf (Berlin)", Vehicle.BUS | Vehicle.S, limit=100)
res = query.call()
print(res.to_json)

Results in:

soup = BeautifulSoup(response.text) Traceback (most recent call last): File "t.py", line 6, in res = query.call() File "/home/bh/devel/epaper/.venv/lib/python3.8/site-packages/bvggrabber/api/scheduleddeparture.py", line 74, in call end=tds[2].text.strip(), IndexError: list index out of range

API request URL:

https://mobil.bvg.de:443/Fahrinfo/bin/stboard.bin/dox?input=S+Schulzendorf+%28Berlin%29&time=20%3A18&date=19.01.2020&productsFilter=0001000&maxJourneys=10&start=yes

MarkusH commented 4 years ago

Fixed in #19 and released in v0.2.0