You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, when we write the WarpCoreConfig to the Registry after warp deploy or warp apply, we are using sortMapEntries: true, which is called via writeDeploymentArtifacts().
This flag will "sort by comparing key values using the native less-than < operator." However, this flag is not predictable and creates inconsistent sorting, which creates large git diffs when we update the WarpCoreConfig (and other configs).
For example, consider this PR that adds Uni and Bera chain to PZETH. In this case, berachain-ethereum-swell-unichain-zircuit-config.yaml is a completely new file instead of a renamed file with additions.
Note
It is understood that github shows diffs in a heuristic and unpredictable manner, especially when there is a rename + large diff. The point of this PR is not to spend too much figuring out how Github show diffs, but to solve the sorting problem such that if we did not rename the file, we'd see the correct diffs.
Solution
Configure toYamlString() in the Registry to sort correctly.
Nice to Have
Consider all the places where we use sortMapEntries: true and use the same configuration
The text was updated successfully, but these errors were encountered:
Problem
Currently, when we write the WarpCoreConfig to the Registry after
warp deploy
orwarp apply
, we are usingsortMapEntries: true
, which is called viawriteDeploymentArtifacts()
.This flag will "sort by comparing key values using the native less-than < operator." However, this flag is not predictable and creates inconsistent sorting, which creates large git diffs when we update the WarpCoreConfig (and other configs).
For example, consider this PR that adds Uni and Bera chain to PZETH. In this case,
berachain-ethereum-swell-unichain-zircuit-config.yaml
is a completely new file instead of a renamed file with additions.Note
It is understood that github shows diffs in a heuristic and unpredictable manner, especially when there is a rename + large diff. The point of this PR is not to spend too much figuring out how Github show diffs, but to solve the sorting problem such that if we did not rename the file, we'd see the correct diffs.
Solution
toYamlString()
in the Registry to sort correctly.Nice to Have
sortMapEntries: true
and use the same configurationThe text was updated successfully, but these errors were encountered: