'SwiftUI SignInWithAppleButton Hangs

I am trying to implement Sign in With Apple with SwiftUI, but it hangs after I enter the correct password.

I am using a real user and the simulator and XCode 12.0 Beta. Unfortunately, I do not have a device available right now to test on. I also tried with Sandbox users without success.

I have added the sign in with apple capability to the provisioning profile

The print statement for success is never reached.

What am I missing?

ui

Using the sample code from https://developer.apple.com/documentation/swiftui/signinwithapplebutton

import SwiftUI
import AuthenticationServices

struct SignInView: View {
    var body: some View {
        VStack {
            SignInWithAppleButton(
                .signIn,
                onRequest: { request in
                    request.requestedScopes = [.fullName]
                },
                onCompletion: { result in
                    switch result {
                    case .success (let authResults):
                        print("rhe01 Authorization successful.")
                    case .failure (let error):
                        print("rhe01 Authorization failed: " + error.localizedDescription)
                    }
                }
            )
        }
    }
}


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source