Action extension incorrectly dismisses view controller if view controller was presented modally

Originator:rob
Number:rdar://35896350 Date Originated:December 6 2017
Status: Resolved:
Product:UIKit Product Version:iOS 11.2
Classification:Bug Reproducible:Always
 
Area:
UIKit

Summary:

If a modally presented view controller (mpvc) presents a UIActivityViewController and the user selects a no-user-interface action extension (com.apple.services type), the mpvc will be dismissed when the extension completes.

Steps to Reproduce:

Open and run the attached sample project on a iOS 11.2 device/simulator.
Tap "Continue" on the first view controller.
Tap "Share" on the modally presented view controller.
Tap "More" on the second row of the UIActivityViewController sheet and enable the No UI Action Extension and push Done.
Tap on the No UI Action Extension icon.

Expected Results:

The second view controller should not be dismissed.

Actual Results:

The second view controller is dismissed

Version/Build:

iOS 11.2. This also seems to affect iOS 10.3, but not iOS 9.0

Notes:
This is different behaviour than other extension types and can cause confusion for users when the content they were acting on automatically dismisses after executing the extension.

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!