Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-23889

iOS: App crashes on iOS 10 when calling Permisson's methods

    Details

    • Type: Bug
    • Status: Closed
    • Priority: None
    • Resolution: Duplicate
    • Affects Version/s: Release 5.5.0
    • Fix Version/s: None
    • Component/s: iOS
    • Labels:

      Description

      I am seeing app crashes when I use methods from permissions (Calendar, Contacts, Camera (Media), etc) in my apps.
      I do not have any log output except from Xcode:

      Termination Reason: TCC, This app has crashed because it attempted 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.
      Triggered by Thread:  5
      

      Steps to reproduce issue
      1. Create a new project
      2. Use a Permission's method in the code, I suggest the below
      3. Run the app on an iOS 10 device

      Expected Results
      The app runs without issue

      Actual Results
      The app crashes when the Permission's method is called

      Notes
      I am able to encounter this issue when checking for media permissions:

      function askCameraPermissions(){
      if (Ti.Media.hasCameraPermissions()) {
             alert("Camera Permissions already granted");    
         } else { 
             Ti.Media.requestCameraPermissions(function(e) {
                      if (e.success === true) {
                          alert("Camera Permissions Granted");
                      } else {
                          alert("Access denied, error: " + e.error);
                      }
             });
         }
      }
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                hknoechel Hans Knöchel
                Reporter:
                ewieber Eric Wieber (Inactive)
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Backbone Issue Sync

                  • Titanium SDK/CLI <> Titanium Mobile
                    Synced with:
                    TIMOB-10089
                    Sync status:
                    ERROR
                    Last received:
                    Last sent:

                    Git Integration