To answer my own questions, this is the best way I have found so far.
// Setup playback
let item = AVPlayerItem(url: videoURL)
let player = AVPlayer(playerItem: item)
avPlayerViewController.player = player
player.play()
// hides the transport bar
avPlayerViewController.playbackControlsIncludeTransportBar = false
// sets behaviour to disable skipping / scrubbing
avPlayerViewController.skippingBehavior = .skipItem
// optionally set as delegate to skip to next or previous item
avPlayerViewController.delegate = self
https://github.com/piterwilson/DisableTransportBarDemo
Post
Replies
Boosts
Views
Activity
RemoteHumanReadableError: Failed to update preview.
Error encountered when sending 'previewInstances' message to agent.
==================================
| RemoteHumanReadableError
|
| LoadingError: failed to load library at path "/Users/jcospina/Library/Developer/Xcode/DerivedData/MML-csmxzsfovwegmkeoxobdomlyhxak/Build/Intermediates.noindex/Previews/SPMCore/Products/Debug-iphonesimulator/PackageFrameworks/SPMCore_3955A1BDE21E4280_PackageProduct.framework/SPMCore_3955A1BDE21E4280_PackageProduct": Optional(dlopen(/Users/jcospina/Library/Developer/Xcode/DerivedData/MML-csmxzsfovwegmkeoxobdomlyhxak/Build/Intermediates.noindex/Previews/SPMCore/Products/Debug-iphonesimulator/PackageFrameworks/SPMCore_3955A1BDE21E4280_PackageProduct.framework/SPMCore_3955A1BDE21E4280_PackageProduct, 0): Library not loaded: @rpath/Anchorage.framework/Anchorage
| Referenced from: /Users/jcospina/Library/Developer/Xcode/DerivedData/MML-csmxzsfovwegmkeoxobdomlyhxak/Build/Intermediates.noindex/Previews/SPMCore/Products/Debug-iphonesimulator/PackageFrameworks/SPMCore_3955A1BDE21E4280_PackageProduct.framework/SPMCore_3955A1BDE21E4280_PackageProduct
| Reason: image not found)
Same issue here. (Xcode 12.5)
It is really unfortunate what a gigantic step back Xcode 14 has been in terms of watch development. It can be more than 30 minutes for Xcode to finish loading metadata and all the rest, only to get stuck with "waiting for first unlock". Yes, developer mode is enabled, yes both phone and watch are unlocked, no plugging and un-plugging doesn't work.
For all of you suffering with this issue, I'll share a workaround which is good if you don't need to check output from the Watch device on the Xcode debugger console and the watch App is setup as an extension (not standalone).
First, delete your Watch app from the Watch
Build and Run the app to the Phone (not the Watch)
When the Phone app is installed, go to the Watch app (the official Apple Watch app where you can change the Watch Faces)
Scroll all the way to the bottom, there you should see your Watch app as "Available" to install, hit that Install button
This will also take a little bit to complete, BUT it will be much faster than waiting for Xcode 14!
At the end you will have your Watch app installed on the Watch and the debugger attached to the Phone. That might be enough for some people. It was enough on my case, I was testing some UserInfo Transfer and could see the requests arriving on the Phone side and into the Xcode debugger console.
I hope that helps someone!
Greetings from 2022. I have now the exact same thing happen to me. Do you have an update you can share on if you were able to solve this issue?
I see this a lot and found the following workaround (after ensuring the developer mode settings):
First install the Phone build. That is Build & Run the Phone target to your phone that is paired with Watch
Then, switch targets and Build & Run the Watch target.
This seems to make the app ready to run in the eyes of Xcode. It just seems like the message displayed by Xcode is a red herring and the real issue is not communicated properly.