Spaces:
Runtime error
Runtime error
Fix ReadTimeoutError crash on Space initialization
#2
by
aviavi12
- opened
This comment has been hidden
Problem
Space crashes with ReadTimeoutError when loading leaderboard submissions, followed by AssertionError at line 514.
Solution
Added robust error handling for empty/missing leaderboard data:
- Created
get_empty_leaderboard_df()helper function inapp.pyto return an empty DataFrame with proper column structure - Modified
refresh_leaderboard_data()to gracefully fall back to empty DataFrame when data is unavailable - Updated leaderboard initialization to display a friendly warning message when no data exists
- Enhanced
get_leaderboard_df()inpopulate.pyto handle missing datasets and "default-only" configs by returning empty DataFrame instead of crashing
aviavi12
changed pull request status to
open