object deinit on async queue cause Fatal error: Running on background thread.
Expected outcome:
rxswift dispose on main queue
What actually happens:
When i use RxDatasource to bind UITableView, then handle data on async queue, at the sametime that viewController deinit, but object deinit on async...
// just click button present viewController and dismiss
// that a simulation code in TestViewController.swift
deinit {
coordinator.refresh()
}
// will crash in RxSwift/MainScheduler.swift at line 54
Platform/Environment
[x] iOS
[ ] macOS
[ ] tvOS
[ ] watchOS
[ ] playgrounds
How easy is to reproduce? (chances of successful reproduce after running the self contained code)
[ ] easy, 100% repro
[x] sometimes, 10%-100%
[ ] hard, 2% - 10%
[ ] extremely hard, %0 - 2%
Xcode version:
Xcode version 13.2.1
Installation method:
[x] CocoaPods
[ ] Carthage
[ ] Git submodules
I have multiple versions of Xcode installed:
(so we can know if this is a potential cause of your issue)
[ ] yes (which ones)
[x] no
Level of RxSwift knowledge:
(this is so we can understand your level of knowledge
and formulate the response in an appropriate manner)
Short description of the issue:
object deinit on async queue cause Fatal error: Running on background thread.
Expected outcome:
rxswift dispose on main queue
What actually happens:
When i use RxDatasource to bind UITableView, then handle data on async queue, at the sametime that viewController deinit, but object deinit on async...
Self contained code example that reproduces the issue: https://github.com/cyg02032015/rxswift_crash_test.git
Platform/Environment
How easy is to reproduce? (chances of successful reproduce after running the self contained code)
Xcode version:
Installation method:
I have multiple versions of Xcode installed: (so we can know if this is a potential cause of your issue)
Level of RxSwift knowledge: (this is so we can understand your level of knowledge and formulate the response in an appropriate manner)