You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"dixTxt" seems to be used to determine the "direction" of the train. Since I dont use it for my case I fixed it by adding a check in the pard_station_board_request method
try:
direction = raw_leg['dirTxt']
except KeyError:
raw_leg['dirTxt'] = "Unknown Direction"
import datetime, csv
import time
import pytz # Ensure you have pytz installed
from pyhafas import HafasClient
from pyhafas.profile import DBProfile, VSNProfile
client = HafasClient(DBProfile(), debug=True)
Trying to get the departures generates a Key Error in this specific case when encountering this substitution for a canceled train:
The text was updated successfully, but these errors were encountered: