-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
Cached video does not fallback to the origin video #27109
Comments
Edit: actually happens on mobile too, just less often for some reason |
Looks like it's a race condition between when the media pool removes the sources, and when the
|
There are reports of this happening on mobile as well, also when served from the AMP cache. |
Under this scenario a video might not fall back to the origin on pre-render. Possible fix for ampproject#27109 Reproduces by navigating (locally to) http://localhost:8000/proxy/s/stories.nonblocking.io/waffles/?usqp=mq331AQFKAGwASA%3D&_js_v=0.1#referrer=https%3A%2F%2Fwww.google.com&visibilityState=prerender&cap=swipe&share=https%3A%2F%2Funumbox.com%2Fwebsite-development-trends-2020-amp-story%2F waiting for the pre-render load to fail, and then executing `AMP.viewer.receiveMessage('visibilitychange', {'state': 'visible'})` in the console. If this if not a fix for ampproject#27109, then it might be the same race, but elsewhere. The problem is that you cannot wait for `loadPromise` on a video element that has failed a source and has just had a new source provided.
Under this scenario a video might not fall back to the origin on pre-render. Possible fix for #27109 Reproduces by navigating (locally to) http://localhost:8000/proxy/s/stories.nonblocking.io/waffles/?usqp=mq331AQFKAGwASA%3D&_js_v=0.1#referrer=https%3A%2F%2Fwww.google.com&visibilityState=prerender&cap=swipe&share=https%3A%2F%2Funumbox.com%2Fwebsite-development-trends-2020-amp-story%2F waiting for the pre-render load to fail, and then executing `AMP.viewer.receiveMessage('visibilitychange', {'state': 'visible'})` in the console. If this if not a fix for #27109, then it might be the same race, but elsewhere. The problem is that you cannot wait for `loadPromise` on a video element that has failed a source and has just had a new source provided. ## Additional changes: - Change preload to also preload non-cache sources - Clarify preconnect docs about the security invariants.
One fundamental problem is I think that media-pool works with Is there any reason that the media pool has to ignore the AMP |
The video source in this story 404s, and does not fallback to the origin video:
https://unumbox-com.cdn.ampproject.org/v/s/unumbox.com/website-development-trends-2020-amp-story/?usqp=mq331AQFKAGwASA%3D&_js_v=a2&_gsa=1#referrer=https%3A%2F%2Fwww.google.com&visibilityState=visible&cap=swipe&share=https%3A%2F%2Funumbox.com%2Fwebsite-development-trends-2020-amp-story%2F
cc @ampproject/wg-stories
The text was updated successfully, but these errors were encountered: