Not sure how to accurately describe this so I apologize for the vague-ness, but in a SwiftUI app built on iOS 15, when users select a NavigationLink from a list, the app freezes. BUT, this only happens on some iPhone 12 and 13's. This does not happen on any iPhone I have personally tested (11, 12, 12 pro max, etc) but users have sent me video of it happening.
In addition to this, the view that this nav link opens, DOES work for these users when it goes through another level of navigation.
So for this user:
MainView->ThisView : this action freezes
MainView->AnotherView->ThisView : This action works
Whereas 90% of other users, the nav link works fine and as expected.
One user submitted a crash log from TestFlight which shows the following information, but I am not sure what this is indicating:
#0 (null) in specialized _ArrayBuffer._consumeAndCreateNew+ 507128 (bufferIsUnique:minimumCapacity:growForAppend:) ()
#1 (null) in DisplayList.ViewUpdater.Model.State.addClip+ 663792 (_:style:) ()
#2 (null) in static DisplayList.ViewUpdater.Model.merge+ 1281064 (item:into:) ()
#3 (null) in DisplayList.ViewUpdater.updateInheritedView+ 421056 (container:from:parentState:) ()
#4 (null) in DisplayList.ViewUpdater.update+ 196956 (container:from:parentState:) ()
#5 (null) in DisplayList.ViewUpdater.updateInheritedView+ 421432 (container:from:parentState:) ()
#6 (null) in DisplayList.ViewUpdater.update+ 196956 (container:from:parentState:) ()
#7 (null) in closure #1 in DisplayList.ViewUpdater.render+ 149008 (rootView:from:time:version:maxVersion:contentsScale:) ()
#8 (null) in DisplayList.ViewUpdater.render+ 67780 (rootView:from:time:version:maxVersion:contentsScale:) ()
#9 (null) in DisplayList.ViewRenderer.render+ 779076 (rootView:from:time:nextTime:version:maxVersion:contentsScale:) ()
#10 (null) in closure #1 in UIHostingView.renderDisplayList+ 967228 (:asynchronously:time:nextTime:version:maxVersion:) ()
#11 (null) in UIHostingView.renderDisplayList+ 408916 (:asynchronously:time:nextTime:version:maxVersion:) ()
#12 (null) in closure #1 in ViewRendererHost.render+ 94160 (interval:updateDisplayList:) ()
#13 (null) in ViewRendererHost.render+ 905080 (interval:updateDisplayList:) ()
#14 (null) in _UIHostingView.layoutSubviews+ 167448 () ()
#15 (null) in @objc _UIHostingView.layoutSubviews+ 183076 () ()
#16 (null) in -[UIView(CALayerDelegate) layoutSublayersOfLayer:] ()
#17 (null) in CA::Layer::layout_if_needed(CA::Transaction*) ()
#18 (null) in CA::Layer::layout_and_display_if_needed(CA::Transaction*) ()
#19 (null) in CA::Context::commit_transaction(CA::Transaction*, double, double*) ()
#20 (null) in CA::Transaction::commit() ()
#21 (null) in _UIApplicationFlushCATransaction ()
#22 (null) in _UIUpdateSequenceRun ()
#23 (null) in schedulerStepScheduledMainSection ()
#24 (null) in runloopSourceCallback ()
#25 (null) in CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION ()
#26 (null) in __CFRunLoopDoSource0 ()
#27 (null) in __CFRunLoopDoSources0 ()
#28 (null) in __CFRunLoopRun ()
#29 (null) in CFRunLoopRunSpecific ()
#30 (null) in GSEventRunModal ()
#31 (null) in -[UIApplication _run] ()
#32 (null) in UIApplicationMain ()
#33 (null) in 0x100b6c000 ()
#34 (null) in start ()
Can anyone point me in the right direction to start trying to figure out what is causing this issue? Any insight is appreciated.
Post
Replies
Boosts
Views
Activity
This newly added feature, is a nice step in the right direction. Wondering if anyone has any idea how to actually allow the user to "select" the text as opposed to selecting all text and offering Copy/Share?
When querying Transaction.all, the output posts the following error:
2021-06-27 20:00:17.765248-0400 Test App[1203:12345] [Default] Error enumerating all transactions: Error Domain=AMSErrorDomain Code=204 "Bag Value Missing" UserInfo={NSLocalizedDescription=Bag Value Missing, NSLocalizedFailureReason=The bag does not contain in-app-history-max-age nor did anyone register a default value. <AMSBagFrozenDataSource: 0x107e5d370; profile: AMSFrozenBagValue; version: 1>}
How might one provide an "in-app-history-max-age" or set a default?
SK2 sounds so easy. I understand they're many different use cases, but why is it made to be so overly complicated?
For instance:
When getting currentEntitlements, why does it return every transaction for this item, even if it is expired? Shouldn't currentEntitlements just return me one transaction which is valid, not expired? If I want all of the transactions for X Product, I should be able to query Transactions.all, or how about Transactions(for: Product)?
Why does Transaction.all not conform to Sequence? Meaning, why cant I just iterate through all Transactions like: for transaction in await Transacion.all { //do stuff }, yet for await transaction in Transaction.all { //do dtuff } does work
It seems so convoluted to get a status of an auto-renewing subscription. Why cant it just be: get Product X, for Product X, get the RenewalInfo, then what is the autoRenewStatus of this product? sounds simple, right? yet in reality, its much more complicated, with verifying responses and guard case and plenty of other extra nonsense that just makes the code grow for no reason. What would be nice here is:
get product from app store: let product = await Product(for: "com.sample.product") (Now, I know that this product is an auto-renewable subscription item, so I want to know what the auto-renew status for it is, so I can display to the user their status)
get autoRenew status from this Product: let willAutoRenew = product.subscription.isAutoRenew
Now, the user may not own this product, so even better would be to be able to get this info from the currentEntitlement, latestTransaction:
if let mySubEntitlement = try await Transaction.currentEntitlement(for: "this.productID") {
//user must have an entitlement to this item
//ensure that the response is verified:
guard case .verified(let verified) = mySubEntitlement else { return }
//give me the the RenewalInfo details of this verified response:
let myRenewalnfo = verified.subscription.renewalInfo
//print out the willAutoRenew details:
print("Will this auto-renew?: \(myRenewalInfo.willAutoRenew)")
In reality, it is really not this simple, but there is no reason that it should not be. Hoping for better in upcoming releases.
Also, why is it so difficult to get access to the JSON data packed into the product and transaction data? I can see it all there when I print it out to the output, but I can't for instance say something like: print(product.payload.thisField)
I look forward to adding so many of the new iOS15 features to my app to assist my customers in managing their purchases, but implementation is just much more complicated than it really needs to be. I hope in the coming betas and final release, some of this will be made much more straight forward.
Beta 2 seems to have removed Transaction.listener, it seems that it may have been replaced with Transaction.updates, but not sure because it does not seem to grab incoming transactions like the listener did.. Is there a special way to implement the updates method as opposed to the Transaction.listener method?
Has anyone else noticed that for the past two days the subscription service, server to server Apple notifications, has not included a purchase or expiration date?