Closed 10gic closed 2 months ago
Fix issue https://github.com/trustwallet/wallet-core/issues/4004
The test case SignMessageToTransferAndDeployWalletV5R1 occasionally fails.
A HashMap is unordered, so iterating over it multiple times may yield different results. https://github.com/trustwallet/wallet-core/blob/af67cae30f132ec139b72b4b93d2b336b84a8c49/rust/frameworks/tw_ton_sdk/src/boc/boc_to_raw_boc.rs#L85
Change the HashMap to an ordered data structure, such as a BTreeMap.
Fix issue https://github.com/trustwallet/wallet-core/issues/4004
The test case SignMessageToTransferAndDeployWalletV5R1 occasionally fails.
Root Cause
A HashMap is unordered, so iterating over it multiple times may yield different results. https://github.com/trustwallet/wallet-core/blob/af67cae30f132ec139b72b4b93d2b336b84a8c49/rust/frameworks/tw_ton_sdk/src/boc/boc_to_raw_boc.rs#L85
Resolution
Change the HashMap to an ordered data structure, such as a BTreeMap.