Skip to content

Preload media period not prepared when onContinueLoadingRequested is called #2315

Description

@Apengsun

Version

Media3 1.5.1

More version details

无

Devices that reproduce the issue

Android14 Redmi Note 13 Pro 5G

Devices that do not reproduce the issue

都复现

Reproducible in the demo app?

No

Reproduction steps

无

Expected result

无奔溃

Actual result

Fatal Exception: java.lang.IllegalStateException:
       at androidx.media3.common.util.Assertions.checkState(Assertions.java:85)
       at androidx.media3.exoplayer.source.ProgressiveMediaPeriod.assertPrepared(ProgressiveMediaPeriod.java:999)
       at androidx.media3.exoplayer.source.ProgressiveMediaPeriod.getBufferedPositionUs(ProgressiveMediaPeriod.java)
       at androidx.media3.exoplayer.source.preload.PreloadMediaPeriod.getBufferedPositionUs(PreloadMediaPeriod.java:264)
       at androidx.media3.exoplayer.source.preload.PreloadMediaSource$PreloadMediaPeriodCallback.lambda$onContinueLoadingRequested$1(PreloadMediaSource.java:508)
       at android.os.Handler.handleCallback(Handler.java:883)
       at android.os.Handler.dispatchMessage(Handler.java:100)
       at android.os.Looper.loop(Looper.java:224)
       at android.app.ActivityThread.main(ActivityThread.java:7562)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:539)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:950)

[com.android.thememanager_issue_2947d0273e7f29d94ddff2a6db7b788f_crash_session_67EE316A008700017C745A594FC6525D_DNE_0_v2_stacktrace.txt](https://github.com/user-attachments/files/19643871/com.android.thememanager_issue_2947d0273e7f29d94ddff2a6db7b788f_crash_session_67EE316A008700017C745A594FC6525D_DNE_0_v2_stacktrace.txt)

Media

无

Bug Report

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions