5

After updating to Xcode 7 and building my app in iOS9, iAds stopped working and I get this error in bannerView

didFailToReceiveAdWithError:

Ad inventory unavailable.

Any ideas?

EDIT: iAds are now working. Apple must have fixed it after we filed bug reports on the issue.

Community
  • 1
  • 1
Mark
  • 2,666
  • 3
  • 25
  • 29
  • Assuming these are test ads. Ads come and go, sometimes not always available. How long did you wait? – Yimin Rong Sep 18 '15 at 17:59
  • Test ads. I'm currently developing this app, so I have it up for long periods of time, 20 minutes or more. I have yet to see the test ad. – Mark Sep 18 '15 at 18:27
  • I've been making ios apps for 5 years. I know it can take a few minutes sometimes for an ad to show up. This appears to be different. – Mark Sep 18 '15 at 18:28
  • Usually iAds are a no-brainer, they just work. Are you doing a simple enable, nothing fancy? – Yimin Rong Sep 18 '15 at 18:29
  • Thanks for taking the time to help, @YiminRong. I agree, i've never had trouble before. No nothing fancy, just displaying the adbannerview at the top of my root view. – Mark Sep 18 '15 at 18:32
  • Did u find any solution for this? – Nazik Nov 24 '15 at 07:08
  • @NAZIK, As I mentioned in the EDIT, they just started working without me doing anything, so I think Apple fixed the issue at the time. I haven't been working on an app for a sec, so I'm not sure what is currently happening. – Mark Nov 24 '15 at 20:19

2 Answers2

1

I am using Xcode 7.3.1 and I received the same error. After I renewed my membership I was able to click at the contracts,tax and banking information section. I saw that there wasn't a contract type for the iAd App Network anymore..only a contract type for paid applications. So my suggestion is that Apple does not support iAd anymore. In that case I would recommend to have a look on AdMob(Google Advertising).

Best regards, Nazar Medeiros

Nazar Medeiros
  • 437
  • 4
  • 10
0

You may have set an invalid (height) constraint for the ADBannerView. Please check the constraints for it.

In my case I had a wrong height constraint set in the storyboard scene. The height was set to 32 which is an invalid height for iPhone portrait mode. When I removed the bad constraint, the error ("Ad inventory unavailable") disappeared and the ads were delivered as before.

Likely the issue may appear as ads working on one device and not on another. (see iAd error: Ad Inventory unavailable) I assume that the constraints match valid ad dimensions on one device but do not match the valid dimensions on the other device and then ads only work on one device and not on the other.

Community
  • 1
  • 1
Rainer Schwarze
  • 4,725
  • 1
  • 27
  • 49