Over the past week, Xcode has started to hang every time I start a build - it doesn't matter if I use a keyboard shortcut, or are running a single test, or clicking on a single test to build and run - after I start a build process, the cursor waits about 1 sec, then turns into a beachball for about 10 seconds, and then the build starts. I've tried deleting Derived Data, cleaning up old simulators, even completely reinstalling Xcode 13.2.1, but nothing has helped. I do have Git/Github integration turned on, but turning it off did not solve it. It only appears to be one project (my main work project) that does this, so I'm thinking there's some cruft built up somewhere in the project itself. It does have about 15 Swift Packages included in it - could it be attempting to check versions before every build? I would think that unlikely, since I already get the obligatory "Updating packages" when I first open the project.
Any thoughts as to any other things in a project that might lead to such a long freeze before building starts? Thanks!
Post
Replies
Boosts
Views
Activity
I am working on a CarPlay app that plays back audio content. When attempting to use the CPNowPlayingPlaybackRateButton button, it works well for changing the speed, except for when the audio is paused. Then it shows the speed as 0x, which is technically true but not great for the UI. In looking at how other audio apps handle this, in the case where the app is using the CPNowPlayingPlaybackRateButton and not an image button, they mostly hide the button when paused. The only apps that don't (that I've found) are Apple's Podcasts and Audiobooks apps, which manage to keep the rate button showing the value it had when playing. So, it's possible? I tried setting the defaultRate property of the AVPlayer, along with the rate property, but that didn't seem to help. I'd like to use the standard button instead of an image button if possible. Any suggestions most welcomed!
As part of dropping support for iOS15, I'm trying to move our app to use the newer navigation architecture for some of its SwiftUI views. However, these views are shown in the context of the main part of the app being written in UIKit. So, when the SwiftUI view is pushed on the nav stack, it needs to interact with the existing UINavigationController, even when navigating to additional SwiftUI-based screens. This works with the simple NavigationLink that takes both a destination view and a label. However, now that the init(isActive:destination:label:) initializer is deprecated, trying to move to the value-based NavigationLink/navigationDestination functions for some more of our data-driven navigations just doesn't work.
Here's a link to a repo with a sample app demonstrating the problem:
https://github.com/lj-dickey/UIKitNav
I'm wondering if there is any way of working around this with a purely SwiftUI solution? Otherwise, if we want to get rid of the deprecation warnings, we'll need to kick back to UKIt to manage SwiftUI -> SwiftUI navigation, which seems particularly unfortunate.
Thanks for any advice!