[GH-ISSUE #270] [Refactor] Centralize configuration, standardize logging, and add type safety #60

Open
opened 2026-05-07 00:18:21 +02:00 by BreizhHardware · 0 comments

Originally created by @JoseCostaUni on GitHub (Apr 2, 2026).
Original GitHub issue: https://github.com/IAmTomShaw/f1-race-replay/issues/270

The codebase has several code quality issues that make it harder to maintain and contribute to, which tend to aggravate the more features are integrated, such as:

  • Magic numbers scattered throughout the project. Values like screen dimensions, playback speeds, network ports, and UI sizes are hardcoded in multiple files with no single source of truth, making tuning or overriding them error-prone;
  • No centralized configuration;
  • Inconsistent logging — third-party libraries (fastf1, urllib3, etc.) and the application itself use different logging formats, making output hard to read;
  • Missing type annotations and exceptions as many functions lack return types and errors are raised as bare Exception, making debugging harder;
Originally created by @JoseCostaUni on GitHub (Apr 2, 2026). Original GitHub issue: https://github.com/IAmTomShaw/f1-race-replay/issues/270 The codebase has several code quality issues that make it harder to maintain and contribute to, which tend to aggravate the more features are integrated, such as: - Magic numbers scattered throughout the project. Values like screen dimensions, playback speeds, network ports, and UI sizes are hardcoded in multiple files with no single source of truth, making tuning or overriding them error-prone; - No centralized configuration; - Inconsistent logging — third-party libraries (fastf1, urllib3, etc.) and the application itself use different logging formats, making output hard to read; - Missing type annotations and exceptions as many functions lack return types and errors are raised as bare Exception, making debugging harder;
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/f1-race-replay#60
No description provided.