Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iOS App Crash #74

Open
Gokulv617 opened this issue Mar 3, 2025 · 1 comment
Open

iOS App Crash #74

Gokulv617 opened this issue Mar 3, 2025 · 1 comment

Comments

@Gokulv617
Copy link

Gokulv617 commented Mar 3, 2025

Hi,

We are trying to implement Admob Ad using Ironsource mediation. It's working fine on Android, but in the iOS app, it crashes while calling the function below.

                     IronSource.instance.init( IRONSRC_APP_KEY,
                            [
                                IronSource.REWARDED_VIDEO,
			        IronSource.INTERSTITIAL		
                            ]

I have share my Action Script code and Manifiest file.

Manifeast ;

<iPhone>
   <InfoAdditions><![CDATA[
  <key>UIDeviceFamily</key>
  <array>
    <string>1</string>
    <string>2</string>
  </array>
  <key>NSUserTrackingUsageDescription</key>
  <string>This identifier will be used to deliver personalized ads to you.</string>
  <key>FirebaseAppDelegateProxyEnabled</key>
  <false/>
  <key>FirebaseAutomaticScreenReportingEnabled</key>
  <false/>
  <key>NSAppTransportSecurity</key>
  <dict>
    <key>NSAllowsArbitraryLoads</key>
    <true/>
    <key>NSAllowsArbitraryLoadsForMedia</key>
    <true/>
    <key>NSAllowsArbitraryLoadsInWebContent</key>
    <true/>
  </dict>
  <key>GADApplicationIdentifier</key>
  <string>ca-app-pub-5309755185839768~7291044841</string>
  <key>SKAdNetworkItems</key>
  <array>
    <dict>
      <!-- IronSource -->
      <key>SKAdNetworkIdentifier</key>
      <string>SU67R6K2V3.skadnetwork</string>
    </dict>
    <dict>
      <!-- AdMob -->
      <key>SKAdNetworkIdentifier</key>
      <string>cstr6suwn9.skadnetwork</string>
    </dict>
  </array>
]]></InfoAdditions>
    <requestedDisplayResolution>high</requestedDisplayResolution>
    <Entitlements>
	<![CDATA[
		<!-- DEVELOPMENT -->
		<key>get-task-allow</key>
		<true/>
		<key>aps-environment</key>
		<string>development</string>
		
		
		<!-- PRODUCTION 
		<key>get-task-allow</key>
		<false/>
		-->
		
		
     ]]>
    </Entitlements>
  </iPhone>

<extensions>
    <extensionID>com.distriqt.Firebase</extensionID>
    <extensionID>com.distriqt.Core</extensionID>
    <extensionID>com.distriqt.InAppBilling</extensionID>
    <extensionID>com.google.guava</extensionID>
    <extensionID>com.distriqt.Share</extensionID>
    <extensionID>com.distriqt.PushNotifications</extensionID>
    <extensionID>com.google.code.gson</extensionID>
    <extensionID>com.google.firebase.core</extensionID>
    <extensionID>com.distriqt.CustomResources</extensionID>
    <extensionID>com.distriqt.IDFA</extensionID>
    <extensionID>com.distriqt.Application</extensionID>
    <extensionID>com.distriqt.IronSource</extensionID>
    <extensionID>com.distriqt.ironsource.AdMob</extensionID>
    <extensionID>com.distriqt.ironsource.AdQualitySDK</extensionID>
  </extensions>
</application>

Action Script ;

import com.distriqt.extension.ironsource.IronSource;
import com.distriqt.extension.ironsource.events.RewardedVideoAdEvent;

var IRONSRC_APP_KEY : String = "20eac4e0d";

if (IronSource.isSupported)
{
	tet.text = "IronSource Version:        " + IronSource.service.version ;
	//message( "IronSource Native Version: " + IronSource.instance.nativeVersion );23159580
	
	IronSource.instance.init( IRONSRC_APP_KEY, [ IronSource.REWARDED_VIDEO ] );
	
	IronSource.instance.addEventListener( RewardedVideoAdEvent.OPENED, onRewardedVideoAdOpened );
	IronSource.instance.addEventListener( RewardedVideoAdEvent.CLOSED, onRewardedVideoAdClosed );
	IronSource.instance.addEventListener( RewardedVideoAdEvent.AVAILABILITY_CHANGED, onRewardedVideoAvailabilityChanged );
	IronSource.instance.addEventListener( RewardedVideoAdEvent.REWARDED, onRewardedVideoAdRewarded );
	IronSource.instance.addEventListener( RewardedVideoAdEvent.SHOW_FAILED, onRewardedVideoAdShowFailed );
	IronSource.instance.addEventListener( RewardedVideoAdEvent.CLICKED, onRewardedVideoAdClicked );
	
	
	
}
btn1.addEventListener( MouseEvent.CLICK, mouseClickHandler);
 function stage_resizeHandler( event:Event ):void
	{
		//_text.width  = stage.stageWidth;
		//_text.height = stage.stageHeight - 100;
	}
		
		
		 function mouseClickHandler( event:MouseEvent ):void
		{
			if (IronSource.instance.isRewardedVideoAvailable())
			{
				IronSource.instance.showRewardedVideo();
			}
			else
			{
				tet.text = "Rewarded Video not available";
			}
			
		}
		
		
		//
		//	EXTENSION HANDLERS
		//
		
		
		
		 function onRewardedVideoAdShowFailed( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAdShowFailed" );
		}


		 function onRewardedVideoAdOpened( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAdOpened" );
		}


		 function onRewardedVideoAdClosed( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAdClosed" );
		}


		 function onRewardedVideoAvailabilityChanged( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAvailabilityChanged: " + event.availability );
		}


		function onRewardedVideoAdStarted( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAdStarted" );
		}


		function onRewardedVideoAdEnded( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAdEnded" );
		}


		 function onRewardedVideoAdRewarded( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAdRewarded" );

		}


		 function onRewardedVideoAdClicked( event:RewardedVideoAdEvent ):void
		{
			//message( "onRewardedVideoAdClicked" );
		}
  • AIR SDK -- 51.1.3.6

Please check and let me know if any other additions are needed or if I have made any mistakes.

@marchbold
Copy link
Contributor

Please can you include the console logs and the crash log from the device,

https://docs.airnativeextensions.com/docs/tutorials/device-logs#ios

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants