google / google/ExoPlayer

Bug on entering replaced ads HLS fmp4

Open
#11,012 20 comments 0 reactions 1 assignee Claimed by @marcbaechinger View on GitHub
bad media needs triage
Dominant language
Java
Stars
21.9k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

### ExoPlayer Version

2.18.3

### Devices that reproduce the issue

The problem doesn't seem to be device specific. Happens on devices and on emulator.

### Devices that do not reproduce the issue

_No response_

### Reproducible in the demo app?

Yes

### Reproduction steps

Play the included live stream and watch it across a couple of ad breaks.

This stream will have a 2 minute ad break every 5 minutes. (:01, :06, :11, :16 ... :56)

### Expected result

The player should play normally across the ad breaks.

### Actual result

Sometimes the ads will play OK. But it will inevitably end up in a broken state upon entering an ad break sooner or later (usually the second ad break). When this happens, the timeline seems broken. The player will attempt to seek to time that is not part of the current buffer, a time in the future.

Example image:
![image](https://user-images.githubusercontent.com/1465282/220957146-881d3ac8-2457-462b-a37b-d3267d52c604.png)
When the problem happens, the timeline looks like on the left. The player is at position 3:17 when it only has 01:38 worth of content. When in a regular state, it will look like the picture on the right.

### Media

REMOVED

### Bug Report

- [ ] You will email the zip file produced by `adb bugreport` to dev.exoplayer@gmail.com after filing this issue.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.