leftshift / python_mvg_api

Yet another library for fetching MVG departures.
https://pypi.org/project/mvg-api/
MIT License
65 stars 18 forks source link

StationID Format has changed #15

Closed Bastlwastl42 closed 4 years ago

Bastlwastl42 commented 4 years ago

Hi,

i noticed that the format of the stationID has been changed, probably somewhere yesterday. It used to be an simple integer, but is now rather complex string format. E.g. for the Munich Central Station, the ID is not 6 anymore but de:09162:6. This in return causes all the type checking for the stationID to crash, however simply using this string format is fine. I fixed my local versionby removing the sanity check in the get_departure, but i saw that checks like isinstance(stationID, int) are also in get_route, which i never used. It might be also fine by replacing the instance cheks here with a check to str?

Best