amphtml icon indicating copy to clipboard operation
amphtml copied to clipboard

AMP Ima Video pause upon scrolling page

Open sultanboss opened this issue 6 years ago • 11 comments

Hi,

I have implemented APM Ima Video and it is working great. The only problem is when you scroll thru half of the page, the video automatically pauses. If you return back to the top half, video auto-resume.

How can I make it play all the time without pausing?

Thanks!

sultanboss avatar Oct 22 '20 15:10 sultanboss

i'm a +1 on this, my video is in a slide rail, so basically always viewable but it still pauses after scroll, i need it to continue playing on scroll

spormeon avatar Oct 22 '20 16:10 spormeon

Hi @sultanboss thank you for submitting this issue. Could you or @spormeon please provide example code that exemplifies this issue?

micajuine-ho avatar Oct 23 '20 03:10 micajuine-ho

i think its quite simply this thats doing it: https://cdn.ampproject.org/v0/amp-ima-video-0.1.js

spormeon avatar Oct 23 '20 05:10 spormeon

i can send you a demo page, but dont want to put it in a public forum, how can i send it to you?

is there a slack group or something, could DM you on there?

spormeon avatar Oct 23 '20 05:10 spormeon

Hi @micajuine-ho thanks for your response.

This is happening with a fixed positioned video setup. For example:

<amp-ima-video id="content_video" style="width: 366px; height: 206px; position: fixed; left: 100px; bottom: 100px;" width="640" height="360" layout="responsive" data-tag="tagUrl..." data-src="sourceUrl..." autoplay data-ad-label="Adverts (%s of %s)"></amp-ima-video>

As you can see I am trying to make it float bottom left corner with fixed position CSS. Also, I have enabled autoplay. Now, this seems falling under the initial view area (under autoplay rule) and whenever you scroll down the bottom, it stops pauses the video.

You can check this issue as well. https://github.com/ampproject/amphtml/issues/30471

sultanboss avatar Oct 23 '20 06:10 sultanboss

I just confirmed via a test page, and I believe this will be solved as a side-effect of https://github.com/ampproject/amphtml/pull/30647

samouri avatar Oct 23 '20 16:10 samouri

Awesome, thanks Jake!

micajuine-ho avatar Oct 23 '20 16:10 micajuine-ho

its still doing it when i tested it this morning, this is fixed for amp-ima-video? as testing this file the behaviour is still there: //cdn.ampproject.org/v0/amp-ima-video-0.1.js

spormeon avatar Oct 29 '20 11:10 spormeon

@spormeon: the fix can be verified if you do a build at HEAD. All AMP deployments are paused right now and won't resume until the election freeze is over.

samouri avatar Oct 29 '20 15:10 samouri

I think someone just pushed some changes about an hour ago, when everything is meant to be freezed until after elections? it gives me a break in this: we basically hacked the amp-ima-video file to work for our need and host the file ourselves but this error started occurring now and no player show on page in effect. DevTools_-_ads_vsvl_co_uk_pub000018_scripts_AMPTEST_html_and_CloudWatch_Management_Console

spormeon avatar Oct 29 '20 22:10 spormeon

I think someone just pushed some changes about an hour ago, when everything is meant to be freezed until after elections?

There is a documented process for cherry-picking high severity fixes even during code freezes. I think this one was merged.

@spormeon: I'm not sure whats going on to produce that error. If you think there is an AMP bug, please file a separate issue with full details for reproduction.

samouri avatar Oct 30 '20 01:10 samouri