goldfire / howler.js

Javascript audio library for the modern web.
https://howlerjs.com
MIT License
23.87k stars 2.23k forks source link

Audio stream not working on Firefox Android #1159

Open bugz313 opened 5 years ago

bugz313 commented 5 years ago

Firefox for Android version 66.0.2

I am trying to play a radio stream but it's stuck loading forever. Static sound files play without problems.

I also tried playing the Live Radio demos from https://howlerjs.com/ and same thing happens.

darren-dev commented 5 years ago

Without code examples, output logs, or anything like that, no one will be able to assist you correctly.

bugz313 commented 5 years ago

Without code examples, output logs, or anything like that, no one will be able to assist you correctly.

You can just visit howlerjs.com in Firefox on Android, scroll down to Demos, open Live Radio demos and try to play BBC Radio 1 or any other live radio. It never plays.

For code you can check: examples/radio/radio.js

darren-dev commented 5 years ago

Firefox for Android version 66.0.2

Yes, however I may not have the EXACT system you are using. I personally have a Note 4 (Which is older) and things work fine. Providing code isn't to prove that there is an issue, it's so another developer can look and try provide assistance.

EDIT: Looking at the demos, and checking in the console, I can see that it's trying to load HTTP data onto an HTTPS website. The cause of your issue could quite possibly be your browser blocking those requests. But again, we need to see code instead of just pointing me to something I can clearly see.

goldfire commented 5 years ago

Are you still seeing this issue? I've tested on the latest Firefox on 2 different Android devices and the live radio demo worked on both.

roks0n commented 5 years ago

I'm experiencing the same issue on my Android. Howler's live demos don't work either. I'm not seeing any errors.

When I was further debugging on my own site, I've noticed the following:

This is how I initialize the howler instance:

new Howl({
    src: ['https://strm.radionula.com/classics'],
    html5: true,
    format: ['mp3'],
    onload: () => console.log('onload'),
    onloaderror: (e, msg) => console.log('onloaderror', e, msg),
    onplayerror: (e, msg) => console.log('onplayerror', e, msg),
    onplay: () => console.log('onplay'),
    onend: () => console.log('onend'),
    onpause: () => console.log('onpause'),
    onrate: () => console.log('onrate'),
    onstop: () => console.log('onstop'),
    onseek: () => console.log('onseek'),
    onfade: () => console.log('onfade'),
    onunlock: () => console.log('onunlock'),
});

Firefox for Android version 66.0.2. Android v9 (OxygenOS v9.0.13).

I'm using the Howler v2.1.2.

I've also tested on :

Let me know if this information is sufficient. I'll try to do further debugging and will prepare a small project that will replicate the issue. Until then, if anyone has any ideas/suggestions what would be worth checking I'd greatly appreciate it.

roks0n commented 5 years ago

I haven't made much progress yet, but this is the sample project with which I'm able to replicate the issue: https://github.com/roks0n/howler-demo

Note:

bugz313 commented 5 years ago

@goldfire I am still seeing the issue. Could this issue be reopened please?

roks0n commented 5 years ago

Just to give my update: nothing changed since I posted and I haven't made any progress on the issue. I'll keep everyone updated if anything changes.

eladkolet commented 5 years ago

we experience the same issues. any update on this will be great.

bugz313 commented 5 years ago

@eladkolet @roks0n The issue on our side was caused by the stream not being secure and using a port. Now it works.

nikhilbhalwankar commented 4 years ago

Still facing the issue on firefox for android. Works well on Chrome but not on Firefox. We already have https url for the audio.

Mobile :- Nokia 6.1 Plus Firefox for Android version:- 68.3