Skip to content

Fix resume when stream duration is initially unknown - #80

Merged
windoze95 merged 1 commit into
mainfrom
fix/resume-zero-duration
Jul 10, 2026
Merged

Fix resume when stream duration is initially unknown#80
windoze95 merged 1 commit into
mainfrom
fix/resume-zero-duration

Conversation

@windoze95

Copy link
Copy Markdown
Owner

Summary

  • preserve saved resume positions while a progressive stream reports an unknown duration
  • retain the known native-duration cap so stale server metadata cannot misplace playback
  • share the corrected target calculation across online and offline playback
  • add regression coverage for unknown, known, and near-zero resume targets

Root cause

Progressive iOS streams can report a duration of zero immediately after initialization. The player screen used that transient zero as the resume upper bound, converting a valid saved position into a seek to the beginning before the controller’s native zero-duration seek fallback ran. Resume only worked when duration metadata happened to arrive early.

Validation

  • flutter analyze --fatal-infos --fatal-warnings
  • flutter test (230 tests)
  • flutter build web --release

@windoze95
windoze95 merged commit e7dcf74 into main Jul 10, 2026
7 checks passed
@windoze95
windoze95 deleted the fix/resume-zero-duration branch July 10, 2026 18:40
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.

1 participant