Posts

Post not yet marked as solved
1 Replies
I have gathered more details by debugging further. PLEASE DO NOT CLOSE THIS BUG UNTIL IT IS ACTUALLY FIXED BY APPLE:- viewDidLoad gets called twice as our App forces user interaction to authenticate. Hence, the provideCredentialWithoutUserInteraction method is made to invoke cancelRequest with ASExtensionError.userInteractionRequired, which discards the currently loaded view and the System launches the CredentialProviderViewController freshly and invokes prepareInterfaceToProvideCredential.- The issue has occurred because we were strictly relying on the viewWillAppear method to get called and were presenting the user interaction screens in the viewWillAppear flow.- For some reason, on iOS 13.4, CredentialProviderViewController's viewWillAppear is not getting invoked after returning from prepareInterfaceToProvideCredential.- As the name suggests, prepareInterfaceToProvideCredential is only meant to PREPARE the interface and NOT PRESENT the interface.- What we have been doing, that is, presenting the user interaction view controllers in the viewWillAppear flow is actually RIGHT as per the point mentioned above.- But as a WORKAROUND ONLY, NOT AS A PERMANENT FIX, we were able to get rid of this bug by presenting the user interaction view controller from within the prepareInterfaceToProvideCredential flow. THIS IS NOT ADVISABLE as the name clearly SUGGESTS THAT THE INTERFACE SHOULD ONLY BE PREPARED AND NOT PRESENTED.- The conclusion is, Apple has to FIX THIS BUG OF VIEWWILLAPPEAR not getting invoked, which was not the case on iOS versions below 13.4.
Post not yet marked as solved
3 Replies