问题描述:

I am tring to integrate flurry test ads but the method setEnableTestAds throws a compilation error-- "the methods is undefined for FlurryAdBanner"

i comment this part and try to fetch and display ads but i do not see any ads in the emulator.

I am following this link.

My code-

 private RelativeLayout mBanner;

private FlurryAdBanner mFlurryAdBanner = null;

private String mAdSpaceName = "BANNER_ADSPACE";

private String adspace = "BANNER_BOTTOM";

@Override

protected void onCreate(Bundle savedInstanceState) {

super.onCreate(savedInstanceState);

setContentView(R.layout.activity_base);

FlurryAgent.init(this, Constants.FLURRY_KEY);

}

@Override

protected void onStart() {

super.onStart();

FlurryAgent.onStartSession(this, Constants.FLURRY_KEY);

//Flurry Ads

mBanner = (RelativeLayout)findViewById(R.id.flurry_banner);

mFlurryAdBanner = new FlurryAdBanner(this, mBanner, mAdSpaceName);

//FlurryAgent.logEvent("Pic taken");

// fetch and display ad for this ad space as soon as it is ready.

//mFlurryAdBanner.fetchAd();

mFlurryAdBanner.fetchAndDisplayAd();

// mFlurryAdBanner.setEnableTestAds(true);

}

My console messsages---

 12-23 11:54:16.034: E/FlurryAgent(2069): There is a problem with the Google Play Services library, which is required for Android Advertising ID support. The Google Play Services library should be integrated in any app shipping in the Play Store that uses analytics or advertising.

12-23 11:54:16.454: D/dalvikvm(2069): GC_FOR_ALLOC freed 252K, 10% free 2913K/3224K, paused 40ms, total 43ms

12-23 11:54:16.734: W/FlurryAgent(2069): Flurry session created for context:[email protected]

12-23 11:54:16.874: I/dalvikvm(2069): Failed resolving Lcom/flurry/sdk/bp; interface 1225 'Lcom/facebook/ads/AdListener;'

12-23 11:54:16.874: W/dalvikvm(2069): Link of class 'Lcom/flurry/sdk/bp;' failed

12-23 11:54:16.884: E/dalvikvm(2069): Could not find class 'com.flurry.sdk.bp', referenced from method com.flurry.sdk.bq.a

12-23 11:54:16.884: W/dalvikvm(2069): VFY: unable to resolve new-instance 1366 (Lcom/flurry/sdk/bp;) in Lcom/flurry/sdk/bq;

12-23 11:54:16.884: D/dalvikvm(2069): VFY: replacing opcode 0x22 at 0x000a

12-23 11:54:16.884: I/dalvikvm(2069): Failed resolving Lcom/flurry/sdk/br; interface 1230 'Lcom/facebook/ads/InterstitialAdListener;'

12-23 11:54:16.884: W/dalvikvm(2069): Link of class 'Lcom/flurry/sdk/br;' failed

12-23 11:54:16.884: E/dalvikvm(2069): Could not find class 'com.flurry.sdk.br', referenced from method com.flurry.sdk.bq.a

12-23 11:54:16.884: W/dalvikvm(2069): VFY: unable to resolve new-instance 1368 (Lcom/flurry/sdk/br;) in Lcom/flurry/sdk/bq;

12-23 11:54:16.884: D/dalvikvm(2069): VFY: replacing opcode 0x22 at 0x0008

12-23 11:54:16.894: I/dalvikvm(2069): Failed resolving Lcom/flurry/sdk/bp; interface 1225 'Lcom/facebook/ads/AdListener;'

12-23 11:54:16.894: W/dalvikvm(2069): Link of class 'Lcom/flurry/sdk/bp;' failed

12-23 11:54:16.894: D/dalvikvm(2069): DexOpt: unable to opt direct call 0x28c0 at 0x0c in Lcom/flurry/sdk/bq;.a

12-23 11:54:16.944: I/dalvikvm(2069): Failed resolving Lcom/flurry/sdk/br; interface 1230 'Lcom/facebook/ads/InterstitialAdListener;'

12-23 11:54:16.994: W/dalvikvm(2069): Link of class 'Lcom/flurry/sdk/br;' failed

12-23 11:54:16.994: D/dalvikvm(2069): DexOpt: unable to opt direct call 0x28d6 at 0x0a in Lcom/flurry/sdk/bq;.a

12-23 11:54:17.024: V/WebViewChromium(2069): Binding Chromium to the main looper Looper (main, tid 1) {b3fb94a8}

12-23 11:54:17.064: I/chromium(2069): [INFO:library_loader_hooks.cc(112)] Chromium logging enabled: level = 0, default verbosity = 0

12-23 11:54:17.104: I/BrowserProcessMain(2069): Initializing chromium process, renderers=0

12-23 11:54:17.394: E/chromium(2069): [ERROR:gl_surface_egl.cc(153)] No suitable EGL configs found.

12-23 11:54:17.394: E/chromium(2069): [ERROR:gl_surface_egl.cc(620)] GLSurfaceEGL::InitializeOneOff failed.

12-23 11:54:17.394: E/chromium(2069): [ERROR:gl_surface_egl.cc(153)] No suitable EGL configs found.

12-23 11:54:17.404: E/chromium(2069): [ERROR:gl_surface_egl.cc(620)] GLSurfaceEGL::InitializeOneOff failed.

12-23 11:54:17.404: E/chromium(2069): [ERROR:gpu_info_collector.cc(86)] gfx::GLSurface::InitializeOneOff() failed

12-23 11:54:17.474: W/FlurryAgent(2069): Flurry session started for context:[email protected]

12-23 11:54:17.484: W/chromium(2069): [WARNING:proxy_service.cc(888)] PAC support disabled because there is no system implementation

12-23 11:54:38.524: W/FlurryAgent(2069): **Analytics report sent.**

12-23 11:54:40.764: E/FlurryAgent(2069): Ad server responded with the following error(s):

12-23 11:54:40.764: E/FlurryAgent(2069): **Unknown Api Key**

网友答案:

The log is very clear: you have not provided the API key corresponding to your app. You can found it on dev.flurry.com

网友答案:

Unfortunately, Ad Test Mode is currently having issues and only works with Gemini Video ads at this time. At this point we do not believe the issue is with your integration. The error just means that the ad is unfilled, and we expect the fill rate to improve going forward.

Not sure, but haven't improved since this mail for me.

相关阅读:
Top