It was reported that due to the way certain system handlers enumerate and setup subscriptions for observables you could have a system added which starts up and processes the entities associated but they get removed when processing which triggers the OnEntityRemoved event which then wants to clean up the associated entity subscriptions in the handler, the problem here being the ProcessEntity methods are generally not finished by this point so subscriptions are not added to the dictionaries.
To side step this we pre-enumerate the observable groups (to bypass underlying enumerator change exceptions) and then pre-emptively create CompositeDisposable sub containers to be added to the sub lists before the processing happens, this now solves the issues for IReactToEntitySystem, IReactToDataSystem and ISetupSystem.
It was reported that due to the way certain system handlers enumerate and setup subscriptions for observables you could have a system added which starts up and processes the entities associated but they get removed when processing which triggers the
OnEntityRemoved
event which then wants to clean up the associated entity subscriptions in the handler, the problem here being theProcessEntity
methods are generally not finished by this point so subscriptions are not added to the dictionaries.To side step this we pre-enumerate the observable groups (to bypass underlying enumerator change exceptions) and then pre-emptively create
CompositeDisposable
sub containers to be added to the sub lists before the processing happens, this now solves the issues forIReactToEntitySystem
,IReactToDataSystem
andISetupSystem
.