Re-adding trackable immediately after removing it causes NullPointerException
AndyTWF opened this issue · comments
When RemoveTrackableWorker is called, the trackables stateflow is removed, but the trackable itself isn't removed until DisconnectSuccessWorker - which happens after various async work. Control returns to the caller of publisher.remove() during RemoveTrackableWorker.
In the unlikely event that the trackable call is re-added after RemoveTrackableWorker but before the rest, a NPE is thrown in AddTracakbleWorker because the trackable state flow no longer exists.
➤ Automation for Jira commented:
The link to the corresponding Jira issue is https://ably.atlassian.net/browse/SDK-3306