Search code examples
app-store-connectxcode8

What makes NSCalendarsUsageDescription required?


When I upload to iTunes Connect, my app gets the error that the NSCalendarsUsageDescription privacy is not provided. I am aware that this information is now mandatory, however I am not aware what and where my app uses something that would require this privacy usage description.

What is my app doing/using that it requires a NSCalendarsUsageDescription?

Dear developer,

We have discovered one or more issues with your recent delivery for "MyApp". To process your delivery, the following issues must be corrected:

This app attempts to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSCalendarsUsageDescription key with a string value explaining to the user how the app uses this data.

Once these issues have been corrected, you can then redeliver the corrected binary.

Regards,

The App Store team

Edit: Not a duplicate because of the fact that the solution didn't work as I already commented on the first answer AND the fact that the possible duplicate doesn't actually answer the question what (generally) makes this usage description required.


Solution

  • You could try using nm tool to look for EventKit specific symbols in your frameworks binaries, something like:

    nm YourFramework.framework/YourFramework | grep EK # EK is a prefix for EventKit classes
    

    Or one-liner (look for files without extension, also ignore CodeResources to reduce irrelevant output):

    find YourApp/Frameworks ! -name '*CodeResources*' -type f ! -name "*.*" -exec nm -o -- {} + | grep EK
    

    If there is such you will see something like:

    0000000000003fdb t -[ClusterPrePermissions EKEquivalentEventType:]
                     U _OBJC_CLASS_$_EKEventStore
    

    To learn more about nm run man nm in your terminal.

    The nm tool is useful when you want to see which symbols a given binary contains. There are plenty of options that you can give to nm but most of the time it is enough to run it without any arguments to answer questions like: is symbol X present in a given binary?