Post

Replies

Boosts

Views

Activity

Xcode 16 Beta 3 Watch App - No Simulator Runtime Version Even though Simulator is installed.
Today I installed Xcode 16 Beta 3. I have the watchOS 11 simulator installed on my Mac. When building my watch app with Xcode Beta 3 I am getting the following error. /Applications/Xcode-16-beta-3.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Library/Application Support/MessagesApplicationStub/MessagesApplicationStub.xcassets: No simulator runtime version from [<DVTBuildVersion 21F79>] available to use with iphonesimulator SDK version <DVTBuildVersion 22A5307d> I have no idea what those assets are for but they aren't part of my project. I tried generating a new standalone watch app project using Xcode 16 Beta 3 and I am getting the same error message so this isn't something particular to my original watch project. Any help on how to fix this issue is appreciated.
1
0
1.2k
Jul ’24
On watchOS NavigationSplitView Always Creates Detail Views from Scratch
I am writing a watchOS app using NavigationSplitView. I notice that whenever I switch to a new item in the list, that its associated detail view is always recreated. In other words if I am in the detail view for List item 1, switch back to the List, tap on item 2, switch back to the List from item 2, and choose List item 1 again the detail view associated with item 1 is recreated from scratch. I verified this same behavior with the sample Back Yard Birds app from WWDC 23. I was expecting that with a short list of items (like I have) that the views wouldn't need to be recreated each time and would just be brought back into the view hierarchy. I am wondering if the behavior I am observing is expected or if there is something I can do to not have the views recreated each time. Any insights are appreciated. Thanks, Rob
0
0
407
Sep ’23
How to Play Audio File on Apple Watch Physical Speaker
I am writing a watchOS app where I have some audio files that I want to play at various points. I am using AVAudioPlayer. It all works in the simulator and it also works if I have Air Pods connected to my watch via Bluetooth. However I get no sound if there isn't a paired set of earphones. In the case of no earphones I would like the sounds to play from the physical watch speaker. I can't seem to find any documentation on how to cause that to happen. Any hints or tips are appreciated.
0
0
683
Sep ’23
Swift Package Manager watchOS v9 not available
Hello, I am trying to use the new Swift regex features in a Swift package built for watchOS. They require watchOS 9. When I try to specify .watchOS(.v9) as part of the platforms in the Package.swift file I get an error that says v9 is unavailable. The documentation says that v9 is available in SwiftPM 5.7. I am using both Xcode 14.0.1 and 14.1 RC3 which I thought would have the latest SwiftPM with the newest OS constants. Can someone help me understand what how to ensure I am using SwiftPM 5.7? thx
0
0
933
Oct ’22
SwiftUI watchOS 7 Multi-page App Can't Swipe Issue
Hello, I have a watchOS 7 app that has multiple pages. It's is built using Xcode 12 Beta 2 as a SwiftUI App and uses a TabView to define each page of the app. When I run the app in the simulator I can swipe right to left to move from the first page to the second. Once on the second page however I swiping from to left to right doesn't move back to the first page. Nothing happens. The interface remains stuck on the second page. I am pretty sure this used to work in Xcode Beta 1. I don't have an actual watch device running watchOS 7 to see if this is a simulator only issues. Here's the code that sets up the main App structure for reference. @main struct MyApp: App {     @StateObject private var model = Model()     @SceneBuilder var body: some Scene {         WindowGroup {             TabView {                 PageOneContentView().environmentObject(settingsModel)                     .tabItem {                         Image(systemName: "1.square.fill")                         Text("First")                     }                 PageTwoContentView(model: model)                     .tabItem {                         Image(systemName: "2.square.fill")                         Text("Second")                     }             }         }         WKNotificationScene(controller: NotificationController.self, category: "myCategory")     } }
1
0
1.7k
Jul ’20
Widgets Code Along Part 2 - EmojiRangerWidgetEntryView doesn't display correctly
In working through the 2nd code along, I put in place the code which allows for the widget to be formatter for system medium. When I run the code all I end up with is the enlarged widget view with a completely orange background and no content. I also tried the finished final project that was provided and it resulted in the same output. Any ideas as to what might be going on with the sample? Thanks, Rob
2
0
592
Jun ’20
Copy local watch app data files to Mac
I am developing a watch app which writes out data files to local storage on the watch as it runs. When I am running in the simulator the I can easily locate these files and inspect them. However I also want to be able to copy off and look at the files created on the watch device itself. To date I have found no way to copy the file off of the watch device. I thought perhaps with Xcode there might be a way to copy the watch apps container off of the device to the Mac but that doesn't appear to be possible. The watch app is an independent app and I would like to avoid having to transfer the file using a WCSession to an iPhone app. I am hoping someone could point me to something that I am overlooking. If nothing else is it possible to copy it off to iCloud Drive by the watch app? Any tips or pointers is much appreciated.ThanksRob
0
0
764
Feb ’20
SwiftUI Watch Navigator Bar Title Text Color
Hello,I am building a Watch app using SwiftUI. I would like to set the text color of the title displayed in the navigation bar. My understanding is that the color used is the tint color for the app. However I haven't found away to specify this in a SwiftUI based app. Does anyone know how it can be done?Thanks,Rob
0
0
866
Feb ’20
CoreData error: API Misuse: Attempt to serialize store access on non-owning coordinator (PSC = 0x174262940, store PSC = 0x0)
Hello,I am observing the following error message in the console window of Xcode when running my app (on iOS).CoreData: error: API Misuse: Attempt to serialize store access on non-owning coordinator (PSC = 0x174262940, store PSC = 0x0)I can't seem to pin down the specific operations that are causing it. It almost seems like it is something that Core Data is emitting at some point after whatever the offending operation is. The Core Data setup in the app is done using a UIManagedDocument and in addition I am adding some private queue concurrency contexts where the parent is the managed context in the document (which is the main). Auto save of the UIManagedDocument is turned on. In addition at certain points the app is also doing explicit save of these private contexts. I don't see any ill affects due to the message but I would like to get to the bottom of the issue. I did do searching and there was an old posting where someone fixed it by saving their managed context before using a fetched results controller it was associated with. This seems wrong to me as having to a do a save before using the fetched results controller might catch updates to the managed objects that are in the middle of being made and aren't ready for saving yet because a save could end up violating a relationship constraint.Someone also suggested to make sure the entities were being created with NSEntityDescription.insertNewObject which I double checked that they are.I have -com.apple.CoreData.ConcurrencyDebug set to 1 and when there were other concrrency issues it helped. However with this particular situation it just emits the message and continues. Is there a way to get Core Data to break in the debugger for his message? Any ideas on how I might get to the bottom of this issue or settings I can enabled are greatly appreciated.Thanks Robert
6
0
7.4k
Oct ’17
Accessibility Inspector says device not setup
Hello,I have an iPhone 6 that I've been using for development for quite a while not and have no issues deploying my code on it and debugging with Xcode. However recently the Accessibility Inspector has a "(not setup)" next to this iPhone in the drop down list. If I pick the device it puts up an alert that says:Device Not SetupThis device must be setup for development using Xcode.I am very confused by this message because I am able to deploy and debug on it. I see nothing in Xcode about needing to setup the device. Any ideas on how to solve this are greatly appreciated.Regards,Rob
4
0
3.2k
Feb ’17