Background
Some code paths attempt to subscribe to collection members whose IDs are invalid (e.g., report_undefined, ..._null, ..._NaN).
Even with skippableCollectionMemberIDs configured, these invalid keys still create a subscription and emit an initial callback, adding overhead and noise.
Problem
Subscriptions are created for invalid keys like report_undefined, which still emit an initial callback and add overhead.
Solution
Add a guard in OnyxUtils.subscribeToKey that checks skippableCollectionMemberIDs and, if the collection member ID is skippable (e.g., 'undefined', 'null', 'NaN'), do not connect the subscription or emit the initial value, but return a subscriptionID so disconnect() is safe.
Results
Reduces fireCallbacks invocations by ~12% skipping all the invalid collection IDs
Next steps
Do testing and comparison of the effect of this change in real account
Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~021986409233270874405
- Upwork Job ID: 1986409233270874405
- Last Price Increase: 2025-11-06
Issue Owner
Current Issue Owner: @hoangzinh
Issue Owner
Current Issue Owner: @waterim
Background
Some code paths attempt to subscribe to collection members whose IDs are invalid (e.g., report_undefined, ..._null, ..._NaN).
Even with skippableCollectionMemberIDs configured, these invalid keys still create a subscription and emit an initial callback, adding overhead and noise.
Problem
Subscriptions are created for invalid keys like report_undefined, which still emit an initial callback and add overhead.
Solution
Add a guard in OnyxUtils.subscribeToKey that checks skippableCollectionMemberIDs and, if the collection member ID is skippable (e.g., 'undefined', 'null', 'NaN'), do not connect the subscription or emit the initial value, but return a subscriptionID so disconnect() is safe.
Results
Reduces fireCallbacks invocations by ~12% skipping all the invalid collection IDs
Next steps
Do testing and comparison of the effect of this change in real account
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @hoangzinhIssue Owner
Current Issue Owner: @waterim