Skip to content

fix(health): ensure playback failures trigger immediate repair - #176

Merged
javi11 merged 1 commit into
kipsilabs:mainfrom
drondeseries:fix/playback-failure-repair
Dec 30, 2025
Merged

fix(health): ensure playback failures trigger immediate repair#176
javi11 merged 1 commit into
kipsilabs:mainfrom
drondeseries:fix/playback-failure-repair

Conversation

@drondeseries

Copy link
Copy Markdown
Contributor

When a file fails during playback due to missing Usenet articles, it currently enters a 'corrupted' dead-end state because the health worker excludes corrupted files from checks.

This PR modifies the behavior to:

  1. Mark playback failures as pending instead of corrupted in the DB.
  2. Set High Priority (HealthPriorityNext) to ensure immediate processing.
  3. Max out retry count to force an immediate repair_triggered transition on the next health check cycle.
  4. Includes regression tests in health_repository_test.go.

- Modify RegisterCorruptedFile to set status to pending with high priority and maxed retries.
- Update UpdateFileHealth to use max_retries - 1 and high priority when noRetry is true (playback errors).
- Update metadata filesystem to report playback errors as pending in DB to trigger repair cycle.
- Add regression test for playback failure behavior in health_repository_test.go.
- Fix scan error in tests by updating priority column type to INTEGER in test setup.
@javi11
javi11 merged commit 5dd936c into kipsilabs:main Dec 30, 2025
1 check passed
@drondeseries
drondeseries deleted the fix/playback-failure-repair branch December 30, 2025 13:34
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

Successfully merging this pull request may close these issues.

2 participants