Xcode Unable to install "Runner" Code: -402620392 (Flutter app)
Solution 1
For everyone with the same issue, i tried for so long to fix that with all the others comments around the internet, but the mistake was more simple than looks like. My pods_runner was in Embed & Sign, but it have to be by default on "Do not embed".
You can change it in : Runner > General > Frameworks, Libraries, and Embeded Content > Pods_Runner.framework.
Maybe is not a solution for everyone, but it was the one for me, good luck (:
Solution 2
I was stuck with this problem for about a week, and finally just tried everything i could think of... What ended up working for me, was deleting the "code signing entitlements" that was generated for the project, because i notices that my other projects didn't have them.
Go to the runner in Targets -> Build Settings -> Scroll down to "Code Signing Entitlements" and delete them by pressing backspace on the keyboard!
After you have deleted them, it should look something like this image.
Image of my Code Signing Entitlements
Let me know if this worked for anyone else :)
Aleks Lagutin
Updated on December 23, 2022Comments
-
Aleks Lagutin over 1 year
XCode Version 11.1 (11A1027) Flutter version 1.17.5
I try to run my Flutter App on IPad (12.4.6). It builds without errors, but on installing step shows the message
Unable to install "Runner" Domain: com.apple.dtdevicekit Code: -402620392 Recovery Suggestion: The certificate used to sign "Runner" has either expired or has been revoked. An updated certificate is required to sign and install the application. -- The identity used to sign the executable is no longer valid. Domain: com.apple.dtdevicekit Code: -402620392 Failure Reason: Please verify that your device’s clock is properly set, and that your signing certificate is not expired. (0xE8008018). User Info: { DVTRadarComponentKey = 487927; "com.apple.dtdevicekit.stacktrace" = ( 0 DTDeviceKitBase 0x000000012a648047 DTDKCreateNSError + 109 1 DTDeviceKitBase 0x000000012a648749 DTDK_AMDErrorToNSError + 792 2 DTDeviceKitBase 0x000000012a687824 __90-[DTDKMobileDeviceToken installApplicationBundleAtPath:withOptions:andError:withCallback:]_block_invoke + 158 3 DVTFoundation 0x000000010fd3d756 DVTInvokeWithStrongOwnership + 73 4 DTDeviceKitBase 0x000000012a6875c1 -[DTDKMobileDeviceToken installApplicationBundleAtPath:withOptions:andError:withCallback:] + 1589 5 IDEiOSSupportCore 0x000000012a521f6c __118-[DVTiOSDevice(DVTiPhoneApplicationInstallation) processAppInstallSet:appUninstallSet:installOptions:completionBlock:]_block_invoke.352 + 4523 6 DVTFoundation 0x000000010fe6e9ba __DVT_CALLING_CLIENT_BLOCK__ + 7 7 DVTFoundation 0x000000010fe70092 __DVTDispatchAsync_block_invoke + 809 8 libdispatch.dylib 0x00007fff6e35e5f8 _dispatch_call_block_and_release + 12 9 libdispatch.dylib 0x00007fff6e35f63d _dispatch_client_callout + 8 10 libdispatch.dylib 0x00007fff6e3658e0 _dispatch_lane_serial_drain + 602 11 libdispatch.dylib 0x00007fff6e366396 _dispatch_lane_invoke + 385 12 libdispatch.dylib 0x00007fff6e36e6ed _dispatch_workloop_worker_thread + 598 13 libsystem_pthread.dylib 0x00007fff6e59f611 _pthread_wqthread + 421 14 libsystem_pthread.dylib 0x00007fff6e59f3fd start_wqthread + 13 ); } --
I tried to run this under my personal developer license (not paid acc) and under my company license (paid acc). All sertificates are valid 100%. I recreated them all at some point but still no luck :(
Also was done:
Library/MobileDevice/Provisioning\ Profiles/
were clearedLibrary/Developer/Xcode/DerivedData
was cleared- Bundle Id - I`ve tried to change it
- Tried to create new project and run it - successfully runs, but only first time, when it has almost no code inside. When I add some extra code and run
pod install
- it fails.
and the strange thing is that I have another Flutter project with no extra dependencies and I can delivery it to the same device.
Could it be that some packages or Info.plist settings like
io.flutter.embedded_views_preview
ruin everything?Can't find any interconnection...
-
Aleks Lagutin over 3 yearsHi Jacob! Thank you for your comment! Unfortunately this doesn`t work for me. All fields in Code Signing Entitlements are clear but still no luck with installing an application to real device(