ICS4: Must revert state if sequence mismatch upgrade error returns
Closed this issue · 0 comments
AdityaSripal commented
Currently when the TRY returns an upgrade mismatch error, the previous writes done before are still retained.
This is especially problematic in the non-crossing-hello case, because then the higher-sequence side will be left initialized with an upgrade that is explicitly rejected from the counterparty with the lower sequence.
The solution is to revert state and only write the upgrade error receipt when returning
See the commits that caught and fixed this behaviour in the following commits: