I'd like to give control to the app developer that uses my library to select which level of logs they'd like to see from my lib (e.g. do they want to see all debug messages or just errors).
I know there are filtering controls that Xcode gives us, but I'm wondering if there is a way to pull this off with code. Ideally the user callsite would look like MyLib(logLevel: .info).
And then I would pass that info level somehow to OSLog. Today, I create my logger like this:
let myLogger = Logger(
subsystem: Bundle.main.bundleIdentifier ?? "UnknownApp",
category: "MyLibrary"
)
As far as I can tell, there is nothing I can then pass to my myLogger instance to configure the threshold level. I'm imagining an interface like:
myLogger.logLevel(.warning)
// Later...
myLogger.debug("You won't see this")
myLogger.error("But you will see this")
Does OSLog and friends give us any ability to do this out of the box, or are we building little wrappers around OSLog to accomplish this?
Thank you,
Lou
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
Weirdness going on here. Our app is crashing on startup with iPad 7s running iOS 18.5. Before updating to iOS 18.5, it was working fine on iPad 7s. Even with iOS 18.5, it is working fine on every device we have tried including dozens of other iPads and iPhones. We have narrowed it down to the SquareReaderSDK. If we remove that SDK, it will launch and work without issues. But, many of our users need the SquareReaderSDK.
The crash happens at app load, before appDelegate didFinishLaunchingWithOptions. So we can't figure out any way to debug the issue. Is anyone else having a similar issue? Square thinks it is an Apple issue.
Topic:
Developer Tools & Services
SubTopic:
General
When attempting to open sysdiagnose logs collected from an iPhone running iOS 26 beta 3 on macOS Console, the application consistently crashes.
Crash report has been added for reference.
Apple Feedback- FB18834450
The project at hand is quite complex, and the link content is especially.
I suddenly saw this warning again in recent days and wanted to inquire about when this deletion would be done, so that our team could make preparations and plan in advance.
When you update XCode it updates the sdk version, but do changes in the sdk take effect for apps running in a lower iOS version or only the corresponding iOS version or higher?
For instance, https://developer.apple.com/documentation/ios-ipados-release-notes/ios-ipados-18_1-release-notes
Do changes listed in the notes only happen for apps that are running on iOS 18.1 devices or on any device with the app compiled against the 18.1 sdk version?
Am I the only person who finds the docs totally unclear on this?
Hi everyone,
We’re testing the new iOS 26 capability, Performing Fast Account Creation with Passkeys, using the sample project provided here: Performing Fast Account Creation with Passkeys.
When running the project on the iOS 26 simulator and tapping the "Sign Up" button, we encounter the following error:
The operation couldn’t be completed. (com.apple.AuthenticationServices.AuthorizationError error 1010.)
From the header file, this error is described as:
/// ASAuthorizationError.h
/// This error signals that the device is not currently set up to create passkeys.
ASAuthorizationErrorDeviceNotConfiguredForPasskeyCreation AS_API_AVAILABLE(ios(19.0), macos(16.0), visionos(3.0)) = 1010,
We’ve tested this on both Xcode 26 Beta 1 and Beta 2, and the error persists on the simulator in both versions.
However, when testing on a physical iOS 26 device, everything works as expected, just like in the WWDC demo.
Could this issue be related to missing simulator settings? Or is it a potential bug in the simulator? Any advice would be greatly appreciated.
Thanks in advance!
Hey guys.
I’m working on a project where I’m using the SwiftTesting framework instead of XCTest to run my unit tests. I have a file (test.png) located in my test resources folder:
PackageName > Tests > PackageNameTests > Resources > test.png
I’m trying to access this file in my tests, but I’m running into issues when trying to load it dynamically. Here’s what I’ve tried so far:
Using Bundle.module.path(forResource:ofType:): This approach didn’t work, as Bundle.module seems to be unsupported or returns nil in Swift Testing.
Using #file Macro for Relative Paths: I tried constructing a path based on #file and navigating to the resources directory, but it also didn’t yield the correct path.
Has anyone successfully loaded test resources in the Swift Testing framework? Is there a recommended way to access resource files in Swift Testing, especially for projects where Bundle.module isn’t available?
I've gone through the Apple Docs for Swift Testing, but I can't seem to find anything that answers my question.
Thanks in advance guys!
Hi,
I have an installer package that runs a postinstall script. The script can take a long time to complete, as one thing it does is copy about 10-30 GB of files using the rsync tool.
We noticed on macOS 15 that the installer would fail almost exactly 10 minutes after it started. Looking in the /var/log/install.log, I see a message like this:
2025-07-01 12:54:32-07 Work-M1 package_script_service[21562]: PackageKit: Terminating PKInstallTask(pid:21573). Task has exceeded its 600 seconds of runtime.
This does not happen in my testing on macOS 12 (Monterey)
I have a few questions about this:
A) Is this documented, and which OS introduced this?
B) Is there a way a developer can extend or disable the time limit via a setting in the installer package. Or if not, is there a way end end user can disable it temporarily on their system?
Thanks, Andrew
Topic:
Developer Tools & Services
SubTopic:
General
Hi,
I have just updated my MacBook to Tahoe Beta 2, but now I cannot boot the iOS simulator.
Where can I download the next Xcode beta? The Application download page is still showing the Xcode beta 1 build.
Cheers,
Jeff
It is gone from where I used to find it on Apple’s web site. Is it deprecated or no longer available?
In previous versions of the simulator, it was possible to import files into the Files app by dragging them from the Finder into the Simulator. It appears that in the iOS 26 Simulator, this opens the file in Safari.
I've only tried it with .json files so far.
The documentation at https://developer.apple.com/documentation/xcode/sharing-data-with-simulator says that the original behaviour should happen:
To add files to Simulator, select one or more files in Finder on your Mac, then click the Share button. Select Simulator from the share destination list. Choose the simulated device from the drop-down list. Simulator opens the Files app, and lets you select where to save the files.
I'd love to learn if this is intentional behaviour, and if so, what workarounds there might be. I use this pattern quite a lot, as I have a HealthKit app, and I've built a system that allows me to export workouts as JSON files from a real device, that I can then import into a simulator for testing.
Edit: I found a workaround. Make a folder in Files.app, then search for it within ~/Library/Developer/CoreSimulator/Devices. Open the folder in Finder, then add any files you want to be available in the Simulator.
I would like to inquire about a concern related to the app review process. Specifically, I would like to understand if forcefully denying an application's execution on the iOS Simulator (for instance, by implementing a check in the code that prevents the app from running in a simulated environment) could negatively impact or delay the app’s approval during the App Store review process.
This measure is intended solely for security and integrity reasons during development and distribution. The app functions normally on real devices, and all other guidelines and requirements outlined by Apple are being strictly followed.
Could you please confirm whether such a restriction on the Simulator is acceptable, and if there are any best practices or recommendations from Apple regarding this?
Thank you for your support, and I look forward to your guidance.
I need to automate updating to latest iOS betas as part of my ci script, but I can't get it to install iOS 26.0 beta for the life of me, using xcodes or xcodebuild.
I can see the version listed using xcodes runtimes --include-betas, and I tried sudo xcodes runtimes install "iOS 26.0-beta1", but I would get the error
Downloading Runtime iOS 26.0-beta1: 0%
Error: ProcessExecutionError()\
I also tried xcodebuild -downloadPlatform iOS -buildVersion 23A5260l, where I found the specific build id on apples dev images website. But I would get the error
iOS 23A5260l is not available for download.
Specific version download failed, trying downloadPlatform ios latest...
And similar error for trying xcodebuild -downloadPlatform iOS -buildVersion 26.0 or other version ids I found online. But this command would work for any other versions and betas listed on the website.
I was able to install iOS 26.0 through xcodebuild -downloadPlatform iOS, which automatically installed it for me, but this is unideal for my situation, as I want to control which betas to install instead of just the latest one (like iOS 18.6 beta that just came out).
Is anyone else also struggling with these errors?
xcodes version 1.6.2 Xcode version 26.0 Beta (installed and selected through xcode)
I am working on a Swift package which uses CoreAudio, and includes some tests in a testTarget which use the Testing framework, and a couple of executableTarget targets which exercise the same code. I'm using Xcode 16.2 on macOS 15.3.1.
One of the things I do in the test code is create a HAL plugin, then find that plugin using the kAudioHardwarePropertyTranslateUIDToDevice.
Finding the plugin that I just created always fails from within a Swift Testing test, unless I run the test which creates the plugin individually first, then separately, run the test which finds the plugin, by clicking on the little arrows next to the function names.
If I put the tests in a serialized suite (so creation always happens first, then finding), running the suite always fails - it creates the plugin, but can't find it. If I run the 'find my plugin' test again manually, it is always found.
If I call the same functions from a regular executable (the thing created by a "executableTarget" in my .package.swift file), the just-created plugin is always found.
Is there a way to mimic the runtime environment of a regular executable in a Swift Testing target, or am I misunderstanding something?
this my be related to this issue: https://github.com/swiftlang/swift/issues/76882 but I don't understand it well enough to be sure.
Recently we tried to update the plist.info file in one of our apps to specify an LSMinimumSystemVersion of 16.0 but when uploading this to App Store Connect using the Transporter app we received an error that this setting cannot be any higher than 15.2. Is there any way around this? Will this be changing soon?
Topic:
Developer Tools & Services
SubTopic:
General
I just turned it on by accident and I can’t turn it off… I’m using IOS 26 rn and I can’t go back and I can’t disable the developer mode, I’m not a developer so yeah
Topic:
Developer Tools & Services
SubTopic:
General
We are looking for a platform or portal provided by Apple that allows us to track crashes, hangs, or other runtime issues faced by users while using our iOS/macOS application. This is similar to how we currently use Windows Error Reporting (WER) for our Windows application.
Important note: Our application is not distributed via the Apple App Store — it is delivered through enterprise distribution or ad-hoc provisioning.
Topic:
Developer Tools & Services
SubTopic:
General
Tags:
MetricKit
App Store
Custom Apps
Enterprise
Hi, after a software update of our previously successfully notarizated installion .pkg we now receive a cryptic notarization issue refusing the entire .pkg:
{
"logFormatVersion": 1,
"jobId": "5cff2d71-7228-4fb4-a39d-329084cd2713",
"status": "Invalid",
"statusSummary": "Archive contains critical validation errors",
"statusCode": 4000,
"archiveFilename": "my_installer.pkg.zip",
"uploadDate": "2024-12-04T23:17:14.016Z",
"sha256": "2f26d0376506abe130ac904d7cb0d0cd5428666624428da9f44da7756352844f",
"ticketContents": null,
"issues": [
{
"severity": "error",
"code": null,
"path": "my_installer.pkg.zip",
"message": "Package my_installer.pkg.zip has no signed executables or bundles. No tickets can be generated.",
"docUrl": null,
"architecture": null
},
{
"severity": "warning",
"code": null,
"path": "my_installer.pkg.zip/my_installer.pkg",
"message": "The contents of the package at my_installer.pkg.zip/my_installer.pkg could not be extracted.",
"docUrl": null,
"architecture": null
}
]
}
What could be the reason for that? We've also submitted the .pkg (not zipped) with the same result. We build it on different macOS versions, including Sonoma 14.7 with latest developer tools installed, without any change in outcome.
But when extracting it via the undocumented:
pkgutil --expand-full
and .zipping the raw contents (without re-packaging it as .pkg) and sending it again, notarization succeeds for all components.
However the installation for the .pkg still fails with the notarization dialog. I was under the assumption that it is sufficient to notarize the .pkg contents but this does not seem to be true, or?
Any hints or help is highly appreciated, Thanks!
My Xcode project has the following configuration:
1 iOS app target
1 Xcode framework target (mach-o-type "Dynamic Library")
5 static libraries
Dependencies:
All the static libraries are target dependencies of the framework.
The framework is the only target dependency of the iOS app.
For the iOS app target, within the General tab > Frameworks, Libraries & Embedded content, I've set the framework as "Do not embed"
So now I have a dynamic framework which won't be copied to the .app bundle in the build output.
As per my understanding, this should result in a runtime error, dyld should not be able to find the framework files as they were not embedded in the final .app bundle.
But regardless, my app runs without any errors, using all the methods exposed by the framework.
What is the correct understanding here?
What exactly does Embed/Do not embed mean (apart from excluding the files from .app bundle)
When both settings are specified, is there any priority or precedence of one setting over the other?
I am using two iPhone11 devices, having iOS v17.6.1 for automation testing using Seleniumv4.X-Appium v2.x.
Today I updated the mac to Sequoia15 version which updated the XCode to v16.
Just after this update, I could not able to run the previously running automation script. The console message is "org.openqa.selenium.SessionNotCreatedException:
Could not start a new session. Response code 500. Message: Unable to launch WebDriverAgent. Original error: xcodebuild failed with code 70. This usually indicates an issue with the local Xcode setup or WebDriverAgent project configuration or the driver-to-platform version mismatch."