Good morning,
We are implementing Live Activities in a push-to-start flow. We wrap the listener for push to start tokens in a high priority task:
if ptsListenerTask == nil || ptsListenerTask?.isCancelled == true {
ptsListenerTask = Task(priority: .high) { [weak self] in
for await pushToken in Activity<LiveAuctionAttributes>.pushToStartTokenUpdates {
//Send token to back-end
}
}
I've tried a few variations of this and they work well on most devices. I have seen a couple of devices that refuse to issue a push to start token.
The user will have logging for the init flow and starting the PTS listener then the logs just go silent, nothing happens.
One thing that seemed to work was getting the user to start a Live Activity manually (from our debugging tool) then the PTS token gets issued.
This is not very reliable and working a mock live activity into the flow for obtaining a PTS token is a poor solution.
Is anyone else seeing this and is there a known issue with obtaining PTS tokens?
Thanks!
Brad
Widgets & Live Activities
RSS for tagDiscuss how to manage and implement Widgets & Live Activities.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
Im having trouble enabling Live Activities in a new app. The option is not available in Xcode or in the developer portal. Is there something I have to do to activate this option?
Topic:
App & System Services
SubTopic:
Widgets & Live Activities