Fix widget value corruption when input order changes (#4983) #4991
+39
−7
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The Problem:
• Widget values were stored as a simple array by index position
• Widget creation order depended on JSON key ordering from backend
• When JSON key order changed, widgets got created in different order
• Same indexed values got assigned to wrong widgets = corruption
The Fix:
• Changed from index-based to name-based widget value storage
• Now stores {name: "seed", value: 12345} instead of just 12345
• On load, matches values by widget name instead of position
• Fully backward compatible - old workflows still work fine
fix #4983
┆Issue is synchronized with this Notion page by Unito