Search code examples
iosios13uidocumentbrowservc

UIDocumentBrowserViewController ignoring Document Type (com.apple.pkpass) on iOS13 device


When running on an iOS13 (beta 5) device, UIDocumentBrowserViewController does not allow selection of Document Type "com.apple.pkpass" (Wallet PKPass) previously set up in the Target's settings. Same project works fine on an iOS12 device.

To reproduce the issue simply create a new project (preferably with Xcode 10 / iOS12) with the "Document Based App" template.

Then add the following Document Type in the Info tab of the Target's settings (leaving the "Images" entry created by the template):

Name: "PKPass"

Types: "com.apple.pkpass"

Additional document type properties:

  • CFBundleTypeRole String "Viewer"

  • LSHandlerRank String "Alternate"

Document Types in Target's Info Tab

When running this on an iOS 12 device, you will be able to see and select .pkpass files (I am doing this on my iCloud Drive with pkPasses previously exported from my Wallet).

When running on an iOS13 device the .pkpass files are visible, but semi-transparent and not selectable. Images (the Document Type already set up in the "Document Based App") however work as expected. Creating the project using Xcode 11 (beta 5) leads to the same result.

Is this a bug in iOS 13 or did I miss some change or new requirement?


Solution

  • There are two types for PKPass documents com.apple.pkpass and com.apple.pkpass-data. You should keep both of them.