Am running Xcode 16.1 on Sequoia and am getting "No such module" error.
Here are my steps:
Create workspace in Xcode and name it AccessControl2
Create Project named OrangeInc and add it to AccessControl2 group.
Create blank playground named AccessControl and add it to AccessControl2 group
Error message in playground after I add "import OrangeInc" reads "No such module"
Have tried repeating this several times; get same error message.
Xcode
RSS for tagBuild, test, and submit your app using Xcode, Apple's integrated development environment.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
I can sucessfully send pushes to an app (which has been installed/run via Xcode) when the pushes are going through the Apple sandbox server.
However I want to test the server is configured correctly to send them through the Apple production server.
In the Xcode scheme I tried to change the build configuration to release (and ticked debug executable off) ,however the pushes still only work when sent through the sandbox.
Is there a way of installing/running the app using Xcode such that its compatible with the push production environment?
Does the APS Environment entitlement come into play here? this only ever says development.
(The app is on behalf of a 3rd party company, they've added me to their apple developer account but with limited powers, I can't upload to Testflight nor make an ad-hoc release with with to test with)
Hi!
I'm trying to create a target application that depends on multiple targets that all use the same Swift package that has xcframework binaryTarget. Each component can be successfully assembled individually, but when I try to create a core application that depends on these components, I get an error message on Prepare build stage:
Multiple commands produce '/Users/<USER>/Library/Developer/Xcode/DerivedData/<PROJECT_ID>/Build/Products/Debug/Frameworks/<FW_NAME>.framework/Versions/A'
Target '<COMPONENT1>' has copy command from '/Users/<USER>/Library/Developer/Xcode/DerivedData/<PROJECT_ID>/SourcePackages/artifacts/.../<FW_NAME>/<FW_NAME>.xcframework/macos-arm64_x86_64/<FW_NAME>.framework' to '/Users/<USER>/Library/Developer/Xcode/DerivedData/<PROJECT_ID>/Build/Products/Debug/Frameworks/<FW_NAME>.framework'
Target '<COMPONENT2>' has copy command from '/Users/<USER>/Library/Developer/Xcode/DerivedData/<PROJECT_ID>/SourcePackages/artifacts/.../<FW_NAME>/<FW_NAME>.xcframework/macos-arm64_x86_64/<FW_NAME>.framework' to '/Users/<USER>/Library/Developer/Xcode/DerivedData/<PROJECT_ID>/Build/Products/Debug/Frameworks/<FW_NAME>.framework'
– where <FW_NAME> is a name of the xcframework which is the binaryTarget in the Swift package.
Could someone please explain to me if it is even possible to use xcframeworks packaged in Swift packages in such cases, and if so, how to do it correctly?
the Xcode Version 16.2 (16C5032a),
I want to know how to setup a directory in Xcode project when develop the iOS app.
Here is the whole thing:
I start a new iOS App project "test_path".
then I right click, and choose "New Folder", to make a new folder "configx"
then I right click on the configx folder, and choose the "add files to test_path", add a file in it
But the folder does not exist in the project when try to access by "Bundle.main.urls" func.
5. when ls in the Mac, /data/Containers/Bundle/Application/E4F11903-3FAD-467F-A4CD-60AC68D64934/test_path.app, the file just at the root path of test_path.app, no "configx" folder ahead the file.
so, how to setup a directory or a path in iOS project?
Hi everyone,
I’m facing a major roadblock with my family location tracking app, and I need some advice or guidance from the community.
Background
Back in 2021, I implemented NSE filtering entitlement to send location-based notifications and retrieve the device's location in return (as suggested by Apple’s technical code support). Over time, I built my app around this entitlement, adding many features that depend on it.
When Location Push Service Extension was introduced for iOS 15+, I adapted accordingly:
NSE filtering was used for devices below iOS 15
Location Push Service Extension was used for iOS 15+
NSE filtering also played a crucial role in:
✅ Accepting/rejecting location-based notifications
✅ Checking device settings & location permissions (since location push won’t work without proper permissions)
The Issue
In November 2024, I created a new developer account to change my business entity. Since then, I’ve been requesting the NSE entitlement repeatedly for four months, but Apple keeps rejecting it. Meanwhile, they approved the Location Push Entitlement, but without NSE filtering, I’m forced to rewrite a huge part of my app’s core functionality.
I’ve sent multiple emails explaining my use case, but I keep getting rejected without any clear explanation or workaround.
My Ask
Has anyone faced a similar issue with NSE entitlement?
Are there any alternative approaches to achieve the same functionality?
Any advice on how to escalate this to Apple or get proper feedback on why it's being rejected?
I’ve invested years into this app, and a forced rewrite would take months. Any help, insights, or contacts who could assist would be greatly appreciated!
Thanks in advance! 🙏
Topic:
Developer Tools & Services
SubTopic:
Xcode
I’m creating code that performs asynchronous processing using the Promises library (https://github.com/google/promises). In this context, when building the app in Xcode 15.4 and Xcode 16.2, the behavior differs between the two.
I’m using version 2.1.1 of the library. Also, I’ve tried using the latest version, 2.4.0, but the result was the same.
Has anyone encountered the same issue or know an effective solution?
Here's a simple code that reproduces this issue.
@IBAction func tapButton(_: UIButton) {
_ = getInfo()
}
func getInfo() -> Promise<Void> {
Promise(on: .global(qos: .background)) { fulfill, _ in
self.callApi()
.then { apiResult -> Promise<ApiResult> in
print("\(#function), first apiResult: \(apiResult)")
return self.callApi() // #1
}
.then { apiResult in
print("\(#function), second apiResult: \(apiResult)") // #2
fulfill(())
}
}
}
func callApi() -> Promise<ApiResult> {
Promise(on: .global(qos: .background)) { fulfill, _ in
print("\(#function), start")
self.wait(3)
.then { _ in
let apiResult = ApiResult(message: "success")
print("\(#function), end")
fulfill(apiResult)
}
}
}
struct ApiResult: Codable {
var message: String
enum CodingKeys: String, CodingKey {
case message
}
}
The Swift Language version in the build settings is 5.0.
The console output when running the above code is as follows:
When built with Xcode 15.4:
2025/03/21 10:10:46.248 callApi(), start
2025/03/21 10:10:46.248 wait 3.0 sec
2025/03/21 10:10:49.515 callApi(), end
2025/03/21 10:10:49.535 getDeviceInfo(), first apiResult: ApiResult(message: "success")
2025/03/21 10:10:49.535 callApi(), start
2025/03/21 10:10:49.536 wait 3.0 sec
2025/03/21 10:10:52.831 callApi(), end
2025/03/21 10:10:52.832 getDeviceInfo(), second apiResult: ApiResult(message: "success")
The process proceeds from #1 to #2 after completing the code comment in #1.
When built with Xcode 16.2:
2025/03/21 09:45:33.399 callApi(), start
2025/03/21 09:45:33.400 wait 3.0 sec
2025/03/21 09:45:36.648 callApi(), end
2025/03/21 09:45:36.666 getDeviceInfo(), first apiResult: ApiResult(message: "success")
2025/03/21 09:45:36.666 callApi(), start
2025/03/21 09:45:36.666 wait 3.0 sec
2025/03/21 09:45:36.677 getDeviceInfo(), second apiResult: Pending: ApiResult
2025/03/21 09:45:39.933 callApi(), end
The process does not wait for the code comment in #1 to finish and outputs the #2 print statement first.
Additionally, even with Xcode 16.2, when changing the #2 line to "print("(#function), second apiResult: (apiResult.message)")", the output becomes as follows. From this, it seems that referencing the ApiResult type, which is not a String, might have some effect on the behavior.
2025/03/21 10:05:42.129 callApi(), start
2025/03/21 10:05:42.131 wait 3.0 sec
2025/03/21 10:05:45.419 callApi(), end
2025/03/21 10:05:45.437 getDeviceInfo(), first apiResult: ApiResult(message: "success")
2025/03/21 10:05:45.437 callApi(), start
2025/03/21 10:05:45.437 wait 3.0 sec
2025/03/21 10:05:48.706 callApi(), end
2025/03/21 10:05:48.707 getDeviceInfo(), second apiResult: success
Thank you in advance
Topic:
Developer Tools & Services
SubTopic:
Xcode
I encountered a problem when adding a new custom font in Xcode 16.1. After including the font and opening my XIB files, the interface preview became blank and the application seemed to experience a heavy load.
To troubleshoot, I removed all custom fonts, and everything returned to normal functionality. However, even after reinstalling Xcode, the issue persisted when adding the font again.
The XIB preview loaded correctly:
The XIB preview turned blank and became unresponsive:
I upgraded xcode to 16.2 and found that the txt file generated by Write Link Map File is different from before, no longer containing detailed data. So, how to set it up to obtain the same link map file as the previous xcode version.
# Path: /Users/....../xxx.app/__preview.dylib
# Arch: arm64
# Object files:
[ 0] linker synthesized
# Sections:
# Address Size Segment Section
0x00004000 0x00000000 __TEXT __text
# Symbols:
# Address Size File Name
Topic:
Developer Tools & Services
SubTopic:
Xcode
I have a problem uploading to testflight. When I archived my app, it announced success, but when I went to the appstoreconnect website I didn't see any builds, while I waited a long time for it to be pushed up. And one more problem, when the upload notification is uploaded, after a while there is a notification that my app for ios is not a valid binary, I don't understand this problem. Can you please ask me how to solve it?
My project is using Fastlane 2.226.0. After converted groups to folders on XCode 16, I got an error when executed below function in Fastfile:
get_version_number(xcodeproj: "MyProject.xcodeproj", target: "MyProject")
Below is the error message output after I ran fastlane:
Unable to find XCode build setting: MARKETING_VERSION
This is the complete Playground code:
import MapKit
import SwiftUI
import PlaygroundSupport
struct AddressSearchView: View {
@State private var region = MKCoordinateRegion(
center: CLLocationCoordinate2D(latitude: 37.7749, longitude: -122.4194),
span: MKCoordinateSpan(latitudeDelta: 0.01, longitudeDelta: 0.01)
)
var body: some View {
VStack {
Map(position: .constant(MapCameraPosition.region(region))) {
}
.frame(height: 300)
}
}
}
struct AddressSearchView_Previews: PreviewProvider {
static var previews: some View {
AddressSearchView()
}
}
PlaygroundPage.current.setLiveView(AddressSearchView())
When I try to run this I get this in the debug console:
error: Couldn't look up symbols:
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
protocol witness table for _MapKit_SwiftUI.EmptyMapContent : _MapKit_SwiftUI.MapContent in _MapKit_SwiftUI
Hint: The expression tried to call a function that is not present in the target, perhaps because it was optimized out by the compiler.
the preview never shows up. If I use other SwiftUI components and not the map it works fine. What is happening?
Playground target is Swift 6 macOS (iOS does the same).
Xcode 16.2
My application is in flightTest mode.
I received my first two crash reports in XCODE /Organizer. The context is well described, and I was able to isolate the locations where very serious errors occurred.
My application is connected. I'm missing one piece of data in this crash report: the time of the crash.
This will help me see what (in my case) static data was being read on the data server at that time. This will help me investigate.
Is it possible to obtain this information?
We are renaming the project and a Static Library the is critical to the operation on the app is not found during compiling.
We have the same project working fine. We have reviewed the project.pbxproj file and searched for erroneous linking, reviewed the Target settings and there is nothing obviously wrong. (Copied and secured the original)
Typically workflow is:
Clean
Delete Derived Data dir
D/l Swift Packages
Build/Run
The team has many years using Xcode / Swift and the project and this is not clear how to resolve. We have scoured SO and the solutions do not apply.
Facts:
-No cocoapods
-Search Paths all set
Linker all set
Thoughts?
The following function could run several hundred times with no problem but will occasionally cause a EXC_BAD_ACCESS (SIGBUS). The last time it was a KERN_PROTECTION_FAILURE perhaps meaning it is trying to write to a read only memory but previously it was KERN_INVALID_ADDRESS. I have tried debugging tools to no avail. Can anyone see any reason why the following function could be causing this. Just in case the function is a red herring the only other thing that was running is a AVQueuePlayer that contains 11 tracks, but the crash happens mid song making it unlikely.
The function includes running other functions so below is all related functions that happen as a result of a swipe gesture.
func completeLeft() {
let add1 = Int(tiles[Square - (squares2move + 2)].name ?? "0") ?? 0
let add2 = Int(currentNode.name ?? "0") ?? 0
let add = add1 + add2
if add.isMultiple(of: 9) == false {
if squares2move == 0 {
self.moveinprogress = 0
return
}
moveLeft1()
}
if add.isMultiple(of: 9) {
squares2move += 1
moveLeft2()
}
func moveLeft1() {
var duration = TimeInterval(0.1)
duration = Double(squares2move) * duration
self.soundEffect = "swipe"
self.playEffects(Volume: self.effectsVolume)
let move = SKAction.move(to: positions[Square - (squares2move + 1)], duration: duration)
currentNode.run(move, completion: {
self.tiles[Square - (squares2move + 1)].name = self.currentNode.name
self.tiles[Square - 1].name = ""
self.currentNode.position = self.positions[Square - (squares2move + 1)]
self.newNumber()
})
}
func moveLeft2() {
var duration = TimeInterval(0.1)
duration = Double(squares2move) * duration
self.soundEffect = "swipe"
self.playEffects(Volume: self.effectsVolume)
let move = SKAction.move(to: positions[Square - (squares2move + 1)], duration: duration)
currentNode.zPosition = currentNode.zPosition - 1
currentNode.run(move, completion: {
self.currentNode.position = self.positions[Square - (squares2move + 1)]
self.tiles[Square - 1].name = ""
self.currentNode.name = "\(add)"
self.tiles[Square - (squares2move + 1)].name = "\(add)"
if add > self.score {
self.score = add
}
if add >
self.currentgoal {
self.levelComplete()}
else {
self.playEffects2(soundEffect: "Tink", Volume: self.effectsVolume, Type: "caf")}
if self.currentNode.childNode(withName: "Label") == nil {
self.currentNode.texture = SKTexture(imageNamed: "0.png")
let Label = SKLabelNode(fontNamed: "CHALKBOARDSE-BOLD")
Label.text = "\(add)"
Label.name = "Label"
let numberofdigits = Label.text!.count
if numberofdigits == 1 {
Label.fontSize = 45 * self.hR}
if numberofdigits == 2 {
Label.fontSize = 40 * self.hR}
if numberofdigits == 3 {
Label.fontSize = 32 * self.hR}
if numberofdigits == 4 {
Label.fontSize = 25 * self.hR}
Label.horizontalAlignmentMode = .center
Label.verticalAlignmentMode = .center
Label.fontColor = .systemBlue
Label.zPosition = 2
self.currentNode.addChild(Label)
self.currentNode.zPosition = self.currentNode.zPosition + 1
var nodes = self.nodes(at: self.positions[Square - (squares2move + 1)])
nodes = nodes.filter { $0.name != "Tile" }
nodes = nodes.filter { $0 != self.currentNode }
nodes = nodes.filter { $0 != self.currentNode.childNode(withName: "Label") }
for v in nodes {
v.removeFromParent()}
}
else {
let Lbl = self.currentNode.childNode(withName: "Label") as? SKLabelNode
Lbl!.text = "\(add)"
let numberofdigits = Lbl!.text!.count
if numberofdigits == 1 {
Lbl!.fontSize = 45 * self.hR}
if numberofdigits == 2 {
Lbl!.fontSize = 40 * self.hR}
if numberofdigits == 3 {
Lbl!.fontSize = 32 * self.hR}
if numberofdigits == 4 {
Lbl!.fontSize = 25 * self.hR}
self.currentNode.zPosition = self.currentNode.zPosition + 1
var nodes = self.nodes(at: self.positions[Square - (squares2move + 1)])
nodes = nodes.filter { $0.name != "Tile" }
nodes = nodes.filter { $0 != self.currentNode }
nodes = nodes.filter { $0 != self.currentNode.childNode(withName: "Label")
}
for v in nodes {
v.removeFromParent()}
}
self.moveinprogress = 0
})
}
}
func moveLeft() {
var duration = TimeInterval(0.1)
duration = Double(squares2move) * duration
self.soundEffect = "swipe"
self.playEffects(Volume: self.effectsVolume)
let move = SKAction.move(to: positions[Square - (squares2move + 1)], duration: duration)
currentNode.run(move, completion: {
self.tiles[Square - (squares2move + 1)].name = self.currentNode.name
self.tiles[Square - 1].name = ""
self.currentNode.position = self.positions[Square - (squares2move + 1)]
self.newNumber()
})
}
Topic:
Developer Tools & Services
SubTopic:
Xcode
Hello.
We have a few iOS devices connected to CI macs. We test our 3D engine, so we really need hardware devices for that. The issue is that Xcode loses connection to the devices once in a while, mostly after mac reboot, which requires a human to enter test room and unplug and plug cable again. Even if device is visible and accessible in Finder, Xcode may still don't see it, and devicectl shows it as disconnected.
Are there any hacks to make connection stable? The best what we could achieve so far was to remove iOS device screen lock - otherwise mac reboot would in 100% cases require human interaction to reconnect the device.
Both iOS and mac are logged into the same Apple ID.
Mac is logged in automatically after reboot
iOS devices have no screen lock
Thank you.
Since upgrading from Xcode 15 to 16, we have been experiencing a build error during compilation. Building on Xcode 15 still works with no issues. The error happens only on the first build after a clean. Subsequent builds succeed. This is an issue because our CI process archives the project from a clean slate, and this causes it to fail every time. I will attempt to describe the issue and include information I believe is relevant in this document.
The error occurs on this import line within an Objective-C file during the Scan Dependencies step of compiling. This line imports our custom Objective-C to Swift bridging header file - "Swift2Objc.h".
Our custom Objective-C to Swift bridging header file is simply wrapping the project’s auto-generated Objective-C to Swift bridging header file - "KWISwift.h".
The error is specific to the import of the OfflineServices Swift Package.
Specifically, the OfflineServices-Swift.h file - the Swift Package’s auto-generated Objective-C to Swift bridging file.
Module JRE not found - the exact error (Also included as text on the bottom of the post)
JRE is a third-party library provided to us as an xcframework. It is placed directly into our Swift Package as a binary target.
The xcframework itself is composed of .a file and a Headers folder which includes header files and a module.modulemap.
The module.modulemap file looks like this.
Hi, I currently have an app that connect to an arduno via CoreBluetooth. However, the app no longer discovers the arduino when the operating system was upgraded to iOS 18.3.1, however on iOS version 17.6.1 the ardiuno was discoverable I was able to test this theory on two different phones each with different iOS versions. Why are my peripherals no longer being discovered with this update? and what is the solution?
ive been using the mac m1 for almmost a year and it used to run vision pro simulator on xcode 15 quite smoothly but now its quitting unexpectedly showing errors in loading the realtiykit content
Topic:
Developer Tools & Services
SubTopic:
Xcode
Tags:
Reality Composer Pro
visionOS
iPad and iOS apps on visionOS
Xcode Version: 16
MacOS Version: 15.0
My app has 2 packages:
Firebase iOS SDK (https://github.com/firebase/firebase-ios-sdk.git)
Google Mobile Ads (https://github.com/googleads/swift-package-manager-google-mobile-ads.git)
My app fails to run on the Xcode Preview window. The app works successfully on a simulator when built. But, not in the Xcode Preview.
I have tried:
Cleaning and rebuilding.
Changing the target device.
Resetting Package Cache
There are no solutions mentioned/provided online. I have a previews-diagnostics zip file ready. Who can I share it with?
Topic:
Developer Tools & Services
SubTopic:
Xcode
We are trying to create a screentime app using the Family Controls as well as Device activity frameworks. The build succeeds but while pushing to an iphone we are getting an info.plist file for deviceactivity.framework could not be found error. For reference when using the Screentime API a physical device must be used not a simulator. When we remove the device activity framework this error also occurs for the family controls framework. We have added the Family Controls(development) Capability and applied for the distribution capability. We have redownloaded xcode multiple times on the main device, deleted derived data, and redownloaded all of the iphone SDKs and the issue still persists.