I got a similar crash recently.
My case is a UIStackView contained in a UITableViewCell.
When binding data to the cell, since the content of the UIStackView is dynamic, I remove all the arrangedSubviews in the stack before populating it again with the new content.
For every arranged subview this following block is executed:
stack.removeArrangedSubview(subview)
subview.removeFromSuperview()
Crash is indicated to occur on the last of the above lines.
Note that this crash hit randomly, i.e. it cannot be systematically reproduced every time.
Attached is the crash log.
Hope this could help.
Crash log - https://developer.apple.com/forums/content/attachment/349040d7-6ef9-42b0-8899-3d5423815c91
Topic:
UI Frameworks
SubTopic:
UIKit
Tags: