Build, test, and submit your app using Xcode, Apple's integrated development environment.

Xcode Documentation

Post

Replies

Boosts

Views

Activity

VisionOS Simulator Stuck on Black Screen with "Hello World" Code in Xcode
Hello everyone, I’m currently developing my first VisionOS app in Xcode, starting with the default "Hello World" code provided when creating a new VisionOS Mixed Reality App. However, I’m facing some issues with performance and previewing that I can’t seem to resolve. When I load the preview, it takes an extremely long time, and sometimes it doesn’t load at all. Even when I try to run the app in the VisionOS Simulator, the simulator shows an endless black screen and never displays the intended view. I’ve made no changes to the code, so it’s purely the base setup. Here are my system details: Xcode version: 16.1, VisionOs 2.0; macOS version: 15.0.1; Hardware: MacBook Air 2020 M1 I’ve tried restarting Xcode and my machine, but the issue persists. Has anyone else faced similar problems or have any suggestions for fixing this? Or is my hardware simply too weak? Any help would be greatly appreciated! Thank you in advance!
1
0
103
2w
IBInspectable was deprecated.
I noticed that IBDesignable was deprecated in the Xcode 16 release notes, and IBInspectable was deprecated in the Xcode 16.1 release notes. So, I performed some tests on IBDesignable and IBInspectable in Xcode. I wrote the following code: @IBDesignable extension UIView { @IBInspectable var cornerRadius: CGFloat { get { layer.cornerRadius } set { layer.cornerRadius = newValue } } @IBInspectable var borderWidth: CGFloat { get { layer.borderWidth } set { layer.borderWidth = newValue } } @IBInspectable var borderColor: UIColor { get { UIColor(cgColor: layer.borderColor ?? .init(red: 1, green: 1, blue: 1, alpha: 0)) } set { layer.borderColor = newValue.cgColor } } } I cannot access the IBInspectable property in Xcode 16. However, I can access the IBInspectable property in Xcode 16.1 and Xcode 16.2 Beta, where the Interface Builder shows it in the Attributes Inspector. Is it possible that this will be updated later, as it differs from the release notes? Thank you.
0
0
180
2w
What files used by Xcode can I delete?
I ran out of disk space and I think I've come to the point that I need to delete files used by Xcode. Can I delete Simulator altogether? It doesn't look like I can run the latest Xcode without iOS 18 installed with it on my Mac Pro. Is there any way I can exclude iOS 18 support using the current Xcode? Would it be a good option to uninstall the latest Xcode and use a previous version of Xcode instead, since I'm not developing for iOS 18? Since I've been working on only macOS apps, is it possible for me to delete anything that has to do with developing for iOS?
1
0
128
2w
Validate fail Archive bundle is invalid Unable to load ‘Info.plist’ for bundle at path
This bundle is invalid. Unable to load ‘Info.plist’ for bundle at path: ‘My App.app/Contents/Library/Spotlight/MyApp-SpotlightIndex.mdimporter’.. This mdimporter is embedded in my app with a Copy step in Build Phases and when I Archive the compiled app, I get that error when I try to Validate. The app works OK, the mdimporter Spotlight works OK, all runs fine. But the Validate on the Archive does not work, it fails with that error.
1
0
142
2w
Unable to add package dependencies in Package Manager
Hi, I try to add the Firebase requirements to my iOS application. I launched the package manager, at first, nothing was loading, therefore I deleted and recreated my Github account, and the previous packages now appears. When I try to paste the url for Firebase in the search bar, there is an infinite loading loop and it never appears. I tried to restart Xcode several times, to disconnect and reconnect from wifi etc. Can anyone help me solve this please?
1
0
61
2w
IBAgent Crash
Could someone help me with a good direction on where or how could I fix for this crash from console log: Not able to open storyboard or XIB. Once opening them, Xcode is crashing. tried uninstalling the Xcode, couldn't fix even after deleting derived data and caches. ------------------------------------- Translated Report (Full Report Below) ------------------------------------- Incident Identifier: 7E6D64FF-D4E9-4E3A-A37A-BC5016316DCD CrashReporter Key: 4776E37C-4D3D-F705-40D5-8A96EE95C89A Hardware Model: Mac15,6 Process: IBAgent-iOS [31688] Path: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Overlays/IBAgent-iOS Identifier: IBAgent-iOS Version: 16.0 (23506) Code Type: ARM-64 (Native) Role: Unspecified Parent Process: launchd_sim [31680] Coalition: com.apple.CoreSimulator.SimDevice.178E8D7E-176F-4B7F-8956-D26C5EF7323A [5165] Responsible Process: SimulatorTrampoline [1185] Date/Time: 2024-11-06 14:59:29.3079 +0530 Launch Time: 2024-11-06 14:59:28.9368 +0530 OS Version: macOS 15.1 (24B83) Release Type: User Report Version: 104 Exception Type: EXC_BREAKPOINT (SIGTRAP) Exception Codes: 0x0000000000000001, 0x0000000102e1e19c Termination Reason: SIGNAL 5 Trace/BPT trap: 5 Terminating Process: exc handler [31688] Triggered by Thread: 0 Application Specific Information: Abort Cause 259 Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libsystem_platform.dylib 0x102e1e19c _os_unfair_lock_recursive_abort + 36 1 libsystem_platform.dylib 0x102e19504 _os_unfair_lock_lock_slow + 304 2 libGSFont.dylib 0x19045ebb4 GSFontFileDescriptorForPath + 28 3 libFontParser.dylib 0x19047d714 TFileDescriptorContext::TFileDescriptorContext(char const*) + 216 4 libFontParser.dylib 0x19057c7e4 TFileDataReference::Map(char const*) + 36 5 libFontParser.dylib 0x19047d514 TFileDataReference::TFileDataReference(char const*) + 88 6 libFontParser.dylib 0x19057c934 TFileDataSurrogate::TFileDataSurrogate(char const*, timespec) + 152 7 libFontParser.dylib 0x1905cbaac TFont::CreateFontEntitiesForFile(char const*, timespec, bool, short, char const*) + 580 8 libFontParser.dylib 0x19047d1e0 FPFontCreateFontsWithPath + 200 9 CoreGraphics 0x18b612c54 create_private_data_array_with_path + 16 10 CoreGraphics 0x18b2cddd4 CGFontCreateFontsWithPath + 36 11 CoreGraphics 0x18b3389b0 CGFontCreateFontsWithURL + 680 12 libGSFont.dylib 0x190465518 AddFontsFromURLOrPath + 288 13 libGSFont.dylib 0x19045ffb4 RegisterURLAndCopyFaces + 168 14 libGSFont.dylib 0x19045fefc GSFontRegisterURL + 76 15 CoreText 0x181c5e0b8 _CTFontManagerRegisterActionFontsForURLs(__CFArray const*, CTFontManagerScope, bool, Action, __CFArray const**) + 396 16 IBCocoaTouchToolFoundation 0x10307e748 +[UIFont(IBCocoaTouchToolIntegration) ib_registerFontsAtURLs:] + 336 17 AssetCatalogFoundation 0x1033e1a88 __80-[IBMessageReceiveChannel deliverMessage:toTarget:withArguments:context:result:]_block_invoke + 196 18 AssetCatalogFoundation 0x1033e191c -[IBMessageReceiveChannel deliverMessage:toTarget:withArguments:context:result:] + 328 19 AssetCatalogFoundation 0x1033e14bc __88-[IBMessageReceiveChannel runBlockingReceiveLoopNotifyingQueue:notifyingTarget:context:]_block_invoke + 100 20 libdispatch.dylib 0x180178de0 _dispatch_client_callout + 16 21 libdispatch.dylib 0x180188bc8 _dispatch_async_and_wait_invoke + 112 22 libdispatch.dylib 0x180178de0 _dispatch_client_callout + 16 23 libdispatch.dylib 0x180187c60 _dispatch_main_queue_drain + 1272 24 libdispatch.dylib 0x180187758 _dispatch_main_queue_callback_4CF + 40 25 CoreFoundation 0x18041b2dc __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 12 26 CoreFoundation 0x180415838 __CFRunLoopRun + 1944 27 CoreFoundation 0x180414c24 CFRunLoopRunSpecific + 552 28 Foundation 0x180f319c8 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 208 29 AssetCatalogFoundation 0x1033bdc00 -[IBAbstractPlatformTool startServingReceiveChannel:] + 292 30 AssetCatalogFoundation 0x1033bddf4 -[IBAbstractPlatformTool startServingWriteDescriptor:readDescriptor:] + 96 31 AssetCatalogFoundation 0x1033be718 +[IBAbstractPlatformTool main] + 800 32 IBAgent-iOS 0x102b77930 main + 32 33 dyld_sim 0x102b89410 start_sim + 20 34 dyld 0x102c96274 start + 2840
1
1
101
2w
没法删除语言
只能在string catalog里面添加语言,不能删除语言??这是什么设计? 在Project里面删除语言,并不能删除Localizable中的语言。但是如果这个语言没有任何国际化,是可以的。 也就是说,删不了曾经做过国际化的语言。 我应用还没发布,还在开发呢,为什么不让我删除语言??????????????????????????、
1
0
85
2w
Profile doesn't include the selected signing certificate
Hello, I have tried both automatic signing and manual signing, and still when I submit I get an error message that says "Provisioning profile failed qualification" and "Profile doesn't include the selected signing certificate.". Everything had been working fine, but I think it may have broken with an Xcode update - not sure. Please let me know what to look for. I appreciate any help you can give me.
1
0
112
2w
Xcode basics
I am trying to learn Xcode with C as a start to learning to program. So far I have not gotten Xcode to successfully build and run a program using C on Mac OS. Any recommendations on basic troubleshooting for Xcode setup and orientation. Every program I try to run says "Build failed".
6
0
154
2w
When application merges libswift_concurrency.dylib is duplicated in app binary
Environment: Xcode 16.1 Swift version: 6.0.2 Inside of an Xcode project, if I declare a framework and an application. The framework is mergeable and the application merges the framework by configuring MERGE_BINARY_TYPE to Manual (or automatic it's independent). If SWIFT_VERSION is set to 6.0.X and deployment target is set to iOS 15< the build is going to fail because of this error Duplicate linked dylib '@rpath/libswift_Concurrency.dylib' in '/Users/**/Library/Developer/Xcode/DerivedData/GSPackage-dvnngsrgctfovgfbvwdlsscfycyq/Build/Products/Debug-iphonesimulator/DummyApp.app/DummyApp.debug.dylib' If I'm checking the generated artifact and inspect all of it's @rpath with otool it's giving me the following: otool -L /Users/****/Library/Developer/Xcode/DerivedData/Dummy-gbccsjwxeajftsafghxzaqksgfim/Build/Products/Debug-iphonesimulator/Dummy.app/Dummy.debug.dylib | grep @rpath @rpath/Dummy.debug.dylib (compatibility version 0.0.0, current version 0.0.0) @rpath/libswift_Concurrency.dylib (compatibility version 1.0.0, current version 0.0.0, weak) @rpath/libswift_Concurrency.dylib (compatibility version 1.0.0, current version 0.0.0, weak) A radar is already opened with the ID: FB15693702
0
0
129
2w
App Groups: How to use group. prefix and Team ID prefix for Multiplatform apps?
Hi there, I have a Multiplatform app with just one app target with an iPhone, iPad and Мас Destination. On the Mac my app is a developer singed App that is being distributed outside of the Mac App Store. I want to use App Groups, but as long as there are multiple destinations, Xcode only allows Group Identifiers starting with group.. However, for macOS I need to have a group ID that starts with the TeamID as explained here. So I created two separate entitlements, which are identical, but with different group IDs: With Automatic Code Signing enabled, I get this warning: Xcode still seems thinks it has to use the macOS Group ID for the iOS version. In the App Groups section, the mac Group ID is red and the iOS Group ID is not checked. The app builds and runs without issues on all platforms. The App Store Connect validation (for the iOS version) also works without any errors. Am I doing something wrong? Do I need a separate Mac target because Xcode does not support separate Group IDs for Multiplatform apps?
2
1
162
2w
macOS Sequoia doesn't respect Full Disk Access for UITests-Runner
We develop and test App for macOS. We start to see system alert - "UlTests-Runner" would like to access data from other apps on each UITest run. Our test suite does cleanup of files generated by App so we need access outside of UITests-Runner sandbox. We enabled Full Disk Access for UITests-Runner at Settings -> Privacy & Security -> Full Disk Access but unfortunately still see this alert. Is there any way to permanently remove/hide this alert or remove sandbox for 'UITests-Runner' since we want to run tests on CI and having this alert is not an option? Note: everything works fine on previous versions of macOS. Environment: macOS - 15.1 (24B83) Xcode - Version 16.1 (16B40)
0
1
140
2w
'Expand macro' menu option does nothing
I somehow broke my Xcode, it does not expand macros anymore. What I have tried: create new project clean the project remove derived data remove contents of ~/Library/org.swift.swiftpm/security What I have not tried: remove Xcode completely and re-install it (will have to re-setup everything, so don't want to resort to it) Xcode version is 16.1. The 'Add File' button has everything grayed-out, so I can't upload a video here, and 'YouTube' website is not a valid URL here for some reason. Has anyone else faced a similar problem?
1
0
84
2w