CoreData: annotation: Failed to load optimized model (React Native) - xcode

I can not start my react native application anymore. I updated XCode yesterday, maybe it has to do with it?
$ react-native run-ios
Found Xcode workspace xyz.xcworkspace
CoreData: annotation: Failed to load optimized model at path '/Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/Frameworks/InstrumentsPackaging.framework/Versions/A/Resources
/XRPackageModel.momd/XRPackageModel 9.0.omo'
dyld: Symbol not found: _SimAudioHostUseSystemDefaultDeviceUID
Referenced from: /Applications/Xcode.app/Contents/Developer/usr/bin/../../Library/PrivateFrameworks/SimulatorKit.framework/Versions/A/SimulatorKit (which was built for Mac OS X 10.12)
Expected in: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
in /Applications/Xcode.app/Contents/Developer/usr/bin/../../Library/PrivateFrameworks/SimulatorKit.framework/Versions/A/SimulatorKit

I simply had to start XCode one time after the update and then I was asked if I want to install additional components. That's all.

+1 on what #Jan mentioned. This happened to me after upgrading XCode to latest, and then running react-native run-ios threw the same error. Booting up XCode prompted me to install additional components, and that resolved the issue.

If you just updated your Xcode to Xcode 11.1 simply go to Xcode->preferences->Locations and change the command line tool to 11.0, this worked for me!

It happened to me to today, and I search for a lot but all failed, finally I find someone says that, if your Xcode is on version 9.x, sth will run wrong on higher version react-native-cli, maybe you can choose react-native-cli #version 0.44.x or below. If I am wrong, sorry

I was running XCode v9.2 and I was getting this error. Basically Then I had to Upgrade to Mac 10.13.2 (Sierra to High Sierra) and then download XCode v9.4. When I opened XCode 9.4 for the first time I was asked to download the components that everyone is talking about. I no longer had the error.

Couldn't figure it out, but I realized that running from Xcode directly works.

Related

Xcode Workspace "Internal error: missingPackageDescriptionModule"

After updating Xcode to version 13.2 i can't build my project anymore. I have a strange error "Internal error: missingPackageDescriptionModule" related to my Workspace file.
It's definitely related to SPM because Xcode is not loading SPM packages also. I tried to "Reset package caches", "Resolve package caches" and also "Updating to latest package caches" but after all of these operating nothing happens. Deleting derived data, cleaning didn't help too...
I tried also to resolve packages from Terminal using xcodebuild -resolvePackageDependencies but I get error message:
--- xcodebuild: WARNING: The directory /Users/ptocicki/Developer/KFC/kfc-ios also contains the legacy project 'project.pbxproj' - ignoring it and using 'KFC.xcodeproj'.
xcodebuild: error: Could not resolve package dependencies:
Internal error: missingPackageDescriptionModule"
Apple is aware of the issue.
We're currently investigating this issue — thank you to those who have
filed bug reports so far. To workaround this issue, please re-download
Xcode 13.2 directly from the Downloads page.
https://developer.apple.com/forums/thread/696504?answerId=698142022#698142022
🎊 Fixed on v13.2.1 and you can download from here
Explaination
This bug is reported and the v13.2.1 AppStore version but As  Apple suggest here, you should download the Xcode manually from the developer center
Manual download of any Apple developer software
✅ The always working and preferred workaround!
Download directly from Apple:
Latest Release version or
Latest Beta version or
Any version you need and all other downloadable contents
Then extract and move it where you like. This has so many benefits compared to AppStore updates. (like the ability to resume download, not replacing the old one, not wasting hidden directories and etc.)
Note that you should use safari to download it.
⚠️ Important note for developers like me!
The page you’re looking for can’t be found.
If you The page you’re looking for can’t be found message, you may need to use a VPN if you are in a country that the US sanctioned like mine. Because Apple is blocking some IP address ranges.
If you’re using Swift packages either standalone or as dependencies in an Xcode project or workspace, the Mac App Store version of Xcode fails during package resolution with the error “Internal error: missingPackageDescriptionModule.” (86435800)
Workaround: Download Xcode 13.2 directly from the Apple Developer website.
I just got the issues late at night after Xcode updated on its own while I was working on my project, which was not a cool surprise. It appears to be affecting all dependencies. You are not alone in this it's affecting everyone. I did what they recommended and downloaded Xcode directly from the Apples developer site and it fixed all my issues super happy right now!!!!!!!
XCode was updated to 13.2.1 at 12/19 which fix the issue.
https://developer.apple.com/documentation/xcode-release-notes/xcode-13_2-release-notes
If you’re using Swift packages either standalone or as dependencies in an Xcode project or workspace, the Mac App Store version of Xcode fails during package resolution with the error “Internal error: missingPackageDescriptionModule.” (86435800)
Workaround: Download Xcode 13.2 directly from the Apple Developer website.
Seems local package still working. So there is a temporary solution: We can download the dependencies then add them to the project as local paclages.
Please update to Xcode 13.2.1.
If not, download Xcode 13.2 from the Apple Developer website.
Updating from Xcode 13.2 to 13.2.1 from App Store fixed the issue for me.

Error in Xcode 12 when trying to upload app binary to App Store Connect

On Mac OS 10.15.7, in Xcode 12.1, when I try to upload my app binary to App Store Connect, I am getting:
"App Store Connect Operation Error: Please update iTMSTransporter to a
newer version. (4107)"
I've tried restarting my computer, deleting .itmstransporter, and various other things to no avail.
In the meantime, I've downloaded the Transporter app from the Mac App Store and have been able to submit from there by exporting the binary rather than uploading it to the App Store, but I'd like to regain the functionality in Xcode.
Does anyone have a clue on what may be causing this?
I finally was able to solve this. Peeking around my system I found 3 versions of iTMSTransporter.
Printing the version of each using ./iTMSTransporter -version gives the following results:
/Applications/Transporter.app/Contents/itms/bin/ has version 2.0.0
/Applications/Xcode.app/Contents/SharedFrameworks/ContentDeliveryServices.framework/Versions/A/itms/bin/ has version 2.1.0
/usr/local/itms/bin/ has version version 1.9.3
So it looks that old version in /usr/local/itms was used by Xcode. After deleting /usr/local/itms I was able to upload my binary within Xcode 12.2 and using the xcodebuild command line tool.
I also deleted ~/Library/Caches/com.apple.amp.itmstransporter but I do not expect that this was the real issue.
UPDATE: This also solved my issue today in Xcode 12.3 where Distribute App and xcodebuild both got stuck in a
authenticating with the app store
I face the same issues and solved it after execute ./iTMSTransporter -updateChannel earlyAccess on command line.
/Applications/Xcode.app/Contents/SharedFrameworks/ContentDeliveryServices.framework/Versions/A/itms/bin/iTMSTransporter -updateChannel earlyAccess
or
/Applications/Transporter.app/Contents/itms/bin/iTMSTransporter -updateChannel earlyAccess
I faced it with XCode 13.0, the solution is just to update your XCode to the new released. Also, u can just ignore this warning.
Just clean build folder and try again archive.
I managed to fix this by installing the copy of Transporter linked to in Apple's Transporter user guide, in the "Install Transporter" section.
Application Loader isn't working anymore.
You can use Xcode or Transporter App from the App Store.
https://apps.apple.com/de/app/transporter/id1450874784?mt=12

Xcode 10 crashes on opening the specific project with unrecognized selector sent to class exception

Just faced an issue with xCode 10 - it continuously crashes on specific project opening with the following exception:
Application Specific Information:
ProductBuildVersion: 10B61
UNCAUGHT EXCEPTION (NSInvalidArgumentException): +[NSColor detailAccentColor]: unrecognized selector sent to class 0x7fff911ce0a8
UserInfo: (null)
Weird, but xCode 10 beta was working fine with the same project before xCode update, currently it's just hanging.
Has anyone faced the same issue?
How did you solve it?
Thank you!
The problem has been resolved after installing Mac OS Mojave.
It was Mac OS Mojave beta before
Same issue happen as well, solve after update to latest Mac OS Mojave version.
First: Quit Xcode and delete the DerivedData folder you use for your project.
If that doesn't solve it:
Try rolling back to a previous stable commit, such as before any Xcode 10 betas at all. Then open that in Xcode 10 (after deleting your DerivedData directory). If that works, I'd then start adding back whatever project changes you had done in commits after that one.
And if you don't use Git, well, now you know why you should always use Git or another source management system. Be prepared to rebuild your entire project from scratch (though you can look at your previous project in Xcode 10 beta for reference purposes as you start over on your project).

iphone simulator Symbol not found: ___CFObjCIsCollectable

The detail content as follwing:
Error loading /System/Library/Extensions/AudioIPCDriver.kext/Contents/Resources/AudioIPCPlugIn.bundle/Contents/MacOS/AudioIPCPlugIn: dlopen(/System/Library/Extensions/AudioIPCDriver.kext/Contents/Resources/AudioIPCPlugIn.bundle/Contents/MacOS/AudioIPCPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode45-DP1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
My condition
There are three xcode versions on my mac os. I have xcode4.3.1, xcode4.5-DP1 and xcode4.6. When I first run my application, all is normal, and the audio files play. Then I changed the xcode version and ran my application, and the problem appeared.
My solution
I had searched many methods to try to find the reason for the problem. Such as the way shown in this link and lldb command, but it didn't work.
My conclusion
Maybe it's the bug with loading the springboard on the simulator when I changed the xcode version, but I don't know how to revert to other xcode version.
Or it may not be the simulator. If anyone knows a solution, it would be appreciated.
May be I had found the solution.When I removed the xcode4.5DP and xcode 4.3.1,and restart the system ,my app can play the audio normal again.

XCode 3 - core compile errors with clean installation and iPhone 4 SDK

This is a copy of another question from AskDifferent, since I'm being adviced to put this question here instead.
This has been asked once elsewhere but nobody could give the guy an answer... and I Google seem to only know that single occurrence of the problem!
So I'm the second guy in history to experience this and my problem is:
I'm running XCode 3.2.3 on Snow Leopard 10.6.4 (I think, it's the minimal required OS version for this XCode version) with iOS SDK 4.0.2
I create a new empty Cordoba (PhoneGap) project
I set up my Base SDK in Project Settings to iPhone Simulator 4.0 per instructions on PhoneGap's website
I don't change any other setting at all
when I hit "Build and Run" button, XCode starts compilation and finished with 3 errors and 10 warnings
Now, I don't mind those warning, but I cannot successfully compile because of those 3 errors now. No idea how to fix this, I'm totally new to PhoneGap or Mac OS for that matter.
The errors I get are:
/Users/[name]/Documents/CordovaLib/Classes/CDVLocation.m:123:32 /Users/[name]/Documents/CordovaLib/Classes/CDVLocation.m:123:32: error: use of undeclared identifier 'kCLAuthorizationStatusAuthorized'
/Users/[name]/Documents/CordovaLib/Classes/CDVCapture.m:783:70 /Users/[name]/Documents/CordovaLib/Classes/CDVCapture.m:783:70: error: use of undeclared identifier 'NSEC_PER_MSEC'
Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/clang failed with exit code 1
I would appreciate any advice from you guys, as I'm completely at a dead-end here.
CLAuthorizationStatus, and thus kCLAuthorizationStatusAuthorized are only available in 4.2 and later.
Check this for more info: https://developer.apple.com/library/ios/#documentation/CoreLocation/Reference/CLLocationManager_Class/CLLocationManager/CLLocationManager.html#//apple_ref/c/econst/kCLAuthorizationStatusAuthorized
As to your other error, google pulls up this: How to resolve Phonegap error while Building the app

Resources