Getting AdError 1009, but only on Chrome

162 views
Skip to first unread message

Lucia Ellan

unread,
Aug 30, 2020, 9:50:55 PM8/30/20
to Interactive Media Ads SDK
Hi IMA team,

I'm using IMA SDK in my HTML5 game to serve ads. The problem is, I'm getting "AdError 1009: The VAST response document is empty." error after I call
 AdsManager.start() on Chrome. But the same code works on Firefox. This is what I get in Chrome:

Error: AdError 1009 (The VAST response document is empty.): AdError 1009: The VAST response document is empty.
Error
at new Kx (https://imasdk.googleapis.com/js/sdkloader/ima3.js:454:456)
at Iy.M (ima3.js:495:276)
at Fh (ima3.js:111:200)
at Sv.l.dispatchEvent (ima3.js:109:365)
at Sv.F (ima3.js:402:425)
at Ch (ima3.js:106:335)
at zh (ima3.js:107:332)
at b (ima3.js:104:285)


This is my ad tag URL:

And this is the code to request my ad:
    afgAdContainer = document.getElementById('afg_container');
    afgAdDisplayContainer = new google.ima.AdDisplayContainer(afgAdContainer);
    afgAdsLoader = new google.ima.AdsLoader(afgAdDisplayContainer);
    afgAdsLoader.addEventListener(google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADEDonAfgAdsManagerLoadedfalse);
    afgAdsLoader.addEventListener(google.ima.AdErrorEvent.Type.AD_ERRORonAfgAdErrorfalse);
    var adsRequest = new google.ima.AdsRequest();
    adsRequest.adTagUrl = 'MY_AD_TAG_URL';
    // in fact, commenting following line out didn't change anything
    adsRequest.forceNonLinearFullSlot = true;
    // Specify the linear and nonlinear slot sizes. This helps the SDK to
    // select the correct creative if multiple are returned.
    adsRequest.linearAdSlotWidth = 760;
    adsRequest.linearAdSlotHeight = 640;
    adsRequest.nonLinearAdSlotWidth = 760;
    adsRequest.nonLinearAdSlotHeight = 640;
    // Pass the request to the afgAdsLoader to request ads
    afgAdsLoader.requestAds(adsRequest);

According to Chrome's network panel, I actually received following (looking valid) XML:
<VAST version="2.0">
  <Ad id="IMA3">
    <InLine>
      <AdSystem>VPAIDIMA3</AdSystem>
      <AdTitle>IMA3</AdTitle>
      <Impression>
        <![CDATA[]]>
      </Impression>
      <Creatives>
        <Creative>
          
<Linear>
  <Duration>00:00:30</Duration>
  <MediaFiles>
    <MediaFile
      width="640"
      height="480"
      delivery="progressive"
      type="application/javascript"
      apiFramework="VPAID">
    <![CDATA[https://imasdk.googleapis.com/js/sdkloader/vpaid_adapter.js?adTagUrl=https%3A%2F%2Fgoogleads.g.doubleclick.net%2Fpagead%2Fads%3Fad_type%3Dvideo_text_image%26client%3Dca-games-pub-1076272347919893%26description_url%3Dhttps%253A%252F%252Fdev.nstage.io%252Fphp5%252Fpigdragon%252F%26videoad_start_delay%3D0%26max_ad_duration%3D30000&type=js]]>
    </MediaFile>

  </MediaFiles>
</Linear>
        </Creative>
      </Creatives>
    </InLine>
  </Ad>
</VAST>


I can confirm that the ad is not served by using VSI on Chrome but works in Firefox. In VSI on Chrome, I get Ad event: start but no further events are triggered and no ads are served.

Actually, the call to my ad tag *does* return a valid XML in both Chrome and Firefox, but it plays only on Firefox. I wonder why the SDK gets panic only on Chrome.

Thanks in advance!

IMA SDK

unread,
Aug 31, 2020, 3:53:46 PM8/31/20
to lucia...@gmail.com, ima...@googlegroups.com
Hi Lucia,

Thank you for reaching out to us. I was not able to reproduce the behavior that you’re seeing with the video ad not being displayed on Chrome using our
VSI. I passed the VAST XML you shared as an ad response to the VSI and the video ad was displayed successfully (see screenshots attached). Can you provide a video recording showing the behavior you encountered?

Regards,
Arnaud Casame
IMA SDK Team


ref:_00D1U1174p._5004Q23vrwZ:ref
ad_display_1.png
ad_display_2.png

Lucia Ellan

unread,
Aug 31, 2020, 10:15:15 PM8/31/20
to Interactive Media Ads SDK
Hi Arnaud,

Thanks for checking out. Though I didn't do anything after posting this issue, now I can confirm that the ad is working in VSI on Chrome as you wrote.
After some experiments, I found that Facebook canvas container is the root of the cause. To cover this, let me explain how my game is loaded.
My HTML5 game works on Facebook canvas, which is essentially an iframe. In detail, my game is loaded as:
And any game player will access the game in https://apps.facebook.com/pigdragon_qa/ .

Now I added a test page to see how ads work, and this page works in following URL, on every browser (this page is a direct copy of Google's sample page but with my ad tag URL):

But this page, which loads the page above in iframe, doesn't work (unfortunately you can't check this page yourself because this Facebook app is not a public app, but please see attached screenshot telling what's going on):
Please note that the page above works in Firefox, but don't work in Chrome, Safari, and (webkit based) Edge.

I don't thing GET/POST is causing this, but could it be related to cross-domain iframe? Due to Facebook canvas app's limitation, I'm bound to serve my game in apps.facebook.com domain. Is there any workaround in this situation?

Thanks,

2020년 9월 1일 화요일 오전 4시 53분 46초 UTC+9에 imasdkforumadvisor님이 작성:
ima_working.png
ima_error_in_fb.png

Lucia Ellan

unread,
Aug 31, 2020, 10:24:20 PM8/31/20
to Interactive Media Ads SDK
I forgot to say that the ad tag is loaded correctly, even in not working case; so VAST response should not be empty in any case. Please refer to attached screenshot.

2020년 9월 1일 화요일 오전 11시 15분 15초 UTC+9에 Lucia Ellan님이 작성:
ima_tag_loaded.png

IMA SDK

unread,
Sep 1, 2020, 4:50:20 AM9/1/20
to lucia...@gmail.com, ima...@googlegroups.com

Hi Lucia,

Thank you for sharing additional information regarding your concern. The team is now aware about this behavior and we are considering this as an Chrome issue rather than an IMA SDK. However, there’s an ongoing discussion with regard to this issue internally. Rest assured, we will give you feedback once we have an update, or you can keep an eye on our release history and our blog for further updates.

Regards,


Google Logo
Sherwin Diesta
IMA SDK Team
 


ref:_00D1U1174p._5004Q23vrwZ:ref

IMA SDK

unread,
Oct 6, 2021, 1:15:49 PM10/6/21
to lucia...@gmail.com, ima...@googlegroups.com
Hello Lucia,

This has been marked as 'Intended Behavior' from the IMA side of things, and we do not expect any additional IMA changes to accommodate this.

Please let me know if you have any questions.

Thank you,
Jackson
IMA SDK team

ref:_00D1U1174p._5004Q23vrwZ:ref
Reply all
Reply to author
Forward
0 new messages