Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

Show useful error message when there's a connection issue.


I'm currently developing a HLS streaming service.

When I disable my wifi (simulate an internet outage), I got an "TypeError: Cannot read property '0' of undefined" error.
Which is nonsense to the users (not even to the developers).

I want to show a custom error message explaining that there's is a connection issue, but there's no way to detect this kind of error.

I know there's "reason" property in "buffer" event, but the "buffer" event never triggered in my case.

Is there a way to handle this?

2 Community Answers


JW Player Support Agent  
0 rated :

You can try the jwplayer().on('error') call. We have a demo of a custom error message on the player at

John Huang

0 rated :

Hi, Jessy

Thanks for replying.

After more experiment with a minimal setup of the latest version JWPlayer, I was not able reproduce the problem that I report.
So the problem is likely be on my part.

Thanks again.


These are the full stack trace of the error I got, In case someone need it.

provider.caterpillar.js:2 Uncaught (in promise) TypeError: Cannot read property '0' of undefined(…)t.Manifest.e.attemptSync_
@ provider.caterpillar.js:2(anonymous function)
@ provider.caterpillar.js:2w.each.w.forEach
@ jwplayer.js:1t.Manifest.e.syncLiveLevels_
@ provider.caterpillar.js:2t.Manifest.e.appendManifestInfoToLevels_
@ provider.caterpillar.js:2(anonymous function)
@ provider.caterpillar.js:2

This question has received the maximum number of answers.