ATT Prompt Issue with iOS 15

Hi all, I recently received the following message from Apple at app review:

"We’re looking forward to completing our review, but we need more information to continue. Your app uses the AppTrackingTransparency framework, but we are unable to locate the App Tracking Transparency permission request when reviewed on iOS 15.0.

Since you indicated in App Store Connect that you collect data in order to track the user, we need to confirm that App Tracking Transparency has been correctly implemented."

I did a bit of Googling and found that this is a common issue:

https://www.reddit.com/r/iOSProgramming/comments/pt41jz/att_prompt_not_showing_on_ios_15/

https://www.reddit.com/r/iOSProgramming/comments/psjmu2/app_review_your_app_uses_the/

Similar to in my case, the ATT prompt works fine in iOS 14.5 but not in iOS 15 and it seems to be related to the application state:

Calls to the API only prompt when the application state is: UIApplicationStateActive

Is there a way I can force this in the code or a planned update to the ATT plugin that will fix this issue?

I don’t think there is a way to force UIApplicationStateActive to be true - it’s literally the flag that says “the app is currently in the foreground”. Anything that backgrounds the app (closing it, an ad appearing, a native dialog box being shown) will change the application state.

It’s strange that it’s reaching a point where you are attempting to show the popup while the app is backgrounded though. If the app is backgrounded due to another permission alert being shown or something like that, then the Lua code would be paused and it shouldn’t get to the point where it calls att.request().

As a workaround can you not delay the request until a point where you know it should be safe to show it?

So the implementation that I have in previous versions of the app simply adds the plugin to build.settings along with the NSUserTrackingUsageDescription in plist which seems to call the ATT dialog box automatically when the app is installed and run for the first time.

This works fine up to iOS 14.5 but I no longer get the native dialog box when testing on iOS 15 and have received the app review message as above.

I haven’t previously called att.request() manually as it seemed to work fine by having the NSUserTrackingUsageDescription set but have since tried to manually request the dialog box just before admob.init and after a short delay with no success. I am guessing that the issue could be that when the app is first installed and opened there is a dialog box for allowing notifications (via plugin.notifications) and also a GDPR message which might be making the app “inactive” whilst the ATT request is being made and therefore failing?

I will experiment further with placing in a delay and re-trying the request a few times until successful and see if that helps. I assume this is an issue that will affect everybody once upgrading to iOS 15 / Xcode 13 / Solar 2D 3656 if they have just been relying on the att plugin working automatically in the background as I have.

I put a simple delay / loop code in place and this seems to have fixed the issue fine in iOS 15:

if att.status == "notDetermined" then
    local function showATTPrompt()
        att.request()
    end
    timer.performWithDelay( 1500, showATTPrompt, 10 )
end

Thank you!
I had the same issue with my build. I use the Appodeal-plugin. For iOS 15 I just had to add the delay (1500ms) before calling appodeal.init. It wasn’t necessary to add the att.request manually.

My iPhone 12 has been refusing the update, will into this

I use appodeal plugin and my app was just rejected for this reason:

‘you do not use App Tracking Transparency to request the user’s permission’

I had been using a gdpr module that pops up advising the user privacy and ad tracking stuff … but apple claims now

Requesting permission with a custom prompt is not appropriate

So, just to clarify from the info provided above and apples input,

  1. I should not use the gdpr module I had been using,

  2. but instead must use this
    local Att = require( “plugin.att” )

  3. and I do not have to initialize Att by calling att.request. But, just including it as required will automatically call it, as long as I delay calling Appodeal,.init by 1500ms

  4. in my build settings I ‘remarked’ this line

– 'NSUserTrackingUsageDescription = … ’

I am not sure if that should if remarking that line is optional or absolutely needed to be in the build settings, since using the att plugin. Is it?

Thanks for any clarification possible.

Hi Thanks for the response,

I had already implemented the ATT stuff in released Version 1.1 of the app and I get tracking stuff okay and it passed apple review 8 months ago and is live and has a few thousand users currently… all good…

I updated some stuff for version 1.2 unrelated to ATT (another Game Center leaderboard and Admob instead appodeal adverts) and they failed the version 1.2 upgrade saying what I have attached below about ATT

I implemented the delay piece and I looked into this and I found that on my iPhone 11 running IOS 14.8 I received the ATT dialog successfully if the app was loaded as if this was the users first download not an upgrade from version 1.1 to 1.2. If you simulated an upgrade from 1.1 to 1.2 the app on an iPhone 11 the status was authorised and so no dialog was shown. I assume that’s the correct behaviour as you have already asked for permission in 1.1 ?. Do you have ask for permission on every version change of the same app ? And if so How do you force that dialog if it’s already authorised ?

Interestingly I tried it on an iPhone 10 using 14.4 and the status is always authorised. I assume this behaviour is correct as the ATT requirement only came in 14.5 ? so I assume thats the correct behaviour too.

I have responded to Apple showing an image of the ATT dialog but have heard nothing back at the moment.

Will keep playing but at a bit of a loss how to sort this and thoughts/support very welcomed

Thanks

Guideline 5.1.2 - Legal - Privacy - Data Use and Sharing

The app privacy information you provided in App Store Connect indicates you collect data in order to track the user, including Advertising Data. However, you do not use App Tracking Transparency to request the user’s permission before tracking their activity.

Starting with iOS 14.5, apps on the App Store need to receive the user’s permission through the AppTrackingTransparency framework before collecting data used to track them. This requirement protects the privacy of App Store users.

Next Steps

Here are two ways to resolve this issue:

Resources

  • Tracking is linking data collected from your app with third-party data for advertising purposes, or sharing the collected data with a data broker. Learn more about tracking.
  • See Frequently Asked Questions about the new requirem