Posts under Developer Tools & Services topic

Post

Replies

Boosts

Views

Activity

Xcode Cloud build phase has massively slowed down
Hi, recently something happened in Xcode Cloud, and the build times increased massively. In our CI workflow we run test, and one of the phases executes xcodebuild build-for-testing: the duration of this phase moved from about 8 minutes to about 36 minutes, without any major changes on our side. We observed this: in different apps; even when running a build on a old tag. All other phases don't seem affected, it's just the xcodebuild build-for-testing phase. I'm attaching 2 screenshots of the logs from AppStoreConnect that show the duration of each phase, where build 7600 is older and 7700 is more recent (but was run on a tag from a few weeks ago, to exclude issues related with the code base itself). We had not other option than to disable the CI checks for PRs, because they would take too long, and use up too much of Xcode Cloud time. What's happening? Thanks
13
12
2.9k
May ’24
Tips on writing forums posts
Thanks so much for contributing to Apple Developer Forums. We'd love to help you get an answer, but we need a little bit more information from you first. Here's some tips on what to add to your post in order to help us help you. Provide context to your post Did you provide enough context of when and how this issue is occurring? Things like platform and Xcode version and language can go a long way. Posting items like the version can also help you to remember to test on the latest software. If it's a bug that you're noticing, it may have been fixed in a recent update. Avoid stating that you're using the "current version" since these change quickly. Example to improve on: Current iOS, Swift Better example: iOS 17.5, Swift (UIKit) Best example: iOS 12 - iOS 17.5, Swift (UIKit), Xcode 15.4 Specific questions to answer: What platform are you targeting? And what version of that platform? What version of Xcode are you using? What version of the OS are you testing on? Add test code Check that it's as easy as possible for someone to reproduce your issue. If you've asked a question along the lines of: "Why isn't ##INSERT_ACTION_HERE## working?", test code can go a long way. If you're posting a link to a project, be sure that it's a newly created project created from one of Xcode's templates that's stripped down to the bare minimum amount of code and files needed to reproduce the issue. Remove any third-party dependencies to focus your project completely on Apple's APIs. See Creating a Test Project for more details. If you're posting a code snippet, make sure you've posted enough context so that someone helping you can copy the code into their own project without having to read between the lines on the rest of your project. Also, make use of the Code Block button, which inserts triple backquote delimiters, for code snippets or logs. Example of code block formatting. Give a thorough description Don't forget to add a detailed description to your post. If you only posted code, or have a minimal description, please add some details to describe your issue and, if applicable, steps needed to reproduce it and what you've tried. Specific questions to answer: What specific API are you using? What are the exact steps you took? If nothing failed, what results did you see? And what were you expecting? If you filed a bug, what was the bug number? What else have you tried? Describe any errors If you're seeing an error message, post the exact wording or a screenshot. If it results in a crash, attach the crash logs to your post. Specific questions to answer: If something failed, what are the symptoms of that failure? If an API returned an error, what was that error? Re-read the post Come back to your post as if you'd never seen it before. Pretend you're going to answer it and think about what it may be missing, even if it wasn't mentioned in the above list. Any of this information, the more the better, is helpful to someone reading your post for the first time. A detailed description goes a long way in getting more detailed answers. These tips should result in some more helpful answers from us and the developer community! Revision History 2024-05-29 Initial version.
0
0
1.1k
May ’24
Swift Assist
Hi, I'm testing out Xcode 16 beta and I have a couple of questions: Is Swift Assist only available on Sequoia? I see that predictive code completion is per https://www.apple.com/newsroom/2024/06/apple-empowers-developers-and-fuels-innovation-with-new-tools-and-resources/, but I tried the beta on Sonoma and I'm not seeing it Regarding Swift Assist - I understand that code is only used to process requests and never stored on servers, and Apple will not use it to train machine learning models. However, my company's security team may still decide that using Swift Assist is too much of a risk. How can we disable it across multiple developer machines? Thank you!
11
4
13k
Jun ’24
Xcode 16 Beta not recognizing Apple Vision Pro on devices
I downloaded the new Xcode 16 Beta and AVP OS 2.0, But I saw that in Windows --> Devices + Simulators, my Mac was not recognizing that I had updated the Vision Pro's OS. So, I disconnected the AVP and tried connecting it again, but the device is not showing up. I've tried going into Remote Devices within the headset, disabling/enabling Developer Mode, turning off/on Wifi, restarting both devices. Is this an issue with XCode 16 Beta and/or Vision OS 2.0?
8
2
1.4k
Jun ’24
Predictive Code Completion Model - failed to find asset
The operation couldn’t be completed. (ModelCatalog.CatalogErrors.AssetErrors error 1.) Domain: ModelCatalog.CatalogErrors.AssetErrors Code: 1 User Info: { DVTErrorCreationDateKey = "2024-06-11 11:01:58 +0000"; } Failed to find asset: com.apple.gm.safety_deny.input.code_intelligence.base - no asset Domain: ModelCatalog.CatalogErrors.AssetErrors Code: 1 System Information macOS Version 15.0 (Build 24A5264n) Xcode 16.0 (23037.4) (Build 16A5171c) Timestamp: 2024-06-11T14:01:58+03:00
26
24
4.7k
Jun ’24
WWDC24 - Xcode 16 + macOS 15 Beta 1 - Unable to Download Predictive Code Completion Model
Hi Excited to try out the new Xcode Swift code completion ML tools demo'd yesterday at the SOTU. I am running macOS 14.5, using a VM Via Virtualization Framework ( UTM.app) to run macOS 15 Beta 1. Ive installed XCode 16 Beta 1 in my Host OS (macOS 14.5) and was able to successfully install, boot, and set up macOS 15 as a VM client. Ive installed Xcode 16 in my VM Client, and upon launch, was asked to download the Predictive Text model. I see this error: The operation couldn’t be completed. (ModelCatalog.CatalogErrors.AssetErrors error 1.) Domain: ModelCatalog.CatalogErrors.AssetErrors Code: 1 User Info: { DVTErrorCreationDateKey = "2024-06-11 20:11:32 +0000"; } -- Failed to find asset: com.apple.fm.code.generate_small_v1.tokenizer - no asset Domain: ModelCatalog.CatalogErrors.AssetErrors Code: 1 -- System Information macOS Version 15.0 (Build 24A5264n) Xcode 16.0 (23037.4) (Build 16A5171c) Timestamp: 2024-06-11T13:11:32-07:00
10
5
4.2k
Jun ’24
Xcode no longer supports temporarily using a local SwiftPM package?
One practice that I use a lot is to drag and drop a SwiftPM package into my project when I want to make local edits - this replaces the remote dependency with a local dependency. Then I can edit and make changes to the dependency. When I am done, I remove that directory and Xcode would revert back to the remote package. In Xcode 16 this feature does not seem to work anymore, and instead it offers to copy the files into the project.
6
1
1.2k
Jun ’24
Xcode seems not compatible with the ssh key RSA-SHA2 while trying to git clone from Azure
Since a few days, I'm trying to fetch our private SPM repo hosted on Azure via Xcode but without success. Actually they now accept only ssh key RSA-SHA2-256 or RSA-SHA2-512. So I created a new SSH key, but it seems the problem persists when I try to fetch spm repo or git clone via xcode: "You’re using ssh-rsa that is about to be deprecated and your request has been blocked intentionally. Any SSH session using SSH-RSA is subject to brown out (failure during random time periods). Please use rsa-sha2-256 or rsa-sha2-512 instead. For more details see aka.ms/ado-ssh-rsa-deprecation. remote: ERROR_SSH_UNSUPPORTED_CIPHER (7) (-20)" Even so I'm choosing the good new ssh key, it seems Xcode is sending wrong information about the new generated ssh key. Anyone is experiencing the same here?
10
4
901
Jun ’24
Package.resolved modified unexpectedly when switching git branches outside of Xcode
We've recently increased our use of SPM in our iOS app's Xcode project. However, we've noticed that if the Xcode project is open when we switch to a different git branch using another tool (e.g. git on the command line or in a 3rd-party GUI), the Package.resolved file is modified unexpectedly. We've received some conflicting advice about the purpose and appropriate treatment of the Package.resolved file. Some say to add it to .gitignore. On the other hand, the docs say: …be sure to commit your project’s Package.resolved file to your Git repository. This ensures a reliable CI workflow that always uses the expected version of a package dependency. For now, our workaround is to use Xcode to switch git branches, but this seems like an unusual limitation. We're on Xcode 15.3/15.4. There is discussion on the Swift Forums of potentially related problems: https://forums.swift.org/t/xcode-automatically-updating-package-resolved/41900
5
0
1.9k
Jun ’24
MacOs 16 - Xcode 16 beta - XCBBuildService quit unexpectedly
Translated Report (Full Report Below) Process: XCBBuildService [19515] Path: /Applications/Xcode.app/Contents/SharedFrameworks/XCBuild.framework/Versions/A/PlugIns/XCBBuildService.bundle/Contents/MacOS/XCBBuildService Identifier: com.apple.dt.XCBBuildService Version: 16.0 (23000.0.209.4) Build Info: XCBuild-23000000209004000~20 (16A5171c) Code Type: ARM-64 (Native) Parent Process: Xcode [1187] Responsible: Xcode [1187] User ID: 501 Date/Time: 2024-06-13 18:52:42.9964 -0300 OS Version: macOS 15.0 (24A5264n) Report Version: 12 Anonymous UUID: E79CA726-937A-A4A4-9B42-9DF9455F3181 Time Awake Since Boot: 1300 seconds System Integrity Protection: enabled Crashed Thread: 15 Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000 Termination Reason: Namespace SIGNAL, Code 6 Abort trap: 6 Terminating Process: XCBBuildService [19515] Application Specific Information: abort() called Kernel Triage: VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter VM - (arg = 0x3) mach_vm_allocate_kernel failed within call to vm_map_enter Thread 0:: Dispatch queue: com.apple.main-thread 0 libsystem_kernel.dylib 0x19c7ece14 mach_msg2_trap + 8 1 libsystem_kernel.dylib 0x19c7ff5b0 mach_msg2_internal + 80 2 libsystem_kernel.dylib 0x19c7f59b8 mach_msg_overwrite + 480 3 libsystem_kernel.dylib 0x19c7ed15c mach_msg + 24 4 CoreFoundation 0x19c916b40 __CFRunLoopServiceMachPort + 160 5 CoreFoundation 0x19c9153f8 __CFRunLoopRun + 1228 6 CoreFoundation 0x19c9148bc CFRunLoopRunSpecific + 608 7 CoreFoundation 0x19c98f6a0 CFRunLoopRun + 64 8 libswift_Concurrency.dylib 0x273f30e50 swift_task_asyncMainDrainQueueImpl() + 40 9 libswift_Concurrency.dylib 0x273f30e10 swift_task_asyncMainDrainQueue + 92 10 XCBBuildService 0x1021eb924 main + 84 11 dyld 0x19c4ad298 start + 2876 Thread 1: 0 libsystem_kernel.dylib 0x19c7ed990 read + 8 1 XCBServiceCore 0x102604e88 closure #3 in ServiceHostConnection.resume() + 552 2 XCBServiceCore 0x1026063c1 partial apply for specialized thunk for @escaping @callee_guaranteed @Sendable @async () -> (@out A) + 1 3 XCBServiceCore 0x10260692d partial apply for closure #1 in closure #1 in OS_dispatch_queue.async(group:qos:flags:execute:) + 1 4 XCBServiceCore 0x10260692d partial apply for closure #1 in closure #1 in OS_dispatch_queue.async(group:qos:flags:execute:) + 1 5 XCBServiceCore 0x1026061d1 specialized thunk for @escaping @callee_guaranteed @Sendable @async () -> (@out A) + 1 6 XCBServiceCore 0x1026063c1 partial apply for specialized thunk for @escaping @callee_guaranteed @Sendable @async () -> (@out A) + 1 7 libswift_Concurrency.dylib 0x273f31921 completeTaskWithClosure(swift::AsyncContext*, swift::SwiftError*) + 1 Thread 2:: llb_buildsystem_build 0 libsystem_kernel.dylib 0x19c7f05ac __psynch_cvwait + 8 1 libsystem_pthread.dylib 0x19c82e894 pthread_cond_wait + 1204 2 libc++.1.dylib 0x19c764578 std::__1::condition_variable::wait(std::__1::unique_lockstd::__1::mutex&) + 28 3 llbuild 0x1032f3308 (anonymous namespace)::BuildEngineImpl::executeTasks(llbuild::core::KeyType const&) + 4552 4 llbuild 0x1032f038c llbuild::core::BuildEngine::build(llbuild::core::KeyType const&) + 580 5 llbuild 0x103309ac4 (anonymous namespace)::BuildSystemImpl::build(llbuild::buildsystem::BuildKey) + 208 6 llbuild 0x103309ca0 llbuild::buildsystem::BuildSystem::build(llvm::StringRef) + 260 7 llbuild 0x1032fc3f0 llbuild::buildsystem::BuildSystemFrontend::build(llvm::StringRef) + 56 8 llbuild 0x1032833a8 0x103268000 + 111528 9 XCBBuildSystem 0x10275b640 partial apply for closure #13 in BuildOperation.build() + 28 10 libswift_Concurrency.dylib 0x273efc564 TaskLocal.withValue(:operation:file:line:) + 368 11 XCBUtil 0x10225d92c closure #1 in closure #1 in static Task<>.detachNewThread(name:_:) + 324 12 XCBUtil 0x102230064 thunk for @escaping @callee_guaranteed () -> () + 28 13 Foundation 0x19e3a1de0 NSThread__block_start + 76 14 libsystem_pthread.dylib 0x19c82e2e4 _pthread_start + 136 15 libsystem_pthread.dylib 0x19c8290fc thread_start + 8
7
3
2.5k
Jun ’24
Running application on 17.4 Simulator from Xcode 16.0 beta is crashing due to missing SwiftUICore.framework
Hi, I have a project that is pretty complex and includes mostly UIKit/Swift code with some SwiftUI added on top. I also have some SPM modules and internal Cocoapods libraries linking in. The project builds fine with the latest release version of Xcode (15) and runs on 17.4 simulator. WIth Xcode 16.0 Beta however, the project builds and runs fine on iOS 18 simulators, however there is a specific crash that happens at startup on iOS 17.4 simulators. Please see crash log below with the name of my application redacted: dyld[91294]: Library not loaded: /System/Library/Frameworks/SwiftUICore.framework/SwiftUICore Referenced from: <14C085D7-ECA8-3287-8038-5DE320ADCEBD> /Users/xxxxxx/Library/Developer/CoreSimulator/Devices/C23AA8A9-8475-4EE2-86B3-136A0EBCC362/data/Containers/Bundle/Application/95A49FCF-A7E3-4A8B-93F1-C4CDDBA74B60/xxxxxx.app/Frameworks/SwiftUI_Common.framework/SwiftUI_Common Reason: tried: '/Users/xxxxxx/Library/Developer/Xcode/DerivedData/xxxxxx-fglltpkbphqqjzgdgdadysinonmq/Build/Products/Debug-iphonesimulator/SwiftUICore.framework/SwiftUICore' (no such file), '/Users/xxxxxx/Library/Developer/Xcode/DerivedData/xxxxxx-fglltpkbphqqjzgdgdadysinonmq/Build/Products/Debug-iphonesimulator/PackageFrameworks/SwiftUICore.framework/SwiftUICore' (no such file), '/Library/Developer/CoreSimulator/Volumes/iOS_21E213/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 17.4.simruntime/Contents/Resources/RuntimeRoot/System/Library/Frameworks/SwiftUICore.framework/SwiftUICore' (no such file), '/System/Library/Frameworks/SwiftUICore.framework/SwiftUICore' (no such file, not in dyld cache), '/Library/Developer/CoreSimulator/Volumes/iOS_21E213/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 17.4.simruntime/Contents/Resources/RuntimeRoot/System/Library/Frameworks/SwiftUICore.framework/SwiftUICore' (no such file) It seems like for some reason Xcode is building the app thinking there would be a SwiftUICore.framework on device, but since this framework is new in iOS 18 and does not exist on iOS 17.4, the system is unable to find it and crashes. I have the min deployment target set to iOS 14.5, so I'm not sure why Xcode would make the assumption that SwiftUICore.framework will be available for linking on runtime. Interestingly, I cannot reproduce this same issue on a clean project created using Xcode 16 and targeting min deployment of iOS 15. I was wondering if anyone has any suggestions regarding specific build settings to check and see where the issue might be coming from. Thanks
7
14
5.2k
Jun ’24
Xcode crash when start
I reinstall macOS system to monterey and restore from a higher version (sonoma), the xcode (version 15.4 on sonoma) can not run, so I delete it and reinstall xcode 14.2, but it always crash when start. here is the error log when I start it in Terminal: command: /Applications/Xcode.app/Contents/MacOS/Xcode error log: Error loading required libraries. If there is an ongoing installation please wait for it to complete. Otherwise reinstall. (dlopen(@rpath/libIDEApplicationLoader.dylib, 0x0001): Symbol not found: (_$s10Foundation10CocoaErrorV13userCancelledAC4CodeVvgZ) Referenced from: '/Library/Developer/PrivateFrameworks/CoreDevice.framework/Versions/A/CoreDevice' Expected in: '/System/Library/Frameworks/Foundation.framework/Versions/C/Foundation') [1] 80496 abort /Applications/Xcode.app/Contents/MacOS/Xcode
2
1
1.2k
Jun ’24
Xcode Cloud Export archive for development distribution fails every time.
Log shows: Run command: 'xcodebuild -exportArchive -archivePath /Volumes/workspace/tmp/d3c9c43f-e24e-4ad9-882d-d0179ab3149b.xcarchive -exportPath /Volumes/workspace/developmentexport -exportOptionsPlist /Volumes/workspace/ci/development-exportoptions.plist '-DVTPortalRequest.Endpoint=http://172.16.182.66:8089' -DVTProvisioningIsManaged=YES -IDEDistributionLogDirectory=/Volumes/workspace/tmp/development-export-archive-logs -DVTSkipCertificateValidityCheck=YES -DVTServicesLogLevel=3' Command exited with non-zero exit-code: 70
2
2
815
Jun ’24
Gaps in Xcode build timeline
Reposting (after a while) from the Swift forums - the build timeline for our project has a lot of weird gaps in the beginning - almost 15 seconds in total, which is quite a big chunk of the total build time. Is there any way to determine why they exist or how I could fix them? I hope it's just something hidden and not the build system literally doing nothing... This is on Xcode 15.4.
1
0
407
Jun ’24
No Apple plug-in library path found
Hey! I'm facing a problem I have 0 idea how to solve it. I'm building a project with Unity 2022.3.21 for visionOS and after a lot of exhausting problems I'm having the last one, I am kinda new to Xcode. I get the error "No Apple plug-in library path found", at the root of the project there Xcode should find the ApplePluginLibraries folder, and it's actually there with two folders inside Apple.Core and Apple.GameKit. Xcode is saying the path was not found and I can see it exists through finder. In Search Paths > Framework Search Paths I have: $(PROJECT_DIR)/ApplePluginLibraries/Apple.GameKit $(PROJECT_DIR)/ApplePluginLibraries/Apple.Core Also in Other Linker Flags I have: -L$(PROJECT_DIR)/ApplePluginLibraries/Apple.GameKit -L$(PROJECT_DIR)/ApplePluginLibraries/Apple.Core I was having a few errors and the last one is: Command PhaseScriptExecution failed with a nonzero exit code, and the description says about the path not found. My info: MacOS: Apple M1 Pro Sonoma 14.5 Xcode: 15.4 Unity: 2022.3.21f1 Any idea? Thanks!!
7
4
1.2k
Jun ’24