On iOS 18, when XCUITest encounters an "Application has not loaded accessibility" error after the 60 second timeout, it performs an undocumented auto-recovery ("Setting up automation session") instead of halting the test as documented. This leaves the XCUITest framework in a corrupted state, causing subsequent tests in the same session to fail with unexpected behavior.
Expected Behavior (per Apple documentation):
Any failure in the launch sequence will be reported as a test failure and the test will be halted at that point.
Actual Behavior:
XCUITest waits 60 seconds for accessibility to load
Logs "Application has not loaded accessibility" error
Instead of halting, performs "Setting up automation session" (auto-recovery)
Test continues with corrupted framework state
Subsequent tests in the same session fail with phantom element queries
Steps
Run XCUITest suite on a real iOS 18 device
Have an app with moderately heavy initialization (e.g., synchronous network operations during bootstrap)
Observe intermittent "accessibility not loaded" errors
When error occurs, subsequent tests fail with unexpected behavior
Test Logs Evidence
First test (accessibility failure + recovery):
t = 11.11s Wait for accessibility to load
t = 71.14s Capturing diagnostic spindump
t = 76.24s Assertion Failure: Application 'com.example.app' has not loaded accessibility
t = 76.26s Setting up automation session ← Undocumented recovery
t = 77.29s Tear Down
Second test (corrupted state):
t = 35.01s Tap "signin-button"
t = 35.55s Waiting for "bannerButtonStackFirstItem" ← Query NOT in test code!
t = 40.58s Assertion Failure: Failed to find element
The second test executes element queries that do not exist in its source code, indicating leaked/corrupted state from the previous test's failed recovery.
Note: The tearDown() method terminates the app but cannot reset the internal state of the XCUITest framework itself, so corruption persists across tests.
We are observing this behavior consistently on iOS 18 real devices. We would like to know:
Is this a known issue with XCUITest on iOS 18?
Is anyone experiencing similar "accessibility not loaded" failures followed by auto-recovery?
Is the "Setting up automation session" recovery behavior intentional or a bug?
Is there a recommended workaround to prevent framework state corruption between tests?
General
RSS for tagDive into the vast array of tools and services available to developers.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
Hello, I’ve attempted to enroll to the Apple developer program on January 5th where after I submitted my credit card info for payment I received an acknowledgment email
In the email it says it’ll take up to 48 hours to process the payment
it has been more than 2 weeks now and I received no response or activation email from apple
throughout these 2 weeks I have attempted additional times to pay and contact support but even when sending a support ticket (which claims response in 2 business days) I didn’t get any response whatsoever
am I doing something wrong? Is this common?
please help 🙏🏻
thank you!
Topic:
Developer Tools & Services
SubTopic:
General
审核团队到底在干什么???开发者发帖,论坛删帖??掩耳盗铃???
Topic:
Developer Tools & Services
SubTopic:
General
Calling dlopen then dlclose causes an increase in the amount of memory used by the program. If I create a loop that calls dlopen / dlclose repeatedly on the same dynamic library, memory usage increases continuously. Is this a bug, or am I using dlopen / dlclose incorrectly?
I can reproduce this by modifying the sample code in the Apple Developer docs Creating Dynamic Libraries. If I modify Runtime.c, changing the line void *lib_handle = dlopen(lib_name, RTLD_NOW); to add the infinite loop, as below:
void *lib_handle = dlopen(lib_name, RTLD_NOW);
for (int ii = 0; ; ++ii) {
printf("loop %i\n", ii);
int close_err = dlclose(lib_handle);
printf("close error: %i\n", close_err);
printf("dlopen(%s, RTLD_NOW)\n", lib_name);
lib_handle = dlopen(lib_name, RTLD_NOW);
}
then opening and closing the dynamic library will succeed, but memory usage (as reported by top) will rapidly increase.
I'm running on x86_64 macOS 13.6.6. Full code for the modified Runtime.c is attached, the rest of the code is available in the Apple Developer docs.
Any suggestions?
Many thanks,
Chris
Runtime.c
I used to develop iPhone apps about a decade ago and am now back at it with an iPhone and companion Apple Watch app.
Why does it suck so bad? I a must be doing something wrong, but what I am doing is out of the box. The majority of the time when I go to build on the watch I get:
Previous preparation error: A connection to this device could not be established.; Timed out while attempting to establish tunnel using negotiated network parameters.
Which I then first try to force quit the app on the watch and if that does not work, reboot the watch (which is pretty ridiculous).
I tried Gemini and it gave me the following explanation:
This is arguably the single most frustrating error in the entire watchOS development ecosystem. As an expert, I can tell you that you are not doing anything wrong; you are fighting a fragile architecture.
Here is the technical breakdown of why this happens and a workflow to mitigate it without constant reboots.
The Technical "Why"
This error message reveals that the issue lies in the CoreDevice (and formerly usbmuxd) infrastructure, specifically in the secure transport layer.
The "Tunnel" Failure: Xcode attempts to establish a secure, encrypted tunnel (DTXConnection) to the Apple Watch to push the debugger and the app binary. Unlike the iPhone, which can sustain a high-bandwidth connection easily, the Watch aggressively manages its radios (Bluetooth vs. WiFi vs. AWDL) to save battery.
The "Handshake" Timeout: If the Watch is on Bluetooth (Low Energy) when Xcode initiates the tunnel, the bandwidth is insufficient. The system tries to escalate the connection to WiFi (or Apple Wireless Direct Link). If this negotiation takes even a few milliseconds too long—due to 2.4GHz interference, router mDNS configuration, or the Watch CPU being throttled—the handshake times out.
The "Previous Preparation Error": This is the insidious part. Once the handshake fails once, Xcode’s device service caches that failure state for the device UUID. It marks the device as "unreachable" to prevent the IDE from hanging indefinitely on subsequent tries.
Why you see it constantly: You aren't actually triggering a new connection attempt; you are hitting the cached "failed" state immediately.
Unfortunately, the solutions it gives me are:
The "Wired Proxy" Method (Most Reliable)
This is the gold standard for watchOS debugging. Do not rely on "Connect via Network" for the Watch directly if you can avoid it.
Disable WiFi on your Mac (temporarily) or ensure the Mac and iPhone are on the exact same SSID.
Plug your iPhone into the Mac via USB.
Ensure the Watch is paired to that iPhone.
Result: Xcode will tunnel the instructions through the USB connection to the Phone, and the Phone acts as a high-bandwidth proxy to the Watch. This eliminates the "Mac-to-Watch" WiFi negotiation failure point.
Do you hit this regularly? What do you do to make for a smooth development and deployment process? Or is it really this fragile?
Thanks for any help!
Bryan
Hi there! I am not a coder, but I built an app in ADALO just for in-house use in my company, PetroImaging. The app looked the way I wanted it to in the preview mode in ADALO, but when my app was approved and ready for download in the app store, a lot of content was missing. Many buttons that linked to screens were just gone - even though they were there in the preview and the buttons are formatted correctly in adalo. How can I get my content that I need back on my app so the employees can being using it?
Topic:
Developer Tools & Services
SubTopic:
General
I have an MAUI based application build and ready for the distribution. The application is working perfectly in the debug environment on the simulator. So the app logic is working correctly as expected without any errors.
But when a release build is created the application crashes on the simulator and physical device.
I'm developing the application using .Net 10 framework with target device iOS 26. The Supported OS Platform is set to 15.0 in csproj file. Also have the entitlements. plist file set in the csproj. The IDe used is Visual Studio Code for Mac (MAC OS). The application uses MSAL for the login / authentication purpose (Microsoft.Identity.Client) and SQLite Database (Sqlite-net-pcl)
Message:
Kindly guide me to build the application correctly in release version and get the ipa file ready for the in house distribution that could be deployed correctly on the physical device with iOS 18 / 26.
Topic:
Developer Tools & Services
SubTopic:
General
This is from an Xcode generated file.
var values: [String] = []
let exp = Expectation()
let c = pub.filter { $0 != nil }.map { $0! }.sink(
The second line gives an error: "'Expectation' cannot be constructed because it has no accessible initializers". My best guess that Expectation objects come from some other Apple Swift Testing function, but I don't know where.
I've suddenly started seeing hundreds of the same block of four error messages (see attached image) when running my app on my iOS device through Xcode. I've tried Cleaning the Build folder, but I keep seeing these messages in the console but can't find anything about them.
Phone is running iOS 26.1. Xcode is at 16.4. Mac is on Sequoia 15.5. The app is primarily a MapKit SwiftUI based application.
Messages below:
Connection error: Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service named com.apple.PerfPowerTelemetryClientRegistrationService was invalidated: Connection init failed at lookup with error 159 - Sandbox restriction." UserInfo={NSDebugDescription=The connection to service named com.apple.PerfPowerTelemetryClientRegistrationService was invalidated: Connection init failed at lookup with error 159 - Sandbox restriction.}
(+[PPSClientDonation isRegisteredSubsystem:category:]) Permission denied: Maps / SpringfieldUsage
(+[PPSClientDonation sendEventWithIdentifier:payload:]) Invalid inputs: payload={
isSPR = 0;
}
CAMetalLayer ignoring invalid setDrawableSize width=0.000000 height=0.000000
I'm also seeing the following error messages:
CoreUI: CUIThemeStore: No theme registered with id=0
I am using macOS’s /bin/date command, both in Terminal and via AppleScript (do shell script). I noticed inconsistent behaviour with the %N format specifier for nanoseconds:
• On some Macs, date +%s%N returns numeric nanoseconds as expected.
• On other Macs, the same command returns a literal N or fails when coerced to a number.
• This occurs across different macOS versions and on both Intel and Apple Silicon machines.
My understanding is that macOS ships BSD date, which does not officially document %N. I am trying to determine:
1. Is %N in /bin/date officially supported on macOS, and if so, on which versions?
2. If %N is not supported, what is Apple’s recommended, portable method for obtaining sub-second or millisecond timestamps in shell scripts or AppleScript across all macOS versions?
I am located in Taiwan and recently updated my Mac to the latest OS and installed the newest Xcode. However, I’m experiencing extremely slow download speeds when trying to add the iOS 26.2 Simulator Runtime (approx. 8GB) via Xcode > Settings > Platforms.
It is currently downloading at a rate of only 500MB per hour, which is impractical. I have checked the official downloads page but couldn't find a standalone DMG link for this specific version.
My questions are:
Is there a direct download link (DMG) available on the Apple Developer portal for the iOS 26.2 Simulator?
If no direct link exists, are there any recommended methods to accelerate the download? (e.g., using terminal commands or changing DNS settings).
Any help or direct URLs would be greatly appreciated. Thank you!
I am developing CarPlay addition on our app. Which is distributed with the Enterprise In distribution method, so we do not have a product in the App Store. I am wondering if CarPlay support can be provided in applications distributed with the Enterprise in distribution method?
If this is not possible, I will inform management that this is not possible.
I am waiting for your answers, thanks.
Topic:
Developer Tools & Services
SubTopic:
General
Tags:
Enterprise
Entitlements
CarPlay
wwdc2022-10016
Background Assets can support a maximum of 200G. Will the Apple server perform file comparison? For example, file0 is included in both a.aar file and b.aar file. On the Apple server, does it occupy twice the size of a single file?
Hello,
"This issue is blocking App store approval"
I have tried pushing my application to Appstore. However it has been rejected on the following ground:
_"As we discussed, the app uses or references the following non-public or deprecated APIs:
Frameworks/CommonLibrary.framework/CommonLibrary
Symbols:
• _SecCertificateIsValid
The use of non-public or deprecated APIs is not permitted, as they can lead to a poor user experience should these APIs change and are otherwise not supported on Apple platforms."_
I have scanned the app using "strings" tool & "otool -ov" tool.
But they have come out clean. No Non-public or deprecated APIs detected.
Please advise which tool can be used to scan the CL to locate where the deprecated API or non-public API lies and also how to rectify the same.
Thanks
Saikat Bakshi.
Hello,
According to documentation, the App Store does not re-download the entire app when updating, but instead generates an update package containing only the changed content compared to the previous version.
I’d like to clarify the following points:
1. Granularity of file changes
If only part of a large file changes, does the update package include the entire file, or does it patch only the modified portions within that file?
2. Guideline on separating files
The documentation recommends separating files that are likely to change from those that are not. How should this be interpreted in practice?
3. Verifying the diff result
Is there a way for developers to check the actual diff result of the update package generated by the App Store without submitting the app?
Is there a diff command tool or comparison method closer to the actual App Store update process?
4. Estimating update size during development
For apps with large-scale resources, minimizing update size is critical.
Are there any tools or best practices to estimate the size of the update package before submitting to the App Store?
Any clarification or reference materials would be greatly appreciated.
Thank you.
Topic:
Developer Tools & Services
SubTopic:
General
Tags:
Developer Tools
App Store
App Store Connect
macOS
How to replicate:
Design a icon in icon composer
Save it and put the .icon file in your project, then in your targets put the name of the .icon file in there. Either clean build folder or restart IDE
One Error:
unable to open dependencies file (/Users/user/Library/Developer/Xcode/DerivedData/project-fqrfzzkwgrutdabmcqjeupvyetci/Build/Intermediates.noindex/project.build/Debug/project.build/assetcatalog_dependencies_thinned)
And one warning:
Icon export exited with status 255, signal 0
Is this a known issue or a easy fix? Or is it a issue on my end? Thanks
Hi, I am developing IOS(Android App) with React Native.
I am very confused about cocoapods and pod and how to correctly install it on my new Macbook Pro M4. I am not using bash but I am using zsh. Note, actuallywhich pod return nothing
During the preparation of my environment, it say
CocoaPods is one of the dependency management system available for iOS. CocoaPods is a Ruby gem. You can install CocoaPods using the version of Ruby that ships with the latest version of macOS.
the web site show two commands
gem install cocoapods
sudo gem install cocoapods
I saw another command as well
brew install cocoapods
During different processes, I experienced several time the following error (Command 'pod install failed)
Command pod install failed.
└─ Cause: pod install --repo-update --ansi exited with non-zero code: 1
Then I am confused about cocoapods and pod. Are both he same?
With my previous MacBook pro, I spend time to install cocoapod on my profile because Ruby was not the latest version on the system. But apparently, on my new Macbook Pro M4, the command ruby -v return (as well)
ruby 2.6.10p210 (2022-04-12 revision 67958) [universal.arm64e-darwin25]
The current stable version is 4.0.0.
I bought a new macbook pro M4 and I reinstalled node and all package for Rect Native 0.81 a expo 54 excepted cocoapods. Now, I need to configure the push notification and it's time to install cocoapods as it's require here
But on my new macbook pro, I would like to make sure I do it correctly and I kindly ask your help and recommandation to install Ruby and cocoapods/pod
Q1: Should I install cocoapods with brew install cocoapods or gem install cocoapods?
Q2: what's is the difference or the common point with cocoapods and pod?
Cocoapod web site said
If using the default Ruby included with macOS, installation will require you to use sudo when installing
gems
As ruby -v print 'ruby 2.6.10p210', I suppose, I should not install cocoapod with sudo
You can use a Ruby Version manager such as RVM or rbenv
to manage multiple Ruby versions, or you can use Homebrew to install a newer Ruby with brew install ruby.
As far I understand, I should not install cocoapods with the Ruby version of the system, then I suppose the command
Q3: Will 'brew install cocopads' install the latest version on my profile? Will it upgrade the system version
Q4: What will do the command
brew install rbenv ruby-build
rbenv install 3.2.2 (or better: rbenv install 4.0.0)
in comparison with
brew install ruby
My guess
I suppose that the following will help, but it would nice if you could correct me and clarify
# All should be done in my profile
brew install rbenv ruby-build
echo 'eval "$(rbenv init - bash)"' >> ~/.zprofile
source ~/.zprofile
rbenv install 4.0.0
# rbenv global 4.0.0 # What is it?
ruby -v
gem install cocoapods
Q5: But then, what about pod and the error message
Command pod install failed.
As you can see, I am a bit confused and I would appreciate your clarification
I thanks you for your help and clarification and I wish you a happy new years
Topic:
Developer Tools & Services
SubTopic:
General
I am encountering an issue where the application running on a physical device does not reflect the most recent source changes.
Observed behavior
On the device, the application behaves as if an older binary is running. Specifically:
Newly added debug UI labels do not appear.
The logs still show old debug prints instead of new ones.
Steps taken to ensure a clean install:
Changed the bundle identifier
Set a new display name (the app still showed the old display name when I click run).
Deleted the app manually from the device before every reinstall.
Build and install steps
Performed multiple clean builds with a fresh Derived Data path.
Built from terminal using xcodebuild (Debug configuration, physical device target, automatic provisioning).
Installed using:
xcrun devicectl device install app
Verified:
The updated source files are listed under Compile Sources and compiled from the expected path.
The bundled Info.plist includes the new bundle identifier and display name.
Installation output confirms new bundle identifier.
Question
What could cause a newly built and installed application to run with behavior from an older binary? Are there recommended ways to verify that the device is actually launching the latest installed build, and to ensure stale binaries are not being executed?
Any guidance on additional diagnostics or misconfigurations to check would be appreciated.
Topic:
Developer Tools & Services
SubTopic:
General
I am trying to add promotional offers in my iOS App. The signature is being verified through a google cloud function. My user id, signature, and product and offerIds return perfect. Promotional offer appears in the payment sheet as well. When applying for payment, the "ding" sound comes as well. But then I get the UIAlert with Unable to Purchase Contact developer. Error code in logs is 3903
Topic:
Developer Tools & Services
SubTopic:
General
I need to install the AirPlay profile on an iphone to watch decrypted traffic in ATS for development work on CarPlay.
The documentation for ATS says to click "Utilities -> Download Profiles -> AirPlay Diagnostic Mode".
When I do this, it brings up a file dialog, presumably to select a location to download. But nothing happens. The other profiles launch a web browser and download the .mobileconfig profile.
How do I get the AirPlay profile? Am I misunderstanding how this is supposed to work?
I found ATSAssetsInfoDefault.plist which references these files. And they all have https://developer.apple.com/services-account/download?path=/iOS/iOS_Logs/... except the AirPlay profile, which is type "slug" and just says ats-airplay-diagnostic-mode-profile.
Is this a bug in the app?