The document “Main.storyboard” requires at least Xcode 12.0 - swift

I am working on Xcode 12. And I created a new project on Xcode 12. I compile & run it successfully. when I run this project on Xcode 11.3 then It throws an error like: The document “Main.storyboard” requires at least Xcode 12.0 .
So, help me to fix this problem. I want to run this project in a lower version of Xcode 12.

Since the project is created in Xcode 12. The minimum required Xcode version is Xcode 12. If you want to compile with Xcode 11.3, recreate the main.storyboard using Xcode 11.3
Edit:
As pointed out my matt in a comment alternative way is to open main.storyboard as source code and update toolversion value same as Xcode 11.3. (try sample storyboard to find toolversion for Xcode 11.3)

Related

Xcode fails to build new projects (12.4) - Could not build Objective-C module 'SwiftUI'

As soon as I create an Xcode project I can't build and have a bunch of errors (Xcode version 12.4)
Could not build Objective-C module 'SwiftUI'
I figured it out! MY Xcode was using the wrong toolchain version even tho I tried to uninstall Xcode and reinstall it.
Make sure you have selected the correct version, in my case since I was running Xcode 12.4, I had to use version 12.4 for toolchains. It's weird that Xcode did not manually change it since I updated.
To updated version:
Xcode > Preferences > Components > Toolchains > and then select your
version

update Xcode to 10.2.1 run project crash with problem dyld: Library not loaded: #rpath/libswiftCore.dylib

I have a project that was created with Xcode 10, Objective-C, and Swift 4.0 and now upgraded to Xcode 10.2.1.
Error reporting for each run.
I have set Always Embed Swift Standard Libraries to YES
Add #executable_path/Frameworks to "Runpath Search Paths"
These methods don't resolve the issue.
dyld: Library not loaded: #rpath/libswiftCore.dylib
Referenced from: /private/var/containers/Bundle/Application/48371FB5-6A90-4D14-9D65-C7AB5DCAC1A1/one mini.app/Frameworks/Framework152x.framework/Framework152x
Reason: image not found
Actually, the problem is the Framework152x.framework is developed in Swift with Xcode version below 10.2. If your project is built with Xcode 10 with Framework152x.framework means Framework152x.framework runtime is swift 4.2. But if you build your project in Xcode 10.2.1 this issue will occur. Because the XCode 10.2.1 has swift 5 Runtime but Framework152x.framework is expecting swift 4.2. You can resolve this problem only by using Framework152x.framework which needs to be built either in Xcode 10.2 or 10.2.1
I had the same or very similar issue with UI tests failing due to their deployment target being set to iOS 12 and the app under test being set to iOS 10. When I set them both to iOS 10 the UI tests would successfully launch (the app always launched fine). Not sure if that's the problem you're having as you've not mentioned UI tests but perhaps you neglected to mention that :)

How to import and use CreateML or CreateMLUI in Xcode

I would like to use the new CreateML and CreateMLUI Swift frameworks.
But when I write:
import CreateML
Xcode gives me an error:
No such module 'CreateML'
How can I use those in Xcode?
To import CoreML or CoreMLUI you need to get latest software:
Go to https://developer.apple.com/download/
Install macOS Mojave 10.14 beta version.
Install Xcode 10 beta.
Create a macOS platform template.
HOW TO CREATE YOUR OWN MLMODEL: https://developer.apple.com/documentation/create_ml/creating_an_image_classifier_model
Use free MLModels provided by apple: https://developer.apple.com/machine-learning/run-a-model/
You need to
Have Mojave installed
Install Xcode 10 beta
Create a macOS template playground (not iOS)
Install Mojave* and Xcode 10.
Create a new playground and make sure you select macOS as the target (e.g. macOS Single View).
Type in import CreateMLUI- it should compile without problems.
(*)macOS Mojave is officially available since yesterday.
For Xcode 10 - beta 6
You don't have to upgrade to Mojave. The newest Xcode - beta already supports 10.13.x. (From Apple Developer Forums).
I followed this step to try CreateML framework.
Upgraded to latest MacOS (Not Mojave)
Upgraded latest Xcode - beta.
Create playground in macOS template (Default is iOS template)
Then, I can use createMLUI.

Module compiled with swift 4.0 cannot be imported in swift 3.0.2

I just used Xcode 9 beta version and did not even compile my app. Now I am not able to run it in Xcode 8. The framework import is giving error. I have to give the archive. Help please. In the snapshot attached , I am importing an external framework MMCardView written in swift. Now that is throwing error in Xcode 8. What should i do?
Try cleaning the project from Product -> Clean in Xcode 8 and build again.

SenTestingKit Not found In Xcode4

When I tried to import <SenTestingKit/SenTestingKit.h>, I get this error: SenTestingKit/SenTestingKit.h: No such file or directory.
I am using unit testing for the first. I am using xcode 4.2 with ios 5 sdk. But in my system I have two xcode version installed,4.2 and 3.2.5. Although i am using xcode 4.2 ,xcode3.2.5 is the default xcode in my system. Can any one help me with the unit testing?
SenTestingKit.framework is at :
/Developer/Library/Frameworks/SenTestingKit.framework (OS X)
/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOSX.X.sdk/Developer/Library/Frameworks/SenTestingKit.framework (iOS)
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulatorX.X.sdk/Developer/Library/Frameworks/SenTestingKit.framework (simulator)
for Xcode versions 4.3 and above prepend /Applications/Xcode.app/Contents/ to the paths above
I don't know, but the frameworks path will be different for both xcodes. it might be in 3.2.5 frameworks path and when using 4.2, it may not find it. Correct me if I'm wrong.