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

Don't attempt casting local episode and inform user #7182

Open
4 tasks done
Bollarice opened this issue May 12, 2024 · 6 comments
Open
4 tasks done

Don't attempt casting local episode and inform user #7182

Bollarice opened this issue May 12, 2024 · 6 comments
Labels
Functionality: Interacting devices Anything related to Android Auto, smart watches & smart speakers Functionality: Local feeds Type: Possible bug Issues that seem to be a bug, but haven't been confirmed yet

Comments

@Bollarice
Copy link

Checklist

  • I have used the search function for OPEN issues to see if someone else has already submitted the same bug report.
  • I have also used the search function for CLOSED issues to see if the problem is already solved and just waiting to be released.
  • I will describe the problem with as much detail as possible.
  • If the bug only to occurs with a certain podcast, I will include the URL of that podcast.

App version

3.3.2 (701b1ce)

Where did you get the app from

Google Play

Android version

5.10.168-android12-9-27760517-abS906USQS4DXD1

Device model

No response

First occurred

Today

Steps to reproduce

Add a podcast from local folder of mp3s to your account

Play that podcast either directly from the podcast page or your queue

Cast to speakers or other device

Expected behaviour

Podcast should play

Current behaviour

Player errors out and plays next non mp3 episode in queue
Screenshot_20240512_112236_AntennaPod

Logs

Environment

Android version: 14
OS version: 5.10.168-android12-9-27760517-abS906USQS4DXD1
AntennaPod version: 3.3.2
Model: SM-S906U
Device: g0q
Product: g0qsqw

Crash info

Time: 11-05-2024 00:59:14
AntennaPod version: 3.3.2

StackTrace

java.lang.NullPointerException: Attempt to invoke virtual method 'void android.support.v4.media.session.MediaSessionCompat.setQueue(java.util.List)' on a null object reference
	at de.danoeh.antennapod.core.service.playback.PlaybackService.lambda$loadQueueForMediaSession$1(PlaybackService.java:355)
	at de.danoeh.antennapod.core.service.playback.PlaybackService.$r8$lambda$3kCEWuNcq1SHYOtaxSddkU4SmrY(PlaybackService.java:0)
	at de.danoeh.antennapod.core.service.playback.PlaybackService$$ExternalSyntheticLambda13.accept(R8$$SyntheticClass:0)
	at io.reactivex.internal.observers.ConsumerSingleObserver.onSuccess(ConsumerSingleObserver.java:62)
	at io.reactivex.internal.operators.single.SingleObserveOn$ObserveOnSingleObserver.run(SingleObserveOn.java:81)
	at io.reactivex.android.schedulers.HandlerScheduler$ScheduledRunnable.run(HandlerScheduler.java:124)
	at android.os.Handler.handleCallback(Handler.java:958)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:230)
	at android.os.Looper.loop(Looper.java:319)
	at android.app.ActivityThread.main(ActivityThread.java:8893)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:608)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)
@Bollarice Bollarice added the Type: Possible bug Issues that seem to be a bug, but haven't been confirmed yet label May 12, 2024
@Bollarice
Copy link
Author

If not casting, function is as expected to

@ByteHamster
Copy link
Member

Unfortunately Cast devices can only play media files from the network. So unless AntennaPod starts a web server on your phone (which would be a significant complication), the cast device cannot access the media files.

@keunes
Copy link
Member

keunes commented May 13, 2024

I'll reopen this one as if we know it's not supported, we should gracefully inform the user (and prevent attempting to cast), rather than crash.

@keunes keunes added Functionality: Interacting devices Anything related to Android Auto, smart watches & smart speakers Functionality: Local feeds labels May 13, 2024
@keunes keunes reopened this May 13, 2024
@keunes keunes changed the title Mp3 can't play while casting Don't attempt casting local episode and inform user May 13, 2024
@keunes keunes added Type: Confirmed bug Bugs confirmed by a lead developer and removed Type: Possible bug Issues that seem to be a bug, but haven't been confirmed yet labels May 13, 2024
@ByteHamster
Copy link
Member

It doesn't crash. It says "media file not compatible with cast device"

@ByteHamster ByteHamster added Type: Possible bug Issues that seem to be a bug, but haven't been confirmed yet and removed Type: Confirmed bug Bugs confirmed by a lead developer labels May 13, 2024
@Bollarice
Copy link
Author

That's confusing as all my music players (YouTube music, vlc, and rocket player) can all cast locally saved mp3s, as can podcast addict.

Or is the initial response comment saying "Unfortunately Cast devices can only play media files from the network" speaking only about antenna pod capability, not generally?

If so, perhaps I should log this as a feature request as it seems fairly standard.

@ByteHamster ByteHamster added the Needs: Triage The core team still needs to decide if this feature would get accepted label May 13, 2024
@keunes
Copy link
Member

keunes commented May 18, 2024

It doesn't crash. It says "media file not compatible with cast device"

Right, sorry. I wasn't paying attention to the screenshot and assumed a crash because of the stacktrace.

I think it'd still be nice to have a targeted message about casting local files; the current dialog says 'error' while it should say 'not supported' and it doesn't mention anything about local files.

Proposal (not super convinced myself):

Cannot cast local files
Casting episodes from local feeds is currently not supported. Consider using a dedicated media player.

@ByteHamster ByteHamster removed the Needs: Triage The core team still needs to decide if this feature would get accepted label May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Functionality: Interacting devices Anything related to Android Auto, smart watches & smart speakers Functionality: Local feeds Type: Possible bug Issues that seem to be a bug, but haven't been confirmed yet
Projects
None yet
Development

No branches or pull requests

3 participants