Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Media3 v1.3.1 crash on API level 22 (Android 5.1) : It's supposed to have media3 v1.3.1 working on Android 5.1? #1379

Closed
priscila225 opened this issue May 17, 2024 · 3 comments
Assignees

Comments

@priscila225
Copy link

The app I work for started to crash after updating media3 to v1.3.1, rollback to v1.3.0 works fine, that's the stack trace and the crash is internally on media3 library:

FATAL EXCEPTION: ExoPlayer:Playback
                 Process: com.hearst.android.wmur, PID: 3137
                 java.lang.NoSuchMethodError: No interface method stream()Ljava/util/stream/Stream; in class Ljava/util/List; or its super classes (declaration of 'java.util.List' appears in /system/framework/core-libart.jar)
                 	at androidx.media3.common.Format.<init>(Format.java:982)
                 	at androidx.media3.common.Format.<init>(Format.java:128)
                 	at androidx.media3.common.Format$Builder.build(Format.java:720)
                 	at androidx.media3.common.Format.copyWithCryptoType(Format.java:1116)
                 	at androidx.media3.exoplayer.hls.HlsSampleStreamWrapper.createTrackGroupArrayWithDrmInfo(HlsSampleStreamWrapper.java:1467)
                 	at androidx.media3.exoplayer.hls.HlsSampleStreamWrapper.prepareWithMultivariantPlaylistInfo(HlsSampleStreamWrapper.java:277)
                 	at androidx.media3.exoplayer.hls.HlsMediaPeriod.buildAndPrepareSampleStreamWrappers(HlsMediaPeriod.java:541)
                 	at androidx.media3.exoplayer.hls.HlsMediaPeriod.prepare(HlsMediaPeriod.java:183)
                 	at androidx.media3.exoplayer.source.MaskingMediaPeriod.createPeriod(MaskingMediaPeriod.java:133)
                 	at androidx.media3.exoplayer.source.MaskingMediaSource.onChildSourceInfoRefreshed(MaskingMediaSource.java:213)
                 	at androidx.media3.exoplayer.source.WrappingMediaSource.onChildSourceInfoRefreshed(WrappingMediaSource.java:154)
                 	at androidx.media3.exoplayer.source.WrappingMediaSource.onChildSourceInfoRefreshed(WrappingMediaSource.java:49)
                 	at androidx.media3.exoplayer.source.CompositeMediaSource.lambda$prepareChildSource$0$androidx-media3-exoplayer-source-CompositeMediaSource(CompositeMediaSource.java:117)
                 	at androidx.media3.exoplayer.source.CompositeMediaSource$$ExternalSyntheticLambda0.onSourceInfoRefreshed(D8$$SyntheticClass)
                 	at androidx.media3.exoplayer.source.BaseMediaSource.refreshSourceInfo(BaseMediaSource.java:90)
                 	at androidx.media3.exoplayer.hls.HlsMediaSource.onPrimaryPlaylistRefreshed(HlsMediaSource.java:565)
                 	at androidx.media3.exoplayer.hls.playlist.DefaultHlsPlaylistTracker.onPlaylistUpdated(DefaultHlsPlaylistTracker.java:428)
                 	at androidx.media3.exoplayer.hls.playlist.DefaultHlsPlaylistTracker.access$1500(DefaultHlsPlaylistTracker.java:54)
                 	at androidx.media3.exoplayer.hls.playlist.DefaultHlsPlaylistTracker$MediaPlaylistBundle.processLoadedPlaylist(DefaultHlsPlaylistTracker.java:726)
                 	at androidx.media3.exoplayer.hls.playlist.DefaultHlsPlaylistTracker$MediaPlaylistBundle.onLoadCompleted(DefaultHlsPlaylistTracker.java:586)
                 	at androidx.media3.exoplayer.hls.playlist.DefaultHlsPlaylistTracker$MediaPlaylistBundle.onLoadCompleted(DefaultHlsPlaylistTracker.java:514)
                 	at androidx.media3.exoplayer.upstream.Loader$LoadTask.handleMessage(Loader.java:487)
                 	at android.os.Handler.dispatchMessage(Handler.java:102)
                 	at android.os.Looper.loop(Looper.java:135)
                 	at android.os.HandlerThread.run(HandlerThread.java:61)
@bsimon36
Copy link

Facing the same issue

@bsimon36
Copy link

It appears this is the same as #1312

@tonihei
Copy link
Collaborator

tonihei commented May 20, 2024

It is the same as #1312. Media3 1.3.0 introduced a dependency on core library desuring, the enhanced Java 8 support. We initially thought that would be transparent to apps, but it's not because of a tooling bug that is now fixed. You can work around the issue by turning on the enhanced Java 8 support in your app. See https://developer.android.com/studio/write/java8-support#library-desugaring

@tonihei tonihei closed this as completed May 20, 2024
@androidx androidx locked and limited conversation to collaborators Jul 20, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants