Search results for

“xcode github”

96,030 results found

Post

Replies

Boosts

Views

Activity

XPC connection consistently invalidated on app upgrade
Hi, Our project is a MacOS SwiftUI GUI application that bundles a System Network Extension, signed with a Developer ID certificate for distribution outside of the app store. The system network extension is used to write a packet tunnel provider. The signing of the app & network extension is handled by XCode (v16.0.0), we do not run codesign ourselves. We have no issues with XPC or the system network extension during normal usage, nor when the application is installed on a user's device for the first time. The problem only arises when the user upgrades the application. I have experienced this issue myself, as have our users. It's been reported on Apple Silicon macbooks running at least macOS 15.3.2. Much like the SimpleFirewall example (which we used as a reference), we use XPC for basic communication of state between the app and NE. These XPC connections stop working when the user installs a new version of the app, with OS logs from the process indicating that the connection is immediately invali
6
0
542
1w
Reply to Xcode 26.4.1, iOS 26.4.2, watchOS 26.4, Apple Watch Ultra 3 not appearing as development device.
Thanks for the post, there are many Apple Watch engineers that I’m just they’ll jump into the thread, however this question seems like how to start with Apple Watch development and pair the Apple Watch to Xcode. When an Apple Watch fails to appear as a development device in Xcode, the issue usually stems from the wireless pairing bridge between Xcode, the iPhone, and the Watch, or a missing Developer Mode toggle. On the iPhone go to Settings → Privacy & Security → Developer Mode and toggle it on. On the Apple Watch go to Settings → Privacy & Security → Developer Mode and toggle it on. Both devices will require a restart. Connect the paired iPhone to your Mac via a physical cable. In Xcode, go to Window → Devices and Simulators. Select your iPhone in the left sidebar. Look at the Paired Watches section. If the Watch is listed but has a yellow warning triangle, hover over it. It may say Preparing device for development. If you have successfully completed all the steps
1w
HLS Tools - hlsreport critical error cause
Hi, I'm currently experiencing issues with HLS streams created by FFmpeg running on Safari. When I pass the stream to the mediastreamvalidator tool and then run hlsreport on the output, I get a critical error reported: Media Entry discontinuity value does not match previous playlist for MEDIA-SEQUENCE 1 If I let the stream finish (it's a live stream from an IoT device) and then perform the stream validation again I no longer receive the critical error. My assumption is that this critical error is contributing to the HLS stall on iOS. I have also noticed that if I let the stream continue and then re-load the video control in Safari the stream starts Is there a resource with explanations or remediation paths relevant to the possible output of the hlsreport? My m3u8 output looks like this (I have redacted the server host) #EXTM3U #EXT-X-VERSION:6 #EXT-X-TARGETDURATION:2 #EXT-X-MEDIA-SEQUENCE:1 #EXT-X-PLAYLIST-TYPE:EVENT #EXT-X-INDEPENDENT-SEGMENTS #EXT-X-DISC
1
0
585
1w
Reply to CLLocationManager permission prompt never appears in Swift Playground
@Marka99 Welcome! Thank you for the post. I believe developers are referring to samples where you can observe how to implement that functionality. https://developer.apple.com/tutorials/sample-apps Also videos are very helpful in my opinion: https://developer.apple.com/search/?q=CLLocation Swift Playgrounds App projects fully support Core Location. Because they compile into real application bundles, they behave exactly like apps built in Xcode. You must provide a Usage Description string. In Xcode, this is done in the Info.plist. In Swift Playgrounds, this is done in the App Settings. If this string is blank, the prompt will never appear. The CLLocationManager instance must be strongly retained in memory. If you declare let manager = CLLocationManager() inside .onAppear, the manager is destroyed the moment the .onAppear closure finishes executing. Do not call startUpdatingLocation() immediately after requesting authorization. Instead, wait for the delegate to confirm you have permission. Albe
1w
Reply to ScrollView/ClipView weirdness.
Here is a sample program to demonstrate the problem. Using Xcode, create a new document project using interface: xib, language: swift Once that is done, delete Document.xib, go into Document.swift and add the following method: override func makeWindowControllers() { let controller = MyWC(document: self) addWindowController(controller) controller.showWindow(self) controller.window?.makeFirstResponder(nil) } Then make a new Swift file named MyWC.swift with this content: import AppKit class MyWC: NSWindowController { init(document: Document) { let window = NSWindow( contentRect: NSRect(x: 0.0, y: 100.0, width: 700.0, height: 500.0), styleMask: [.titled, .closable, .miniaturizable, .resizable], backing: .buffered, defer: false ) super.init(window: window) window.minSize = NSSize(width: 200, height: 200) let myScrollView = NSScrollView() let contentView = NSView(frame: NSRect(x: 0.0, y: 0.0, width: 800.0, height: 600.0)) let clipView = NSClipView(frame: myScrollView.contentView.frame) clipView.backgroundC
Topic: UI Frameworks SubTopic: AppKit Tags:
1w
Reply to Charts performance issue
Hi everyone, I observe similar performance issue. They performance is degraded when the x axis domain is enlarged. I add 5 bars per day, and around 150 days there is a visible jitter and tearing while dragging. I've tried various techniques to improve it such as large xAxis and displaying events only around the scroll position, however as noted above using it lowers the performance. I've also tried prepending and apending days, without having a large x axis domain, but this makes the scroll position jump. Here is another code sample. import Charts import SwiftUI struct PerformanceBarChart: View { struct DataPoint: Identifiable { let id = UUID() let date: Date let x: Int let yStart: Date let yEnd: Date let category: String } private var today = Date.now.startOfDay() @State private var data: [DataPoint] = [] @State private var scrollPosition: Date = Date.now @State private var loading = false @State var xAxisDomain: ClosedRange = Date.now...Date.now private let calendar = Cal
Topic: UI Frameworks SubTopic: SwiftUI Tags:
1w
Xcode 26.4 productivity/UX regression.
I switch between Project / Tests / Breakpoints using top left pane 100s times a day. I also switch to search using CMD-Shift-F. In Xcode 26.4 I have to tap the <> to open menu. Is there a way to bring back the old behavior. Does any of the UX guys who worked on that feature use Xcode on daily basis? This is so bad :(
1
0
85
1w
Reply to SwiftUI Text rendering with too small height / one line missing causing unexpected text truncation on iPhone devices
I can always reproduce this with any iPhone device or simulator with 2556x1179 screen for iOS 18.6, 26.4, and 26.5, but not on iOS 17.5. I didn't test other iOS versions so far. On my iPhone 15 device I have now reproduced again with 26.4.2 and earlier 26.4.1 I believe. macOS 26.4.1 (25E253) Xcode 26.5.0 beta 2 and beta 3 or Xcode 26.4.0 (17E192) I'm not sure what variable is different in your setup. In our main app this is part of an UICollectionView To confirm, you see the same result outside of a UIViewRepresentable as well? To make this more clear: Our main app is a bigger UICollectionViewController with UICollectionViewCell's with SwiftUI hosted content configuration. It happens here on the same devices (screen size) and horizontal padding of 20. No dynamic type involved here, because we have our own Typography system (creating Font and UIFont) with fixed font sizes and line heights. We now will ship a UILabel embedded in the same cell via UIViewRepresentable, which doesn't have this bu
Topic: UI Frameworks SubTopic: SwiftUI Tags:
1w
Reply to Xcode now hangs; SDKs are "status unavailable"
I'm wondering if this is actually as much of a macOS 26.4.x issue as well as an Xcode issue. I've tried Xcode 26.4, Xcode 26.4.1, Xcode 26.5 beta 3, cleaning out my installation and data directories each time as suggested in the above posts, and still no joy. Sometimes the simulators go status unavailable after a few hours, other times it happens after a reboot of the computer. I've even gone back to installing Xcode 26.3, but a reboot still causes the problem. I'm leery about installing the beta of macOS 26.5 because this is my production machine. Apple informed me they are aware of this bug, but nothing seems to fix it for me. Has anyone had luck with the macOS 26.5 beta along with the Xcode 26.5 beta regarding this bug? How are people getting their work done with this?
1w
Reply to SwiftData with CloudKit Error: Error updating background task request
@DTS Engineer Albert, thanks for the response. Error Please see the screenshot of the fault log, Subsystem for the log iscom.apple.cloudkit Category for the log is Scheduler Answer to your questions: Cloud sync works and data gets synced, no issue with the data. Yes correct primary sync doesn't happen via BGTaskScheduler. However SwiftData / CloudKit initiates a background task to do some processing. The background is the one that gets blocked. This is a clean new project (no 3rd party libraries) and I have written the code so I am sure of that there is no background task I am initiating. Testing / Sample project: If you really want to test it, please refer to the project attached in FB22634797 Though FB22634797 is for a different issue, the Xcode project would throw the fault log in Xcode. It is a very simple project. Question It would be great if someone from SwiftData / CoreData / CloudKit team can confirm this.
1w
NSFileSandboxingRequestRelatedItemExtension: Failed to issue extension
Hi there, I have an SwiftUI app that opens a user selected audio file (wave). For each audio file an additional file exists containing events that were extracted from the audio file. This additional file has the same filename and uses the extension bcCalls. I load the audio file using FileImporter view modifier and within access the audio file with a security scoped bookmark. That works well. After loading the audio I create a CallsSidecar NSFilePresenter with the url of the audio file. I make the presenter known to the NSFileCoordinator and upon this add it to the FileCoordinator. This fails with NSFileSandboxingRequestRelatedItemExtension: Failed to issue extension for; Error Domain=NSPOSIXErrorDomain Code=3 No such process My Info.plist contains an entry for the document with NSIsRelatedItemType set to YES I am using this kind of FilePresenter code in various live apps developed some years ago. Now when starting from scratch on a fresh macOS26 system with most current Xcode I do not manage to get
9
0
372
1w
Reply to SwiftUI Text rendering with too small height / one line missing causing unexpected text truncation on iPhone devices
This is interesting, thanks for your input @DTS Engineer @kai_ , When I test your latest code snippet, the text does not truncate for me on an iPhone 15, 16, or 17 simulator running iOS 17 - iOS 26. When I compare our view debugger screenshots sent above, I can see your content margins appear to have more padding then what I'm seeing in my Xcode. What version of Xcode and macOS are you using, and are you able to share the Xcode project file here? [quote='886011022, kai_, /thread/823675?answerId=886011022#886011022, /profile/kai_'] In our main app this is part of an UICollectionView [/quote] To confirm, you see the same result outside of a UIViewRepresentable as well? Thanks!  Travis
Topic: UI Frameworks SubTopic: SwiftUI Tags:
1w
XPC connection consistently invalidated on app upgrade
Hi, Our project is a MacOS SwiftUI GUI application that bundles a System Network Extension, signed with a Developer ID certificate for distribution outside of the app store. The system network extension is used to write a packet tunnel provider. The signing of the app & network extension is handled by XCode (v16.0.0), we do not run codesign ourselves. We have no issues with XPC or the system network extension during normal usage, nor when the application is installed on a user's device for the first time. The problem only arises when the user upgrades the application. I have experienced this issue myself, as have our users. It's been reported on Apple Silicon macbooks running at least macOS 15.3.2. Much like the SimpleFirewall example (which we used as a reference), we use XPC for basic communication of state between the app and NE. These XPC connections stop working when the user installs a new version of the app, with OS logs from the process indicating that the connection is immediately invali
Replies
6
Boosts
0
Views
542
Activity
1w
Reply to Xcode 26.4.1, iOS 26.4.2, watchOS 26.4, Apple Watch Ultra 3 not appearing as development device.
Thanks for the post, there are many Apple Watch engineers that I’m just they’ll jump into the thread, however this question seems like how to start with Apple Watch development and pair the Apple Watch to Xcode. When an Apple Watch fails to appear as a development device in Xcode, the issue usually stems from the wireless pairing bridge between Xcode, the iPhone, and the Watch, or a missing Developer Mode toggle. On the iPhone go to Settings → Privacy & Security → Developer Mode and toggle it on. On the Apple Watch go to Settings → Privacy & Security → Developer Mode and toggle it on. Both devices will require a restart. Connect the paired iPhone to your Mac via a physical cable. In Xcode, go to Window → Devices and Simulators. Select your iPhone in the left sidebar. Look at the Paired Watches section. If the Watch is listed but has a yellow warning triangle, hover over it. It may say Preparing device for development. If you have successfully completed all the steps
Replies
Boosts
Views
Activity
1w
Reply to SwiftData with CloudKit Error: Error updating background task request
Thanks @DTS Engineer I have created a feedback FB22670187 It contains a sample project and also attached a video Run it on a real device The video shows the log being generated on Xcode. Look at the subsystem of the log, it is from com.apple.cloudkit It contains details about the fault and how to reproduce it.
Replies
Boosts
Views
Activity
1w
HLS Tools - hlsreport critical error cause
Hi, I'm currently experiencing issues with HLS streams created by FFmpeg running on Safari. When I pass the stream to the mediastreamvalidator tool and then run hlsreport on the output, I get a critical error reported: Media Entry discontinuity value does not match previous playlist for MEDIA-SEQUENCE 1 If I let the stream finish (it's a live stream from an IoT device) and then perform the stream validation again I no longer receive the critical error. My assumption is that this critical error is contributing to the HLS stall on iOS. I have also noticed that if I let the stream continue and then re-load the video control in Safari the stream starts Is there a resource with explanations or remediation paths relevant to the possible output of the hlsreport? My m3u8 output looks like this (I have redacted the server host) #EXTM3U #EXT-X-VERSION:6 #EXT-X-TARGETDURATION:2 #EXT-X-MEDIA-SEQUENCE:1 #EXT-X-PLAYLIST-TYPE:EVENT #EXT-X-INDEPENDENT-SEGMENTS #EXT-X-DISC
Replies
1
Boosts
0
Views
585
Activity
1w
Reply to CLLocationManager permission prompt never appears in Swift Playground
@Marka99 Welcome! Thank you for the post. I believe developers are referring to samples where you can observe how to implement that functionality. https://developer.apple.com/tutorials/sample-apps Also videos are very helpful in my opinion: https://developer.apple.com/search/?q=CLLocation Swift Playgrounds App projects fully support Core Location. Because they compile into real application bundles, they behave exactly like apps built in Xcode. You must provide a Usage Description string. In Xcode, this is done in the Info.plist. In Swift Playgrounds, this is done in the App Settings. If this string is blank, the prompt will never appear. The CLLocationManager instance must be strongly retained in memory. If you declare let manager = CLLocationManager() inside .onAppear, the manager is destroyed the moment the .onAppear closure finishes executing. Do not call startUpdatingLocation() immediately after requesting authorization. Instead, wait for the delegate to confirm you have permission. Albe
Replies
Boosts
Views
Activity
1w
Reply to ScrollView/ClipView weirdness.
Here is a sample program to demonstrate the problem. Using Xcode, create a new document project using interface: xib, language: swift Once that is done, delete Document.xib, go into Document.swift and add the following method: override func makeWindowControllers() { let controller = MyWC(document: self) addWindowController(controller) controller.showWindow(self) controller.window?.makeFirstResponder(nil) } Then make a new Swift file named MyWC.swift with this content: import AppKit class MyWC: NSWindowController { init(document: Document) { let window = NSWindow( contentRect: NSRect(x: 0.0, y: 100.0, width: 700.0, height: 500.0), styleMask: [.titled, .closable, .miniaturizable, .resizable], backing: .buffered, defer: false ) super.init(window: window) window.minSize = NSSize(width: 200, height: 200) let myScrollView = NSScrollView() let contentView = NSView(frame: NSRect(x: 0.0, y: 0.0, width: 800.0, height: 600.0)) let clipView = NSClipView(frame: myScrollView.contentView.frame) clipView.backgroundC
Topic: UI Frameworks SubTopic: AppKit Tags:
Replies
Boosts
Views
Activity
1w
Reply to Charts performance issue
Hi everyone, I observe similar performance issue. They performance is degraded when the x axis domain is enlarged. I add 5 bars per day, and around 150 days there is a visible jitter and tearing while dragging. I've tried various techniques to improve it such as large xAxis and displaying events only around the scroll position, however as noted above using it lowers the performance. I've also tried prepending and apending days, without having a large x axis domain, but this makes the scroll position jump. Here is another code sample. import Charts import SwiftUI struct PerformanceBarChart: View { struct DataPoint: Identifiable { let id = UUID() let date: Date let x: Int let yStart: Date let yEnd: Date let category: String } private var today = Date.now.startOfDay() @State private var data: [DataPoint] = [] @State private var scrollPosition: Date = Date.now @State private var loading = false @State var xAxisDomain: ClosedRange = Date.now...Date.now private let calendar = Cal
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w
Xcode 26.4 productivity/UX regression.
I switch between Project / Tests / Breakpoints using top left pane 100s times a day. I also switch to search using CMD-Shift-F. In Xcode 26.4 I have to tap the <> to open menu. Is there a way to bring back the old behavior. Does any of the UX guys who worked on that feature use Xcode on daily basis? This is so bad :(
Replies
1
Boosts
0
Views
85
Activity
1w
Reply to SwiftUI Text rendering with too small height / one line missing causing unexpected text truncation on iPhone devices
Hi, I’m a colleague of Kai’s. I think the missing piece here is the app language. When I run Kai’s code snippet, I only see truncated text when the app language is set to German (via the scheme’s run options), not when it is set to English. Here are screenshots from the iPhone 16 simulator (Xcode 26.5b3, iOS 26.5).
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w
Reply to SwiftUI Text rendering with too small height / one line missing causing unexpected text truncation on iPhone devices
I can always reproduce this with any iPhone device or simulator with 2556x1179 screen for iOS 18.6, 26.4, and 26.5, but not on iOS 17.5. I didn't test other iOS versions so far. On my iPhone 15 device I have now reproduced again with 26.4.2 and earlier 26.4.1 I believe. macOS 26.4.1 (25E253) Xcode 26.5.0 beta 2 and beta 3 or Xcode 26.4.0 (17E192) I'm not sure what variable is different in your setup. In our main app this is part of an UICollectionView To confirm, you see the same result outside of a UIViewRepresentable as well? To make this more clear: Our main app is a bigger UICollectionViewController with UICollectionViewCell's with SwiftUI hosted content configuration. It happens here on the same devices (screen size) and horizontal padding of 20. No dynamic type involved here, because we have our own Typography system (creating Font and UIFont) with fixed font sizes and line heights. We now will ship a UILabel embedded in the same cell via UIViewRepresentable, which doesn't have this bu
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w
Reply to Xcode now hangs; SDKs are "status unavailable"
FWIW, my Intel MacBook Pro is still at macOS 26.3 and Xcode 26.3, and everything is running correctly with regard to the simulators always being available.
Replies
Boosts
Views
Activity
1w
Reply to Xcode now hangs; SDKs are "status unavailable"
I'm wondering if this is actually as much of a macOS 26.4.x issue as well as an Xcode issue. I've tried Xcode 26.4, Xcode 26.4.1, Xcode 26.5 beta 3, cleaning out my installation and data directories each time as suggested in the above posts, and still no joy. Sometimes the simulators go status unavailable after a few hours, other times it happens after a reboot of the computer. I've even gone back to installing Xcode 26.3, but a reboot still causes the problem. I'm leery about installing the beta of macOS 26.5 because this is my production machine. Apple informed me they are aware of this bug, but nothing seems to fix it for me. Has anyone had luck with the macOS 26.5 beta along with the Xcode 26.5 beta regarding this bug? How are people getting their work done with this?
Replies
Boosts
Views
Activity
1w
Reply to SwiftData with CloudKit Error: Error updating background task request
@DTS Engineer Albert, thanks for the response. Error Please see the screenshot of the fault log, Subsystem for the log iscom.apple.cloudkit Category for the log is Scheduler Answer to your questions: Cloud sync works and data gets synced, no issue with the data. Yes correct primary sync doesn't happen via BGTaskScheduler. However SwiftData / CloudKit initiates a background task to do some processing. The background is the one that gets blocked. This is a clean new project (no 3rd party libraries) and I have written the code so I am sure of that there is no background task I am initiating. Testing / Sample project: If you really want to test it, please refer to the project attached in FB22634797 Though FB22634797 is for a different issue, the Xcode project would throw the fault log in Xcode. It is a very simple project. Question It would be great if someone from SwiftData / CoreData / CloudKit team can confirm this.
Replies
Boosts
Views
Activity
1w
NSFileSandboxingRequestRelatedItemExtension: Failed to issue extension
Hi there, I have an SwiftUI app that opens a user selected audio file (wave). For each audio file an additional file exists containing events that were extracted from the audio file. This additional file has the same filename and uses the extension bcCalls. I load the audio file using FileImporter view modifier and within access the audio file with a security scoped bookmark. That works well. After loading the audio I create a CallsSidecar NSFilePresenter with the url of the audio file. I make the presenter known to the NSFileCoordinator and upon this add it to the FileCoordinator. This fails with NSFileSandboxingRequestRelatedItemExtension: Failed to issue extension for; Error Domain=NSPOSIXErrorDomain Code=3 No such process My Info.plist contains an entry for the document with NSIsRelatedItemType set to YES I am using this kind of FilePresenter code in various live apps developed some years ago. Now when starting from scratch on a fresh macOS26 system with most current Xcode I do not manage to get
Replies
9
Boosts
0
Views
372
Activity
1w
Reply to SwiftUI Text rendering with too small height / one line missing causing unexpected text truncation on iPhone devices
This is interesting, thanks for your input @DTS Engineer @kai_ , When I test your latest code snippet, the text does not truncate for me on an iPhone 15, 16, or 17 simulator running iOS 17 - iOS 26. When I compare our view debugger screenshots sent above, I can see your content margins appear to have more padding then what I'm seeing in my Xcode. What version of Xcode and macOS are you using, and are you able to share the Xcode project file here? [quote='886011022, kai_, /thread/823675?answerId=886011022#886011022, /profile/kai_'] In our main app this is part of an UICollectionView [/quote] To confirm, you see the same result outside of a UIViewRepresentable as well? Thanks!  Travis
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w