Debug Logging and Logs
Debug logging helps you collect useful information when F1 Sensor does not behave as expected. Use this page when you are asked to provide logs for a GitHub issue, beta test, replay test, or F1TV Auth problem.
Never share F1TV tokens, full Authorization headers, cookies, callback URLs, nonce values, or browser session data in an issue, screenshot, log excerpt, or discussion post.
Redact secrets before sharing logs.
Enable debug logging
Home Assistant can enable debug logging for an integration from the UI. Use this flow first when you are collecting logs for an issue:
- Open Settings.
- Go to Devices & services.
- Open F1 Sensor.
- Select the three-dot menu.
- Select Enable debug logging.
After debug logging is enabled, reproduce the issue before you disable it again.
When you disable debug logging from the same menu, Home Assistant downloads a debug log file automatically. Attach that file to the issue after you remove any secrets.
Enable debug logging with YAML
Use YAML only if the UI option is not available, if you need debug logging to start during Home Assistant startup, or if you are asked to keep debug logging enabled across a restart.
Add this to your Home Assistant configuration.yaml:
logger:
default: warning
logs:
custom_components.f1_sensor: debug
Restart Home Assistant after changing the logger configuration.
Enable debug logging before you reproduce the issue. Logs are most useful when they include the full sequence from setup, reload, or the failing action.
Reproduce the problem
After Home Assistant restarts:
- Reproduce the issue you are testing or reporting.
- Note the approximate time when it happened.
- Note the installed F1 Sensor version.
- Note whether the integration is using public live timing, F1TV Auth live timing, Replay Mode, or Developer mode with a replay dump.
- Note the state of
sensor.f1_f1tv_token_statusif the issue involves live auth. - If present, note the state and attributes of
sensor.f1_live_timing_modewhen live timing is involved.
These details make it easier to match log entries to the behavior you saw.
Incident detection reports
For false positive or missing on-track incident reports, include the same basic log package plus:
- Session type and session name.
- Driver or car number involved.
- Approximate real-world time and, if relevant, broadcast time.
- Current
sensor.f1_track_statusstate. - Latest Race Control message around the incident.
- The
f1_sensor_incidentevent payload for the relevantincident_id, if one fired. - Whether Live Delay, Replay Mode, No Spoiler Mode, or F1TV Auth was active.
- Whether Track Map showed live or replay car positions.
- The Track Map card status, source, and stale indicator if visible.
- Whether the incident event included
location, and whetherlocation.stalewastrueorfalse.
Do not include F1TV tokens, authorization headers, browser session data, or large telemetry dumps.
Find raw logs
Use Home Assistant raw logs if you need to copy a smaller log excerpt manually.
- Open Settings.
- Go to System.
- Open Logs.
- Select the three-dot menu in the top right corner.
- Select Show raw logs.
- Copy the relevant entries around the time the issue happened.
What to include in an issue
When you create a GitHub issue, include:
- The F1 Sensor version.
- Your Home Assistant version.
- Whether you are using a beta release.
- Whether you are using public live timing, F1TV Auth live timing, Replay Mode, or Developer mode with a replay dump.
- What you expected to happen.
- What actually happened.
- The state and attributes of
sensor.f1_live_timing_modewhen relevant and present. - The state of
sensor.f1_f1tv_token_statuswhen relevant. - Track Map status, source, and stale state when relevant.
- Relevant debug log output with secrets removed.
Logs are often the key to understanding setup failures, token problems, replay behavior, and unexpected entity updates.
Disable debug logging
Debug logging can generate a lot of log data. Disable it when you are done testing.
If you enabled debug logging from the UI, return to Settings → Devices & services, open F1 Sensor, select the three-dot menu, and select Disable debug logging. Home Assistant downloads the debug log file when debug logging is disabled.
If you enabled debug logging with YAML, remove the custom_components.f1_sensor: debug entry from configuration.yaml, then restart Home Assistant.