> get_driver_telemetry(2022, 4, driver = 'PER')
The first time a session is loaded, some time is required. Please be patient. Subsequent times will be faster
core INFO Loading data for Emilia Romagna Grand Prix - Race [v2.3.0]
api INFO Using cached data for driver_info
api INFO Using cached data for timing_data
api INFO Using cached data for timing_app_data
core INFO Processing timing data...
api INFO Using cached data for session_status_data
api INFO Using cached data for track_status_data
api INFO Using cached data for car_data
api INFO Using cached data for position_data
api INFO Using cached data for weather_data
api INFO Using cached data for race_control_messages
core INFO Finished loading data for 20 drivers: ['1', '11', '4', '63', '77', '16', '22', '5', '20', '18', '23', '10', '44', '31', '24', '6', '47', '3', '14', '55']
Error in py_to_r.default(.) : Object to convert is not a Python object
I took a look at the function, and I think the error raises because in line 14 the first command (tel %>% reticulate::py_to_r())$tel
already returns a data.frame, and then you try to convert it again with reticulate::py_to_r()
. I have removed this part of the code and seems that it works.