Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] KeyError: "None of ['Date'] are in the columns" when fetching any driver's telemetry for season 2018 round 1 session 2 #677

Open
borolepratik opened this issue Jan 20, 2025 · 0 comments

Comments

@borolepratik
Copy link

borolepratik commented Jan 20, 2025

Describe the issue:

Seeing KeyError: "None of ['Date'] are in the columns" error when fetching any driver's telemetry for season 2018 round 1 session 2

Reproduce the code example:

import fastf1

# Parameters
year = 2018
grand_prix = 1
session = 2

# Load session data
session = fastf1.get_session(year, grand_prix, session)
session.load()

session.laps.pick_drivers("10").get_telemetry() # Gasly

Logs:

core           INFO 	Loading data for Australian Grand Prix - Practice 2 [v3.4.4]
req            INFO 	No cached data found for session_info. Loading data...
_api           INFO 	Fetching session info data...
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for driver_info. Loading data...
_api           INFO 	Fetching driver list...
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for session_status_data. Loading data...
_api           INFO 	Fetching session status data...
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for track_status_data. Loading data...
_api           INFO 	Fetching track status data...
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for _extended_timing_data. Loading data...
_api           INFO 	Fetching timing data...
_api           INFO 	Parsing timing data...
_api        WARNING 	Driver  5: Encountered 1 timing integrity error(s) near lap(s): [24].
This might be a bug and should be reported.
_api        WARNING 	Driver  7: Encountered 1 timing integrity error(s) near lap(s): [27].
This might be a bug and should be reported.
_api        WARNING 	Driver  9: Encountered 1 timing integrity error(s) near lap(s): [4].
This might be a bug and should be reported.
_api        WARNING 	Driver 55: Encountered 1 timing integrity error(s) near lap(s): [9].
This might be a bug and should be reported.
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for timing_app_data. Loading data...
_api           INFO 	Fetching timing app data...
req            INFO 	Data has been written to cache!
core           INFO 	Processing timing data...
core        WARNING 	Driver 11: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver 14: Lap timing integrity check failed for 2 lap(s)
core        WARNING 	Driver 18: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver  2: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver 27: Lap timing integrity check failed for 3 lap(s)
core        WARNING 	Driver 28: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver 31: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver 33: Lap timing integrity check failed for 2 lap(s)
core        WARNING 	Driver 35: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver 55: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver  7: Lap timing integrity check failed for 1 lap(s)
core        WARNING 	Driver 77: Lap timing integrity check failed for 1 lap(s)
req            INFO 	No cached data found for car_data. Loading data...
_api           INFO 	Fetching car data...
_api           INFO 	Parsing car data...
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for position_data. Loading data...
_api           INFO 	Fetching position data...
_api           INFO 	Parsing position data...
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for weather_data. Loading data...
_api           INFO 	Fetching weather data...
req            INFO 	Data has been written to cache!
req            INFO 	No cached data found for race_control_messages. Loading data...
_api           INFO 	Fetching race control messages...
req            INFO 	Data has been written to cache!
core           INFO 	Finished loading data for 20 drivers: ['10', '11', '14', '16', '18', '2', '20', '27', '28', '3', '31', '33', '35', '44', '5', '55', '7', '77', '8', '9']

Error message:

Traceback (most recent call last):
  at cell 6, line 1
  at /opt/python/envs/customPyEnv311/lib/python3.11/site-packages/fastf1/core.py, line 2813, in get_telemetry(self, frequency)
  at /opt/python/envs/customPyEnv311/lib/python3.11/site-packages/fastf1/core.py, line 438, in merge_channels(self, other, frequency)
  at /opt/python/envs/customPyEnv311/lib/python3.11/site-packages/pandas/core/frame.py, line 6122, in set_index(self, keys, drop, append, inplace, verify_integrity)
  at KeyError: "None of ['Date'] are, line 0, in the columns"
KeyError: "None of ['Date'] are in the columns"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant