amphtml icon indicating copy to clipboard operation
amphtml copied to clipboard

A4A 3p iframe stuck with visibility hidden when invalid/missing signature

Open keithwrightbos opened this issue 10 years ago • 2 comments

Short description of your issue:

A4A requested, non-AMP verified creatives potentially never reset visibility hidden set via AmpAdApiHandler#startUp. Visibility is reset when render-start postMessage is received however currently this is done from within 3p code for all but doubleclick requests. Presumably the idea is that we want iframe to be hidden until after the network specific, draw3p JS executes. However, for A4A, the code to build/setup the ad request has already been executed. Recommend removing visibility hidden for A4A code path unless 3p/integration.js#waitForRenderStart array of types indicates otherwise (e.g. is doubleclick).

How do we reproduce the issue?

Requires E2E A4A code execution with non or invalid AMP creative. Please contact keithwrightbos@ for details.

What browsers are affected?

All

Which AMP version is affected?

All

keithwrightbos avatar Jul 26 '16 14:07 keithwrightbos

Recommend removing visibility hidden for A4A code path

This'll show the iframe before it's ready though. Why aren't these calling draw3p?

jridgewell avatar Jul 26 '16 17:07 jridgewell

The A4A flow handles non-AMP creatives (or those whose signature was not valid or those) and AMP creatives where browser does not support shadow DOM (e.g. Safari) by rendering within an iframe where the src equals the ad url (response has short cache lifetime). It never calls the draw3p path as the ad url is constructed via JS within the extensions. So, when we attach the iframe the creative is already in cache and will render immediately.

keithwrightbos avatar Jul 26 '16 18:07 keithwrightbos