Closed christianbkoehler closed 4 years ago
Hi,
I was not able to reproduce the behavior that you're seeing with the videojs loading spinner. Is it specific to your implementation? Are you able to reproduce it using your ad tag against our Advanced sample?
I wasn't able to reproduce the spinning wheel showing up in the Advanced sample, but I was able to reproduce the same behavior where the contentended
event handler wasn't being turned back on after an ad error. So using the debugger I was able to see that SdkImpl.prototype.onContentComplete
was never called after a preroll ad error.
Hi,
As per the videojs-contrib-ads integrator reference, the contentended
event is deprecated. Can you share the ad tag you were using when you encountered this issue?
Hi,
I’m closing this issue because it has been inactive for more than a month. Please reopen if you still encounter this issue with the latest stable version
Thank you!
If the ad tag url only has a preroll ad defined and the preroll ad encounters an error, the plugin will try and load a postroll ad that doesn't exist. This causes the videojs loading spinner to unexpectedly appear at the end of the video.
If the preroll ad encountered an error this is logged:
If the preroll ad played with no errors this is logged:
What I found is that
SdkImpl.prototype.onContentComplete
is never called if a preroll ad errors out and therefore never checks whether or not a postroll ad exists. I think this happens because onPlayerWrapper.prototype.onAdBreakStart
this event listener is turned offand if the preroll ad encounters an error
PlayerWrapper.prototype.onAdBreakEnd
is never called and the event listener is not turned back on.A workaround that I found is listening to
ads-ima-adError
and if there is an error I trigger the nopostroll eventplayer.trigger('nopostroll')