简体   繁体   中英

Flurry Error FlurryAgent: Ad server responded but sent no ad units

Hello Guys i am integrating Flurry ad network and trying to show test ads but it gives me following error

12-12 11:09:58.669 17082-17627/cpp.eminosoft.com.adserver E/FlurryAgent: Ad server responded but sent no ad units.
12-12 11:09:58.686 17082-17243/cpp.eminosoft.com.adserver E/FlurryAgent: AdRequest: url:https://ads.flurry.com/v16/getAds.do

This is my Code

 new FlurryAgent.Builder()
            .withLogEnabled(true)
           // .withListener(flurryListener)
            .build(this, Keys.FlurryAPIkey);

    mFlurryAdInterstitial = new FlurryAdInterstitial(this, "TestNew");

    FlurryAdTargeting adTargeting = new FlurryAdTargeting();
    adTargeting.setEnableTestAds(true);
    mFlurryAdInterstitial.setTargeting(adTargeting);
    mFlurryAdInterstitial.fetchAd();


     flurryAdInterstitialListener=new FlurryAdInterstitialListener() {
        @Override
        public void onFetched(FlurryAdInterstitial flurryAdInterstitial) {
            Toast.makeText(getApplicationContext(),"Flurry Fetched",Toast.LENGTH_SHORT).show();
            mFlurryAdInterstitial.displayAd();
        }

        @Override
        public void onRendered(FlurryAdInterstitial flurryAdInterstitial) {

        }

        @Override
        public void onDisplay(FlurryAdInterstitial flurryAdInterstitial) {

        }

        @Override
        public void onClose(FlurryAdInterstitial flurryAdInterstitial) {
            mFlurryAdInterstitial.fetchAd();
        }

        @Override
        public void onAppExit(FlurryAdInterstitial flurryAdInterstitial) {

        }

        @Override
        public void onClicked(FlurryAdInterstitial flurryAdInterstitial) {

        }

        @Override
        public void onVideoCompleted(FlurryAdInterstitial flurryAdInterstitial) {

        }

        @Override
        public void onError(FlurryAdInterstitial flurryAdInterstitial, FlurryAdErrorType flurryAdErrorType, int i) {
            Toast.makeText(getApplicationContext(),"Flurry not Fetched error",Toast.LENGTH_SHORT).show();
        }
    };



    mBanner = (FrameLayout)findViewById(R.id.Flurry_banner);




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


    mFlurryAdBanner.fetchAd();
    FlurryAdBannerListener bannerAdListener = new FlurryAdBannerListener() {
        @Override
        public void onFetched(FlurryAdBanner adBanner) {
            adBanner.displayAd();
        }
        @Override
        public void onError(FlurryAdBanner adBanner, FlurryAdErrorType adErrorType, int errorCode)
        {
            Toast.makeText(getApplicationContext(),"Flurry Banner Failed To Load",Toast.LENGTH_SHORT).show();
            adBanner.destroy();
        }
        @Override
        public void onRendered(FlurryAdBanner adBanner) {

        }
        @Override
        public void onShowFullscreen(FlurryAdBanner adBanner) {

        }
        @Override
        public void onCloseFullscreen(FlurryAdBanner adBanner) {

        }
        @Override
        public void onAppExit(FlurryAdBanner adBanner) {

        }
        @Override
        public void onClicked(FlurryAdBanner adBanner) {

        }
        @Override
        public void onVideoCompleted(FlurryAdBanner adBanner) {

        } };
    mFlurryAdBanner.setListener(bannerAdListener);

and on button click i am trying to show interstetial and fetch again

  mFlurryAdInterstitial.setListener(flurryAdInterstitialListener);
    mFlurryAdInterstitial = new FlurryAdInterstitial(this, mAdSpaceName);
    FlurryAdTargeting adTargeting = new FlurryAdTargeting();
    adTargeting.setEnableTestAds(true);
    mFlurryAdInterstitial.setTargeting(adTargeting);
    mFlurryAdInterstitial.fetchAd();

The Flurry session is initialized correctly

I already Looked This question but not helpful .How Do i get ads To Display ? Thanks in advance

This is not the problem from coding side, This problem occurs because there are no ads present at the current location ,try changing your phone VPN to US and see.The ads should start displaying. If you are still facing the problem you can mail the flurry support team at support@flurry.com .They helped us solving the problem.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM