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

Xcode Documentation

Pinned Posts

Posts under Xcode tag

3,078 Posts
Sort by:
Post not yet marked as solved
0 Replies
9 Views
I was watching https://developer.apple.com/videos/play/wwdc2023/10248/ , in this video it is adviced to make below shated property async to benefit from concurency (in video 40:04 , exact time) , do yo know how to do it ? class ColorizingService { static let shared = ColorizingService() func colorize(_ grayscaleImage: CGImage) async throws -> CGImage // [...] } struct ImageTile: View { // [...] // implicit @MainActor var body: some View { mainContent .task() { // inherits @MainActor isolation // [...] result = try await ColorizingService.shared.colorize(image) } } }
Posted
by Huseyin_.
Last updated
.
Post not yet marked as solved
1 Replies
26 Views
I just bought a m2 MacBook Pro running latest Xcode / Sonoma from apple refurbed. I am porting from an older macbook pro/intel chip a project that uses pthread. as this is my first week using the laptop, I recompiled the project but the apple linker does not find the libpthread library. I see it is not included in the installed Xcode. how do I get this library from Apple? regards Dave
Posted
by DaveBone.
Last updated
.
Post not yet marked as solved
1 Replies
35 Views
Hello! We are experiencing crashes on iOS both in debug and release builds in a game made in Godot 3.5.1. The main problem is that we don’t know where exactly the problem is and cannot understand how could we find a way to fix it. We don't expect that someone here will know how to fix this on Godot's side, but we would appreciate some help on how to get more info about the problem and potentially fix it. Debug builds: It is way more frequent in debug builds when we make a build, open it in Xcode, and install it directly on an iOS device. The first type of the crash in debug build is occurring like 70% of the time when the game is loading and trying to get into its main menu. The thing we are getting in Xcode looks like on first image below. Another type of crash happens when we open some save files and start the actual playable part of the game. It happens just after moving the character a few steps and it looks like on second image below. We are aware that the log recommends using breakpoints to find where exactly the problem is, but the thing is that we don’t know where we could do that in Xcode. We are not sure if we are missing something in Xcode or if we cannot do that when opening a project made in Godot. We tried many different builds with removed shader files, and scenes and changed different kinds of settings. We would get the same crash every time. When we made a new build, we cleared the build’s folder. Also, we occasionally deleted the .import folder of the project during development and reimported it. The problem occurred on many different iOS devices with more than 4GB of RAM. Release builds: These builds are uploaded on TestFlight. In release builds crashes wouldn’t occur like in debug builds. They would happen like totally randomly. In some testing sessions, it would happen like 10 minutes in the game, and in others in a few hours. Some testers couldn’t get the crash and altogether and we couldn’t find some repro steps to produce these crashes. In the attached files, you can find logs that we managed to collect from TestFlight. The most frequent type of the crash that we got, is following: Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Subtype: KERN_INVALID_ADDRESS Additional info: From reading Apple’s documentation Investigating memory access crashes, we got it that the problem is in “Invalid memory fetch”, but we couldn’t find how this could help us with further investigation. When we used Address Sanitizer tool and made a build, suddently the game stopped crashing in debug builds like it did before. Also we then didn't receive logs in Xcode that would hint us that something is going on. Tried to build our project in newer version of Godot, but the problem still persisted. Used software and hardware: Godot 3.5.1 macOS, Ventura, 13.5 Xcode, 15.2 iPad Air (5th generation), 17.4.1 MacBook Pro, Apple M1 If you have some clues or ideas on how to fix this problem, please write it, it would mean us a lot. Don’t hesitate to ask questions if something is unclear. Thank you very much in advance!
Posted
by fury_ivan.
Last updated
.
Post not yet marked as solved
0 Replies
25 Views
I am working on a white label product and have around 400+ white label customers with minor changes in color, assets, and strings. I am considering creating a workspace and adding all customer projects to the workspace. However, I am unsure about the limitations of Xcode workspace. How many projects can be added to an Xcode workspace?
Posted Last updated
.
Post not yet marked as solved
0 Replies
23 Views
In order to test an iPhone app I am developing on my mac on an actual device, I connected my iPhone to my mac with a wired connection and installed the app, but got an error message saying “Uneble to verify app”. I went to Settings -> General -> VPN and Device Management -> the app in question in ENTERPRISE APP -> Verify App -> Verify, but no matter how many times I tap on it, the status of the app remains “Not verified”. If anyone has a solution to this problem, we would appreciate it if you could help us.
Posted
by Kyo_jp.
Last updated
.
Post not yet marked as solved
0 Replies
29 Views
We are received the following error while uploading the application into TestFlight. **ITMS-90714: Invalid binary - The app contains one or more corrupted binaries. Please rebuild the app and resubmit. ** After sometimes we submit the same application without changing the configurations application submitted successfully into the App Store. We are using the Xcode 15.3 version.
Posted Last updated
.
Post not yet marked as solved
0 Replies
17 Views
Hi, our app has been using single size app icon for a while and today when I trying to upload a new version of our app I got an email from App Store Connect saying ITMS-90013: Corrupt Image File - The image file 'AppIcon60x60@2x.png' appears to be corrupt. We haven't touched the image for ages and these 60x60 image were generated by Xcode from the single 1024x1024 image supplied. I've tried to use a new image and still got the same error. Does anyone experienced this recently?
Posted
by YK_LS.
Last updated
.
Post not yet marked as solved
1 Replies
26 Views
Hello everyone, I have a problem in a project I am currently working on. Some background information regarding the problem is that I am creating some buttons in a foreach loop in another script that retrieve information from a server. These buttons are displayed in a grid with a width of 2 entries. The element that the buttons belong to also contain a fullScreenCover functionality, but the full screen cover functionality is only being called for the top four entries in the grid but the button works on all of the entries. Here is the partial code: Button(action:{ let _ = print("Button was clicked",self.title) isDetailPresented.toggle() let _ = print("Button was clicked",self.isDetailPresented) }) { VStack { ... } .foregroundColor(Color.black) .fullScreenCover(isPresented: $isDetailPresented, onDismiss: { //some function is being called here let _ = print("Moving on") }, content: { let _ = print("I have moved on") //a view to be opened }) I already checked that the boolean changes on all entries but I can't figure out why the content is not being displayed for the entries below the 4 top ones. Any help would be appreciated.
Posted Last updated
.
Post not yet marked as solved
0 Replies
30 Views
I'm working on some apps at the minute, with the intention of running a lot of automated UI tests. Xcode cloud looks great and has a lot of integrated features, but having to make sure I don't run too many hours so my subscription doesn't stop mid dev cycle, or getting a surprise large bill etc, are things I want to avoid. Even the cheapest paid plan for a year works out about the same cost as an M2 mac mini, which would probably be significantly faster than the cloud nodes. Github actions allow you to provide your own machines. But actions requires a lot more scripting, and so far they've been very slow to update Macos/Xcode versions (not sure how this will effect supplying own machine). My preference would be to deploy my own machine for Xcode cloud, similar to what we used to be able to do with Xcode server. I think this is currently impossible right? Is there any word that this might be an added feature in the near future?
Posted
by simonmcl.
Last updated
.
Post not yet marked as solved
0 Replies
62 Views
My project was working fine on xcode 14 for ios 16 simulators and real devices with all setup and pods, recently i updated system for xcode 15, and sicne then on build getting this error for simulator and real devices - Driver threw unknown argument: '-bvvutkjqcsvcmlfdhxkrjtgqdzeg/Build/Intermediates.noindex/' without emitting errors. i did everyting - clean ,deep clean, restart, update cocoapod, all pods update, deintegrate - install again, delete cache, delete derived data btw - this- bvvutkjqcsvcmlfdhxkrjtgqdzeg/Build/Intermediates.noindex/ is a file getting generated in derived data - and in log getting this also - error: Driver threw unknown argument: '-bvvutkjqcsvcmlfdhxkrjtgqdzeg/Build/Intermediates.noindex/' without emitting errors. (in target 'fabfinance' from project ' ') this is my pod file - # Uncomment the next line to define a global platform for your project # platform :ios, '13.0' target 'fabfinance' do # Comment the next line if you don't want to use dynamic frameworks use_frameworks! # Pods for fabfinance pod 'Alamofire' pod 'SwiftyJSON' pod 'PopupDialog' pod 'JMImageCache' #pod 'Firebase/Analytics' #pod 'Firebase/Messaging' #pod 'Firebase/Crashlytics' #pod 'Firebase/Core' #pod 'Firebase/Auth' pod 'SOTabBar' pod 'MaterialComponents' pod 'IQKeyboardManagerSwift' pod 'DropDown' pod 'DLRadioButton', '~> 1.4' pod 'ADCountryPicker', '~> 2.1.0' pod 'MDFInternationalization' pod 'SDWebImage' pod 'ProgressHUD' pod 'DatePickerDialog' pod 'PhoneNumberKit' pod 'Charts' target 'fabfinanceTests' do inherit! :search_paths # Pods for testing end target 'fabfinanceUITests' do # Pods for testing end end post_install do |installer| installer.generated_projects.each do |project| project.targets.each do |target| target.build_configurations.each do |config| config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '13.0' end end end end
Posted Last updated
.
Post not yet marked as solved
0 Replies
43 Views
Hi all, i am setting up my MacBook Pro and cant install Xcode. I downloaded it through the app store. On click it starts up and asks me what platform I would like to develop for. (The window where you have to select When continue is clicked it asks for admin permissions then quits and starts the process over again. I tried running this /Applications/Xcode.app/Contents/MacOS/Xcode -installComponents in the CMD and this opens the same window but still doesnt run but now i get an error when it closes Xcode[837:10271] [MT] IDEFirstLaunch: Cannot continue without relaunching because of already-loaded bundles: [NSBundle </Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework> (loaded)] Specs: MacBook Pro M1 Pro macOS 14.1
Posted
by Denonono.
Last updated
.
Post not yet marked as solved
1 Replies
44 Views
HI i have coded an App for Mac OSX that has embedded a Command line tool, the problem is that everything works fine while i am running from the xcode compiler, after build the final product, the app is not working properly and i can see messages like this in the console. Task .<251932> not allowed to create a new connection (existing Connection 224) Task <37752B7F-5827-4160-83C4-773B17AE72DF>.<255990> resuming, timeouts(60.0, 604800.0) QOS(0x21) Voucher (null) i was reading a link posted here but the solution is not working, some ideas are appreciated. My guess is that maybe is something related with a security setting. This is the code: NSTask *task; NSString *executableName = @"websocat"; NSString *executablePath = [[[NSBundle mainBundle] resourcePath] stringByAppendingPathComponent:executableName]; task = [[NSTask alloc] init]; [task setLaunchPath:executablePath]; Quinn “The Eskimo!" please help!
Posted Last updated
.
Post not yet marked as solved
0 Replies
41 Views
We have a workspace with three projects in it. Trying to export localizations for the workspace fails with the "ComputeTargetDependencyGraph failed with a nonzero exit code" error but with no additional information to track down the failure. Here are the exact steps I've tried: Click Menu Bar &gt; Product &gt; Export Localizations &gt; Workspace (the first item in the menu) A few moments later, an error alert pops up that says "Unable to build project for localization string extraction" In the build log tab, it shows this: If I try running xcodebuild -exportLocalizations -localizationPath ~/ExportedWorkspaceLocalizations -workspace &lt;workspaceLocation&gt; -exportLanguage en, the same "ComputeTargetDependencyGraph failed with a nonzero exit code" error message appears. Exporting the three projects individually works great when I go to Menu Bar &gt; Product &gt; Export Localizations &gt; Select one of the three projects instead of the workspace. Has anyone else run into this error? I haven't been able to find any additional build logs that would point to a more concrete error.
Posted Last updated
.
Post not yet marked as solved
4 Replies
877 Views
After uploading a new iOS build, we received an error message via email from Apple stating: "ITMS-90013: Corrupt Image File - The image file "AppIcon60x60 2x.png" appears to be corrupt." Strangely, we don't have any image file with that name in our project. It seems to be a build processing error on Apple's side. While I've seen similar issues reported for Apple TV in the past, this is happening with our iOS build. Has anyone discovered a workaround? I've uploaded another app build and haven't encountered any errors.
Posted
by Starkode.
Last updated
.
Post not yet marked as solved
1 Replies
73 Views
I can run it on the simulators, and directly on physical devices, but not on My Mac (Designed for iPad). The error is: error: attach by pid '33190' failed -- attach failed (Not allowed to attach to process. Look in the console messages (Console.app), near the debugserver entries, when the attach failed. The subsystem that denied the attach permission will likely have logged an informative message about why it was denied.) Checked the log and this is what I found: error 12:44:36.527139-0500 mdbulkimport could not make proxies from uuids in optimized path! Error Domain=NSOSStatusErrorDomain Code=-10814 "Unable to find this application extension record in the Launch Services database." UserInfo={_LSFunction=, _LSLine=679, NSDebugDescription=Unable to find this application extension record in the Launch Services database., SK=, IS=0} error 12:44:36.527174-0500 mdbulkimport Using expensive fallback path for obtaining plugin proxies from install notifications. This process should be entitled to use the LS database. default 12:44:36.529748-0500 debugserver [LaunchAttach] (32518) about to task_for_pid(32517) default 12:44:36.529778-0500 kernel macOSTaskPolicy: (com.apple.debugserver) may not get the task control port of (Piano Motifs) (pid: 32517): (Piano Motifs) is hardened, (Piano Motifs) doesn't have get-task-allow, (com.apple.debugserver) is a declared debugger(com.apple.debugserver) is not a declared read-only debugger error 12:44:36.529795-0500 debugserver error: [LaunchAttach] MachTask::TaskPortForProcessID task_for_pid(32517) failed: ::task_for_pid ( target_tport = 0x0203, pid = 32517, &task ) => err = 0x00000005 ((os/kern) failure) So the issue seems to be not finding the application's extension record in the Launch Services database. How is this problem solved?
Posted
by fermor.
Last updated
.
Post not yet marked as solved
0 Replies
51 Views
I am converting a large core data app to SwiftData and have hit a problem I can't fix, namely code generated by a Model crashing. Here is the model showing the failing expansion. Here is the model containing the inverse for the failing attribute: /Users/writingshedprod/Desktop/Screenshot 2024-05-08 at 20.21.51.png And here is the mass of core data output generated when the app launches. If anyone can make sense of this I'd be grateful. This is where the problem might lie. Debugger.txt
Posted Last updated
.
Post marked as solved
1 Replies
58 Views
We have a server with mac and Xcode which generates apps for IOS signing them with release provisioning profile and sign identities. It does by command line It worked perfectly until we upgraded from Xcode 14 to Xcode 15.2 This is the command that we execute to generate the Xarchive, and it is failing, not generating anything and giving error: xcodebuild -workspace Project.xcworkspace -scheme "Release Ads" -xcconfig Project/Custom.xcconfig PROVISIONING_PROFILE_SPECIFIER=realidentifier CODE_SIGN_IDENTITY=realsignidentity CODE_SIGN_ENTITLEMENTS=/Users/user/project/Project/Project.entitlements archive This is the content of Custom.xcconfig file: OTHER_SWIFT_FLAGS = -Onone -DCOCOAPODS -DRELEASE -DADS -DFIREBASE -DPUSH This is the content of Project.entitlements file: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>aps-environment</key> <string>production</string> <key>application-identifier</key> <string>$(AppIdentifierPrefix)$(CFBundleIdentifier)</string> <key>beta-reports-active</key> <true/> </dict> </plist> I can see this on the error log of the console: 2024-05-08 18:38:55.527 --- xcodebuild: WARNING: Using the first of multiple matching destinations: 2024-05-08 18:38:55.527 { platform:macOS, arch:arm64, variant:Designed for [iPad,iPhone], id:00008103-001904CE1EC3001E } 2024-05-08 18:38:55.527 { platform:iOS, id:dvtdevice-DVTiPhonePlaceholder-iphoneos:placeholder, name:Any iOS Device } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:dvtdevice-DVTiOSDeviceSimulatorPlaceholder-iphonesimulator:placeholder, name:Any iOS Simulator Device } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:588FF55F-AFE3-4201-883D-AA074825765E, OS:17.2, name:iPad (10th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:588FF55F-AFE3-4201-883D-AA074825765E, OS:17.2, name:iPad (10th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:E7D3BE01-626C-4448-AD07-9B72E8D59778, OS:17.2, name:iPad Air (5th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:E7D3BE01-626C-4448-AD07-9B72E8D59778, OS:17.2, name:iPad Air (5th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:CE0E7741-9872-4903-95D3-DA86730D8D91, OS:17.2, name:iPad Pro (11-inch) (4th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:CE0E7741-9872-4903-95D3-DA86730D8D91, OS:17.2, name:iPad Pro (11-inch) (4th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:23DEF9D6-7B62-4829-A2F0-9C4356F7CB22, OS:17.2, name:iPad Pro (12.9-inch) (6th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:23DEF9D6-7B62-4829-A2F0-9C4356F7CB22, OS:17.2, name:iPad Pro (12.9-inch) (6th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:00F68979-CC31-4FDA-BD44-6AE3E41EEC3A, OS:17.2, name:iPad mini (6th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:00F68979-CC31-4FDA-BD44-6AE3E41EEC3A, OS:17.2, name:iPad mini (6th generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:5396905C-A343-4D94-95DD-23FE0ADDDCEB, OS:17.2, name:iPhone 15 } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:5396905C-A343-4D94-95DD-23FE0ADDDCEB, OS:17.2, name:iPhone 15 } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:F713CFB0-8617-424D-BE03-51B506931BFD, OS:17.2, name:iPhone 15 Plus } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:F713CFB0-8617-424D-BE03-51B506931BFD, OS:17.2, name:iPhone 15 Plus } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:594E330B-252D-4728-955C-B508E70AD20A, OS:17.2, name:iPhone 15 Pro } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:594E330B-252D-4728-955C-B508E70AD20A, OS:17.2, name:iPhone 15 Pro } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:B7551687-D9C6-46E9-BA26-D0CC70AC134D, OS:17.2, name:iPhone 15 Pro Max } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:B7551687-D9C6-46E9-BA26-D0CC70AC134D, OS:17.2, name:iPhone 15 Pro Max } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:E5D6C1EA-81B1-49D5-BF55-673258AE1227, OS:17.2, name:iPhone SE (3rd generation) } 2024-05-08 18:38:55.527 { platform:iOS Simulator, id:E5D6C1EA-81B1-49D5-BF55-673258AE1227, OS:17.2, name:iPhone SE (3rd generation) } 2024-05-08 18:39:24.105 ** ARCHIVE FAILED ** 2024-05-08 18:39:24.105 2024-05-08 18:39:24.105 2024-05-08 18:39:24.105 The following build commands failed: 2024-05-08 18:39:24.105 PhaseScriptExecution [CP]\ Embed\ Pods\ Frameworks /Users/user/Library/Developer/Xcode/DerivedData/Project-bdyzwdcujggpnmedzctlookvtuwv/Build/Intermediates.noindex/ArchiveIntermediates/Release/IntermediateBuildFilesPath/Project.build/Release-iphoneos/Project.build/Script-FEF05C244C47CB5438EC384B.sh (in target 'Project' from project 'Project')
Posted
by abouza.
Last updated
.
Post not yet marked as solved
0 Replies
55 Views
When I build my product for the simulator or for direct install from Xcode to my device, all works fine. When I archive>distribute, the app is missing modules when it starts. "Runtime error module 'network' not found:resource (network.lu) does not exist in archive... And then a list of al the places it looked. Xcode 15.3 Solar2d 2024.3706 (latest) Macbook Pro M3 Sonoma 14.4.1 Programming in Lua on Solar2d "native" (includes Objective-C and Swift code) I have had a related (I think) problem with the simulator and device builds missing other modules (all includes) -- but only after working fine for maybe a dozen builds. I then explicitly add them in, one by one. There is no way I can manually add in network, because it is built into the Solar2d environment. I am pretty sure this is an Xcode bug, not a Solar2d bug. But also likely I have a setting wrong.
Posted Last updated
.
Post not yet marked as solved
3 Replies
1.5k Views
Since the macOS 14.4 and Xcode 15.3 update, I'm getting these message posted in the Xcode log when I run a Mac app, even for template apps. BOOL _NSPersistentUIDeleteItemAtFileURL(NSURL *const __strong) Failed to stat item: file:///Users/***/Library/Containers/***/Data/Library/Saved%20Application%20State/***.savedState/restorecount.plist I've already reported this to Apple. I just wanted to know if I was the only one affected (it happens on all my development Macs).
Posted
by jeanlain.
Last updated
.