From 55545562dba27ca3a5693fc4867be6f34f282a8d Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 26 Feb 2024 17:31:21 +0200 Subject: [PATCH 001/103] Remove the SC check for XMEX unwrap endpoint --- locked-asset/locked-token-wrapper/src/lib.rs | 5 ----- 1 file changed, 5 deletions(-) diff --git a/locked-asset/locked-token-wrapper/src/lib.rs b/locked-asset/locked-token-wrapper/src/lib.rs index 980736f63..a6aa3e96f 100644 --- a/locked-asset/locked-token-wrapper/src/lib.rs +++ b/locked-asset/locked-token-wrapper/src/lib.rs @@ -44,11 +44,6 @@ pub trait LockedTokenWrapper: #[endpoint(unwrapLockedToken)] fn unwrap_locked_token_endpoint(&self) -> EsdtTokenPayment { let caller = self.blockchain().get_caller(); - require!( - !self.blockchain().is_smart_contract(&caller), - "SCs cannot unwrap locked tokens" - ); - let payment = self.call_value().single_esdt(); let locked_token_id = self.get_locked_token_id(); let original_locked_tokens = self.unwrap_locked_token(locked_token_id, payment); From 6a2cd7c18851afd226c0f91ab6d83ea8d4a3b9cd Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 5 Mar 2024 00:44:40 +0200 Subject: [PATCH 002/103] Safe price with weighted LP supply --- Cargo.lock | 166 +++++++++++------------- dex/pair/src/pair_actions/add_liq.rs | 1 + dex/pair/src/pair_actions/remove_liq.rs | 2 + dex/pair/src/pair_actions/swap.rs | 3 + dex/pair/src/safe_price.rs | 55 +++++++- dex/pair/src/safe_price_view.rs | 52 +++++--- 6 files changed, 168 insertions(+), 111 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index fe863b981..dbfbf95f6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -52,9 +52,9 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.6" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8901269c6307e8d93993578286ac0edf7f195079ffff5ebdeea6a59ffb7e36bc" +checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" [[package]] name = "anstyle-parse" @@ -562,9 +562,9 @@ dependencies = [ [[package]] name = "ed25519-dalek" -version = "2.1.1" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a3daa8e81a3963a60642bcc1f90a670680bd4a77535faa384e9d1c79d620871" +checksum = "1f628eaec48bfd21b865dc2950cfa014450c01d2fa2b69a86c2fd5844ec523c0" dependencies = [ "curve25519-dalek", "ed25519", @@ -971,9 +971,9 @@ dependencies = [ [[package]] name = "fiat-crypto" -version = "0.2.6" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1676f435fc1dadde4d03e43f5d62b259e1ce5f40bd4ffb21db2b42ebe59c1382" +checksum = "27573eac26f4dd11e2b1916c3fe1baa56407c83c71a773a8ba17ec0bca03b6b7" [[package]] name = "fixed-supply-token" @@ -1206,9 +1206,9 @@ checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" [[package]] name = "hermit-abi" -version = "0.3.5" +version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0c62115964e08cb8039170eb33c1d0e2388a256930279edca206fff675f82c3" +checksum = "5d3d0e0f38255e7fa3cf31335b3a56f05febd18025f4db5ef7a0cfb4f8da651f" [[package]] name = "hex" @@ -1336,9 +1336,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.2.2" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "824b2ae422412366ba479e8111fd301f7b5faece8149317bb81925979a53f520" +checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" dependencies = [ "equivalent", "hashbrown", @@ -1361,9 +1361,9 @@ dependencies = [ [[package]] name = "itertools" -version = "0.12.1" +version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +checksum = "25db6b064527c5d482d0423354fcd07a89a2dfe07b67892e62411946db7f07b0" dependencies = [ "either", ] @@ -1376,9 +1376,9 @@ checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" [[package]] name = "js-sys" -version = "0.3.68" +version = "0.3.67" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "406cda4b368d531c842222cf9d2600a9a4acce8d29423695379c6868a143a9ee" +checksum = "9a1d36f1235bc969acba30b7f5990b864423a6068a10f7c90ae8f0112e3a59d1" dependencies = [ "wasm-bindgen", ] @@ -1409,9 +1409,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.153" +version = "0.2.152" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" +checksum = "13e3bf6590cbc649f4d1a3eefc9d5d6eb746f5200ffb04e5e142700b8faa56e7" [[package]] name = "linux-raw-sys" @@ -1551,9 +1551,9 @@ checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" [[package]] name = "miniz_oxide" -version = "0.7.2" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" +checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" dependencies = [ "adler", ] @@ -1594,7 +1594,7 @@ dependencies = [ "ed25519-dalek", "hex", "hex-literal 0.4.1", - "itertools 0.12.1", + "itertools 0.12.0", "multiversx-chain-vm-executor", "num-bigint", "num-traits", @@ -1705,7 +1705,7 @@ dependencies = [ "clap", "colored", "hex", - "itertools 0.12.1", + "itertools 0.12.0", "log", "multiversx-chain-scenario-format", "multiversx-chain-vm", @@ -1734,7 +1734,7 @@ dependencies = [ "bip39", "hex", "hmac", - "itertools 0.12.1", + "itertools 0.12.0", "pbkdf2", "pem", "rand", @@ -1832,9 +1832,9 @@ checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" [[package]] name = "openssl" -version = "0.10.63" +version = "0.10.62" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15c9d69dd87a29568d4d017cfe8ec518706046a05184e5aea92d0af890b803c8" +checksum = "8cde4d2d9200ad5909f8dac647e29482e07c3a35de8a13fce7c9c7747ad9f671" dependencies = [ "bitflags 2.4.2", "cfg-if 1.0.0", @@ -1864,9 +1864,9 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-sys" -version = "0.9.99" +version = "0.9.98" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22e1bf214306098e4832460f797824c05d25aacdf896f64a985fb0fd992454ae" +checksum = "c1665caf8ab2dc9aef43d1c0023bd904633a6a05cb30b0ad59bec2ae986e57a7" dependencies = [ "cc", "libc", @@ -2074,9 +2074,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.76" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "95fc56cda0b5c3325f5fbbd7ff9fda9e02bb00bb3dac51252d2f1bfa1cb8cc8c" dependencies = [ "unicode-ident", ] @@ -2213,9 +2213,9 @@ dependencies = [ [[package]] name = "regex" -version = "1.10.3" +version = "1.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b62dbe01f0b06f9d8dc7d49e05a0785f153b00b2c227856282f671e0318c9b15" +checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" dependencies = [ "aho-corasick", "memchr", @@ -2225,9 +2225,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.5" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bb987efffd3c6d0d8f5f89510bb458559eab11e4f869acb20bf845e016259cd" +checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" dependencies = [ "aho-corasick", "memchr", @@ -2242,9 +2242,9 @@ checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" [[package]] name = "reqwest" -version = "0.11.24" +version = "0.11.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6920094eb85afde5e4a138be3f2de8bbdf28000f0029e72c45025a56b042251" +checksum = "37b1ae8d9ac08420c66222fb9096fc5de435c3c48542bc5336c51892cffafb41" dependencies = [ "base64", "bytes", @@ -2264,11 +2264,9 @@ dependencies = [ "once_cell", "percent-encoding", "pin-project-lite", - "rustls-pemfile", "serde", "serde_json", "serde_urlencoded", - "sync_wrapper", "system-configuration", "tokio", "tokio-native-tls", @@ -2347,9 +2345,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.38.31" +version = "0.38.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ea3e1a662af26cd7a3ba09c0297a31af215563ecf42817c98df621387f4e949" +checksum = "322394588aaf33c24007e8bb3238ee3e4c5c09c084ab32bc73890b99ff326bca" dependencies = [ "bitflags 2.4.2", "errno", @@ -2358,15 +2356,6 @@ dependencies = [ "windows-sys 0.52.0", ] -[[package]] -name = "rustls-pemfile" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" -dependencies = [ - "base64", -] - [[package]] name = "ryu" version = "1.0.16" @@ -2436,18 +2425,18 @@ checksum = "b97ed7a9823b74f99c7742f5336af7be5ecd3eeafcb1507d1fa93347b1d589b0" [[package]] name = "serde" -version = "1.0.196" +version = "1.0.195" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "870026e60fa08c69f064aa766c10f10b1d62db9ccd4d0abb206472bee0ce3b32" +checksum = "63261df402c67811e9ac6def069e4786148c4563f4b50fd4bf30aa370d626b02" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.196" +version = "1.0.195" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33c85360c95e7d137454dc81d9a4ed2b8efd8fbe19cee57357b32b9771fccb67" +checksum = "46fe8f8603d81ba86327b23a2e9cdf49e1255fb94a4c5f297f6ee0547178ea2c" dependencies = [ "proc-macro2", "quote", @@ -2456,9 +2445,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.113" +version = "1.0.111" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69801b70b1c3dac963ecb03a364ba0ceda9cf60c71cfe475e99864759c8b8a79" +checksum = "176e46fa42316f18edd598015a5166857fc835ec732f5215eac6b7bdbf0a84f4" dependencies = [ "indexmap", "itoa", @@ -2591,9 +2580,9 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.13.1" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6ecd384b10a64542d77071bd64bd7b231f4ed5940fba55e98c3de13824cf3d7" +checksum = "3b187f0231d56fe41bfb12034819dd2bf336422a5866de41bc3fec4b2e3883e8" [[package]] name = "socket2" @@ -2638,12 +2627,6 @@ dependencies = [ "unicode-ident", ] -[[package]] -name = "sync_wrapper" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" - [[package]] name = "system-configuration" version = "0.5.1" @@ -2667,12 +2650,13 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.10.0" +version = "3.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a365e8cd18e44762ef95d87f284f4b5cd04107fec2ff3052bd6a3e6069669e67" +checksum = "01ce4141aa927a6d1bd34a041795abd0db1cccba5d5f24b009f694bdf3a1f3fa" dependencies = [ "cfg-if 1.0.0", "fastrand", + "redox_syscall", "rustix", "windows-sys 0.52.0", ] @@ -2738,9 +2722,9 @@ dependencies = [ [[package]] name = "tokio" -version = "1.36.0" +version = "1.35.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61285f6515fa018fb2d1e46eb21223fff441ee8db5d0f1435e8ab4f5cdb80931" +checksum = "c89b4efa943be685f629b149f53829423f8f5531ea21249408e8e2f8671ec104" dependencies = [ "backtrace", "bytes", @@ -2792,9 +2776,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.10" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a9aad4a3066010876e8dcf5a8a06e70a558751117a145c6ce2b82c2e2054290" +checksum = "a1a195ec8c9da26928f773888e0742ca3ca1040c6cd859c919c9f59c1954ab35" dependencies = [ "indexmap", "serde", @@ -2814,9 +2798,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.22.4" +version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c9ffdf896f8daaabf9b66ba8e77ea1ed5ed0f72821b398aba62352e95062951" +checksum = "d34d383cd00a163b4a5b85053df514d45bc330f6de7737edfe0a93311d1eaa03" dependencies = [ "indexmap", "serde", @@ -2885,9 +2869,9 @@ dependencies = [ [[package]] name = "unicode-segmentation" -version = "1.11.0" +version = "1.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" +checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" [[package]] name = "unwrappable" @@ -2962,9 +2946,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.91" +version = "0.2.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1e124130aee3fb58c5bdd6b639a0509486b0338acaaae0c84a5124b0f588b7f" +checksum = "b1223296a201415c7fad14792dbefaace9bd52b62d33453ade1c5b5f07555406" dependencies = [ "cfg-if 1.0.0", "wasm-bindgen-macro", @@ -2972,9 +2956,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.91" +version = "0.2.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e7e1900c352b609c8488ad12639a311045f40a35491fb69ba8c12f758af70b" +checksum = "fcdc935b63408d58a32f8cc9738a0bffd8f05cc7c002086c6ef20b7312ad9dcd" dependencies = [ "bumpalo", "log", @@ -2987,9 +2971,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-futures" -version = "0.4.41" +version = "0.4.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "877b9c3f61ceea0e56331985743b13f3d25c406a7098d45180fb5f09bc19ed97" +checksum = "bde2032aeb86bdfaecc8b261eef3cba735cc426c1f3a3416d1e0791be95fc461" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -2999,9 +2983,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.91" +version = "0.2.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b30af9e2d358182b5c7449424f017eba305ed32a7010509ede96cdc4696c46ed" +checksum = "3e4c238561b2d428924c49815533a8b9121c664599558a5d9ec51f8a1740a999" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -3009,9 +2993,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.91" +version = "0.2.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "642f325be6301eb8107a83d12a8ac6c1e1c54345a7ef1a9261962dfefda09e66" +checksum = "bae1abb6806dc1ad9e560ed242107c0f6c84335f1749dd4e8ddb012ebd5e25a7" dependencies = [ "proc-macro2", "quote", @@ -3022,9 +3006,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-shared" -version = "0.2.91" +version = "0.2.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f186bd2dcf04330886ce82d6f33dd75a7bfcf69ecf5763b89fcde53b6ac9838" +checksum = "4d91413b1c31d7539ba5ef2451af3f0b833a005eb27a631cec32bc0635a8602b" [[package]] name = "wasmparser" @@ -3038,9 +3022,9 @@ dependencies = [ [[package]] name = "wasmparser" -version = "0.121.0" +version = "0.119.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "953cf6a7606ab31382cb1caa5ae403e77ba70c7f8e12eeda167e7040d42bfda8" +checksum = "8c35daf77afb4f9b14016625144a391085ec2ca99ca9cc53ed291bb53ab5278d" dependencies = [ "bitflags 2.4.2", "indexmap", @@ -3049,19 +3033,19 @@ dependencies = [ [[package]] name = "wasmprinter" -version = "0.2.78" +version = "0.2.76" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05e32c13c59fdc64d3f6998a1d52eb1d362b6904a88b754190ccb85661ad577a" +checksum = "cac2a7745372074e5573e365e17100f5a26058740576313784ef03fb900ea8d2" dependencies = [ "anyhow", - "wasmparser 0.121.0", + "wasmparser 0.119.0", ] [[package]] name = "web-sys" -version = "0.3.68" +version = "0.3.67" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96565907687f7aceb35bc5fc03770a8a0471d82e479f25832f54a0e3f4b28446" +checksum = "58cd2333b6e0be7a39605f0e255892fd7418a682d8da8fe042fe25128794d2ed" dependencies = [ "js-sys", "wasm-bindgen", @@ -3264,9 +3248,9 @@ checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" [[package]] name = "winnow" -version = "0.5.39" +version = "0.5.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5389a154b01683d28c77f8f68f49dea75f0a4da32557a58f68ee51ebba472d29" +checksum = "b7cf47b659b318dccbd69cc4797a39ae128f533dce7902a1096044d1967b9c16" dependencies = [ "memchr", ] diff --git a/dex/pair/src/pair_actions/add_liq.rs b/dex/pair/src/pair_actions/add_liq.rs index 769e805f4..1e9dbc8d9 100644 --- a/dex/pair/src/pair_actions/add_liq.rs +++ b/dex/pair/src/pair_actions/add_liq.rs @@ -65,6 +65,7 @@ pub trait AddLiquidityModule: self.update_safe_price( &storage_cache.first_token_reserve, &storage_cache.second_token_reserve, + &storage_cache.lp_token_supply, ); let initial_k = self.calculate_k_constant( diff --git a/dex/pair/src/pair_actions/remove_liq.rs b/dex/pair/src/pair_actions/remove_liq.rs index 5ee58d591..1010ac666 100644 --- a/dex/pair/src/pair_actions/remove_liq.rs +++ b/dex/pair/src/pair_actions/remove_liq.rs @@ -56,6 +56,7 @@ pub trait RemoveLiquidityModule: self.update_safe_price( &storage_cache.first_token_reserve, &storage_cache.second_token_reserve, + &storage_cache.lp_token_supply, ); let initial_k = self.calculate_k_constant( @@ -122,6 +123,7 @@ pub trait RemoveLiquidityModule: self.update_safe_price( &storage_cache.first_token_reserve, &storage_cache.second_token_reserve, + &storage_cache.lp_token_supply, ); let mut remove_liq_context = diff --git a/dex/pair/src/pair_actions/swap.rs b/dex/pair/src/pair_actions/swap.rs index f1ec88d94..62cdc01d4 100644 --- a/dex/pair/src/pair_actions/swap.rs +++ b/dex/pair/src/pair_actions/swap.rs @@ -50,6 +50,7 @@ pub trait SwapModule: self.update_safe_price( &storage_cache.first_token_reserve, &storage_cache.second_token_reserve, + &storage_cache.lp_token_supply, ); let initial_k = self.calculate_k_constant( @@ -114,6 +115,7 @@ pub trait SwapModule: self.update_safe_price( &storage_cache.first_token_reserve, &storage_cache.second_token_reserve, + &storage_cache.lp_token_supply, ); let initial_k = self.calculate_k_constant( @@ -185,6 +187,7 @@ pub trait SwapModule: self.update_safe_price( &storage_cache.first_token_reserve, &storage_cache.second_token_reserve, + &storage_cache.lp_token_supply, ); let initial_k = self.calculate_k_constant( diff --git a/dex/pair/src/safe_price.rs b/dex/pair/src/safe_price.rs index 1173cc291..4b80e139d 100644 --- a/dex/pair/src/safe_price.rs +++ b/dex/pair/src/safe_price.rs @@ -1,18 +1,21 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); +use multiversx_sc::codec::{NestedDecodeInput, TopDecodeInput}; + use crate::{amm, config, errors::ERROR_SAFE_PRICE_CURRENT_INDEX}; pub type Round = u64; pub const MAX_OBSERVATIONS: usize = 65_536; // 2^{16} records, to optimise binary search -#[derive(ManagedVecItem, Clone, TopEncode, TopDecode, NestedEncode, NestedDecode, TypeAbi)] +#[derive(ManagedVecItem, Clone, TopEncode, NestedEncode, TypeAbi)] pub struct PriceObservation { pub first_token_reserve_accumulated: BigUint, pub second_token_reserve_accumulated: BigUint, pub weight_accumulated: u64, pub recording_round: Round, + pub lp_supply_accumulated: BigUint, } impl Default for PriceObservation { @@ -22,7 +25,45 @@ impl Default for PriceObservation { second_token_reserve_accumulated: BigUint::zero(), weight_accumulated: 0, recording_round: 0, + lp_supply_accumulated: BigUint::zero(), + } + } +} + +impl TopDecode for PriceObservation { + fn top_decode(input: I) -> Result + where + I: TopDecodeInput, + { + let mut buffer = input.into_nested_buffer(); + Self::dep_decode(&mut buffer) + } +} + +impl NestedDecode for PriceObservation { + fn dep_decode(input: &mut I) -> Result { + let first_token_reserve_accumulated = BigUint::dep_decode(input)?; + let second_token_reserve_accumulated = BigUint::dep_decode(input)?; + let weight_accumulated = u64::dep_decode(input)?; + let recording_round = u64::dep_decode(input)?; + + let lp_supply_accumulated = if !input.is_depleted() { + BigUint::dep_decode(input)? + } else { + BigUint::zero() + }; + + if !input.is_depleted() { + return Result::Err(DecodeError::INPUT_TOO_LONG); } + + Result::Ok(PriceObservation { + first_token_reserve_accumulated, + second_token_reserve_accumulated, + weight_accumulated, + recording_round, + lp_supply_accumulated, + }) } } @@ -34,8 +75,13 @@ pub trait SafePriceModule: + permissions_module::PermissionsModule + pausable::PausableModule { - fn update_safe_price(&self, first_token_reserve: &BigUint, second_token_reserve: &BigUint) { - if first_token_reserve == &0u64 || second_token_reserve == &0u64 { + fn update_safe_price( + &self, + first_token_reserve: &BigUint, + second_token_reserve: &BigUint, + lp_supply: &BigUint, + ) { + if first_token_reserve == &0u64 || second_token_reserve == &0u64 || lp_supply == &0u64 { return; } @@ -62,6 +108,7 @@ pub trait SafePriceModule: current_round, first_token_reserve, second_token_reserve, + lp_supply, &last_price_observation, ); @@ -79,6 +126,7 @@ pub trait SafePriceModule: new_round: Round, new_first_reserve: &BigUint, new_second_reserve: &BigUint, + lp_supply: &BigUint, current_price_observation: &PriceObservation, ) -> PriceObservation { let new_weight = if current_price_observation.recording_round == 0 { @@ -92,6 +140,7 @@ pub trait SafePriceModule: BigUint::from(new_weight) * new_first_reserve; new_price_observation.second_token_reserve_accumulated += BigUint::from(new_weight) * new_second_reserve; + new_price_observation.lp_supply_accumulated += BigUint::from(new_weight) * lp_supply; new_price_observation.weight_accumulated += new_weight; new_price_observation.recording_round = new_round; diff --git a/dex/pair/src/safe_price_view.rs b/dex/pair/src/safe_price_view.rs index 4a1042a56..dd21e6780 100644 --- a/dex/pair/src/safe_price_view.rs +++ b/dex/pair/src/safe_price_view.rs @@ -83,16 +83,8 @@ pub trait SafePriceViewModule: ) -> MultiValue2 { require!(end_round > start_round, ERROR_PARAMETERS); - let lp_total_supply = self.lp_token_supply().get_from_address(&pair_address); let first_token_id = self.first_token_id().get_from_address(&pair_address); let second_token_id = self.second_token_id().get_from_address(&pair_address); - if lp_total_supply == 0 { - return ( - EsdtTokenPayment::new(first_token_id, 0, BigUint::zero()), - EsdtTokenPayment::new(second_token_id, 0, BigUint::zero()), - ) - .into(); - } let safe_price_current_index = self .safe_price_current_index() @@ -128,11 +120,24 @@ pub trait SafePriceViewModule: start_round, ); - let (weighted_first_token_reserve, weighted_second_token_reserve) = - self.compute_weighted_reserves(&first_price_observation, &last_price_observation); + let (weighted_first_token_reserve, weighted_second_token_reserve, mut weighted_lp_supply) = + self.compute_weighted_amounts(&first_price_observation, &last_price_observation); + + if weighted_lp_supply == 0 { + let current_lp_supply = self.lp_token_supply().get_from_address(&pair_address); + if current_lp_supply == 0 { + return ( + EsdtTokenPayment::new(first_token_id, 0, BigUint::zero()), + EsdtTokenPayment::new(second_token_id, 0, BigUint::zero()), + ) + .into(); + } else { + weighted_lp_supply = current_lp_supply; + } + } - let first_token_worth = &liquidity * &weighted_first_token_reserve / &lp_total_supply; - let second_token_worth = &liquidity * &weighted_second_token_reserve / &lp_total_supply; + let first_token_worth = &liquidity * &weighted_first_token_reserve / &weighted_lp_supply; + let second_token_worth = &liquidity * &weighted_second_token_reserve / &weighted_lp_supply; let first_token_payment = EsdtTokenPayment::new(first_token_id, 0, first_token_worth); let second_token_payment = EsdtTokenPayment::new(second_token_id, 0, second_token_worth); @@ -284,8 +289,8 @@ pub trait SafePriceViewModule: let first_token_id = self.first_token_id().get_from_address(pair_address); let second_token_id = self.second_token_id().get_from_address(pair_address); - let (weighted_first_token_reserve, weighted_second_token_reserve) = - self.compute_weighted_reserves(first_price_observation, last_price_observation); + let (weighted_first_token_reserve, weighted_second_token_reserve, _weighted_lp_supply) = + self.compute_weighted_amounts(first_price_observation, last_price_observation); if input_payment.token_identifier == first_token_id { let output_amount = @@ -336,10 +341,12 @@ pub trait SafePriceViewModule: let second_token_reserve = self .pair_reserve(second_token_id) .get_from_address(pair_address); + let current_lp_supply = self.lp_token_supply().get_from_address(pair_address); return self.compute_new_observation( search_round, &first_token_reserve, &second_token_reserve, + ¤t_lp_supply, &last_observation, ); } @@ -455,9 +462,12 @@ pub trait SafePriceViewModule: let second_token_reserve_sum = BigUint::from(left_weight) * left_observation.second_token_reserve_accumulated + BigUint::from(right_weight) * right_observation.second_token_reserve_accumulated; + let lp_supply_sum = BigUint::from(left_weight) * left_observation.lp_supply_accumulated + + BigUint::from(right_weight) * right_observation.lp_supply_accumulated; let first_token_reserve_accumulated = first_token_reserve_sum / weight_sum; let second_token_reserve_accumulated = second_token_reserve_sum / weight_sum; + let lp_supply_accumulated = lp_supply_sum / weight_sum; let weight_accumulated = left_observation.weight_accumulated + search_round - left_observation.recording_round; @@ -466,14 +476,15 @@ pub trait SafePriceViewModule: second_token_reserve_accumulated, weight_accumulated, recording_round: search_round, + lp_supply_accumulated, } } - fn compute_weighted_reserves( + fn compute_weighted_amounts( &self, first_price_observation: &PriceObservation, last_price_observation: &PriceObservation, - ) -> (BigUint, BigUint) { + ) -> (BigUint, BigUint, BigUint) { let weight_diff = last_price_observation.weight_accumulated - first_price_observation.weight_accumulated; @@ -491,10 +502,17 @@ pub trait SafePriceViewModule: - first_price_observation .second_token_reserve_accumulated .clone(); + let lp_supply_diff = last_price_observation.lp_supply_accumulated.clone() + - first_price_observation.lp_supply_accumulated.clone(); let weighted_first_token_reserve = first_token_reserve_diff / weight_diff; let weighted_second_token_reserve = second_token_reserve_diff / weight_diff; - (weighted_first_token_reserve, weighted_second_token_reserve) + let weighted_lp_supply = lp_supply_diff / weight_diff; + ( + weighted_first_token_reserve, + weighted_second_token_reserve, + weighted_lp_supply, + ) } fn get_default_offset_rounds(&self, pair_address: &ManagedAddress, end_round: Round) -> u64 { From 2c09f851666117a78fd122bb013f0ea1c2f5b6b2 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 6 Mar 2024 17:08:46 +0200 Subject: [PATCH 003/103] small refactor + decoding test --- dex/pair/src/safe_price.rs | 6 ++-- dex/pair/src/safe_price_view.rs | 37 +++++++++++++-------- dex/pair/tests/pair_rs_test.rs | 57 +++++++++++++++++++++++++++++++-- 3 files changed, 81 insertions(+), 19 deletions(-) diff --git a/dex/pair/src/safe_price.rs b/dex/pair/src/safe_price.rs index 4b80e139d..c3823ca44 100644 --- a/dex/pair/src/safe_price.rs +++ b/dex/pair/src/safe_price.rs @@ -9,7 +9,7 @@ pub type Round = u64; pub const MAX_OBSERVATIONS: usize = 65_536; // 2^{16} records, to optimise binary search -#[derive(ManagedVecItem, Clone, TopEncode, NestedEncode, TypeAbi)] +#[derive(ManagedVecItem, Clone, TopEncode, NestedEncode, TypeAbi, Debug)] pub struct PriceObservation { pub first_token_reserve_accumulated: BigUint, pub second_token_reserve_accumulated: BigUint, @@ -126,7 +126,7 @@ pub trait SafePriceModule: new_round: Round, new_first_reserve: &BigUint, new_second_reserve: &BigUint, - lp_supply: &BigUint, + new_lp_supply: &BigUint, current_price_observation: &PriceObservation, ) -> PriceObservation { let new_weight = if current_price_observation.recording_round == 0 { @@ -140,7 +140,7 @@ pub trait SafePriceModule: BigUint::from(new_weight) * new_first_reserve; new_price_observation.second_token_reserve_accumulated += BigUint::from(new_weight) * new_second_reserve; - new_price_observation.lp_supply_accumulated += BigUint::from(new_weight) * lp_supply; + new_price_observation.lp_supply_accumulated += BigUint::from(new_weight) * new_lp_supply; new_price_observation.weight_accumulated += new_weight; new_price_observation.recording_round = new_round; diff --git a/dex/pair/src/safe_price_view.rs b/dex/pair/src/safe_price_view.rs index dd21e6780..31704e58a 100644 --- a/dex/pair/src/safe_price_view.rs +++ b/dex/pair/src/safe_price_view.rs @@ -12,6 +12,12 @@ use crate::{ pub const DEFAULT_SAFE_PRICE_ROUNDS_OFFSET: u64 = 10 * 60; pub const SECONDS_PER_ROUND: u64 = 6; +struct PriceObservationWeightedAmounts { + weighted_first_token_reserve: BigUint, + weighted_second_token_reserve: BigUint, + weighted_lp_supply: BigUint, +} + #[multiversx_sc::module] pub trait SafePriceViewModule: safe_price::SafePriceModule @@ -120,10 +126,10 @@ pub trait SafePriceViewModule: start_round, ); - let (weighted_first_token_reserve, weighted_second_token_reserve, mut weighted_lp_supply) = + let mut weighted_amounts = self.compute_weighted_amounts(&first_price_observation, &last_price_observation); - if weighted_lp_supply == 0 { + if weighted_amounts.weighted_lp_supply == 0 { let current_lp_supply = self.lp_token_supply().get_from_address(&pair_address); if current_lp_supply == 0 { return ( @@ -132,12 +138,14 @@ pub trait SafePriceViewModule: ) .into(); } else { - weighted_lp_supply = current_lp_supply; + weighted_amounts.weighted_lp_supply = current_lp_supply; } } - let first_token_worth = &liquidity * &weighted_first_token_reserve / &weighted_lp_supply; - let second_token_worth = &liquidity * &weighted_second_token_reserve / &weighted_lp_supply; + let first_token_worth = &liquidity * &weighted_amounts.weighted_first_token_reserve + / &weighted_amounts.weighted_lp_supply; + let second_token_worth = &liquidity * &weighted_amounts.weighted_second_token_reserve + / &weighted_amounts.weighted_lp_supply; let first_token_payment = EsdtTokenPayment::new(first_token_id, 0, first_token_worth); let second_token_payment = EsdtTokenPayment::new(second_token_id, 0, second_token_worth); @@ -289,16 +297,18 @@ pub trait SafePriceViewModule: let first_token_id = self.first_token_id().get_from_address(pair_address); let second_token_id = self.second_token_id().get_from_address(pair_address); - let (weighted_first_token_reserve, weighted_second_token_reserve, _weighted_lp_supply) = + let weighted_amounts = self.compute_weighted_amounts(first_price_observation, last_price_observation); if input_payment.token_identifier == first_token_id { - let output_amount = - input_payment.amount * weighted_second_token_reserve / weighted_first_token_reserve; + let output_amount = input_payment.amount + * weighted_amounts.weighted_second_token_reserve + / weighted_amounts.weighted_first_token_reserve; EsdtTokenPayment::new(second_token_id, 0, output_amount) } else if input_payment.token_identifier == second_token_id { - let output_amount = - input_payment.amount * weighted_first_token_reserve / weighted_second_token_reserve; + let output_amount = input_payment.amount + * weighted_amounts.weighted_first_token_reserve + / weighted_amounts.weighted_second_token_reserve; EsdtTokenPayment::new(first_token_id, 0, output_amount) } else { sc_panic!(ERROR_BAD_INPUT_TOKEN); @@ -484,7 +494,7 @@ pub trait SafePriceViewModule: &self, first_price_observation: &PriceObservation, last_price_observation: &PriceObservation, - ) -> (BigUint, BigUint, BigUint) { + ) -> PriceObservationWeightedAmounts { let weight_diff = last_price_observation.weight_accumulated - first_price_observation.weight_accumulated; @@ -508,11 +518,12 @@ pub trait SafePriceViewModule: let weighted_first_token_reserve = first_token_reserve_diff / weight_diff; let weighted_second_token_reserve = second_token_reserve_diff / weight_diff; let weighted_lp_supply = lp_supply_diff / weight_diff; - ( + + PriceObservationWeightedAmounts { weighted_first_token_reserve, weighted_second_token_reserve, weighted_lp_supply, - ) + } } fn get_default_offset_rounds(&self, pair_address: &ManagedAddress, end_round: Round) -> u64 { diff --git a/dex/pair/tests/pair_rs_test.rs b/dex/pair/tests/pair_rs_test.rs index 5ff6fbce9..ec2c3f772 100644 --- a/dex/pair/tests/pair_rs_test.rs +++ b/dex/pair/tests/pair_rs_test.rs @@ -4,18 +4,27 @@ mod pair_setup; use fees_collector::{ config::ConfigModule, fees_accumulation::FeesAccumulationModule, FeesCollector, }; +use multiversx_sc::codec::{self, TopDecode}; use multiversx_sc::{ - codec::multi_types::OptionalValue, + api::ManagedTypeApi, + codec::{ + derive::{NestedEncode, TopEncode}, + multi_types::OptionalValue, + top_encode_to_vec_u8, + }, storage::mappers::StorageTokenWrapper, - types::{EsdtLocalRole, MultiValueEncoded}, + types::{BigUint, EsdtLocalRole, MultiValueEncoded}, }; use multiversx_sc_scenario::{ managed_address, managed_biguint, managed_token_id, managed_token_id_wrapped, rust_biguint, whitebox_legacy::TxTokenTransfer, DebugApi, }; use pair::{ - config::MAX_PERCENTAGE, fee::FeeModule, locking_wrapper::LockingWrapperModule, + config::MAX_PERCENTAGE, + fee::FeeModule, + locking_wrapper::LockingWrapperModule, pair_actions::swap::SwapModule, + safe_price::{PriceObservation, Round, SafePriceModule}, }; use pair_setup::*; use simple_lock::{ @@ -24,6 +33,14 @@ use simple_lock::{ SimpleLock, }; +#[derive(TopEncode, NestedEncode, Clone, Debug)] +pub struct OldPriceObservation { + pub first_token_reserve_accumulated: BigUint, + pub second_token_reserve_accumulated: BigUint, + pub weight_accumulated: u64, + pub recording_round: Round, +} + #[test] fn test_pair_setup() { let _ = PairSetup::new(pair::contract_obj); @@ -60,6 +77,40 @@ fn test_swap_fixed_output() { pair_setup.swap_fixed_output(WEGLD_TOKEN_ID, 1_000, MEX_TOKEN_ID, 900, 96); } +#[test] +fn test_safe_price_observation_decoding() { + let mut pair_setup = PairSetup::new(pair::contract_obj); + let _ = pair_setup.b_mock.execute_tx( + &pair_setup.owner_address, + &pair_setup.pair_wrapper, + &rust_biguint!(0), + |sc| { + let old_observation: OldPriceObservation = OldPriceObservation { + first_token_reserve_accumulated: managed_biguint!(1u64), + second_token_reserve_accumulated: managed_biguint!(1u64), + weight_accumulated: 1u64, + recording_round: 1u64, + }; + + let buffer = top_encode_to_vec_u8(&old_observation).unwrap(); + + let mut new_observation = PriceObservation::::top_decode(buffer).unwrap(); + assert_eq!( + new_observation.lp_supply_accumulated, + managed_biguint!(0u64) + ); + + new_observation.lp_supply_accumulated = managed_biguint!(2u64); + sc.price_observations().push(&new_observation.clone()); + let final_observation = sc.price_observations().get(1); + assert_eq!( + new_observation.lp_supply_accumulated, + final_observation.lp_supply_accumulated + ); + }, + ); +} + #[test] fn test_safe_price() { let mut pair_setup = PairSetup::new(pair::contract_obj); From 7a4f5a103b10045c5761c5da547259cb923a6045 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 26 Mar 2024 01:54:25 +0200 Subject: [PATCH 004/103] Safe Price accumulated LP supply migration fix --- dex/pair/src/safe_price_view.rs | 29 +++-- dex/pair/tests/pair_rs_test.rs | 194 +++++++++++++++++++++++++++++++ dex/pair/tests/pair_setup/mod.rs | 65 ++++++++++- 3 files changed, 275 insertions(+), 13 deletions(-) diff --git a/dex/pair/src/safe_price_view.rs b/dex/pair/src/safe_price_view.rs index 31704e58a..9668147a9 100644 --- a/dex/pair/src/safe_price_view.rs +++ b/dex/pair/src/safe_price_view.rs @@ -97,15 +97,6 @@ pub trait SafePriceViewModule: .get_from_address(&pair_address); let price_observations = self.price_observations(); - let last_price_observation = self.get_price_observation( - &pair_address, - &first_token_id, - &second_token_id, - safe_price_current_index, - &price_observations, - end_round, - ); - let oldest_price_observation = self.get_oldest_price_observation( &pair_address, safe_price_current_index, @@ -126,6 +117,15 @@ pub trait SafePriceViewModule: start_round, ); + let last_price_observation = self.get_price_observation( + &pair_address, + &first_token_id, + &second_token_id, + safe_price_current_index, + &price_observations, + end_round, + ); + let mut weighted_amounts = self.compute_weighted_amounts(&first_price_observation, &last_price_observation); @@ -512,12 +512,17 @@ pub trait SafePriceViewModule: - first_price_observation .second_token_reserve_accumulated .clone(); - let lp_supply_diff = last_price_observation.lp_supply_accumulated.clone() - - first_price_observation.lp_supply_accumulated.clone(); let weighted_first_token_reserve = first_token_reserve_diff / weight_diff; let weighted_second_token_reserve = second_token_reserve_diff / weight_diff; - let weighted_lp_supply = lp_supply_diff / weight_diff; + + let weighted_lp_supply = if first_price_observation.lp_supply_accumulated > 0 { + let lp_supply_diff = last_price_observation.lp_supply_accumulated.clone() + - first_price_observation.lp_supply_accumulated.clone(); + lp_supply_diff / weight_diff + } else { + BigUint::zero() + }; PriceObservationWeightedAmounts { weighted_first_token_reserve, diff --git a/dex/pair/tests/pair_rs_test.rs b/dex/pair/tests/pair_rs_test.rs index ec2c3f772..c67be08ec 100644 --- a/dex/pair/tests/pair_rs_test.rs +++ b/dex/pair/tests/pair_rs_test.rs @@ -111,6 +111,200 @@ fn test_safe_price_observation_decoding() { ); } +#[test] +fn test_safe_price_migration() { + let mut pair_setup = PairSetup::new(pair::contract_obj); + let pair_address = pair_setup.pair_wrapper.address_ref().clone(); + let starting_round = 1000; + let payment_amount = 1000; + let mut expected_amount = 996; + + let mut first_token_reserve = 1_002_000; + let mut second_token_reserve = 1_000_004; + let mut first_token_accumulated = 1_001_000; + let mut second_token_accumulated = 1_001_000; + + let weight = 10; + let mut block_round = starting_round + weight; + pair_setup.b_mock.set_block_round(block_round); + + let lp_increase = 1_000_000; + let min_lp_amount = 1_000; + let mut lp_amount = lp_increase + min_lp_amount; + pair_setup.add_liquidity( + lp_increase + min_lp_amount, + lp_increase, + lp_increase + min_lp_amount, + lp_increase, + lp_increase, + lp_increase + min_lp_amount, + lp_increase + min_lp_amount, + ); + pair_setup.swap_fixed_input( + WEGLD_TOKEN_ID, + payment_amount, + MEX_TOKEN_ID, + 900, + expected_amount, + ); + pair_setup.check_lp_amount(lp_amount); + + block_round += weight; + expected_amount -= 2; // slippage + pair_setup.b_mock.set_block_round(block_round); + pair_setup.swap_fixed_input( + WEGLD_TOKEN_ID, + payment_amount, + MEX_TOKEN_ID, + 900, + expected_amount, + ); + pair_setup.check_lp_amount(lp_amount); + + first_token_accumulated += weight * first_token_reserve; + second_token_accumulated += weight * second_token_reserve; + + block_round += weight; + first_token_reserve += payment_amount; + second_token_reserve -= expected_amount; + first_token_accumulated += weight * first_token_reserve; + second_token_accumulated += weight * second_token_reserve; + expected_amount -= 2; + pair_setup.b_mock.set_block_round(block_round); + + // Change LP amount starting block 1030 + let lp_amount_increase = 998_005; + lp_amount += lp_amount_increase; + pair_setup.add_liquidity( + lp_increase, + lp_increase, + 996_021, + 996_021, + lp_amount_increase, + lp_increase, + 996_021, + ); + pair_setup.swap_fixed_input( + WEGLD_TOKEN_ID, + payment_amount, + MEX_TOKEN_ID, + 900, + expected_amount, + ); + pair_setup.check_lp_amount(lp_amount); + + block_round += weight; + first_token_reserve += payment_amount; + second_token_reserve -= expected_amount; + first_token_accumulated += weight * first_token_reserve; + second_token_accumulated += weight * second_token_reserve; + expected_amount -= 1; + pair_setup.b_mock.set_block_round(block_round); + pair_setup.swap_fixed_input( + WEGLD_TOKEN_ID, + payment_amount, + MEX_TOKEN_ID, + 900, + expected_amount, + ); + pair_setup.check_lp_amount(lp_amount); + + block_round += weight; + first_token_reserve += payment_amount; + second_token_reserve -= expected_amount; + first_token_accumulated += weight * first_token_reserve; + second_token_accumulated += weight * second_token_reserve; + expected_amount -= 1; + pair_setup.b_mock.set_block_round(block_round); + pair_setup.swap_fixed_input( + WEGLD_TOKEN_ID, + payment_amount, + MEX_TOKEN_ID, + 900, + expected_amount, + ); + pair_setup.check_lp_amount(lp_amount); + + // Check the normal safe price + let lp_token_amount = 100_000; + pair_setup.check_lp_tokens_safe_price( + &pair_address, + 1011, + 1019, + lp_token_amount, + WEGLD_TOKEN_ID, + 100_099, + MEX_TOKEN_ID, + 99_900, + ); + + pair_setup.check_lp_tokens_safe_price( + &pair_address, + 1020, + 1030, + lp_token_amount, + WEGLD_TOKEN_ID, + 100_199, + MEX_TOKEN_ID, + 99_801, + ); + + pair_setup.check_lp_tokens_safe_price( + &pair_address, + 1030, + 1040, + lp_token_amount, + WEGLD_TOKEN_ID, + 100_249, + MEX_TOKEN_ID, + 99_751, + ); + + // Simulate old price observations + pair_setup.set_price_observation_as_old(&pair_address, 1); + pair_setup.set_price_observation_as_old(&pair_address, 2); + + // Check migration safe price + // Both observations are old + // Latest LP amount is used, so this should be the different than before + pair_setup.check_lp_tokens_safe_price( + &pair_address, + 1011, + 1019, + lp_token_amount, + WEGLD_TOKEN_ID, + 50124, + MEX_TOKEN_ID, + 50_025, + ); + + // First observation is old and the last observation is migrated + // Latest LP amount is used, so this should be the different than before + pair_setup.check_lp_tokens_safe_price( + &pair_address, + 1020, + 1030, + lp_token_amount, + WEGLD_TOKEN_ID, + 50_174, + MEX_TOKEN_ID, + 49_975, + ); + + // Both observations are migrated, + // Saved LP is used, so this should be the same as before + pair_setup.check_lp_tokens_safe_price( + &pair_address, + 1030, + 1040, + lp_token_amount, + WEGLD_TOKEN_ID, + 100_249, + MEX_TOKEN_ID, + 99_751, + ); +} + #[test] fn test_safe_price() { let mut pair_setup = PairSetup::new(pair::contract_obj); diff --git a/dex/pair/tests/pair_setup/mod.rs b/dex/pair/tests/pair_setup/mod.rs index 5ca0fcd84..a232daf5d 100644 --- a/dex/pair/tests/pair_setup/mod.rs +++ b/dex/pair/tests/pair_setup/mod.rs @@ -1,6 +1,6 @@ use multiversx_sc::codec::multi_types::MultiValue3; use multiversx_sc::types::{ - Address, EsdtLocalRole, EsdtTokenPayment, ManagedAddress, MultiValueEncoded, + Address, BigUint, EsdtLocalRole, EsdtTokenPayment, ManagedAddress, MultiValueEncoded, }; use multiversx_sc_scenario::whitebox_legacy::TxTokenTransfer; use multiversx_sc_scenario::{ @@ -22,6 +22,7 @@ pub const USER_TOTAL_WEGLD_TOKENS: u64 = 5_000_000_000; use pair::config::ConfigModule as PairConfigModule; use pair::pair_actions::add_liq::AddLiquidityModule; use pair::pair_actions::swap::SwapModule; +use pair::safe_price::SafePriceModule; use pair::safe_price_view::*; use pair::*; use pausable::{PausableModule, State}; @@ -274,6 +275,15 @@ where ); } + pub fn check_lp_amount(&mut self, expected_amount: u64) { + self.b_mock + .execute_query(&self.pair_wrapper, |sc| { + let lp_amount = sc.lp_token_supply().get(); + assert_eq!(lp_amount, managed_biguint!(expected_amount)); + }) + .assert_ok(); + } + pub fn check_price_observation( &mut self, pair_address: &Address, @@ -358,6 +368,59 @@ where }); } + #[allow(clippy::too_many_arguments)] + pub fn check_lp_tokens_safe_price( + &mut self, + pair_address: &Address, + start_round: u64, + end_round: u64, + lp_token_amount: u64, + expected_first_token_id: &[u8], + expected_first_token_amount: u64, + expected_second_token_id: &[u8], + expected_second_token_amount: u64, + ) { + let _ = self.b_mock.execute_query(&self.pair_wrapper, |sc| { + let lp_tokens_safe_price = sc.get_lp_tokens_safe_price( + managed_address!(pair_address), + start_round, + end_round, + managed_biguint!(lp_token_amount), + ); + let (first_payment, second_payment) = lp_tokens_safe_price.into_tuple(); + assert_eq!( + first_payment.token_identifier, + managed_token_id!(expected_first_token_id) + ); + assert_eq!( + first_payment.amount, + managed_biguint!(expected_first_token_amount) + ); + assert_eq!( + second_payment.token_identifier, + managed_token_id!(expected_second_token_id) + ); + assert_eq!( + second_payment.amount, + managed_biguint!(expected_second_token_amount) + ); + }); + } + + pub fn set_price_observation_as_old( + &mut self, + pair_address: &Address, + observation_index: usize, + ) { + let _ = self.b_mock.execute_query(&self.pair_wrapper, |sc| { + let price_observations = sc.price_observations(); + + let mut price_observation = price_observations.get(observation_index); + price_observation.lp_supply_accumulated = BigUint::zero(); + price_observations.set(observation_index, &price_observation); + }); + } + #[allow(clippy::too_many_arguments)] pub fn check_safe_price_from_second_pair( &mut self, From 2f5e66c1af3164a51971fd0100ed9e5aa20fa76d Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 26 Mar 2024 12:22:42 +0200 Subject: [PATCH 005/103] Energy factory extra checks for public endpoints --- locked-asset/energy-factory/src/locked_token_transfer.rs | 6 +++++- locked-asset/energy-factory/src/unlock_with_penalty.rs | 2 ++ locked-asset/energy-factory/src/unstake.rs | 1 + locked-asset/energy-factory/src/virtual_lock.rs | 1 + 4 files changed, 9 insertions(+), 1 deletion(-) diff --git a/locked-asset/energy-factory/src/locked_token_transfer.rs b/locked-asset/energy-factory/src/locked_token_transfer.rs index a233fa336..8e9397e48 100644 --- a/locked-asset/energy-factory/src/locked_token_transfer.rs +++ b/locked-asset/energy-factory/src/locked_token_transfer.rs @@ -4,7 +4,10 @@ use crate::energy::Energy; #[multiversx_sc::module] pub trait LockedTokenTransferModule: - utils::UtilsModule + crate::energy::EnergyModule + crate::events::EventsModule + utils::UtilsModule + + crate::energy::EnergyModule + + crate::events::EventsModule + + multiversx_sc_modules::pause::PauseModule { #[only_owner] #[endpoint(addToTokenTransferWhitelist)] @@ -34,6 +37,7 @@ pub trait LockedTokenTransferModule: user: ManagedAddress, energy: Energy, ) { + self.require_not_paused(); let caller = self.blockchain().get_caller(); self.token_transfer_whitelist().require_whitelisted(&caller); diff --git a/locked-asset/energy-factory/src/unlock_with_penalty.rs b/locked-asset/energy-factory/src/unlock_with_penalty.rs index a59ca05e2..102565ed5 100644 --- a/locked-asset/energy-factory/src/unlock_with_penalty.rs +++ b/locked-asset/energy-factory/src/unlock_with_penalty.rs @@ -38,6 +38,7 @@ pub trait UnlockWithPenaltyModule: #[payable("*")] #[endpoint(unlockEarly)] fn unlock_early(&self) { + self.require_not_paused(); let caller = self.blockchain().get_caller(); let payment = self.call_value().single_esdt(); let reduce_result = self.reduce_lock_period_common(&caller, payment.clone(), None); @@ -59,6 +60,7 @@ pub trait UnlockWithPenaltyModule: #[payable("*")] #[endpoint(reduceLockPeriod)] fn reduce_lock_period(&self, new_lock_period: Epoch) -> EsdtTokenPayment { + self.require_not_paused(); self.require_is_listed_lock_option(new_lock_period); let caller = self.blockchain().get_caller(); diff --git a/locked-asset/energy-factory/src/unstake.rs b/locked-asset/energy-factory/src/unstake.rs index 9f0409e00..9d9df5f8d 100644 --- a/locked-asset/energy-factory/src/unstake.rs +++ b/locked-asset/energy-factory/src/unstake.rs @@ -45,6 +45,7 @@ pub trait UnstakeModule: #[payable("*")] #[endpoint(revertUnstake)] fn revert_unstake(&self, user: ManagedAddress, new_energy: Energy) { + self.require_not_paused(); self.require_caller_unstake_sc(); self.set_energy_entry(&user, new_energy); diff --git a/locked-asset/energy-factory/src/virtual_lock.rs b/locked-asset/energy-factory/src/virtual_lock.rs index 9d7172989..94aa0abf5 100644 --- a/locked-asset/energy-factory/src/virtual_lock.rs +++ b/locked-asset/energy-factory/src/virtual_lock.rs @@ -29,6 +29,7 @@ pub trait VirtualLockModule: dest_address: ManagedAddress, energy_address: ManagedAddress, ) -> EsdtTokenPayment { + self.require_not_paused(); require!( self.is_base_asset_token(&token_id), "May only lock the base asset token" From b72b93cce2b22096c35046d3629d033dc1f18f52 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 26 Mar 2024 12:30:55 +0200 Subject: [PATCH 006/103] small code update --- dex/pair/src/safe_price_view.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dex/pair/src/safe_price_view.rs b/dex/pair/src/safe_price_view.rs index 9668147a9..16d5d96c3 100644 --- a/dex/pair/src/safe_price_view.rs +++ b/dex/pair/src/safe_price_view.rs @@ -517,8 +517,8 @@ pub trait SafePriceViewModule: let weighted_second_token_reserve = second_token_reserve_diff / weight_diff; let weighted_lp_supply = if first_price_observation.lp_supply_accumulated > 0 { - let lp_supply_diff = last_price_observation.lp_supply_accumulated.clone() - - first_price_observation.lp_supply_accumulated.clone(); + let lp_supply_diff = &last_price_observation.lp_supply_accumulated + - &first_price_observation.lp_supply_accumulated; lp_supply_diff / weight_diff } else { BigUint::zero() From d06040a98509a28c524c339e928af34eb581657b Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 4 Apr 2024 13:39:10 +0300 Subject: [PATCH 007/103] set boosted yields percentage fix --- dex/farm-with-locked-rewards/src/lib.rs | 13 ++++++++++++- .../tests/farm_with_locked_rewards_setup/mod.rs | 1 - dex/farm-with-locked-rewards/wasm/src/lib.rs | 2 +- dex/farm/src/base_functions.rs | 4 ++-- dex/farm/src/exit_penalty.rs | 3 ++- dex/farm/src/lib.rs | 13 +++++++++++++ dex/farm/wasm/src/lib.rs | 2 +- energy-integration/farm-boosted-yields/src/lib.rs | 8 -------- .../mod.rs | 1 - farm-staking/farm-staking/src/lib.rs | 13 ++++++++++++- .../farm-staking/tests/farm_staking_setup/mod.rs | 1 - farm-staking/farm-staking/wasm/src/lib.rs | 2 +- locked-asset/proxy_dex/tests/proxy_farm_test.rs | 3 ++- 13 files changed, 46 insertions(+), 20 deletions(-) diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index a42f6518c..e7fd871c4 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -14,7 +14,7 @@ use farm::{ exit_penalty::{ DEFAULT_BURN_GAS_LIMIT, DEFAULT_MINUMUM_FARMING_EPOCHS, DEFAULT_PENALTY_PERCENT, }, - EnterFarmResultType, ExitFarmWithPartialPosResultType, + EnterFarmResultType, ExitFarmWithPartialPosResultType, MAX_PERCENT, }; use farm_base_impl::base_traits_impl::FarmContract; @@ -256,6 +256,17 @@ pub trait Farm: self.set_per_block_rewards::>(per_block_amount); } + #[endpoint(setBoostedYieldsRewardsPercentage)] + fn set_boosted_yields_rewards_percentage(&self, percentage: u64) { + self.require_caller_has_admin_permissions(); + require!(percentage <= MAX_PERCENT, "Invalid percentage"); + + let mut storage_cache = StorageCache::new(self); + NoMintWrapper::::generate_aggregated_rewards(self, &mut storage_cache); + + self.boosted_yields_rewards_percentage().set(percentage); + } + #[view(calculateRewardsForGivenPosition)] fn calculate_rewards_for_given_position( &self, diff --git a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs index f92abc5c7..7125f474b 100644 --- a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs +++ b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs @@ -19,7 +19,6 @@ use fees_collector_mock::*; use energy_factory::{energy::EnergyModule, SimpleLockEnergy}; use energy_query::{Energy, EnergyQueryModule}; use farm_boosted_yields::boosted_yields_factors::BoostedYieldsFactorsModule; -use farm_boosted_yields::FarmBoostedYieldsModule; use farm_token::FarmTokenModule; use farm_with_locked_rewards::Farm; use locking_module::lock_with_energy_module::LockWithEnergyModule; diff --git a/dex/farm-with-locked-rewards/wasm/src/lib.rs b/dex/farm-with-locked-rewards/wasm/src/lib.rs index 47d140e12..c3aaf7509 100644 --- a/dex/farm-with-locked-rewards/wasm/src/lib.rs +++ b/dex/farm-with-locked-rewards/wasm/src/lib.rs @@ -29,6 +29,7 @@ multiversx_sc_wasm_adapter::endpoints! { startProduceRewards => start_produce_rewards_endpoint endProduceRewards => end_produce_rewards_endpoint setPerBlockRewardAmount => set_per_block_rewards_endpoint + setBoostedYieldsRewardsPercentage => set_boosted_yields_rewards_percentage calculateRewardsForGivenPosition => calculate_rewards_for_given_position getRewardPerShare => reward_per_share getRewardReserve => reward_reserve @@ -67,7 +68,6 @@ multiversx_sc_wasm_adapter::endpoints! { getMinimumFarmingEpoch => minimum_farming_epochs getBurnGasLimit => burn_gas_limit getPairContractManagedAddress => pair_contract_address - setBoostedYieldsRewardsPercentage => set_boosted_yields_rewards_percentage collectUndistributedBoostedRewards => collect_undistributed_boosted_rewards getBoostedYieldsRewardsPercentage => boosted_yields_rewards_percentage getAccumulatedRewardsForWeek => accumulated_rewards_for_week diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index 968e3381d..76ce024c9 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -13,7 +13,7 @@ use contexts::storage_cache::StorageCache; use farm_base_impl::base_traits_impl::{DefaultFarmWrapper, FarmContract}; use fixed_supply_token::FixedSupplyToken; -use crate::exit_penalty; +use crate::{exit_penalty, MAX_PERCENT}; pub type DoubleMultiPayment = MultiValue2, EsdtTokenPayment>; pub type ClaimRewardsResultType = DoubleMultiPayment; @@ -346,7 +346,7 @@ where if user_farming_epochs >= min_farming_epochs { BigUint::zero() } else { - total_exit_amount * sc.penalty_percent().get() / exit_penalty::MAX_PERCENT + total_exit_amount * sc.penalty_percent().get() / MAX_PERCENT } } diff --git a/dex/farm/src/exit_penalty.rs b/dex/farm/src/exit_penalty.rs index e8905fade..19f101a26 100644 --- a/dex/farm/src/exit_penalty.rs +++ b/dex/farm/src/exit_penalty.rs @@ -4,7 +4,8 @@ use common_errors::ERROR_PARAMETERS; use common_structs::Epoch; use pair::pair_actions::remove_liq::ProxyTrait as _; -pub const MAX_PERCENT: u64 = 10_000; +use crate::MAX_PERCENT; + pub const DEFAULT_PENALTY_PERCENT: u64 = 100; pub const DEFAULT_MINUMUM_FARMING_EPOCHS: u64 = 3; pub const DEFAULT_BURN_GAS_LIMIT: u64 = 50_000_000; diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 669dd2e50..0afc41c62 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -20,6 +20,8 @@ use farm_base_impl::base_traits_impl::FarmContract; pub type EnterFarmResultType = DoubleMultiPayment; pub type ExitFarmWithPartialPosResultType = DoubleMultiPayment; +pub const MAX_PERCENT: u64 = 10_000; + #[multiversx_sc::contract] pub trait Farm: rewards::RewardsModule @@ -245,6 +247,17 @@ pub trait Farm: self.set_per_block_rewards::>(per_block_amount); } + #[endpoint(setBoostedYieldsRewardsPercentage)] + fn set_boosted_yields_rewards_percentage(&self, percentage: u64) { + self.require_caller_has_admin_permissions(); + require!(percentage <= MAX_PERCENT, "Invalid percentage"); + + let mut storage_cache = StorageCache::new(self); + Wrapper::::generate_aggregated_rewards(self, &mut storage_cache); + + self.boosted_yields_rewards_percentage().set(percentage); + } + #[view(calculateRewardsForGivenPosition)] fn calculate_rewards_for_given_position( &self, diff --git a/dex/farm/wasm/src/lib.rs b/dex/farm/wasm/src/lib.rs index de7b89ee5..c129590b3 100644 --- a/dex/farm/wasm/src/lib.rs +++ b/dex/farm/wasm/src/lib.rs @@ -30,6 +30,7 @@ multiversx_sc_wasm_adapter::endpoints! { startProduceRewards => start_produce_rewards_endpoint endProduceRewards => end_produce_rewards_endpoint setPerBlockRewardAmount => set_per_block_rewards_endpoint + setBoostedYieldsRewardsPercentage => set_boosted_yields_rewards_percentage calculateRewardsForGivenPosition => calculate_rewards_for_given_position getRewardPerShare => reward_per_share getRewardReserve => reward_reserve @@ -64,7 +65,6 @@ multiversx_sc_wasm_adapter::endpoints! { getMinimumFarmingEpoch => minimum_farming_epochs getBurnGasLimit => burn_gas_limit getPairContractManagedAddress => pair_contract_address - setBoostedYieldsRewardsPercentage => set_boosted_yields_rewards_percentage collectUndistributedBoostedRewards => collect_undistributed_boosted_rewards getBoostedYieldsRewardsPercentage => boosted_yields_rewards_percentage getAccumulatedRewardsForWeek => accumulated_rewards_for_week diff --git a/energy-integration/farm-boosted-yields/src/lib.rs b/energy-integration/farm-boosted-yields/src/lib.rs index 931c58f9d..09bacc676 100644 --- a/energy-integration/farm-boosted-yields/src/lib.rs +++ b/energy-integration/farm-boosted-yields/src/lib.rs @@ -44,14 +44,6 @@ pub trait FarmBoostedYieldsModule: + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule { - #[endpoint(setBoostedYieldsRewardsPercentage)] - fn set_boosted_yields_rewards_percentage(&self, percentage: u64) { - self.require_caller_has_admin_permissions(); - require!(percentage <= MAX_PERCENT, "Invalid percentage"); - - self.boosted_yields_rewards_percentage().set(percentage); - } - #[endpoint(collectUndistributedBoostedRewards)] fn collect_undistributed_boosted_rewards(&self) { self.require_caller_has_admin_permissions(); diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs index 8860a604e..dca88dce5 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs @@ -2,7 +2,6 @@ use energy_factory::energy::EnergyModule; use energy_query::Energy; -use farm_boosted_yields::FarmBoostedYieldsModule; use farm_with_locked_rewards::Farm; use multiversx_sc::{ codec::multi_types::OptionalValue, diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index e517d2aa6..c210d080c 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -7,7 +7,7 @@ multiversx_sc::derive_imports!(); use base_impl_wrapper::FarmStakingWrapper; use contexts::storage_cache::StorageCache; -use farm::base_functions::DoubleMultiPayment; +use farm::{base_functions::DoubleMultiPayment, MAX_PERCENT}; use farm_base_impl::base_traits_impl::FarmContract; use fixed_supply_token::FixedSupplyToken; use token_attributes::StakingFarmTokenAttributes; @@ -130,6 +130,17 @@ pub trait FarmStaking: (merged_farm_token, boosted_rewards_payment).into() } + #[endpoint(setBoostedYieldsRewardsPercentage)] + fn set_boosted_yields_rewards_percentage(&self, percentage: u64) { + self.require_caller_has_admin_permissions(); + require!(percentage <= MAX_PERCENT, "Invalid percentage"); + + let mut storage_cache = StorageCache::new(self); + FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); + + self.boosted_yields_rewards_percentage().set(percentage); + } + #[view(calculateRewardsForGivenPosition)] fn calculate_rewards_for_given_position( &self, diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index d8cfc9a46..f9c2b5955 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -15,7 +15,6 @@ use config::*; use energy_factory::energy::EnergyModule; use energy_query::{Energy, EnergyQueryModule}; use farm_boosted_yields::boosted_yields_factors::BoostedYieldsFactorsModule; -use farm_boosted_yields::FarmBoostedYieldsModule; use farm_staking::claim_stake_farm_rewards::ClaimStakeFarmRewardsModule; use farm_staking::custom_rewards::CustomRewardsModule; use farm_staking::stake_farm::StakeFarmModule; diff --git a/farm-staking/farm-staking/wasm/src/lib.rs b/farm-staking/farm-staking/wasm/src/lib.rs index 02de33846..4bc7e0bbb 100644 --- a/farm-staking/farm-staking/wasm/src/lib.rs +++ b/farm-staking/farm-staking/wasm/src/lib.rs @@ -22,6 +22,7 @@ multiversx_sc_wasm_adapter::endpoints! { init => init upgrade => upgrade mergeFarmTokens => merge_farm_tokens_endpoint + setBoostedYieldsRewardsPercentage => set_boosted_yields_rewards_percentage calculateRewardsForGivenPosition => calculate_rewards_for_given_position topUpRewards => top_up_rewards withdrawRewards => withdraw_rewards @@ -70,7 +71,6 @@ multiversx_sc_wasm_adapter::endpoints! { unstakeFarmThroughProxy => unstake_farm_through_proxy unbondFarm => unbond_farm claimBoostedRewards => claim_boosted_rewards - setBoostedYieldsRewardsPercentage => set_boosted_yields_rewards_percentage collectUndistributedBoostedRewards => collect_undistributed_boosted_rewards getBoostedYieldsRewardsPercentage => boosted_yields_rewards_percentage getAccumulatedRewardsForWeek => accumulated_rewards_for_week diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index ad0917915..e4c426d27 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -6,7 +6,8 @@ use common_structs::FarmTokenAttributes; use config::ConfigModule; use energy_factory::{energy::EnergyModule, SimpleLockEnergy}; use energy_query::Energy; -use farm::exit_penalty::{DEFAULT_PENALTY_PERCENT, MAX_PERCENT}; +use farm::exit_penalty::DEFAULT_PENALTY_PERCENT; +use farm::MAX_PERCENT; use multiversx_sc::{ codec::{multi_types::OptionalValue, Empty}, types::{BigInt, EsdtLocalRole, EsdtTokenPayment}, From df2e51d8b73d183fbda4262ceed30c369c0c7437 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 5 Apr 2024 13:47:43 +0300 Subject: [PATCH 008/103] Simple lock whitelist audit improvements --- locked-asset/simple-lock-whitelist/src/lib.rs | 28 ++++++++++++++----- .../simple-lock-whitelist/wasm/src/lib.rs | 7 +++-- 2 files changed, 25 insertions(+), 10 deletions(-) diff --git a/locked-asset/simple-lock-whitelist/src/lib.rs b/locked-asset/simple-lock-whitelist/src/lib.rs index 48192fb15..ad7242da7 100644 --- a/locked-asset/simple-lock-whitelist/src/lib.rs +++ b/locked-asset/simple-lock-whitelist/src/lib.rs @@ -44,6 +44,14 @@ pub trait SimpleLockWhitelist: .set_local_roles_for_address(&address, &[EsdtLocalRole::Transfer], None); } + #[only_owner] + #[endpoint(setTransferRolesReady)] + fn set_transfer_roles_ready(&self, roles_ready: bool) { + self.locked_token().require_issued_or_set(); + + self.transfer_roles_ready().set(roles_ready); + } + #[only_owner] #[endpoint(setTransferRoleProxyLpToken)] fn set_transfer_role_proxy_lp(&self, opt_address: OptionalValue) { @@ -74,13 +82,6 @@ pub trait SimpleLockWhitelist: ); } - #[only_owner] - #[endpoint(setLockedToken)] - fn set_locked_token(&self, token_id: TokenIdentifier) { - require!(token_id.is_valid_esdt_identifier(), "Token id is not valid"); - self.locked_token().set_token_id(token_id); - } - /// Locks a whitelisted token until `unlock_epoch` and receive meta ESDT LOCKED tokens. /// on a 1:1 ratio. If unlock epoch has already passed, the original tokens are sent instead. /// @@ -98,6 +99,7 @@ pub trait SimpleLockWhitelist: unlock_epoch: u64, opt_destination: OptionalValue, ) -> EgldOrEsdtTokenPayment { + self.require_transfer_roles_ready(); let payment = self.call_value().single_esdt(); self.require_token_in_whitelist(&payment.token_identifier); @@ -123,6 +125,7 @@ pub trait SimpleLockWhitelist: &self, opt_destination: OptionalValue, ) -> EgldOrEsdtTokenPayment { + self.require_transfer_roles_ready(); let payment = self.call_value().single_esdt(); let dest_address = self.dest_from_optional(opt_destination); self.unlock_and_send(&dest_address, payment) @@ -135,7 +138,18 @@ pub trait SimpleLockWhitelist: ); } + fn require_transfer_roles_ready(&self) { + require!( + self.transfer_roles_ready().get(), + "Transfer roles not ready" + ); + } + #[view(getTokenWhitelist)] #[storage_mapper("tokenWhitelist")] fn token_whitelist(&self) -> UnorderedSetMapper; + + #[view(getTransferRolesReady)] + #[storage_mapper("transferRolesReady")] + fn transfer_roles_ready(&self) -> SingleValueMapper; } diff --git a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs b/locked-asset/simple-lock-whitelist/wasm/src/lib.rs index ce5b64928..c5890d851 100644 --- a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs +++ b/locked-asset/simple-lock-whitelist/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 26 +// Endpoints: 27 // Async Callback: 1 -// Total number of exported functions: 28 +// Total number of exported functions: 29 #![no_std] #![allow(internal_features)] @@ -22,12 +22,13 @@ multiversx_sc_wasm_adapter::endpoints! { init => init upgrade => upgrade setTransferRoleLockedToken => set_transfer_role + setTransferRolesReady => set_transfer_roles_ready setTransferRoleProxyLpToken => set_transfer_role_proxy_lp setTransferRoleProxyFarmToken => set_transfer_role_proxy_farm - setLockedToken => set_locked_token lockTokens => lock_tokens_endpoint unlockTokens => unlock_tokens_endpoint getTokenWhitelist => token_whitelist + getTransferRolesReady => transfer_roles_ready issueLockedToken => issue_locked_token getLockedTokenId => locked_token issueLpProxyToken => issue_lp_proxy_token From 5a2b1efe1319a13fad67272f5f762956ca3e46ed Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 5 Apr 2024 13:53:45 +0300 Subject: [PATCH 009/103] test fix --- locked-asset/simple-lock-whitelist/tests/whitelist_test.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs b/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs index 54bb650a5..ad429f5a7 100644 --- a/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs +++ b/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs @@ -37,6 +37,8 @@ fn lock_whitelist_test() { sc.init(whitelist); sc.locked_token() .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); + + sc.set_transfer_roles_ready(true); }) .assert_ok(); From f4dcc0438dfa11fc4cdccf1d68a476b5c185c29c Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 8 Apr 2024 11:37:41 +0300 Subject: [PATCH 010/103] transfer roles status backwards compatibility fix --- locked-asset/simple-lock-whitelist/src/lib.rs | 16 +++++++++------- .../tests/whitelist_test.rs | 2 +- .../simple-lock-whitelist/wasm/src/lib.rs | 4 ++-- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/locked-asset/simple-lock-whitelist/src/lib.rs b/locked-asset/simple-lock-whitelist/src/lib.rs index ad7242da7..577671ede 100644 --- a/locked-asset/simple-lock-whitelist/src/lib.rs +++ b/locked-asset/simple-lock-whitelist/src/lib.rs @@ -26,6 +26,8 @@ pub trait SimpleLockWhitelist: let _ = whitelist.insert(token_id); } + + self.transfer_roles_not_set().set(true); } #[endpoint] @@ -45,11 +47,11 @@ pub trait SimpleLockWhitelist: } #[only_owner] - #[endpoint(setTransferRolesReady)] - fn set_transfer_roles_ready(&self, roles_ready: bool) { + #[endpoint(setTransferRolesStatus)] + fn set_transfer_roles_status(&self, roles_status: bool) { self.locked_token().require_issued_or_set(); - self.transfer_roles_ready().set(roles_ready); + self.transfer_roles_not_set().set(roles_status); } #[only_owner] @@ -140,7 +142,7 @@ pub trait SimpleLockWhitelist: fn require_transfer_roles_ready(&self) { require!( - self.transfer_roles_ready().get(), + !self.transfer_roles_not_set().get(), "Transfer roles not ready" ); } @@ -149,7 +151,7 @@ pub trait SimpleLockWhitelist: #[storage_mapper("tokenWhitelist")] fn token_whitelist(&self) -> UnorderedSetMapper; - #[view(getTransferRolesReady)] - #[storage_mapper("transferRolesReady")] - fn transfer_roles_ready(&self) -> SingleValueMapper; + #[view(getTransferRolesNotSet)] + #[storage_mapper("transferRolesNotSet")] + fn transfer_roles_not_set(&self) -> SingleValueMapper; } diff --git a/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs b/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs index ad429f5a7..193c633cf 100644 --- a/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs +++ b/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs @@ -38,7 +38,7 @@ fn lock_whitelist_test() { sc.locked_token() .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); - sc.set_transfer_roles_ready(true); + sc.set_transfer_roles_status(false); }) .assert_ok(); diff --git a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs b/locked-asset/simple-lock-whitelist/wasm/src/lib.rs index c5890d851..855cffa7f 100644 --- a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs +++ b/locked-asset/simple-lock-whitelist/wasm/src/lib.rs @@ -22,13 +22,13 @@ multiversx_sc_wasm_adapter::endpoints! { init => init upgrade => upgrade setTransferRoleLockedToken => set_transfer_role - setTransferRolesReady => set_transfer_roles_ready + setTransferRolesStatus => set_transfer_roles_status setTransferRoleProxyLpToken => set_transfer_role_proxy_lp setTransferRoleProxyFarmToken => set_transfer_role_proxy_farm lockTokens => lock_tokens_endpoint unlockTokens => unlock_tokens_endpoint getTokenWhitelist => token_whitelist - getTransferRolesReady => transfer_roles_ready + getTransferRolesNotSet => transfer_roles_not_set issueLockedToken => issue_locked_token getLockedTokenId => locked_token issueLpProxyToken => issue_lp_proxy_token From 44cbbf1ab7ea463ca8109df3ad5e1eac1b474deb Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 8 Apr 2024 12:29:51 +0300 Subject: [PATCH 011/103] Farm tests with original caller merge fix --- common/common_structs/src/farm_types.rs | 4 +- dex/farm-with-locked-rewards/src/lib.rs | 9 +- dex/farm/src/base_functions.rs | 8 +- dex/farm/src/lib.rs | 10 +- .../tests/farm_setup/multi_user_farm_setup.rs | 171 +++++++- dex/farm/tests/total_farm_position_test.rs | 378 +++++++++++++++++- 6 files changed, 548 insertions(+), 32 deletions(-) diff --git a/common/common_structs/src/farm_types.rs b/common/common_structs/src/farm_types.rs index db4d515c9..d7d85e20b 100644 --- a/common/common_structs/src/farm_types.rs +++ b/common/common_structs/src/farm_types.rs @@ -51,8 +51,8 @@ impl FixedSupplyToken for FarmTokenAttributes { impl Mergeable for FarmTokenAttributes { #[inline] - fn can_merge_with(&self, other: &Self) -> bool { - self.original_owner == other.original_owner + fn can_merge_with(&self, _other: &Self) -> bool { + true } fn merge_with(&mut self, other: Self) { diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index a42f6518c..a80286cb0 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -8,6 +8,7 @@ multiversx_sc::derive_imports!(); use common_structs::FarmTokenAttributes; use contexts::storage_cache::StorageCache; use core::marker::PhantomData; +use fixed_supply_token::FixedSupplyToken; use farm::{ base_functions::{BaseFunctionsModule, ClaimRewardsResultType, DoubleMultiPayment, Wrapper}, @@ -198,7 +199,13 @@ pub trait Farm: self.migrate_old_farm_positions(&orig_caller); let boosted_rewards = self.claim_only_boosted_payment(&orig_caller); - let merged_farm_token = self.merge_farm_tokens::>(); + let mut output_attributes = self.merge_and_return_attributes::>(); + output_attributes.original_owner = orig_caller.clone(); + + let new_token_amount = output_attributes.get_total_supply(); + let merged_farm_token = self + .farm_token() + .nft_create(new_token_amount, &output_attributes); self.send_payment_non_zero(&caller, &merged_farm_token); let locked_rewards_payment = self.send_to_lock_contract_non_zero( diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index 968e3381d..5db197c67 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -11,7 +11,6 @@ use common_structs::FarmTokenAttributes; use contexts::storage_cache::StorageCache; use farm_base_impl::base_traits_impl::{DefaultFarmWrapper, FarmContract}; -use fixed_supply_token::FixedSupplyToken; use crate::exit_penalty; @@ -183,7 +182,7 @@ pub trait BaseFunctionsModule: } } - fn merge_farm_tokens>(&self) -> EsdtTokenPayment { + fn merge_and_return_attributes>(&self) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); token_mapper.require_all_same_token(&payments); @@ -191,10 +190,7 @@ pub trait BaseFunctionsModule: let caller = self.blockchain().get_caller(); FC::check_and_update_user_farm_position(self, &caller, &payments); - let output_attributes: FC::AttributesType = - self.merge_from_payments_and_burn(payments, &token_mapper); - let new_token_amount = output_attributes.get_total_supply(); - token_mapper.nft_create(new_token_amount, &output_attributes) + self.merge_from_payments_and_burn(payments, &token_mapper) } fn claim_only_boosted_payment(&self, caller: &ManagedAddress) -> BigUint { diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 669dd2e50..ac425143b 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -16,6 +16,7 @@ use exit_penalty::{ DEFAULT_BURN_GAS_LIMIT, DEFAULT_MINUMUM_FARMING_EPOCHS, DEFAULT_PENALTY_PERCENT, }; use farm_base_impl::base_traits_impl::FarmContract; +use fixed_supply_token::FixedSupplyToken; pub type EnterFarmResultType = DoubleMultiPayment; pub type ExitFarmWithPartialPosResultType = DoubleMultiPayment; @@ -193,7 +194,14 @@ pub trait Farm: let boosted_rewards_payment = EsdtTokenPayment::new(self.reward_token_id().get(), 0, boosted_rewards); - let merged_farm_token = self.merge_farm_tokens::>(); + let mut output_attributes = self.merge_and_return_attributes::>(); + output_attributes.original_owner = orig_caller; + + let new_token_amount = output_attributes.get_total_supply(); + let merged_farm_token = self + .farm_token() + .nft_create(new_token_amount, &output_attributes); + self.send_payment_non_zero(&caller, &merged_farm_token); self.send_payment_non_zero(&caller, &boosted_rewards_payment); diff --git a/dex/farm/tests/farm_setup/multi_user_farm_setup.rs b/dex/farm/tests/farm_setup/multi_user_farm_setup.rs index 2e74ab42c..60a82cea2 100644 --- a/dex/farm/tests/farm_setup/multi_user_farm_setup.rs +++ b/dex/farm/tests/farm_setup/multi_user_farm_setup.rs @@ -33,6 +33,7 @@ pub static FARM_TOKEN_ID: &[u8] = b"FARM-123456"; pub const DIV_SAFETY: u64 = 1_000_000_000_000; pub const PER_BLOCK_REWARD_AMOUNT: u64 = 1_000; pub const FARMING_TOKEN_BALANCE: u64 = 200_000_000; +pub const MAX_PERCENTAGE: u64 = 10_000; // 100% pub const BOOSTED_YIELDS_PERCENTAGE: u64 = 2_500; // 25% pub const MAX_REWARDS_FACTOR: u64 = 10; pub const USER_REWARDS_ENERGY_CONST: u64 = 3; @@ -48,6 +49,11 @@ pub struct RawFarmTokenAttributes { pub original_owner_bytes: [u8; 32], } +pub struct NonceAmountPair { + pub nonce: u64, + pub amount: u64, +} + pub struct MultiUserFarmSetup where FarmObjBuilder: 'static + Copy + Fn() -> farm::ContractObj, @@ -310,28 +316,18 @@ where result } - pub fn merge_farm_tokens( - &mut self, - user: &Address, - first_token_nonce: u64, - first_token_amount: u64, - second_token_nonce: u64, - second_token_amount: u64, - ) { + pub fn merge_farm_tokens(&mut self, user: &Address, farm_tokens: Vec) { self.last_farm_token_nonce += 1; - let expected_farm_token_nonce = self.last_farm_token_nonce; - let expected_farm_token_amount = first_token_amount + second_token_amount; + let mut expected_farm_token_amount = 0; let mut payments = Vec::new(); - payments.push(TxTokenTransfer { - token_identifier: FARM_TOKEN_ID.to_vec(), - nonce: first_token_nonce, - value: rust_biguint!(first_token_amount), - }); - payments.push(TxTokenTransfer { - token_identifier: FARM_TOKEN_ID.to_vec(), - nonce: second_token_nonce, - value: rust_biguint!(second_token_amount), - }); + for farm_token in farm_tokens { + expected_farm_token_amount += farm_token.amount; + payments.push(TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: farm_token.nonce, + value: rust_biguint!(farm_token.amount), + }); + } self.b_mock .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { @@ -342,7 +338,7 @@ where out_farm_token.token_identifier, managed_token_id!(FARM_TOKEN_ID) ); - assert_eq!(out_farm_token.token_nonce, expected_farm_token_nonce); + assert_eq!(out_farm_token.token_nonce, self.last_farm_token_nonce); assert_eq!( out_farm_token.amount, managed_biguint!(expected_farm_token_amount) @@ -451,6 +447,54 @@ where result } + pub fn claim_rewards_with_multiple_payments( + &mut self, + user: &Address, + farm_token_payments: Vec, + ) -> u64 { + self.last_farm_token_nonce += 1; + + let mut expected_farm_token_amount = 0; + let mut payments = vec![]; + + for farm_token_payment in farm_token_payments { + expected_farm_token_amount += farm_token_payment.amount; + payments.push(TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: farm_token_payment.nonce, + value: rust_biguint!(farm_token_payment.amount), + }); + } + + let expected_farm_token_nonce = self.last_farm_token_nonce; + let mut result = 0; + self.b_mock + .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { + let (out_farm_token, out_reward_token) = + sc.claim_rewards_endpoint(OptionalValue::None).into_tuple(); + assert_eq!( + out_farm_token.token_identifier, + managed_token_id!(FARM_TOKEN_ID) + ); + assert_eq!(out_farm_token.token_nonce, expected_farm_token_nonce); + assert_eq!( + out_farm_token.amount, + managed_biguint!(expected_farm_token_amount) + ); + + assert_eq!( + out_reward_token.token_identifier, + managed_token_id!(REWARD_TOKEN_ID) + ); + assert_eq!(out_reward_token.token_nonce, 0); + + result = out_reward_token.amount.to_u64().unwrap(); + }) + .assert_ok(); + + result + } + pub fn claim_boosted_rewards_for_user(&mut self, owner: &Address, broker: &Address) -> u64 { self.last_farm_token_nonce += 1; @@ -691,4 +735,89 @@ where }) .assert_ok(); } + + // With the current checks, works only on full position sent (amount/nonce) + pub fn send_farm_position( + &mut self, + sender: &Address, + receiver: &Address, + nonce: u64, + amount: u64, + attr_reward_per_share: u64, + attr_entering_epoch: u64, + ) { + self.b_mock.check_nft_balance( + sender, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(amount), + Some(&FarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + entering_epoch: attr_entering_epoch, + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }), + ); + + self.b_mock + .check_nft_balance::>( + receiver, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(0), + None, + ); + + self.b_mock.set_nft_balance( + sender, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(0), + &FarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + entering_epoch: attr_entering_epoch, + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }, + ); + + self.b_mock.set_nft_balance( + receiver, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(amount), + &FarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + entering_epoch: attr_entering_epoch, + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }, + ); + + self.b_mock + .check_nft_balance::>( + sender, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(0), + None, + ); + + self.b_mock.check_nft_balance( + receiver, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(amount), + Some(&FarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + entering_epoch: attr_entering_epoch, + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }), + ); + } } diff --git a/dex/farm/tests/total_farm_position_test.rs b/dex/farm/tests/total_farm_position_test.rs index 26756ebaa..694f6f12e 100644 --- a/dex/farm/tests/total_farm_position_test.rs +++ b/dex/farm/tests/total_farm_position_test.rs @@ -4,7 +4,10 @@ mod farm_setup; use common_structs::FarmTokenAttributes; use config::ConfigModule; -use farm_setup::multi_user_farm_setup::{MultiUserFarmSetup, BOOSTED_YIELDS_PERCENTAGE}; +use farm_setup::multi_user_farm_setup::{ + MultiUserFarmSetup, NonceAmountPair, BOOSTED_YIELDS_PERCENTAGE, MAX_PERCENTAGE, + PER_BLOCK_REWARD_AMOUNT, +}; use multiversx_sc_scenario::{managed_address, managed_biguint, rust_biguint, DebugApi}; use crate::farm_setup::multi_user_farm_setup::{FARM_TOKEN_ID, REWARD_TOKEN_ID}; @@ -480,6 +483,177 @@ fn farm_total_position_exit_migration_test() { ); } +#[test] +fn farm_total_position_on_claim_migration_test() { + DebugApi::dummy(); + let mut farm_setup = MultiUserFarmSetup::new( + farm::contract_obj, + energy_factory_mock::contract_obj, + energy_update::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + // first user enter farm + let farm_in_amount = 50_000_000; + let first_user = farm_setup.first_user.clone(); + farm_setup.enter_farm(&first_user, farm_in_amount); + + // Remove current farm position from storage + farm_setup.set_user_total_farm_position(&first_user, 0); + farm_setup.check_user_total_farm_position(&first_user, 0); + + // User enters farm again + farm_setup.enter_farm(&first_user, farm_in_amount); + farm_setup.check_user_total_farm_position(&first_user, farm_in_amount); + + // Set farm position migration nonce + farm_setup + .b_mock + .execute_tx( + &farm_setup.owner, + &farm_setup.farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.farm_position_migration_nonce().set(2); + }, + ) + .assert_ok(); + + farm_setup.check_farm_token_supply(farm_in_amount * 2); + + // claim rewards with both positions + let total_farm_tokens = farm_in_amount * 2; + let payments = vec![ + NonceAmountPair { + nonce: 1, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 2, + amount: farm_in_amount, + }, + ]; + + let block_nonce = 10; + farm_setup.b_mock.set_block_nonce(block_nonce); + + farm_setup.check_user_total_farm_position(&first_user, farm_in_amount); + let _ = farm_setup.claim_rewards_with_multiple_payments(&first_user, payments); + farm_setup.check_user_total_farm_position(&first_user, total_farm_tokens); + + farm_setup + .b_mock + .check_nft_balance::>( + &first_user, + FARM_TOKEN_ID, + 3, + &rust_biguint!(total_farm_tokens), + None, + ); + + // User receives rewards only for the new position + let expected_user_rewards = block_nonce + * PER_BLOCK_REWARD_AMOUNT + * (MAX_PERCENTAGE - BOOSTED_YIELDS_PERCENTAGE) + * farm_in_amount + / total_farm_tokens + / MAX_PERCENTAGE; + farm_setup.b_mock.check_esdt_balance( + &first_user, + REWARD_TOKEN_ID, + &rust_biguint!(expected_user_rewards), + ); +} + +#[test] +fn farm_total_position_on_merge_migration_test() { + DebugApi::dummy(); + let mut farm_setup = MultiUserFarmSetup::new( + farm::contract_obj, + energy_factory_mock::contract_obj, + energy_update::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + // user has 2 old farm position + let farm_in_amount = 25_000_000; + let first_user = farm_setup.first_user.clone(); + farm_setup.enter_farm(&first_user, farm_in_amount); + farm_setup.enter_farm(&first_user, farm_in_amount); + + // Remove current farm position from storage + farm_setup.set_user_total_farm_position(&first_user, 0); + farm_setup.check_user_total_farm_position(&first_user, 0); + + // User enters farm again, with 2 new positions + farm_setup.enter_farm(&first_user, farm_in_amount); + farm_setup.enter_farm(&first_user, farm_in_amount); + farm_setup.check_user_total_farm_position(&first_user, farm_in_amount * 2); + + // Set farm position migration nonce + farm_setup + .b_mock + .execute_tx( + &farm_setup.owner, + &farm_setup.farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.farm_position_migration_nonce().set(3); + }, + ) + .assert_ok(); + + let total_farm_tokens = farm_in_amount * 4; + farm_setup.check_farm_token_supply(total_farm_tokens); + + // merge all 4 farm positions + let payments = vec![ + NonceAmountPair { + nonce: 1, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 2, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 3, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 4, + amount: farm_in_amount, + }, + ]; + + let block_nonce = 10; + farm_setup.b_mock.set_block_nonce(block_nonce); + + farm_setup.check_user_total_farm_position(&first_user, farm_in_amount * 2); + let _ = farm_setup.merge_farm_tokens(&first_user, payments); + farm_setup.check_user_total_farm_position(&first_user, total_farm_tokens); + + farm_setup + .b_mock + .check_nft_balance::>( + &first_user, + FARM_TOKEN_ID, + 5, + &rust_biguint!(total_farm_tokens), + None, + ); + + farm_setup + .b_mock + .check_esdt_balance(&first_user, REWARD_TOKEN_ID, &rust_biguint!(0)); +} + #[test] fn no_boosted_rewards_penalty_for_no_energy_test() { DebugApi::dummy(); @@ -560,3 +734,205 @@ fn no_boosted_rewards_penalty_for_no_energy_test() { &rust_biguint!(first_receveived_reward_amt), ); } + +#[test] +fn total_farm_position_owner_change_test() { + DebugApi::dummy(); + let mut farm_setup = MultiUserFarmSetup::new( + farm::contract_obj, + energy_factory_mock::contract_obj, + energy_update::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + // first user enters farm 6 times + let farm_token_amount = 10_000_000; + let first_user = farm_setup.first_user.clone(); + let second_user = farm_setup.second_user.clone(); + let third_user = farm_setup.third_user.clone(); + + farm_setup.set_user_energy(&first_user, 1_000, 2, 1); + farm_setup.enter_farm(&first_user, farm_token_amount); + farm_setup.enter_farm(&first_user, farm_token_amount); + farm_setup.enter_farm(&first_user, farm_token_amount); + farm_setup.enter_farm(&first_user, farm_token_amount); + farm_setup.enter_farm(&first_user, farm_token_amount); + farm_setup.enter_farm(&first_user, farm_token_amount); + + farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 6); + farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 0); + + assert_eq!(farm_setup.last_farm_token_nonce, 6); + + // First user transfers 5 position to second user + farm_setup.send_farm_position(&first_user, &second_user, 1, farm_token_amount, 0, 2); + farm_setup.send_farm_position(&first_user, &second_user, 2, farm_token_amount, 0, 2); + farm_setup.send_farm_position(&first_user, &second_user, 3, farm_token_amount, 0, 2); + farm_setup.send_farm_position(&first_user, &second_user, 4, farm_token_amount, 0, 2); + farm_setup.send_farm_position(&first_user, &second_user, 5, farm_token_amount, 0, 2); + + // Total farm position unchanged as users only transfered the farm positions + farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 6); + farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 0); + + // second user enter farm + farm_setup.set_user_energy(&second_user, 4_000, 2, 1); + farm_setup.enter_farm_with_additional_payment( + &second_user, + farm_token_amount, + 1, + farm_token_amount, + ); + + // 1 farm position was removed from first user and added to the second user (who entered the farm with a position of his own) + farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 5); + farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 2); + + // users claim rewards to get their energy registered + let _ = farm_setup.claim_rewards(&first_user, 6, farm_token_amount); + let _ = farm_setup.claim_rewards(&second_user, 7, farm_token_amount); + + // random tx on end of week 1, to cummulate rewards + farm_setup.b_mock.set_block_nonce(10); + farm_setup.b_mock.set_block_epoch(6); + farm_setup.set_user_energy(&first_user, 1_000, 6, 1); + farm_setup.set_user_energy(&second_user, 4_000, 6, 1); + farm_setup.set_user_energy(&third_user, 1, 6, 1); + farm_setup.enter_farm(&third_user, 1); + farm_setup.exit_farm(&third_user, 10, 1); + + // advance 1 week + farm_setup.b_mock.set_block_epoch(10); + farm_setup.set_user_energy(&first_user, 1_000, 10, 1); + farm_setup.set_user_energy(&second_user, 4_000, 10, 1); + + // Second user claims with a position from the first user + let base_rewards_amount = 1071; + let boosted_rewards_amount = 1485; + let mut second_user_reward_balance = base_rewards_amount + boosted_rewards_amount; + + let second_received_reward_amt = farm_setup.claim_rewards(&second_user, 2, farm_token_amount); + assert_eq!(second_received_reward_amt, second_user_reward_balance); + + farm_setup.b_mock.check_esdt_balance( + &second_user, + REWARD_TOKEN_ID, + &rust_biguint!(second_user_reward_balance), + ); + + farm_setup.b_mock.check_nft_balance( + &second_user, + FARM_TOKEN_ID, + 11, + &rust_biguint!(farm_token_amount), + Some(&FarmTokenAttributes:: { + reward_per_share: managed_biguint!(107142857), + entering_epoch: 2, + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(farm_token_amount), + original_owner: managed_address!(&second_user), + }), + ); + + // Check users positions after claim + farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 4); + farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 3); + + // random tx on end of week 2, to cummulate rewards + farm_setup.b_mock.set_block_nonce(20); + farm_setup.b_mock.set_block_epoch(13); + farm_setup.set_user_energy(&first_user, 1_000, 13, 1); + farm_setup.set_user_energy(&second_user, 4_000, 13, 1); + farm_setup.set_user_energy(&third_user, 1, 13, 1); + farm_setup.enter_farm(&third_user, 1); + farm_setup.exit_farm(&third_user, 12, 1); + + // advance 1 week + farm_setup.b_mock.set_block_epoch(15); + farm_setup.set_user_energy(&first_user, 1_000, 15, 1); + farm_setup.set_user_energy(&second_user, 4_000, 15, 1); + + // Second user exits farm with a position previously owned by user 1 + second_user_reward_balance += 2142; // base rewards + second_user_reward_balance += 1630; // boosted rewards + farm_setup.exit_farm(&second_user, 3, farm_token_amount); + farm_setup + .b_mock + .check_esdt_balance(&second_user, REWARD_TOKEN_ID, &rust_biguint!(6328)); + + // Check users positions after exit + farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 3); + farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 3); + + // random tx on end of week 3, to cummulate rewards + farm_setup.b_mock.set_block_nonce(30); + farm_setup.b_mock.set_block_epoch(20); + farm_setup.set_user_energy(&first_user, 1_000, 20, 1); + farm_setup.set_user_energy(&second_user, 4_000, 20, 1); + farm_setup.set_user_energy(&third_user, 1, 20, 1); + farm_setup.enter_farm(&third_user, 1); + farm_setup.exit_farm(&third_user, 13, 1); + + // advance 1 week + farm_setup.b_mock.set_block_epoch(25); + farm_setup.set_user_energy(&first_user, 1_000, 25, 1); + farm_setup.set_user_energy(&second_user, 4_000, 25, 1); + + // First user claims rewards + let first_user_received_reward_amt = + farm_setup.claim_rewards(&first_user, 8, farm_token_amount); + assert_eq!(first_user_received_reward_amt, 5642); + + // Check users positions after first user claim + farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 3); + farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 3); + + // Second user merges his tokens with first user initial token + let farm_tokens = vec![ + NonceAmountPair { + nonce: 4, + amount: farm_token_amount, + }, + NonceAmountPair { + nonce: 5, + amount: farm_token_amount, + }, + NonceAmountPair { + nonce: 11, + amount: farm_token_amount, + }, + ]; + + farm_setup.b_mock.check_esdt_balance( + &second_user, + REWARD_TOKEN_ID, + &rust_biguint!(second_user_reward_balance), + ); + farm_setup.merge_farm_tokens(&second_user, farm_tokens); + second_user_reward_balance += 1703; // boosted rewards + farm_setup.b_mock.check_esdt_balance( + &second_user, + REWARD_TOKEN_ID, + &rust_biguint!(second_user_reward_balance), + ); + farm_setup.b_mock.check_nft_balance( + &second_user, + FARM_TOKEN_ID, + 15, + &rust_biguint!(farm_token_amount * 3), + Some(&FarmTokenAttributes:: { + reward_per_share: managed_biguint!(35714286), + entering_epoch: 2, + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(farm_token_amount * 3), + original_owner: managed_address!(&second_user), + }), + ); + + // Check users positions after merge + farm_setup.check_user_total_farm_position(&first_user, farm_token_amount); + farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 5); +} From e4cfd1397756f39d42bcfb666969dba7f6ffbbe6 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 8 Apr 2024 12:33:38 +0300 Subject: [PATCH 012/103] clippy fixes --- dex/farm/tests/total_farm_position_test.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dex/farm/tests/total_farm_position_test.rs b/dex/farm/tests/total_farm_position_test.rs index 694f6f12e..47518da0c 100644 --- a/dex/farm/tests/total_farm_position_test.rs +++ b/dex/farm/tests/total_farm_position_test.rs @@ -636,7 +636,7 @@ fn farm_total_position_on_merge_migration_test() { farm_setup.b_mock.set_block_nonce(block_nonce); farm_setup.check_user_total_farm_position(&first_user, farm_in_amount * 2); - let _ = farm_setup.merge_farm_tokens(&first_user, payments); + farm_setup.merge_farm_tokens(&first_user, payments); farm_setup.check_user_total_farm_position(&first_user, total_farm_tokens); farm_setup @@ -763,7 +763,7 @@ fn total_farm_position_owner_change_test() { farm_setup.enter_farm(&first_user, farm_token_amount); farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 6); - farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 0); + farm_setup.check_user_total_farm_position(&second_user, 0); assert_eq!(farm_setup.last_farm_token_nonce, 6); @@ -776,7 +776,7 @@ fn total_farm_position_owner_change_test() { // Total farm position unchanged as users only transfered the farm positions farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 6); - farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 0); + farm_setup.check_user_total_farm_position(&second_user, 0); // second user enter farm farm_setup.set_user_energy(&second_user, 4_000, 2, 1); From d7dc1ac7a255f43285e1c01a22a5c9b86c6ceed4 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 8 Apr 2024 18:07:03 +0300 Subject: [PATCH 013/103] Safe Price tests clippy fixes --- dex/pair/tests/pair_rs_test.rs | 24 ++---------------------- dex/pair/tests/pair_setup/mod.rs | 6 +----- 2 files changed, 3 insertions(+), 27 deletions(-) diff --git a/dex/pair/tests/pair_rs_test.rs b/dex/pair/tests/pair_rs_test.rs index 4de31606c..bd82750d8 100644 --- a/dex/pair/tests/pair_rs_test.rs +++ b/dex/pair/tests/pair_rs_test.rs @@ -148,11 +148,6 @@ fn test_safe_price_migration() { let payment_amount = 1000; let mut expected_amount = 996; - let mut first_token_reserve = 1_002_000; - let mut second_token_reserve = 1_000_004; - let mut first_token_accumulated = 1_001_000; - let mut second_token_accumulated = 1_001_000; - let weight = 10; let mut block_round = starting_round + weight; pair_setup.b_mock.set_block_round(block_round); @@ -190,14 +185,7 @@ fn test_safe_price_migration() { ); pair_setup.check_lp_amount(lp_amount); - first_token_accumulated += weight * first_token_reserve; - second_token_accumulated += weight * second_token_reserve; - block_round += weight; - first_token_reserve += payment_amount; - second_token_reserve -= expected_amount; - first_token_accumulated += weight * first_token_reserve; - second_token_accumulated += weight * second_token_reserve; expected_amount -= 2; pair_setup.b_mock.set_block_round(block_round); @@ -223,10 +211,6 @@ fn test_safe_price_migration() { pair_setup.check_lp_amount(lp_amount); block_round += weight; - first_token_reserve += payment_amount; - second_token_reserve -= expected_amount; - first_token_accumulated += weight * first_token_reserve; - second_token_accumulated += weight * second_token_reserve; expected_amount -= 1; pair_setup.b_mock.set_block_round(block_round); pair_setup.swap_fixed_input( @@ -239,10 +223,6 @@ fn test_safe_price_migration() { pair_setup.check_lp_amount(lp_amount); block_round += weight; - first_token_reserve += payment_amount; - second_token_reserve -= expected_amount; - first_token_accumulated += weight * first_token_reserve; - second_token_accumulated += weight * second_token_reserve; expected_amount -= 1; pair_setup.b_mock.set_block_round(block_round); pair_setup.swap_fixed_input( @@ -290,8 +270,8 @@ fn test_safe_price_migration() { ); // Simulate old price observations - pair_setup.set_price_observation_as_old(&pair_address, 1); - pair_setup.set_price_observation_as_old(&pair_address, 2); + pair_setup.set_price_observation_as_old(1); + pair_setup.set_price_observation_as_old(2); // Check migration safe price // Both observations are old diff --git a/dex/pair/tests/pair_setup/mod.rs b/dex/pair/tests/pair_setup/mod.rs index a232daf5d..083ec8e40 100644 --- a/dex/pair/tests/pair_setup/mod.rs +++ b/dex/pair/tests/pair_setup/mod.rs @@ -407,11 +407,7 @@ where }); } - pub fn set_price_observation_as_old( - &mut self, - pair_address: &Address, - observation_index: usize, - ) { + pub fn set_price_observation_as_old(&mut self, observation_index: usize) { let _ = self.b_mock.execute_query(&self.pair_wrapper, |sc| { let price_observations = sc.price_observations(); From ce8b8330176f9afbc5ddfdf656e2a78ef2d5a9e4 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 9 Apr 2024 13:43:01 +0300 Subject: [PATCH 014/103] Github actions on rc branches --- .github/workflows/actions.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml index 56d357593..afa63aa92 100644 --- a/.github/workflows/actions.yml +++ b/.github/workflows/actions.yml @@ -2,9 +2,9 @@ name: CI on: push: - branches: [ main, feat/* ] + branches: [ main, feat/*, rc/* ] pull_request: - branches: [ main, feat/* ] + branches: [ main, feat/*, rc/* ] workflow_dispatch: permissions: From b21ea70bf19ffbdaea84585ce279e21c7e3fd126 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 10 Apr 2024 16:28:52 +0300 Subject: [PATCH 015/103] Router check pair refactor --- dex/router/src/config.rs | 39 +++++++++++++++++++++++----- dex/router/src/contract.rs | 25 ------------------ dex/router/src/factory.rs | 14 ---------- dex/router/tests/router_setup/mod.rs | 13 ---------- dex/router/tests/router_test.rs | 5 ---- dex/router/wasm/src/lib.rs | 8 +++--- 6 files changed, 36 insertions(+), 68 deletions(-) diff --git a/dex/router/src/config.rs b/dex/router/src/config.rs index 25c96a3e6..925725959 100644 --- a/dex/router/src/config.rs +++ b/dex/router/src/config.rs @@ -10,10 +10,29 @@ pub trait ConfigModule { } fn check_is_pair_sc(&self, pair_address: &ManagedAddress) { - require!( - self.address_pair_map().contains_key(pair_address), - "Not a pair SC" - ); + let first_token_id = self.first_token_id().get_from_address(&pair_address); + let second_token_id = self.second_token_id().get_from_address(&pair_address); + + let pair_tokens = PairTokens { + first_token_id: first_token_id.clone(), + second_token_id: second_token_id.clone(), + }; + + let mut pair_map_address_opt = self.pair_map().get(&pair_tokens); + if pair_map_address_opt.is_none() { + let reverse_pair_tokens = PairTokens { + first_token_id: second_token_id.clone(), + second_token_id: first_token_id.clone(), + }; + pair_map_address_opt = self.pair_map().get(&reverse_pair_tokens); + } + + require!(pair_map_address_opt.is_some(), "Not a pair SC"); + + unsafe { + let pair_map_address = pair_map_address_opt.unwrap_unchecked(); + require!(&pair_map_address == pair_address, "Not a pair SC"); + } } #[view(getPairCreationEnabled)] @@ -43,9 +62,6 @@ pub trait ConfigModule { #[storage_mapper("pair_map")] fn pair_map(&self) -> MapMapper, ManagedAddress>; - #[storage_mapper("address_pair_map")] - fn address_pair_map(&self) -> MapMapper>; - #[view(getPairTemplateAddress)] #[storage_mapper("pair_template_address")] fn pair_template_address(&self) -> SingleValueMapper; @@ -66,4 +82,13 @@ pub trait ConfigModule { #[view(getCommonTokensForUserPairs)] #[storage_mapper("commonTokensForUserPairs")] fn common_tokens_for_user_pairs(&self) -> UnorderedSetMapper; + + // read from other storage + #[view(getFirstTokenId)] + #[storage_mapper("first_token_id")] + fn first_token_id(&self) -> SingleValueMapper; + + #[view(getSecondTokenId)] + #[storage_mapper("second_token_id")] + fn second_token_id(&self) -> SingleValueMapper; } diff --git a/dex/router/src/contract.rs b/dex/router/src/contract.rs index 04b787a03..f90416226 100644 --- a/dex/router/src/contract.rs +++ b/dex/router/src/contract.rs @@ -64,10 +64,6 @@ pub trait Router: #[endpoint] fn resume(&self, address: ManagedAddress) { if address == self.blockchain().get_sc_address() { - require!( - self.pair_map().len() == self.address_pair_map().len(), - "The size of the 2 pair maps is not the same" - ); self.state().set(true); } else { self.check_is_pair_sc(&address); @@ -317,8 +313,6 @@ pub trait Router: .unwrap_or_else(ManagedAddress::zero); } - self.address_pair_map().remove(&pair_address); - pair_address } @@ -385,23 +379,4 @@ pub trait Router: fn set_pair_creation_enabled(&self, enabled: bool) { self.pair_creation_enabled().set(enabled); } - - #[only_owner] - #[endpoint(migratePairMap)] - fn migrate_pair_map(&self) { - let pair_map = self.pair_map(); - let mut address_pair_map = self.address_pair_map(); - require!( - address_pair_map.is_empty(), - "The destination mapper must be empty" - ); - for (pair_tokens, address) in pair_map.iter() { - address_pair_map.insert(address, pair_tokens); - } - - require!( - pair_map.len() == address_pair_map.len(), - "The size of the 2 pair maps is not the same" - ); - } } diff --git a/dex/router/src/factory.rs b/dex/router/src/factory.rs index 4994db235..37a476a8d 100644 --- a/dex/router/src/factory.rs +++ b/dex/router/src/factory.rs @@ -71,13 +71,6 @@ pub trait FactoryModule: config::ConfigModule { }, new_address.clone(), ); - self.address_pair_map().insert( - new_address.clone(), - PairTokens { - first_token_id: first_token_id.clone(), - second_token_id: second_token_id.clone(), - }, - ); self.pair_temporary_owner().insert( new_address.clone(), ( @@ -174,13 +167,6 @@ pub trait FactoryModule: config::ConfigModule { address } - #[view(getPairTokens)] - fn get_pair_tokens(&self, pair_address: ManagedAddress) -> PairTokens { - let pair_tokens_opt = self.address_pair_map().get(&pair_address); - require!(pair_tokens_opt.is_some(), "Pair address not found"); - pair_tokens_opt.unwrap() - } - fn get_pair_temporary_owner(&self, pair_address: &ManagedAddress) -> Option { let result = self.pair_temporary_owner().get(pair_address); diff --git a/dex/router/tests/router_setup/mod.rs b/dex/router/tests/router_setup/mod.rs index c72b6a971..4339d502d 100644 --- a/dex/router/tests/router_setup/mod.rs +++ b/dex/router/tests/router_setup/mod.rs @@ -284,17 +284,4 @@ where ) .assert_ok(); } - - pub fn migrate_pair_map(&mut self) { - self.blockchain_wrapper - .execute_tx( - &self.owner_address, - &self.router_wrapper, - &rust_biguint!(0u64), - |sc| { - sc.migrate_pair_map(); - }, - ) - .assert_ok(); - } } diff --git a/dex/router/tests/router_test.rs b/dex/router/tests/router_test.rs index 54c73c838..54765f2c4 100644 --- a/dex/router/tests/router_test.rs +++ b/dex/router/tests/router_test.rs @@ -134,7 +134,6 @@ fn test_router_upgrade_pair() { #[test] fn test_multi_pair_swap() { let mut router_setup = RouterSetup::new(router::contract_obj, pair::contract_obj); - router_setup.migrate_pair_map(); router_setup.add_liquidity(); @@ -255,8 +254,6 @@ fn user_enable_pair_swaps_through_router_test() { managed_address!(pair_wrapper.address_ref()), ); - sc.migrate_pair_map(); - sc.add_common_tokens_for_user_pairs(MultiValueEncoded::from(ManagedVec::from(vec![ managed_token_id!(USDC_TOKEN_ID), ]))); @@ -442,8 +439,6 @@ fn user_enable_pair_swaps_fail_test() { managed_address!(pair_wrapper.address_ref()), ); - sc.migrate_pair_map(); - sc.add_common_tokens_for_user_pairs(MultiValueEncoded::from(ManagedVec::from(vec![ managed_token_id!(USDC_TOKEN_ID), ]))); diff --git a/dex/router/wasm/src/lib.rs b/dex/router/wasm/src/lib.rs index e840498ec..ee22e6ba5 100644 --- a/dex/router/wasm/src/lib.rs +++ b/dex/router/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 33 +// Endpoints: 32 // Async Callback: 1 -// Total number of exported functions: 35 +// Total number of exported functions: 34 #![no_std] #![allow(internal_features)] @@ -31,7 +31,6 @@ multiversx_sc_wasm_adapter::endpoints! { setFeeOn => set_fee_on setFeeOff => set_fee_off setPairCreationEnabled => set_pair_creation_enabled - migratePairMap => migrate_pair_map getPairCreationEnabled => pair_creation_enabled getState => state getOwner => owner @@ -40,11 +39,12 @@ multiversx_sc_wasm_adapter::endpoints! { getPairTemplateAddress => pair_template_address getTemporaryOwnerPeriod => temporary_owner_period getCommonTokensForUserPairs => common_tokens_for_user_pairs + getFirstTokenId => first_token_id + getSecondTokenId => second_token_id getAllPairsManagedAddresses => get_all_pairs_addresses getAllPairTokens => get_all_token_pairs getAllPairContractMetadata => get_all_pair_contract_metadata getPair => get_pair - getPairTokens => get_pair_tokens clearPairTemporaryOwnerStorage => clear_pair_temporary_owner_storage multiPairSwap => multi_pair_swap configEnableByUserParameters => config_enable_by_user_parameters From 16f0d725d1d6717612023e349450d6bed79bf0de Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 10 Apr 2024 17:04:13 +0300 Subject: [PATCH 016/103] clippy fixes --- dex/router/src/config.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dex/router/src/config.rs b/dex/router/src/config.rs index 925725959..388bc0a44 100644 --- a/dex/router/src/config.rs +++ b/dex/router/src/config.rs @@ -10,8 +10,8 @@ pub trait ConfigModule { } fn check_is_pair_sc(&self, pair_address: &ManagedAddress) { - let first_token_id = self.first_token_id().get_from_address(&pair_address); - let second_token_id = self.second_token_id().get_from_address(&pair_address); + let first_token_id = self.first_token_id().get_from_address(pair_address); + let second_token_id = self.second_token_id().get_from_address(pair_address); let pair_tokens = PairTokens { first_token_id: first_token_id.clone(), From e09da89084d34f342f3ed9cd6819eaeb708244e6 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 11 Apr 2024 11:49:54 +0300 Subject: [PATCH 017/103] framework update v0.48.0 --- Cargo.lock | 305 ++++++++++-------- common/common_errors/Cargo.toml | 2 +- common/common_structs/Cargo.toml | 2 +- common/modules/farm/config/Cargo.toml | 2 +- common/modules/farm/contexts/Cargo.toml | 4 +- common/modules/farm/events/Cargo.toml | 2 +- common/modules/farm/farm_base_impl/Cargo.toml | 6 +- common/modules/farm/farm_token/Cargo.toml | 4 +- .../modules/farm/farm_token_merge/Cargo.toml | 4 +- common/modules/farm/rewards/Cargo.toml | 4 +- .../legacy_token_decode_module/Cargo.toml | 2 +- common/modules/locking_module/Cargo.toml | 2 +- common/modules/math/Cargo.toml | 2 +- common/modules/pausable/Cargo.toml | 2 +- common/modules/permissions_module/Cargo.toml | 2 +- common/modules/sc_whitelist_module/Cargo.toml | 2 +- common/modules/token_merge_helper/Cargo.toml | 2 +- common/modules/token_send/Cargo.toml | 2 +- common/modules/utils/Cargo.toml | 2 +- common/traits/fixed-supply-token/Cargo.toml | 2 +- common/traits/mergeable/Cargo.toml | 2 +- common/traits/unwrappable/Cargo.toml | 2 +- dex/Cargo.toml | 6 +- dex/farm-with-locked-rewards/Cargo.toml | 6 +- dex/farm-with-locked-rewards/meta/Cargo.toml | 2 +- dex/farm-with-locked-rewards/wasm/Cargo.lock | 32 +- dex/farm-with-locked-rewards/wasm/Cargo.toml | 2 +- dex/farm/Cargo.toml | 6 +- dex/farm/meta/Cargo.toml | 2 +- dex/farm/wasm/Cargo.lock | 32 +- dex/farm/wasm/Cargo.toml | 2 +- dex/fuzz/Cargo.toml | 4 +- dex/governance/Cargo.toml | 4 +- dex/governance/meta/Cargo.toml | 2 +- dex/governance/wasm/Cargo.lock | 28 +- dex/governance/wasm/Cargo.toml | 2 +- dex/pair-mock/Cargo.toml | 4 +- dex/pair-mock/elrond.json | 3 - dex/pair-mock/meta/Cargo.toml | 2 +- dex/pair-mock/wasm/Cargo.lock | 28 +- dex/pair-mock/wasm/Cargo.toml | 2 +- dex/pair/Cargo.toml | 4 +- dex/pair/meta/Cargo.toml | 2 +- dex/pair/src/lib.rs | 2 + dex/pair/src/read_pair_storage.rs | 76 +++++ dex/pair/src/safe_price_view.rs | 128 ++++---- dex/pair/tests/pair_setup/mod.rs | 2 +- dex/pair/wasm-pair-full/Cargo.lock | 32 +- dex/pair/wasm-pair-full/Cargo.toml | 2 +- dex/pair/wasm-safe-price-view/Cargo.lock | 32 +- dex/pair/wasm-safe-price-view/Cargo.toml | 2 +- dex/pair/wasm/Cargo.lock | 32 +- dex/pair/wasm/Cargo.toml | 2 +- dex/price-discovery/Cargo.toml | 6 +- dex/price-discovery/meta/Cargo.toml | 2 +- dex/price-discovery/wasm/Cargo.lock | 32 +- dex/price-discovery/wasm/Cargo.toml | 2 +- dex/proxy-deployer/Cargo.toml | 4 +- dex/proxy-deployer/meta/Cargo.toml | 2 +- dex/proxy-deployer/wasm/Cargo.lock | 32 +- dex/proxy-deployer/wasm/Cargo.toml | 2 +- dex/router/Cargo.toml | 4 +- dex/router/meta/Cargo.toml | 2 +- dex/router/wasm/Cargo.lock | 32 +- dex/router/wasm/Cargo.toml | 2 +- dex/router/wasm/src/lib.rs | 4 +- .../common-modules/energy-query/Cargo.toml | 2 +- .../week-timekeeping/Cargo.toml | 2 +- .../weekly-rewards-splitting/Cargo.toml | 2 +- energy-integration/common-types/Cargo.toml | 2 +- .../energy-factory-mock/Cargo.toml | 4 +- .../energy-factory-mock/meta/Cargo.toml | 2 +- .../energy-factory-mock/wasm/Cargo.lock | 32 +- .../energy-factory-mock/wasm/Cargo.toml | 2 +- energy-integration/energy-update/Cargo.toml | 6 +- .../energy-update/meta/Cargo.toml | 2 +- .../energy-update/wasm/Cargo.lock | 32 +- .../energy-update/wasm/Cargo.toml | 2 +- .../farm-boosted-yields/Cargo.toml | 2 +- energy-integration/fees-collector/Cargo.toml | 6 +- .../fees-collector/meta/Cargo.toml | 2 +- .../fees-collector/wasm/Cargo.lock | 32 +- .../fees-collector/wasm/Cargo.toml | 2 +- energy-integration/governance-v2/Cargo.toml | 4 +- .../governance-v2/meta/Cargo.toml | 2 +- .../governance-v2/wasm/Cargo.lock | 32 +- .../governance-v2/wasm/Cargo.toml | 2 +- farm-staking/farm-staking-proxy/Cargo.toml | 6 +- .../farm-staking-proxy/meta/Cargo.toml | 2 +- .../farm-staking-proxy/wasm/Cargo.lock | 32 +- .../farm-staking-proxy/wasm/Cargo.toml | 2 +- farm-staking/farm-staking/Cargo.toml | 6 +- farm-staking/farm-staking/meta/Cargo.toml | 2 +- farm-staking/farm-staking/wasm/Cargo.lock | 32 +- farm-staking/farm-staking/wasm/Cargo.toml | 2 +- farm-staking/metabonding-staking/Cargo.toml | 6 +- .../metabonding-staking/meta/Cargo.toml | 2 +- .../metabonding-staking/wasm/Cargo.lock | 32 +- .../metabonding-staking/wasm/Cargo.toml | 2 +- locked-asset/Cargo.toml | 6 +- locked-asset/distribution/Cargo.toml | 4 +- locked-asset/distribution/meta/Cargo.toml | 2 +- locked-asset/distribution/wasm/Cargo.lock | 32 +- locked-asset/distribution/wasm/Cargo.toml | 2 +- locked-asset/energy-factory/Cargo.toml | 6 +- locked-asset/energy-factory/meta/Cargo.toml | 2 +- locked-asset/energy-factory/wasm/Cargo.lock | 32 +- locked-asset/energy-factory/wasm/Cargo.toml | 2 +- locked-asset/factory/Cargo.toml | 6 +- locked-asset/factory/meta/Cargo.toml | 2 +- locked-asset/factory/wasm/Cargo.lock | 32 +- locked-asset/factory/wasm/Cargo.toml | 2 +- locked-asset/lkmex-transfer/Cargo.toml | 6 +- locked-asset/lkmex-transfer/meta/Cargo.toml | 2 +- locked-asset/lkmex-transfer/wasm/Cargo.lock | 32 +- locked-asset/lkmex-transfer/wasm/Cargo.toml | 2 +- locked-asset/locked-token-wrapper/Cargo.toml | 6 +- .../locked-token-wrapper/meta/Cargo.toml | 2 +- .../locked-token-wrapper/wasm/Cargo.lock | 32 +- .../locked-token-wrapper/wasm/Cargo.toml | 2 +- locked-asset/proxy_dex/Cargo.toml | 6 +- locked-asset/proxy_dex/meta/Cargo.toml | 2 +- locked-asset/proxy_dex/wasm/Cargo.lock | 32 +- locked-asset/proxy_dex/wasm/Cargo.toml | 2 +- locked-asset/simple-lock-whitelist/Cargo.toml | 6 +- .../simple-lock-whitelist/meta/Cargo.toml | 2 +- .../simple-lock-whitelist/wasm/Cargo.lock | 32 +- .../simple-lock-whitelist/wasm/Cargo.toml | 2 +- .../simple-lock-whitelist/wasm/src/lib.rs | 4 +- locked-asset/simple-lock/Cargo.toml | 6 +- locked-asset/simple-lock/meta/Cargo.toml | 2 +- locked-asset/simple-lock/wasm/Cargo.lock | 32 +- locked-asset/simple-lock/wasm/Cargo.toml | 2 +- locked-asset/token-unstake/Cargo.toml | 6 +- locked-asset/token-unstake/meta/Cargo.toml | 2 +- locked-asset/token-unstake/wasm/Cargo.lock | 32 +- locked-asset/token-unstake/wasm/Cargo.toml | 2 +- pause-all/Cargo.toml | 6 +- pause-all/meta/Cargo.toml | 2 +- pause-all/wasm/Cargo.lock | 32 +- pause-all/wasm/Cargo.toml | 2 +- 141 files changed, 896 insertions(+), 802 deletions(-) delete mode 100644 dex/pair-mock/elrond.json create mode 100644 dex/pair/src/read_pair_storage.rs diff --git a/Cargo.lock b/Cargo.lock index dbfbf95f6..6f7637b31 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -123,12 +123,6 @@ version = "0.21.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" -[[package]] -name = "base64ct" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" - [[package]] name = "bech32" version = "0.9.1" @@ -142,8 +136,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" dependencies = [ "bitcoin_hashes", - "rand", - "rand_core", + "rand 0.8.5", + "rand_core 0.6.4", "serde", "unicode-normalization", ] @@ -166,6 +160,15 @@ version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + [[package]] name = "block-buffer" version = "0.10.4" @@ -323,12 +326,6 @@ dependencies = [ "token_send", ] -[[package]] -name = "const-oid" -version = "0.9.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" - [[package]] name = "contexts" version = "0.0.0" @@ -435,42 +432,17 @@ dependencies = [ [[package]] name = "curve25519-dalek" -version = "4.1.1" +version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89b8c6a2e4b1f45971ad09761aafb85514a84744b67a95e32c3cc1352d1f65c" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" dependencies = [ - "cfg-if 1.0.0", - "cpufeatures", - "curve25519-dalek-derive", - "digest", - "fiat-crypto", - "platforms", - "rustc_version", + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", "subtle", "zeroize", ] -[[package]] -name = "curve25519-dalek-derive" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "der" -version = "0.7.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fffa369a668c8af7dbf8b5e56c9f744fbd399949ed171606040001947de40b1c" -dependencies = [ - "const-oid", - "zeroize", -] - [[package]] name = "dex-tests" version = "0.0.0" @@ -497,13 +469,22 @@ dependencies = [ "simple-lock", ] +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + [[package]] name = "digest" version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ - "block-buffer", + "block-buffer 0.10.4", "crypto-common", "subtle", ] @@ -552,25 +533,24 @@ dependencies = [ [[package]] name = "ed25519" -version = "2.2.3" +version = "1.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "115531babc129696a58c64a4fef0a8bf9e9698629fb97e9e40767d235cfbcd53" +checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" dependencies = [ - "pkcs8", "signature", ] [[package]] name = "ed25519-dalek" -version = "2.1.0" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f628eaec48bfd21b865dc2950cfa014450c01d2fa2b69a86c2fd5844ec523c0" +checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" dependencies = [ "curve25519-dalek", "ed25519", + "rand 0.7.3", "serde", - "sha2", - "subtle", + "sha2 0.9.9", "zeroize", ] @@ -969,12 +949,6 @@ dependencies = [ "multiversx-sc-meta", ] -[[package]] -name = "fiat-crypto" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "27573eac26f4dd11e2b1916c3fe1baa56407c83c71a773a8ba17ec0bca03b6b7" - [[package]] name = "fixed-supply-token" version = "0.0.0" @@ -1087,7 +1061,7 @@ dependencies = [ "pair-mock", "pausable", "price-discovery", - "rand", + "rand 0.8.5", "rewards", "router", "simple-lock", @@ -1103,6 +1077,17 @@ dependencies = [ "version_check", ] +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if 1.0.0", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + [[package]] name = "getrandom" version = "0.2.12" @@ -1111,7 +1096,7 @@ checksum = "190092ea657667030ac6a35e305e62fc4dd69fd98ac98631e5d3a2b1575a12b5" dependencies = [ "cfg-if 1.0.0", "libc", - "wasi", + "wasi 0.11.0+wasi-snapshot-preview1", ] [[package]] @@ -1234,7 +1219,7 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "digest", + "digest 0.10.7", ] [[package]] @@ -1565,15 +1550,15 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" dependencies = [ "libc", - "wasi", + "wasi 0.11.0+wasi-snapshot-preview1", "windows-sys 0.48.0", ] [[package]] name = "multiversx-chain-scenario-format" -version = "0.21.1" +version = "0.22.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dfc2b1dc76af14c24145672c2779474046ab44ef56bac82a58844328f4b4d2e" +checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" dependencies = [ "bech32", "hex", @@ -1586,11 +1571,12 @@ dependencies = [ [[package]] name = "multiversx-chain-vm" -version = "0.7.1" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75459864359798406a45a7bb2ed221d623b2e39484ec3e4ac6d23167bfc50b33" +checksum = "a363734a77774f4095fad6f49c6772b82edd833ed47a7c1ca87db18f68ccfffd" dependencies = [ "bitflags 2.4.2", + "colored", "ed25519-dalek", "hex", "hex-literal 0.4.1", @@ -1598,9 +1584,9 @@ dependencies = [ "multiversx-chain-vm-executor", "num-bigint", "num-traits", - "rand", + "rand 0.8.5", "rand_seeder", - "sha2", + "sha2 0.10.8", "sha3", ] @@ -1612,9 +1598,9 @@ checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags 2.4.2", "hex-literal 0.4.1", @@ -1625,9 +1611,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -1636,9 +1622,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -1648,9 +1634,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -1661,9 +1647,9 @@ dependencies = [ [[package]] name = "multiversx-sc-meta" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c8250fd72b78dff76fd3789078aee3dec2524ca37250c645dcb2b1bf067551e" +checksum = "add1bda75ed39bdb246097e5233a4ed7af6587f7c06a7e5084742199d685f6ab" dependencies = [ "clap", "colored", @@ -1677,28 +1663,29 @@ dependencies = [ "reqwest", "ruplacer", "rustc_version", + "semver", "serde", "serde_json", "toml", - "wasmparser 0.118.1", + "wasmparser 0.121.2", "wasmprinter", "zip", ] [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-scenario" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3aa2644018c85caf3cc39a130961e39bd719ff3d75751b60a7394d6eace1c847" +checksum = "42dea5dcc79ef692e907d919ca6bffc81a07c84af977e98b4192c2fd4ff2c67f" dependencies = [ "base64", "bech32", @@ -1718,15 +1705,15 @@ dependencies = [ "pathdiff", "serde", "serde_json", - "sha2", + "sha2 0.10.8", "tokio", ] [[package]] name = "multiversx-sdk" -version = "0.3.1" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f86d0da66ca2eb334414786a287010bb669b8d815a7d3b690d629a04b86bb80" +checksum = "46d709ddf46c50a407ce4b90ff487e854926d47f80de6abfe4a4adca3eaa7964" dependencies = [ "anyhow", "base64", @@ -1737,12 +1724,12 @@ dependencies = [ "itertools 0.12.0", "pbkdf2", "pem", - "rand", + "rand 0.8.5", "reqwest", "serde", "serde_json", "serde_repr", - "sha2", + "sha2 0.10.8", "sha3", "tokio", "zeroize", @@ -1830,6 +1817,12 @@ version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" +[[package]] +name = "opaque-debug" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" + [[package]] name = "openssl" version = "0.10.62" @@ -1981,7 +1974,7 @@ version = "0.12.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" dependencies = [ - "digest", + "digest 0.10.7", ] [[package]] @@ -2021,28 +2014,12 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" -[[package]] -name = "pkcs8" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" -dependencies = [ - "der", - "spki", -] - [[package]] name = "pkg-config" version = "0.3.29" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2900ede94e305130c13ddd391e0ab7cbaeb783945ae07a279c268cb05109c6cb" -[[package]] -name = "platforms" -version = "3.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "626dec3cac7cc0e1577a2ec3fc496277ec2baa084bebad95bb6fdbfae235f84c" - [[package]] name = "ppv-lite86" version = "0.2.17" @@ -2074,9 +2051,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.76" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95fc56cda0b5c3325f5fbbd7ff9fda9e02bb00bb3dac51252d2f1bfa1cb8cc8c" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] @@ -2163,6 +2140,19 @@ dependencies = [ "nibble_vec", ] +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + [[package]] name = "rand" version = "0.8.5" @@ -2170,8 +2160,18 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" dependencies = [ "libc", - "rand_chacha", - "rand_core", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", ] [[package]] @@ -2181,7 +2181,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" dependencies = [ "ppv-lite86", - "rand_core", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", ] [[package]] @@ -2190,7 +2199,16 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom", + "getrandom 0.2.12", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", ] [[package]] @@ -2199,7 +2217,7 @@ version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" dependencies = [ - "rand_core", + "rand_core 0.6.4", ] [[package]] @@ -2487,6 +2505,19 @@ dependencies = [ "serde", ] +[[package]] +name = "sha2" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if 1.0.0", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + [[package]] name = "sha2" version = "0.10.8" @@ -2495,7 +2526,7 @@ checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" dependencies = [ "cfg-if 1.0.0", "cpufeatures", - "digest", + "digest 0.10.7", ] [[package]] @@ -2504,7 +2535,7 @@ version = "0.10.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" dependencies = [ - "digest", + "digest 0.10.7", "keccak", ] @@ -2519,12 +2550,9 @@ dependencies = [ [[package]] name = "signature" -version = "2.2.0" +version = "1.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" -dependencies = [ - "rand_core", -] +checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" [[package]] name = "simple-lock" @@ -2594,16 +2622,6 @@ dependencies = [ "windows-sys 0.48.0", ] -[[package]] -name = "spki" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" -dependencies = [ - "base64ct", - "der", -] - [[package]] name = "strsim" version = "0.10.0" @@ -2938,6 +2956,12 @@ dependencies = [ "try-lock", ] +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + [[package]] name = "wasi" version = "0.11.0+wasi-snapshot-preview1" @@ -3012,19 +3036,20 @@ checksum = "4d91413b1c31d7539ba5ef2451af3f0b833a005eb27a631cec32bc0635a8602b" [[package]] name = "wasmparser" -version = "0.118.1" +version = "0.119.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ee9723b928e735d53000dec9eae7b07a60e490c85ab54abb66659fc61bfcd9" +checksum = "8c35daf77afb4f9b14016625144a391085ec2ca99ca9cc53ed291bb53ab5278d" dependencies = [ + "bitflags 2.4.2", "indexmap", "semver", ] [[package]] name = "wasmparser" -version = "0.119.0" +version = "0.121.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c35daf77afb4f9b14016625144a391085ec2ca99ca9cc53ed291bb53ab5278d" +checksum = "9dbe55c8f9d0dbd25d9447a5a889ff90c0cc3feaa7395310d3d826b2c703eaab" dependencies = [ "bitflags 2.4.2", "indexmap", @@ -3270,6 +3295,20 @@ name = "zeroize" version = "1.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] [[package]] name = "zip" diff --git a/common/common_errors/Cargo.toml b/common/common_errors/Cargo.toml index c61a89e80..09ba443fb 100644 --- a/common/common_errors/Cargo.toml +++ b/common/common_errors/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/common_structs/Cargo.toml b/common/common_structs/Cargo.toml index 8e5655f12..80c4d6b33 100644 --- a/common/common_structs/Cargo.toml +++ b/common/common_structs/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] diff --git a/common/modules/farm/config/Cargo.toml b/common/modules/farm/config/Cargo.toml index b5de657af..f7f478234 100644 --- a/common/modules/farm/config/Cargo.toml +++ b/common/modules/farm/config/Cargo.toml @@ -23,5 +23,5 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/contexts/Cargo.toml b/common/modules/farm/contexts/Cargo.toml index b61c7a7cb..033d99987 100644 --- a/common/modules/farm/contexts/Cargo.toml +++ b/common/modules/farm/contexts/Cargo.toml @@ -35,8 +35,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" diff --git a/common/modules/farm/events/Cargo.toml b/common/modules/farm/events/Cargo.toml index f69904d95..1c4a763d4 100644 --- a/common/modules/farm/events/Cargo.toml +++ b/common/modules/farm/events/Cargo.toml @@ -14,5 +14,5 @@ path = "../../../common_structs" path = "../contexts" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/farm_base_impl/Cargo.toml b/common/modules/farm/farm_base_impl/Cargo.toml index 7ac538eff..119d39c53 100644 --- a/common/modules/farm/farm_base_impl/Cargo.toml +++ b/common/modules/farm/farm_base_impl/Cargo.toml @@ -50,11 +50,11 @@ path = "../../../traits/mergeable" path = "../../../traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/common/modules/farm/farm_token/Cargo.toml b/common/modules/farm/farm_token/Cargo.toml index 64834bd68..d66aef7ed 100644 --- a/common/modules/farm/farm_token/Cargo.toml +++ b/common/modules/farm/farm_token/Cargo.toml @@ -26,8 +26,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" diff --git a/common/modules/farm/farm_token_merge/Cargo.toml b/common/modules/farm/farm_token_merge/Cargo.toml index 4df9540e8..07e671721 100644 --- a/common/modules/farm/farm_token_merge/Cargo.toml +++ b/common/modules/farm/farm_token_merge/Cargo.toml @@ -23,11 +23,11 @@ path = "../../token_merge_helper" path = "../farm_token" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/common/modules/farm/rewards/Cargo.toml b/common/modules/farm/rewards/Cargo.toml index 68d37f46d..d11286d68 100644 --- a/common/modules/farm/rewards/Cargo.toml +++ b/common/modules/farm/rewards/Cargo.toml @@ -29,8 +29,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" diff --git a/common/modules/legacy_token_decode_module/Cargo.toml b/common/modules/legacy_token_decode_module/Cargo.toml index 124b2ec02..54c96c1ca 100644 --- a/common/modules/legacy_token_decode_module/Cargo.toml +++ b/common/modules/legacy_token_decode_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/modules/locking_module/Cargo.toml b/common/modules/locking_module/Cargo.toml index 660635a24..5be58100d 100644 --- a/common/modules/locking_module/Cargo.toml +++ b/common/modules/locking_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.simple-lock] diff --git a/common/modules/math/Cargo.toml b/common/modules/math/Cargo.toml index 5f1f99325..987f0021e 100644 --- a/common/modules/math/Cargo.toml +++ b/common/modules/math/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/pausable/Cargo.toml b/common/modules/pausable/Cargo.toml index 2f258161b..271081564 100644 --- a/common/modules/pausable/Cargo.toml +++ b/common/modules/pausable/Cargo.toml @@ -11,5 +11,5 @@ path = "src/pausable.rs" path = "../permissions_module" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/permissions_module/Cargo.toml b/common/modules/permissions_module/Cargo.toml index fdc8d7d2e..85d7e9b3c 100644 --- a/common/modules/permissions_module/Cargo.toml +++ b/common/modules/permissions_module/Cargo.toml @@ -17,5 +17,5 @@ bitflags = "2.4.1" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/sc_whitelist_module/Cargo.toml b/common/modules/sc_whitelist_module/Cargo.toml index 978cd6a89..1c0fdd874 100644 --- a/common/modules/sc_whitelist_module/Cargo.toml +++ b/common/modules/sc_whitelist_module/Cargo.toml @@ -11,5 +11,5 @@ path = "src/sc_whitelist_module.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_merge_helper/Cargo.toml b/common/modules/token_merge_helper/Cargo.toml index c337a5996..216bf3ebf 100644 --- a/common/modules/token_merge_helper/Cargo.toml +++ b/common/modules/token_merge_helper/Cargo.toml @@ -11,5 +11,5 @@ path = "src/lib.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_send/Cargo.toml b/common/modules/token_send/Cargo.toml index 28b005064..17b83882c 100644 --- a/common/modules/token_send/Cargo.toml +++ b/common/modules/token_send/Cargo.toml @@ -14,5 +14,5 @@ path = "../../common_structs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/utils/Cargo.toml b/common/modules/utils/Cargo.toml index a18635d6e..c17c30212 100644 --- a/common/modules/utils/Cargo.toml +++ b/common/modules/utils/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/traits/fixed-supply-token/Cargo.toml b/common/traits/fixed-supply-token/Cargo.toml index eafd9fe32..bc26dc17d 100644 --- a/common/traits/fixed-supply-token/Cargo.toml +++ b/common/traits/fixed-supply-token/Cargo.toml @@ -8,4 +8,4 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" diff --git a/common/traits/mergeable/Cargo.toml b/common/traits/mergeable/Cargo.toml index 4800de5ca..d0e86244d 100644 --- a/common/traits/mergeable/Cargo.toml +++ b/common/traits/mergeable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/traits/unwrappable/Cargo.toml b/common/traits/unwrappable/Cargo.toml index 9ba6e7e73..fd10b42e4 100644 --- a/common/traits/unwrappable/Cargo.toml +++ b/common/traits/unwrappable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/dex/Cargo.toml b/dex/Cargo.toml index 62d9161bf..7b517a030 100644 --- a/dex/Cargo.toml +++ b/dex/Cargo.toml @@ -5,17 +5,17 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.config] path = "../common/modules/farm/config" diff --git a/dex/farm-with-locked-rewards/Cargo.toml b/dex/farm-with-locked-rewards/Cargo.toml index c19480688..4471c010d 100644 --- a/dex/farm-with-locked-rewards/Cargo.toml +++ b/dex/farm-with-locked-rewards/Cargo.toml @@ -75,17 +75,17 @@ path = "../../locked-asset/energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.simple-lock] path = "../../locked-asset/simple-lock" diff --git a/dex/farm-with-locked-rewards/meta/Cargo.toml b/dex/farm-with-locked-rewards/meta/Cargo.toml index 47476c339..453251275 100644 --- a/dex/farm-with-locked-rewards/meta/Cargo.toml +++ b/dex/farm-with-locked-rewards/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.lock b/dex/farm-with-locked-rewards/wasm/Cargo.lock index f3af20c87..04273a9ea 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.lock +++ b/dex/farm-with-locked-rewards/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -315,9 +315,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -328,9 +328,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -338,9 +338,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -350,9 +350,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -363,18 +363,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -432,9 +432,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.toml b/dex/farm-with-locked-rewards/wasm/Cargo.toml index 369d8346f..701179e7f 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.toml +++ b/dex/farm-with-locked-rewards/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/farm/Cargo.toml b/dex/farm/Cargo.toml index 517a35cae..8563b6fa5 100644 --- a/dex/farm/Cargo.toml +++ b/dex/farm/Cargo.toml @@ -69,11 +69,11 @@ path = "../../energy-integration/common-modules/weekly-rewards-splitting" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies] num-bigint = "0.4.2" @@ -82,7 +82,7 @@ num-bigint = "0.4.2" path = "../../energy-integration/energy-update" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.energy-factory-mock] path = "../../energy-integration/energy-factory-mock" diff --git a/dex/farm/meta/Cargo.toml b/dex/farm/meta/Cargo.toml index d6abd09e7..28f681018 100644 --- a/dex/farm/meta/Cargo.toml +++ b/dex/farm/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/farm/wasm/Cargo.lock b/dex/farm/wasm/Cargo.lock index 2308d9073..2dacef823 100644 --- a/dex/farm/wasm/Cargo.lock +++ b/dex/farm/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -285,9 +285,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -298,9 +298,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -308,9 +308,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -320,9 +320,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -333,18 +333,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -402,9 +402,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/farm/wasm/Cargo.toml b/dex/farm/wasm/Cargo.toml index 26ce2670b..1fa20b905 100644 --- a/dex/farm/wasm/Cargo.toml +++ b/dex/farm/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/fuzz/Cargo.toml b/dex/fuzz/Cargo.toml index 57800c37f..391a4c7c1 100644 --- a/dex/fuzz/Cargo.toml +++ b/dex/fuzz/Cargo.toml @@ -12,11 +12,11 @@ num-bigint = "0.4.2" rand = "0.8.4" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dependencies.pausable] path = "../../common/modules/pausable" diff --git a/dex/governance/Cargo.toml b/dex/governance/Cargo.toml index 74d9f2849..61ba59e59 100644 --- a/dex/governance/Cargo.toml +++ b/dex/governance/Cargo.toml @@ -9,14 +9,14 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.pair-mock] path = "../pair-mock" diff --git a/dex/governance/meta/Cargo.toml b/dex/governance/meta/Cargo.toml index b692c9007..e99c24667 100644 --- a/dex/governance/meta/Cargo.toml +++ b/dex/governance/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/governance/wasm/Cargo.lock b/dex/governance/wasm/Cargo.lock index 30ca50940..5104abd3f 100644 --- a/dex/governance/wasm/Cargo.lock +++ b/dex/governance/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "endian-type" @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -68,9 +68,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -78,9 +78,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -90,9 +90,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -103,9 +103,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -130,9 +130,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/governance/wasm/Cargo.toml b/dex/governance/wasm/Cargo.toml index 905950d0e..7b1d0521f 100644 --- a/dex/governance/wasm/Cargo.toml +++ b/dex/governance/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/pair-mock/Cargo.toml b/dex/pair-mock/Cargo.toml index bc58d1089..4854f150c 100644 --- a/dex/pair-mock/Cargo.toml +++ b/dex/pair-mock/Cargo.toml @@ -12,7 +12,7 @@ path = "src/pair.rs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.itertools] @@ -20,4 +20,4 @@ version = "0.10.1" default-features = false [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/dex/pair-mock/elrond.json b/dex/pair-mock/elrond.json deleted file mode 100644 index 736553962..000000000 --- a/dex/pair-mock/elrond.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "language": "rust" -} \ No newline at end of file diff --git a/dex/pair-mock/meta/Cargo.toml b/dex/pair-mock/meta/Cargo.toml index 673a8fc84..8f2d3b0ca 100644 --- a/dex/pair-mock/meta/Cargo.toml +++ b/dex/pair-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/pair-mock/wasm/Cargo.lock b/dex/pair-mock/wasm/Cargo.lock index 6311e01de..6e83ea775 100644 --- a/dex/pair-mock/wasm/Cargo.lock +++ b/dex/pair-mock/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_errors" @@ -62,9 +62,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -75,9 +75,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -85,9 +85,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -97,9 +97,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -110,9 +110,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/pair-mock/wasm/Cargo.toml b/dex/pair-mock/wasm/Cargo.toml index 9bf537c94..2bbacc718 100644 --- a/dex/pair-mock/wasm/Cargo.toml +++ b/dex/pair-mock/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/pair/Cargo.toml b/dex/pair/Cargo.toml index 457fb8d8f..7fc6998a8 100644 --- a/dex/pair/Cargo.toml +++ b/dex/pair/Cargo.toml @@ -37,11 +37,11 @@ version = "0.10.1" default-features = false [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/dex/pair/meta/Cargo.toml b/dex/pair/meta/Cargo.toml index b07218ea1..508ad1a44 100644 --- a/dex/pair/meta/Cargo.toml +++ b/dex/pair/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/pair/src/lib.rs b/dex/pair/src/lib.rs index 98996e34a..090b66cf3 100644 --- a/dex/pair/src/lib.rs +++ b/dex/pair/src/lib.rs @@ -12,6 +12,7 @@ pub mod fee; mod liquidity_pool; pub mod locking_wrapper; pub mod pair_actions; +pub mod read_pair_storage; pub mod safe_price; pub mod safe_price_view; @@ -33,6 +34,7 @@ pub trait Pair: + config::ConfigModule + token_send::TokenSendModule + events::EventsModule + + read_pair_storage::ReadPairStorageModule + safe_price::SafePriceModule + safe_price_view::SafePriceViewModule + contexts::output_builder::OutputBuilderModule diff --git a/dex/pair/src/read_pair_storage.rs b/dex/pair/src/read_pair_storage.rs new file mode 100644 index 000000000..a14f862c3 --- /dev/null +++ b/dex/pair/src/read_pair_storage.rs @@ -0,0 +1,76 @@ +use multiversx_sc::storage::StorageKey; + +use crate::safe_price::PriceObservation; + +multiversx_sc::imports!(); + +pub static LP_TOKEN_SUPPLY_STORAGE_KEY: &[u8] = b"lp_token_supply"; +pub static FIRST_TOKEN_ID_STORAGE_KEY: &[u8] = b"first_token_id"; +pub static SECOND_TOKEN_ID_STORAGE_KEY: &[u8] = b"second_token_id"; +pub static SAFE_PRICE_CURRENT_INDEX_STORAGE_KEY: &[u8] = b"safe_price_current_index"; +pub static PRICE_OBSERVATIONS_STORAGE_KEY: &[u8] = b"price_observations"; +pub static PAIR_RESERVE_BASE_STORAGE_KEY: &[u8] = b"reserve"; + +#[multiversx_sc::module] +pub trait ReadPairStorageModule { + fn get_lp_token_supply_mapper( + &self, + pair_address: ManagedAddress, + ) -> SingleValueMapper { + SingleValueMapper::<_, _, ManagedAddress>::new_from_address( + pair_address, + StorageKey::new(LP_TOKEN_SUPPLY_STORAGE_KEY), + ) + } + + fn get_first_token_id_mapper( + &self, + pair_address: ManagedAddress, + ) -> SingleValueMapper { + SingleValueMapper::<_, _, ManagedAddress>::new_from_address( + pair_address, + StorageKey::new(FIRST_TOKEN_ID_STORAGE_KEY), + ) + } + + fn get_second_token_id_mapper( + &self, + pair_address: ManagedAddress, + ) -> SingleValueMapper { + SingleValueMapper::<_, _, ManagedAddress>::new_from_address( + pair_address, + StorageKey::new(SECOND_TOKEN_ID_STORAGE_KEY), + ) + } + + fn get_safe_price_current_index_mapper( + &self, + pair_address: ManagedAddress, + ) -> SingleValueMapper { + SingleValueMapper::<_, _, ManagedAddress>::new_from_address( + pair_address, + StorageKey::new(SAFE_PRICE_CURRENT_INDEX_STORAGE_KEY), + ) + } + + fn get_price_observation_mapper( + &self, + pair_address: ManagedAddress, + ) -> VecMapper, ManagedAddress> { + VecMapper::<_, _, ManagedAddress>::new_from_address( + pair_address, + StorageKey::new(PRICE_OBSERVATIONS_STORAGE_KEY), + ) + } + + fn get_pair_reserve_mapper( + &self, + pair_address: ManagedAddress, + token_id: &TokenIdentifier, + ) -> SingleValueMapper { + let mut storage_key = StorageKey::new(PAIR_RESERVE_BASE_STORAGE_KEY); + storage_key.append_item(&token_id); + + SingleValueMapper::<_, _, ManagedAddress>::new_from_address(pair_address, storage_key) + } +} \ No newline at end of file diff --git a/dex/pair/src/safe_price_view.rs b/dex/pair/src/safe_price_view.rs index 16d5d96c3..e286bc370 100644 --- a/dex/pair/src/safe_price_view.rs +++ b/dex/pair/src/safe_price_view.rs @@ -6,6 +6,7 @@ use core::cmp::Ordering; use crate::{ amm, config, errors::{ERROR_SAFE_PRICE_OBSERVATION_DOES_NOT_EXIST, ERROR_SAFE_PRICE_SAME_ROUNDS}, + read_pair_storage, safe_price::{self, PriceObservation, Round, MAX_OBSERVATIONS}, }; @@ -26,6 +27,7 @@ pub trait SafePriceViewModule: + amm::AmmModule + permissions_module::PermissionsModule + pausable::PausableModule + + read_pair_storage::ReadPairStorageModule { #[label("safe-price-view")] #[view(getLpTokensSafePriceByDefaultOffset)] @@ -89,19 +91,16 @@ pub trait SafePriceViewModule: ) -> MultiValue2 { require!(end_round > start_round, ERROR_PARAMETERS); - let first_token_id = self.first_token_id().get_from_address(&pair_address); - let second_token_id = self.second_token_id().get_from_address(&pair_address); + let first_token_id = self.get_first_token_id_mapper(pair_address.clone()).get(); + let second_token_id = self.get_second_token_id_mapper(pair_address.clone()).get(); let safe_price_current_index = self - .safe_price_current_index() - .get_from_address(&pair_address); - let price_observations = self.price_observations(); + .get_safe_price_current_index_mapper(pair_address.clone()) + .get(); + let price_observations = self.get_price_observation_mapper(pair_address.clone()); - let oldest_price_observation = self.get_oldest_price_observation( - &pair_address, - safe_price_current_index, - &price_observations, - ); + let oldest_price_observation = + self.get_oldest_price_observation(safe_price_current_index, &price_observations); require!( start_round >= oldest_price_observation.recording_round, @@ -130,7 +129,7 @@ pub trait SafePriceViewModule: self.compute_weighted_amounts(&first_price_observation, &last_price_observation); if weighted_amounts.weighted_lp_supply == 0 { - let current_lp_supply = self.lp_token_supply().get_from_address(&pair_address); + let current_lp_supply = self.get_lp_token_supply_mapper(pair_address.clone()).get(); if current_lp_supply == 0 { return ( EsdtTokenPayment::new(first_token_id, 0, BigUint::zero()), @@ -212,22 +211,19 @@ pub trait SafePriceViewModule: require!(end_round > start_round, ERROR_PARAMETERS); let safe_price_current_index = self - .safe_price_current_index() - .get_from_address(&pair_address); - let price_observations = self.price_observations(); + .get_safe_price_current_index_mapper(pair_address.clone()) + .get(); + let price_observations = self.get_price_observation_mapper(pair_address.clone()); - let oldest_price_observation = self.get_oldest_price_observation( - &pair_address, - safe_price_current_index, - &price_observations, - ); + let oldest_price_observation = + self.get_oldest_price_observation(safe_price_current_index, &price_observations); require!( oldest_price_observation.recording_round <= start_round, ERROR_SAFE_PRICE_OBSERVATION_DOES_NOT_EXIST ); - let first_token_id = self.first_token_id().get_from_address(&pair_address); - let second_token_id = self.second_token_id().get_from_address(&pair_address); + let first_token_id = self.get_first_token_id_mapper(pair_address.clone()).get(); + let second_token_id = self.get_second_token_id_mapper(pair_address.clone()).get(); let first_price_observation = self.get_price_observation( &pair_address, &first_token_id, @@ -261,17 +257,14 @@ pub trait SafePriceViewModule: search_round: Round, ) -> PriceObservation { let safe_price_current_index = self - .safe_price_current_index() - .get_from_address(&pair_address); - let first_token_id = self.first_token_id().get_from_address(&pair_address); - let second_token_id = self.second_token_id().get_from_address(&pair_address); - let price_observations = self.price_observations(); - - let oldest_price_observation = self.get_oldest_price_observation( - &pair_address, - safe_price_current_index, - &price_observations, - ); + .get_safe_price_current_index_mapper(pair_address.clone()) + .get(); + let first_token_id = self.get_first_token_id_mapper(pair_address.clone()).get(); + let second_token_id = self.get_second_token_id_mapper(pair_address.clone()).get(); + let price_observations = self.get_price_observation_mapper(pair_address.clone()); + + let oldest_price_observation = + self.get_oldest_price_observation(safe_price_current_index, &price_observations); require!( oldest_price_observation.recording_round <= search_round, ERROR_SAFE_PRICE_OBSERVATION_DOES_NOT_EXIST @@ -294,8 +287,8 @@ pub trait SafePriceViewModule: first_price_observation: &PriceObservation, last_price_observation: &PriceObservation, ) -> EsdtTokenPayment { - let first_token_id = self.first_token_id().get_from_address(pair_address); - let second_token_id = self.second_token_id().get_from_address(pair_address); + let first_token_id = self.get_first_token_id_mapper(pair_address.clone()).get(); + let second_token_id = self.get_second_token_id_mapper(pair_address.clone()).get(); let weighted_amounts = self.compute_weighted_amounts(first_price_observation, last_price_observation); @@ -321,16 +314,16 @@ pub trait SafePriceViewModule: first_token_id: &TokenIdentifier, second_token_id: &TokenIdentifier, current_index: usize, - price_observations: &VecMapper>, + price_observations: &VecMapper, ManagedAddress>, search_round: Round, ) -> PriceObservation { require!( - !price_observations.is_empty_at_address(pair_address), + !price_observations.is_empty(), ERROR_SAFE_PRICE_OBSERVATION_DOES_NOT_EXIST ); // Check if the requested price observation is the last one - let last_observation = price_observations.get_at_address(pair_address, current_index); + let last_observation = price_observations.get(current_index); if last_observation.recording_round == search_round { return last_observation; } @@ -346,12 +339,12 @@ pub trait SafePriceViewModule: ); let first_token_reserve = self - .pair_reserve(first_token_id) - .get_from_address(pair_address); + .get_pair_reserve_mapper(pair_address.clone(), first_token_id) + .get(); let second_token_reserve = self - .pair_reserve(second_token_id) - .get_from_address(pair_address); - let current_lp_supply = self.lp_token_supply().get_from_address(pair_address); + .get_pair_reserve_mapper(pair_address.clone(), second_token_id) + .get(); + let current_lp_supply = self.get_lp_token_supply_mapper(pair_address.clone()).get(); return self.compute_new_observation( search_round, &first_token_reserve, @@ -362,7 +355,6 @@ pub trait SafePriceViewModule: } let (mut price_observation, last_search_index) = self.price_observation_by_binary_search( - pair_address, current_index, price_observations, search_round, @@ -373,7 +365,6 @@ pub trait SafePriceViewModule: } price_observation = self.price_observation_by_linear_interpolation( - pair_address, price_observations, search_round, last_search_index, @@ -384,45 +375,43 @@ pub trait SafePriceViewModule: fn get_oldest_price_observation( &self, - pair_address: &ManagedAddress, current_index: usize, - price_observations: &VecMapper>, + price_observations: &VecMapper, ManagedAddress>, ) -> PriceObservation { require!( - !price_observations.is_empty_at_address(pair_address), + !price_observations.is_empty(), ERROR_SAFE_PRICE_OBSERVATION_DOES_NOT_EXIST ); // VecMapper index starts at 1 let mut oldest_observation_index = 1; - if price_observations.len_at_address(pair_address) == MAX_OBSERVATIONS { + if price_observations.len() == MAX_OBSERVATIONS { oldest_observation_index = (current_index % MAX_OBSERVATIONS) + 1 } - price_observations.get_at_address(pair_address, oldest_observation_index) + price_observations.get(oldest_observation_index) } fn price_observation_by_binary_search( &self, - pair_address: &ManagedAddress, current_index: usize, - price_observations: &VecMapper>, + price_observations: &VecMapper, ManagedAddress>, search_round: Round, ) -> (PriceObservation, usize) { let mut search_index = 1; let mut left_index; let mut right_index; - let observation_at_index_1 = price_observations.get_at_address(pair_address, search_index); + let observation_at_index_1 = price_observations.get(search_index); if observation_at_index_1.recording_round <= search_round { left_index = search_index; right_index = current_index - 1; } else { left_index = current_index + 1; - right_index = price_observations.len_at_address(pair_address); + right_index = price_observations.len(); } while left_index <= right_index { search_index = (left_index + right_index) / 2; - let price_observation = price_observations.get_at_address(pair_address, search_index); + let price_observation = price_observations.get(search_index); match price_observation.recording_round.cmp(&search_round) { Ordering::Equal => return (price_observation, search_index), Ordering::Less => left_index = search_index + 1, @@ -435,27 +424,24 @@ pub trait SafePriceViewModule: fn price_observation_by_linear_interpolation( &self, - pair_address: &ManagedAddress, - price_observations: &VecMapper>, + price_observations: &VecMapper, ManagedAddress>, search_round: Round, search_index: usize, ) -> PriceObservation { - let last_found_observation = price_observations.get_at_address(pair_address, search_index); + let last_found_observation = price_observations.get(search_index); let left_observation; let right_observation; if last_found_observation.recording_round < search_round { left_observation = last_found_observation; let right_observation_index = (search_index % MAX_OBSERVATIONS) + 1; - right_observation = - price_observations.get_at_address(pair_address, right_observation_index); + right_observation = price_observations.get(right_observation_index); } else { let left_observation_index = if search_index == 1 { MAX_OBSERVATIONS } else { search_index - 1 }; - left_observation = - price_observations.get_at_address(pair_address, left_observation_index); + left_observation = price_observations.get(left_observation_index); right_observation = last_found_observation; }; @@ -533,14 +519,11 @@ pub trait SafePriceViewModule: fn get_default_offset_rounds(&self, pair_address: &ManagedAddress, end_round: Round) -> u64 { let safe_price_current_index = self - .safe_price_current_index() - .get_from_address(pair_address); - let price_observations = self.price_observations(); - let oldest_price_observation = self.get_oldest_price_observation( - pair_address, - safe_price_current_index, - &price_observations, - ); + .get_safe_price_current_index_mapper(pair_address.clone()) + .get(); + let price_observations = self.get_price_observation_mapper(pair_address.clone()); + let oldest_price_observation = + self.get_oldest_price_observation(safe_price_current_index, &price_observations); let mut default_offset_rounds = end_round - oldest_price_observation.recording_round; if default_offset_rounds > DEFAULT_SAFE_PRICE_ROUNDS_OFFSET { @@ -556,16 +539,13 @@ pub trait SafePriceViewModule: fn update_and_get_tokens_for_given_position_with_safe_price( &self, liquidity: BigUint, - ) -> MultiValue2, EsdtTokenPayment> { + ) -> MultiValue2 { let pair_address = self.blockchain().get_sc_address(); self.get_lp_tokens_safe_price_by_default_offset(pair_address, liquidity) } #[endpoint(updateAndGetSafePrice)] - fn update_and_get_safe_price( - &self, - input: EsdtTokenPayment, - ) -> EsdtTokenPayment { + fn update_and_get_safe_price(&self, input: EsdtTokenPayment) -> EsdtTokenPayment { let pair_address = self.blockchain().get_sc_address(); self.get_safe_price_by_default_offset(pair_address, input) } diff --git a/dex/pair/tests/pair_setup/mod.rs b/dex/pair/tests/pair_setup/mod.rs index 083ec8e40..78f99b6e9 100644 --- a/dex/pair/tests/pair_setup/mod.rs +++ b/dex/pair/tests/pair_setup/mod.rs @@ -409,7 +409,7 @@ where pub fn set_price_observation_as_old(&mut self, observation_index: usize) { let _ = self.b_mock.execute_query(&self.pair_wrapper, |sc| { - let price_observations = sc.price_observations(); + let mut price_observations = sc.price_observations(); let mut price_observation = price_observations.get(observation_index); price_observation.lp_supply_accumulated = BigUint::zero(); diff --git a/dex/pair/wasm-pair-full/Cargo.lock b/dex/pair/wasm-pair-full/Cargo.lock index 77c4e33e1..9ca48d0d0 100644 --- a/dex/pair/wasm-pair-full/Cargo.lock +++ b/dex/pair/wasm-pair-full/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -286,9 +286,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/pair/wasm-pair-full/Cargo.toml b/dex/pair/wasm-pair-full/Cargo.toml index 5fc0f4b76..702f1a1fd 100644 --- a/dex/pair/wasm-pair-full/Cargo.toml +++ b/dex/pair/wasm-pair-full/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/pair/wasm-safe-price-view/Cargo.lock b/dex/pair/wasm-safe-price-view/Cargo.lock index 48471aad0..929875e3f 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.lock +++ b/dex/pair/wasm-safe-price-view/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -278,9 +278,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/pair/wasm-safe-price-view/Cargo.toml b/dex/pair/wasm-safe-price-view/Cargo.toml index 28c1d40a9..035a097bf 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.toml +++ b/dex/pair/wasm-safe-price-view/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/pair/wasm/Cargo.lock b/dex/pair/wasm/Cargo.lock index c1f2406db..26d648185 100644 --- a/dex/pair/wasm/Cargo.lock +++ b/dex/pair/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -286,9 +286,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/pair/wasm/Cargo.toml b/dex/pair/wasm/Cargo.toml index 7e096d156..8114353ef 100644 --- a/dex/pair/wasm/Cargo.toml +++ b/dex/pair/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/price-discovery/Cargo.toml b/dex/price-discovery/Cargo.toml index 51aa316e3..7eecf6dd9 100644 --- a/dex/price-discovery/Cargo.toml +++ b/dex/price-discovery/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.locking_module] path = "../../common/modules/locking_module" @@ -30,4 +30,4 @@ hex = "0.4" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/dex/price-discovery/meta/Cargo.toml b/dex/price-discovery/meta/Cargo.toml index 176823d06..c6955d199 100644 --- a/dex/price-discovery/meta/Cargo.toml +++ b/dex/price-discovery/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/price-discovery/wasm/Cargo.lock b/dex/price-discovery/wasm/Cargo.lock index fbcb7ca84..65c5b9037 100644 --- a/dex/price-discovery/wasm/Cargo.lock +++ b/dex/price-discovery/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_errors" @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -142,9 +142,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -167,18 +167,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -221,9 +221,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/price-discovery/wasm/Cargo.toml b/dex/price-discovery/wasm/Cargo.toml index 04885bcda..e1d773a07 100644 --- a/dex/price-discovery/wasm/Cargo.toml +++ b/dex/price-discovery/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/proxy-deployer/Cargo.toml b/dex/proxy-deployer/Cargo.toml index f5c3b8955..f4efe45d6 100644 --- a/dex/proxy-deployer/Cargo.toml +++ b/dex/proxy-deployer/Cargo.toml @@ -21,11 +21,11 @@ path = "../../common/modules/farm/config" path = "../../common/modules/farm/farm_token" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/dex/proxy-deployer/meta/Cargo.toml b/dex/proxy-deployer/meta/Cargo.toml index 629fddbdf..9a516a7c0 100644 --- a/dex/proxy-deployer/meta/Cargo.toml +++ b/dex/proxy-deployer/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/proxy-deployer/wasm/Cargo.lock b/dex/proxy-deployer/wasm/Cargo.lock index 371955a5f..02b775cc5 100644 --- a/dex/proxy-deployer/wasm/Cargo.lock +++ b/dex/proxy-deployer/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -277,9 +277,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -290,9 +290,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -300,9 +300,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -312,9 +312,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -325,18 +325,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -394,9 +394,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/proxy-deployer/wasm/Cargo.toml b/dex/proxy-deployer/wasm/Cargo.toml index 97ada3a24..1a9bc3b4f 100644 --- a/dex/proxy-deployer/wasm/Cargo.toml +++ b/dex/proxy-deployer/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/router/Cargo.toml b/dex/router/Cargo.toml index cc3698241..f70fa5c04 100644 --- a/dex/router/Cargo.toml +++ b/dex/router/Cargo.toml @@ -15,7 +15,7 @@ path = "../../common/modules/token_send" path = "../../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.pair] @@ -28,4 +28,4 @@ path = "../../common/modules/locking_module" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/dex/router/meta/Cargo.toml b/dex/router/meta/Cargo.toml index c5deaf0be..8966e7476 100644 --- a/dex/router/meta/Cargo.toml +++ b/dex/router/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/dex/router/wasm/Cargo.lock b/dex/router/wasm/Cargo.lock index 0f5cc1535..6b2344040 100644 --- a/dex/router/wasm/Cargo.lock +++ b/dex/router/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -278,9 +278,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/dex/router/wasm/Cargo.toml b/dex/router/wasm/Cargo.toml index dc895383b..678a87da6 100644 --- a/dex/router/wasm/Cargo.toml +++ b/dex/router/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/dex/router/wasm/src/lib.rs b/dex/router/wasm/src/lib.rs index e840498ec..df0c8feb5 100644 --- a/dex/router/wasm/src/lib.rs +++ b/dex/router/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 33 +// Endpoints: 32 // Async Callback: 1 -// Total number of exported functions: 35 +// Total number of exported functions: 34 #![no_std] #![allow(internal_features)] diff --git a/energy-integration/common-modules/energy-query/Cargo.toml b/energy-integration/common-modules/energy-query/Cargo.toml index 429ddafe2..adefb3769 100644 --- a/energy-integration/common-modules/energy-query/Cargo.toml +++ b/energy-integration/common-modules/energy-query/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-factory] diff --git a/energy-integration/common-modules/week-timekeeping/Cargo.toml b/energy-integration/common-modules/week-timekeeping/Cargo.toml index 32e16b01e..b4af11ce3 100644 --- a/energy-integration/common-modules/week-timekeeping/Cargo.toml +++ b/energy-integration/common-modules/week-timekeeping/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.common-types] diff --git a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml index 0603f0084..36bb5efe2 100644 --- a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml +++ b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-query] diff --git a/energy-integration/common-types/Cargo.toml b/energy-integration/common-types/Cargo.toml index b2ba8bc79..a368f9f75 100644 --- a/energy-integration/common-types/Cargo.toml +++ b/energy-integration/common-types/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] diff --git a/energy-integration/energy-factory-mock/Cargo.toml b/energy-integration/energy-factory-mock/Cargo.toml index 6e246e8fb..1c919df1f 100644 --- a/energy-integration/energy-factory-mock/Cargo.toml +++ b/energy-integration/energy-factory-mock/Cargo.toml @@ -12,8 +12,8 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/energy-integration/energy-factory-mock/meta/Cargo.toml b/energy-integration/energy-factory-mock/meta/Cargo.toml index 94241670d..a2872b370 100644 --- a/energy-integration/energy-factory-mock/meta/Cargo.toml +++ b/energy-integration/energy-factory-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.lock b/energy-integration/energy-factory-mock/wasm/Cargo.lock index 0693d6d5f..63470f3ab 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.lock +++ b/energy-integration/energy-factory-mock/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_errors" @@ -128,9 +128,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -141,9 +141,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -151,9 +151,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -163,9 +163,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -176,18 +176,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -212,9 +212,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.toml b/energy-integration/energy-factory-mock/wasm/Cargo.toml index 426c4c9f0..0d381efb7 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.toml +++ b/energy-integration/energy-factory-mock/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/energy-integration/energy-update/Cargo.toml b/energy-integration/energy-update/Cargo.toml index 01489f0d7..c7a8d41c8 100644 --- a/energy-integration/energy-update/Cargo.toml +++ b/energy-integration/energy-update/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.farm] path = "../../dex/farm" @@ -25,4 +25,4 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/energy-integration/energy-update/meta/Cargo.toml b/energy-integration/energy-update/meta/Cargo.toml index aa816ac82..627514dae 100644 --- a/energy-integration/energy-update/meta/Cargo.toml +++ b/energy-integration/energy-update/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/energy-integration/energy-update/wasm/Cargo.lock b/energy-integration/energy-update/wasm/Cargo.lock index 559a8a519..9d23276fc 100644 --- a/energy-integration/energy-update/wasm/Cargo.lock +++ b/energy-integration/energy-update/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -295,9 +295,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -308,9 +308,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -318,9 +318,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -330,9 +330,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -343,18 +343,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -412,9 +412,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/energy-integration/energy-update/wasm/Cargo.toml b/energy-integration/energy-update/wasm/Cargo.toml index 399b3a678..5042edb22 100644 --- a/energy-integration/energy-update/wasm/Cargo.toml +++ b/energy-integration/energy-update/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/energy-integration/farm-boosted-yields/Cargo.toml b/energy-integration/farm-boosted-yields/Cargo.toml index 5a75c8b80..afd011e84 100644 --- a/energy-integration/farm-boosted-yields/Cargo.toml +++ b/energy-integration/farm-boosted-yields/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.config] diff --git a/energy-integration/fees-collector/Cargo.toml b/energy-integration/fees-collector/Cargo.toml index 1b233b7f6..09b6525d5 100644 --- a/energy-integration/fees-collector/Cargo.toml +++ b/energy-integration/fees-collector/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.energy-query] path = "../common-modules/energy-query" @@ -49,7 +49,7 @@ path = "../../common/common_errors" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.sc_whitelist_module] path = "../../common/modules/sc_whitelist_module" diff --git a/energy-integration/fees-collector/meta/Cargo.toml b/energy-integration/fees-collector/meta/Cargo.toml index c91986348..f4cd4b07f 100644 --- a/energy-integration/fees-collector/meta/Cargo.toml +++ b/energy-integration/fees-collector/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/energy-integration/fees-collector/wasm/Cargo.lock b/energy-integration/fees-collector/wasm/Cargo.lock index d31ccf2dc..c91a53592 100644 --- a/energy-integration/fees-collector/wasm/Cargo.lock +++ b/energy-integration/fees-collector/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -167,9 +167,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -177,9 +177,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -189,9 +189,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -202,18 +202,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -238,9 +238,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/energy-integration/fees-collector/wasm/Cargo.toml b/energy-integration/fees-collector/wasm/Cargo.toml index 67ff1cdc8..cf5c52d0b 100644 --- a/energy-integration/fees-collector/wasm/Cargo.toml +++ b/energy-integration/fees-collector/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/energy-integration/governance-v2/Cargo.toml b/energy-integration/governance-v2/Cargo.toml index 1b190cd64..606b40d8c 100644 --- a/energy-integration/governance-v2/Cargo.toml +++ b/energy-integration/governance-v2/Cargo.toml @@ -12,7 +12,7 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.permissions_module] @@ -28,7 +28,7 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.energy-factory-mock] path = "../energy-factory-mock" diff --git a/energy-integration/governance-v2/meta/Cargo.toml b/energy-integration/governance-v2/meta/Cargo.toml index ca5a80d29..3187a47ce 100644 --- a/energy-integration/governance-v2/meta/Cargo.toml +++ b/energy-integration/governance-v2/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/energy-integration/governance-v2/wasm/Cargo.lock b/energy-integration/governance-v2/wasm/Cargo.lock index 71cf78cfd..6ff033cc1 100644 --- a/energy-integration/governance-v2/wasm/Cargo.lock +++ b/energy-integration/governance-v2/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -178,9 +178,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -188,9 +188,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -200,9 +200,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -213,18 +213,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -258,9 +258,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/energy-integration/governance-v2/wasm/Cargo.toml b/energy-integration/governance-v2/wasm/Cargo.toml index 02189aabe..3615366fb 100644 --- a/energy-integration/governance-v2/wasm/Cargo.toml +++ b/energy-integration/governance-v2/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/farm-staking/farm-staking-proxy/Cargo.toml b/farm-staking/farm-staking-proxy/Cargo.toml index 7e986d221..fb3c4b339 100644 --- a/farm-staking/farm-staking-proxy/Cargo.toml +++ b/farm-staking/farm-staking-proxy/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.farm] path = "../../dex/farm" @@ -67,7 +67,7 @@ path = "../../energy-integration/common-modules/energy-query" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.farm_token] path = "../../common/modules/farm/farm_token" diff --git a/farm-staking/farm-staking-proxy/meta/Cargo.toml b/farm-staking/farm-staking-proxy/meta/Cargo.toml index 404e23810..1c7a0f9fe 100644 --- a/farm-staking/farm-staking-proxy/meta/Cargo.toml +++ b/farm-staking/farm-staking-proxy/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.lock b/farm-staking/farm-staking-proxy/wasm/Cargo.lock index feded38ab..4462d4205 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.lock +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -376,9 +376,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -389,9 +389,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -399,9 +399,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -411,9 +411,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -424,18 +424,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -493,9 +493,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.toml b/farm-staking/farm-staking-proxy/wasm/Cargo.toml index b95744497..ee87f5eee 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.toml +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/farm-staking/farm-staking/Cargo.toml b/farm-staking/farm-staking/Cargo.toml index c4db81ca1..b4e81589f 100644 --- a/farm-staking/farm-staking/Cargo.toml +++ b/farm-staking/farm-staking/Cargo.toml @@ -78,14 +78,14 @@ path = "../../common/common_structs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/farm-staking/farm-staking/meta/Cargo.toml b/farm-staking/farm-staking/meta/Cargo.toml index 20d07fb79..49357bd4a 100644 --- a/farm-staking/farm-staking/meta/Cargo.toml +++ b/farm-staking/farm-staking/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/farm-staking/farm-staking/wasm/Cargo.lock b/farm-staking/farm-staking/wasm/Cargo.lock index 88d4b1bba..79a0f410b 100644 --- a/farm-staking/farm-staking/wasm/Cargo.lock +++ b/farm-staking/farm-staking/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -316,9 +316,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -329,9 +329,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -339,9 +339,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -351,9 +351,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -364,18 +364,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -433,9 +433,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/farm-staking/farm-staking/wasm/Cargo.toml b/farm-staking/farm-staking/wasm/Cargo.toml index 0dbb347b9..7068d3f6e 100644 --- a/farm-staking/farm-staking/wasm/Cargo.toml +++ b/farm-staking/farm-staking/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/farm-staking/metabonding-staking/Cargo.toml b/farm-staking/metabonding-staking/Cargo.toml index de3c1ff97..ee8282db3 100644 --- a/farm-staking/metabonding-staking/Cargo.toml +++ b/farm-staking/metabonding-staking/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.factory] path = "../../locked-asset/factory" @@ -22,7 +22,7 @@ path = "../../locked-asset/factory" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.common_structs] path = "../../common/common_structs" diff --git a/farm-staking/metabonding-staking/meta/Cargo.toml b/farm-staking/metabonding-staking/meta/Cargo.toml index 71df2c0ba..2e049a4d6 100644 --- a/farm-staking/metabonding-staking/meta/Cargo.toml +++ b/farm-staking/metabonding-staking/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/farm-staking/metabonding-staking/wasm/Cargo.lock b/farm-staking/metabonding-staking/wasm/Cargo.lock index 739fec429..21aba28e9 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.lock +++ b/farm-staking/metabonding-staking/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "cfg-if" @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -183,9 +183,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -193,9 +193,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -205,9 +205,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -218,18 +218,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -254,9 +254,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/farm-staking/metabonding-staking/wasm/Cargo.toml b/farm-staking/metabonding-staking/wasm/Cargo.toml index fe2a7c6c2..79b5e4fc0 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.toml +++ b/farm-staking/metabonding-staking/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/Cargo.toml b/locked-asset/Cargo.toml index d7ba66a4c..443d0040d 100644 --- a/locked-asset/Cargo.toml +++ b/locked-asset/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.farm] @@ -50,7 +50,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/distribution/Cargo.toml b/locked-asset/distribution/Cargo.toml index 3ebf0939b..a966c5af6 100644 --- a/locked-asset/distribution/Cargo.toml +++ b/locked-asset/distribution/Cargo.toml @@ -14,8 +14,8 @@ path = "../../common/common_structs" path = "../factory" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/distribution/meta/Cargo.toml b/locked-asset/distribution/meta/Cargo.toml index 76c13747b..de2ca6868 100644 --- a/locked-asset/distribution/meta/Cargo.toml +++ b/locked-asset/distribution/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/distribution/wasm/Cargo.lock b/locked-asset/distribution/wasm/Cargo.lock index fce0d3ebe..a66da5bfb 100644 --- a/locked-asset/distribution/wasm/Cargo.lock +++ b/locked-asset/distribution/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "cfg-if" @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -183,9 +183,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -193,9 +193,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -205,9 +205,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -218,18 +218,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -254,9 +254,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/distribution/wasm/Cargo.toml b/locked-asset/distribution/wasm/Cargo.toml index f1cc0ae57..e63900a72 100644 --- a/locked-asset/distribution/wasm/Cargo.toml +++ b/locked-asset/distribution/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/energy-factory/Cargo.toml b/locked-asset/energy-factory/Cargo.toml index 74e3cbea9..2e2f62dc6 100644 --- a/locked-asset/energy-factory/Cargo.toml +++ b/locked-asset/energy-factory/Cargo.toml @@ -33,11 +33,11 @@ path = "../../common/traits/unwrappable" path = "../../common/modules/legacy_token_decode_module" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies] num-bigint = "0.4.2" @@ -45,4 +45,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/energy-factory/meta/Cargo.toml b/locked-asset/energy-factory/meta/Cargo.toml index 6365191f0..5516a213f 100644 --- a/locked-asset/energy-factory/meta/Cargo.toml +++ b/locked-asset/energy-factory/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/energy-factory/wasm/Cargo.lock b/locked-asset/energy-factory/wasm/Cargo.lock index b7f42af38..d25961008 100644 --- a/locked-asset/energy-factory/wasm/Cargo.lock +++ b/locked-asset/energy-factory/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_errors" @@ -112,9 +112,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -125,9 +125,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -135,9 +135,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -147,9 +147,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -160,18 +160,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/energy-factory/wasm/Cargo.toml b/locked-asset/energy-factory/wasm/Cargo.toml index 944055b38..05c44897a 100644 --- a/locked-asset/energy-factory/wasm/Cargo.toml +++ b/locked-asset/energy-factory/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/factory/Cargo.toml b/locked-asset/factory/Cargo.toml index 6996881d1..2fb4cc002 100644 --- a/locked-asset/factory/Cargo.toml +++ b/locked-asset/factory/Cargo.toml @@ -26,11 +26,11 @@ path = "../../common/modules/token_merge_helper" path = "../energy-factory" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.arrayvec] version = "0.7.1" @@ -49,4 +49,4 @@ hex = "0.4" path = "../simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/factory/meta/Cargo.toml b/locked-asset/factory/meta/Cargo.toml index d81d3bb85..4bc27087e 100644 --- a/locked-asset/factory/meta/Cargo.toml +++ b/locked-asset/factory/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/factory/wasm/Cargo.lock b/locked-asset/factory/wasm/Cargo.lock index 39d478ef4..26e60cd35 100644 --- a/locked-asset/factory/wasm/Cargo.lock +++ b/locked-asset/factory/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "cfg-if" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -245,9 +245,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/factory/wasm/Cargo.toml b/locked-asset/factory/wasm/Cargo.toml index eb8c084a5..e3d3cf466 100644 --- a/locked-asset/factory/wasm/Cargo.toml +++ b/locked-asset/factory/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/lkmex-transfer/Cargo.toml b/locked-asset/lkmex-transfer/Cargo.toml index a6fb9ca95..2f4631f56 100644 --- a/locked-asset/lkmex-transfer/Cargo.toml +++ b/locked-asset/lkmex-transfer/Cargo.toml @@ -30,14 +30,14 @@ path = "../energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/lkmex-transfer/meta/Cargo.toml b/locked-asset/lkmex-transfer/meta/Cargo.toml index e0c0588d1..78211a21e 100644 --- a/locked-asset/lkmex-transfer/meta/Cargo.toml +++ b/locked-asset/lkmex-transfer/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.lock b/locked-asset/lkmex-transfer/wasm/Cargo.lock index 503d067d7..b1689bd61 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.lock +++ b/locked-asset/lkmex-transfer/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_errors" @@ -134,9 +134,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -147,9 +147,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -157,9 +157,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -169,9 +169,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -182,18 +182,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -227,9 +227,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.toml b/locked-asset/lkmex-transfer/wasm/Cargo.toml index dee74ceae..474ebc202 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.toml +++ b/locked-asset/lkmex-transfer/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/locked-token-wrapper/Cargo.toml b/locked-asset/locked-token-wrapper/Cargo.toml index 787914eeb..941f8aa52 100644 --- a/locked-asset/locked-token-wrapper/Cargo.toml +++ b/locked-asset/locked-token-wrapper/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.utils] path = "../../common/modules/utils" @@ -44,4 +44,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/locked-token-wrapper/meta/Cargo.toml b/locked-asset/locked-token-wrapper/meta/Cargo.toml index 6de0a4093..400316ce3 100644 --- a/locked-asset/locked-token-wrapper/meta/Cargo.toml +++ b/locked-asset/locked-token-wrapper/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.lock b/locked-asset/locked-token-wrapper/wasm/Cargo.lock index eb6ca7c6e..cf219a208 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.lock +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_errors" @@ -158,9 +158,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -171,9 +171,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -181,9 +181,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -193,9 +193,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -206,18 +206,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -251,9 +251,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.toml b/locked-asset/locked-token-wrapper/wasm/Cargo.toml index 0d10a2666..87150c0ca 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.toml +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/proxy_dex/Cargo.toml b/locked-asset/proxy_dex/Cargo.toml index 5c52745d9..f598598eb 100644 --- a/locked-asset/proxy_dex/Cargo.toml +++ b/locked-asset/proxy_dex/Cargo.toml @@ -45,11 +45,11 @@ path = "../../common/traits/mergeable" path = "../../common/traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.energy-factory] path = "../energy-factory" @@ -69,7 +69,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.pausable] path = "../../common/modules/pausable" diff --git a/locked-asset/proxy_dex/meta/Cargo.toml b/locked-asset/proxy_dex/meta/Cargo.toml index 41fea1fc8..3a3e9de3e 100644 --- a/locked-asset/proxy_dex/meta/Cargo.toml +++ b/locked-asset/proxy_dex/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/proxy_dex/wasm/Cargo.lock b/locked-asset/proxy_dex/wasm/Cargo.lock index 7cc65eaa5..d601aa1f1 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.lock +++ b/locked-asset/proxy_dex/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -307,9 +307,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -320,9 +320,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -330,9 +330,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -342,9 +342,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -355,18 +355,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -424,9 +424,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/proxy_dex/wasm/Cargo.toml b/locked-asset/proxy_dex/wasm/Cargo.toml index b0753d94f..6101d9e7a 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.toml +++ b/locked-asset/proxy_dex/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/simple-lock-whitelist/Cargo.toml b/locked-asset/simple-lock-whitelist/Cargo.toml index a8d637a5c..e49600a9a 100644 --- a/locked-asset/simple-lock-whitelist/Cargo.toml +++ b/locked-asset/simple-lock-whitelist/Cargo.toml @@ -15,11 +15,11 @@ path = "../simple-lock" path = "../../common/modules/utils" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies] num-bigint = "0.4.2" @@ -27,4 +27,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/simple-lock-whitelist/meta/Cargo.toml b/locked-asset/simple-lock-whitelist/meta/Cargo.toml index 8b95c8a50..e5efe2245 100644 --- a/locked-asset/simple-lock-whitelist/meta/Cargo.toml +++ b/locked-asset/simple-lock-whitelist/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/simple-lock-whitelist/wasm/Cargo.lock b/locked-asset/simple-lock-whitelist/wasm/Cargo.lock index e6300116a..34b1df932 100644 --- a/locked-asset/simple-lock-whitelist/wasm/Cargo.lock +++ b/locked-asset/simple-lock-whitelist/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_structs" @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -85,9 +85,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -95,9 +95,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -107,9 +107,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -120,18 +120,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -156,9 +156,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/simple-lock-whitelist/wasm/Cargo.toml b/locked-asset/simple-lock-whitelist/wasm/Cargo.toml index 068857df3..57d2e8645 100644 --- a/locked-asset/simple-lock-whitelist/wasm/Cargo.toml +++ b/locked-asset/simple-lock-whitelist/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs b/locked-asset/simple-lock-whitelist/wasm/src/lib.rs index 6b3f02559..aa78142e1 100644 --- a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs +++ b/locked-asset/simple-lock-whitelist/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 27 +// Endpoints: 26 // Async Callback: 1 -// Total number of exported functions: 29 +// Total number of exported functions: 28 #![no_std] #![allow(internal_features)] diff --git a/locked-asset/simple-lock/Cargo.toml b/locked-asset/simple-lock/Cargo.toml index 8f6b5bd1d..08a745214 100644 --- a/locked-asset/simple-lock/Cargo.toml +++ b/locked-asset/simple-lock/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/simple-lock/meta/Cargo.toml b/locked-asset/simple-lock/meta/Cargo.toml index 889dce931..ade748c64 100644 --- a/locked-asset/simple-lock/meta/Cargo.toml +++ b/locked-asset/simple-lock/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/simple-lock/wasm/Cargo.lock b/locked-asset/simple-lock/wasm/Cargo.lock index e5957696c..102bb0d32 100644 --- a/locked-asset/simple-lock/wasm/Cargo.lock +++ b/locked-asset/simple-lock/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_structs" @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -85,9 +85,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -95,9 +95,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -107,9 +107,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -120,18 +120,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -156,9 +156,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/simple-lock/wasm/Cargo.toml b/locked-asset/simple-lock/wasm/Cargo.toml index cc2cf0244..c52eb04df 100644 --- a/locked-asset/simple-lock/wasm/Cargo.toml +++ b/locked-asset/simple-lock/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/locked-asset/token-unstake/Cargo.toml b/locked-asset/token-unstake/Cargo.toml index da727566e..9f05894e6 100644 --- a/locked-asset/token-unstake/Cargo.toml +++ b/locked-asset/token-unstake/Cargo.toml @@ -9,7 +9,7 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] @@ -39,7 +39,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" diff --git a/locked-asset/token-unstake/meta/Cargo.toml b/locked-asset/token-unstake/meta/Cargo.toml index fb4914c3d..035037168 100644 --- a/locked-asset/token-unstake/meta/Cargo.toml +++ b/locked-asset/token-unstake/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/locked-asset/token-unstake/wasm/Cargo.lock b/locked-asset/token-unstake/wasm/Cargo.lock index d74f133fa..415f82989 100644 --- a/locked-asset/token-unstake/wasm/Cargo.lock +++ b/locked-asset/token-unstake/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common-types" @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -142,9 +142,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -167,18 +167,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -203,9 +203,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/locked-asset/token-unstake/wasm/Cargo.toml b/locked-asset/token-unstake/wasm/Cargo.toml index f3e21bb9b..f7753f8de 100644 --- a/locked-asset/token-unstake/wasm/Cargo.toml +++ b/locked-asset/token-unstake/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] diff --git a/pause-all/Cargo.toml b/pause-all/Cargo.toml index 30046978d..becbee8e1 100644 --- a/pause-all/Cargo.toml +++ b/pause-all/Cargo.toml @@ -12,14 +12,14 @@ path = "src/lib.rs" path = "../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.46.1" +version = "=0.48.0" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.multiversx-sc-scenario] -version = "=0.46.1" +version = "=0.48.0" [dev-dependencies.farm] path = "../dex/farm" diff --git a/pause-all/meta/Cargo.toml b/pause-all/meta/Cargo.toml index f6be6643e..cec738238 100644 --- a/pause-all/meta/Cargo.toml +++ b/pause-all/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.46.1" +version = "0.48.0" default-features = false diff --git a/pause-all/wasm/Cargo.lock b/pause-all/wasm/Cargo.lock index d1b8021d6..0972422cf 100644 --- a/pause-all/wasm/Cargo.lock +++ b/pause-all/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" [[package]] name = "common_errors" @@ -47,9 +47,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c94b173dc5ff0e157f767275fe6b7a1b4d2ad343bef7b66cd22a6353e016b93" +checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" dependencies = [ "bitflags", "hex-literal", @@ -60,9 +60,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19908153158c03df4582af08f47c0eb39fb52a7dff4736b301a66acbbb9955d3" +checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -70,9 +70,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.3" +version = "0.18.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3b03b43f9cad320992f54ed162de2ed63e3ec83ed01361e57ee9c1865fba5a2" +checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" dependencies = [ "hex", "proc-macro2", @@ -82,9 +82,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b78945957036c281ad6ee21bb5120dcefa2017688adf43ec94e3e7c982efb09" +checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" dependencies = [ "hex", "proc-macro2", @@ -95,18 +95,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c63ffaba95e630ff75981e2f5f50da64f523219b52f484234c66f3adc248885f" +checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.46.1" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9579f40c00da56a5a68e010ff851fa48ac7b9c6a16ad4314795cb32d889d9e78" +checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" dependencies = [ "multiversx-sc", ] @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.75" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907a61bd0f64c2f29cd1cf1dc34d05176426a3f504a78010f08416ddb7b13708" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] diff --git a/pause-all/wasm/Cargo.toml b/pause-all/wasm/Cargo.toml index ccffee39c..3fcca5422 100644 --- a/pause-all/wasm/Cargo.toml +++ b/pause-all/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.46.1" +version = "=0.48.0" [workspace] members = ["."] From b01507b6a36397b717ac491835ff7d1a7ccbac70 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 11 Apr 2024 12:25:54 +0300 Subject: [PATCH 018/103] add check on enable swap by user --- dex/router/src/enable_swap_by_user.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/dex/router/src/enable_swap_by_user.rs b/dex/router/src/enable_swap_by_user.rs index 7c77036c1..f5929f4f7 100644 --- a/dex/router/src/enable_swap_by_user.rs +++ b/dex/router/src/enable_swap_by_user.rs @@ -83,6 +83,7 @@ pub trait EnableSwapByUserModule: #[payable("*")] #[endpoint(setSwapEnabledByUser)] fn set_swap_enabled_by_user(&self, pair_address: ManagedAddress) { + require!(self.is_active(), "Not active"); self.check_is_pair_sc(&pair_address); self.require_state_active_no_swaps(&pair_address); From 19e8ce328a1d06cba9d9d6ba07a593354e0f5d2d Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 12 Apr 2024 02:55:16 +0300 Subject: [PATCH 019/103] Farm staking merge fix + unit tests --- farm-staking/farm-staking/src/lib.rs | 29 +- .../farm-staking/src/token_attributes.rs | 4 +- .../tests/farm_staking_energy_test.rs | 626 +++++++++++++++++- .../tests/farm_staking_setup/mod.rs | 217 +++++- .../farm-staking/tests/farm_staking_test.rs | 74 ++- 5 files changed, 890 insertions(+), 60 deletions(-) diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index c210d080c..e4f0a6533 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -119,8 +119,35 @@ pub trait FarmStaking: let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); - let output_attributes: StakingFarmTokenAttributes = + + for farm_position in &payments { + if self.is_old_farm_position(farm_position.token_nonce) { + continue; + } + + let token_attributes: StakingFarmTokenAttributes = + token_mapper.get_token_attributes(farm_position.token_nonce); + + if token_attributes.original_owner != caller { + self.user_total_farm_position(&token_attributes.original_owner) + .update(|user_total_farm_position| { + if user_total_farm_position.total_farm_position > farm_position.amount { + user_total_farm_position.total_farm_position -= &farm_position.amount; + } else { + user_total_farm_position.total_farm_position = BigUint::zero(); + } + }); + self.user_total_farm_position(&caller) + .update(|user_total_farm_position| { + user_total_farm_position.total_farm_position += &farm_position.amount; + }); + } + } + + let mut output_attributes: StakingFarmTokenAttributes = self.merge_from_payments_and_burn(payments, &token_mapper); + output_attributes.original_owner = caller.clone(); + let new_token_amount = output_attributes.get_total_supply(); let merged_farm_token = token_mapper.nft_create(new_token_amount, &output_attributes); diff --git a/farm-staking/farm-staking/src/token_attributes.rs b/farm-staking/farm-staking/src/token_attributes.rs index 54074a958..59f8c6326 100644 --- a/farm-staking/farm-staking/src/token_attributes.rs +++ b/farm-staking/farm-staking/src/token_attributes.rs @@ -108,8 +108,8 @@ impl FixedSupplyToken for StakingFarmTokenAttributes { impl Mergeable for StakingFarmTokenAttributes { #[inline] - fn can_merge_with(&self, other: &Self) -> bool { - self.original_owner == other.original_owner + fn can_merge_with(&self, _other: &Self) -> bool { + true } fn merge_with(&mut self, other: Self) { diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index 230d84747..8b51dee1b 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -2,12 +2,17 @@ pub mod farm_staking_setup; use farm_staking::{ - claim_stake_farm_rewards::ClaimStakeFarmRewardsModule, stake_farm::StakeFarmModule, + claim_stake_farm_rewards::ClaimStakeFarmRewardsModule, + stake_farm::StakeFarmModule, + token_attributes::{StakingFarmTokenAttributes, UnbondSftAttributes}, unstake_farm::UnstakeFarmModule, + FarmStaking, }; use farm_staking_setup::*; use multiversx_sc::codec::multi_types::OptionalValue; -use multiversx_sc_scenario::{rust_biguint, DebugApi}; +use multiversx_sc_scenario::{ + managed_address, managed_biguint, rust_biguint, testing_framework::TxTokenTransfer, DebugApi, +}; #[test] fn farm_staking_with_energy_setup_test() { @@ -24,12 +29,21 @@ fn farm_staking_boosted_rewards_no_energy_test() { let mut fs_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = fs_setup.user_address.clone(); + fs_setup.set_boosted_yields_factors(); fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); let farm_in_amount = 100_000_000; let expected_farm_token_nonce = 1; - fs_setup.stake_farm(farm_in_amount, &[], expected_farm_token_nonce, 0, 0); + fs_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); fs_setup.check_farm_token_supply(farm_in_amount); fs_setup.set_block_epoch(5); @@ -43,6 +57,7 @@ fn farm_staking_boosted_rewards_no_energy_test() { rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out); let expected_reward_per_share = 300_000; // from 400_000 -> 300_000 fs_setup.claim_rewards( + &user_address, farm_in_amount, expected_farm_token_nonce, expected_reward_token_out, @@ -54,26 +69,203 @@ fn farm_staking_boosted_rewards_no_energy_test() { fs_setup.check_farm_token_supply(farm_in_amount); } +#[test] +fn farm_staking_other_user_enter_negative_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + let user_address = fs_setup.user_address.clone(); + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + let farm_in_amount = 100_000_000; + fs_setup + .stake_farm_for_other_user(&rand_user, &user_address, farm_in_amount, &vec![]) + .assert_error(4, "Item not whitelisted"); + + let expected_farm_token_nonce = 1; + fs_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); + + fs_setup + .claim_farm_for_other_user( + &rand_user, + &user_address, + expected_farm_token_nonce, + farm_in_amount, + ) + .assert_error(4, "Item not whitelisted"); + + fs_setup + .unstake_farm_for_other_user( + &rand_user, + &user_address, + expected_farm_token_nonce, + farm_in_amount, + ) + .assert_error(4, "Item not whitelisted"); +} + #[test] fn farm_staking_boosted_rewards_with_energy_test() { DebugApi::dummy(); let mut fs_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = fs_setup.user_address.clone(); + let user_address2 = fs_setup.user_address2.clone(); + fs_setup.set_boosted_yields_factors(); fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); - fs_setup.set_user_energy(&fs_setup.user_address.clone(), 10_000, 0, 10); + fs_setup.set_user_energy(&user_address, 10_000, 0, 10); + fs_setup.set_user_energy(&user_address2, 5_000, 0, 10); let farm_in_amount = 100_000_000; - fs_setup.stake_farm(farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&user_address, farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&user_address2, farm_in_amount, &[], 2, 0, 0); + fs_setup.check_farm_token_supply(farm_in_amount * 2); + + // claim to get energy registered + fs_setup + .b_mock + .execute_esdt_transfer( + &user_address, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 1, + &rust_biguint!(farm_in_amount), + |sc| { + let _ = sc.claim_rewards(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &user_address2, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 2, + &rust_biguint!(farm_in_amount), + |sc| { + let _ = sc.claim_rewards(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_nonce(10); + + // random user tx to collect rewards + + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &rand_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + fs_setup.set_user_energy(&rand_user, 1, 5, 1); + fs_setup.set_block_epoch(5); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 5, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(8); + + fs_setup.set_user_energy(&user_address, 10_000, 8, 10); + fs_setup.set_user_energy(&user_address2, 5_000, 8, 10); + + let base_rewards = 34; + let boosted_rewards_user = 13; + let boosted_rewards_user2 = 8; + let expected_reward_token_out_user = base_rewards + boosted_rewards_user; + let expected_reward_token_out_user2 = base_rewards + boosted_rewards_user2; + let expected_farming_token_balance_user = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out_user); + let expected_farming_token_balance_user2 = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out_user2); + let expected_reward_per_share = 340_000; + fs_setup.claim_rewards( + &user_address, + farm_in_amount, + 3, + expected_reward_token_out_user, + &expected_farming_token_balance_user, + &expected_farming_token_balance_user, + 7, + expected_reward_per_share, + ); + fs_setup.claim_rewards( + &user_address2, + farm_in_amount, + 4, + expected_reward_token_out_user2, + &expected_farming_token_balance_user2, + &expected_farming_token_balance_user2, + 8, + expected_reward_per_share, + ); + fs_setup.check_farm_token_supply(farm_in_amount * 2); +} + +#[test] +fn farm_staking_partial_position_handling_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + let user_address = fs_setup.user_address.clone(); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + fs_setup.set_user_energy(&user_address, 10_000, 0, 10); + + let farm_in_amount = 100_000_000; + fs_setup.stake_farm(&user_address, farm_in_amount, &[], 1, 0, 0); fs_setup.check_farm_token_supply(farm_in_amount); // claim to get energy registered fs_setup .b_mock .execute_esdt_transfer( - &fs_setup.user_address, + &user_address, &fs_setup.farm_wrapper, FARM_TOKEN_ID, 1, @@ -128,27 +320,90 @@ fn farm_staking_boosted_rewards_with_energy_test() { fs_setup.set_block_epoch(8); - fs_setup.set_user_energy(&fs_setup.user_address.clone(), 10_000, 8, 10); + fs_setup.set_user_energy(&user_address, 10_000, 8, 10); - // value taken from the "test_unstake_farm" test - // originally, it was 40, but since 25% of the rewards go to boosted yields - // rewards are now only 3/4 * 40 = 30 - // - // 10 reserved for boosted yields -> 30 + 10 - let expected_reward_token_out = 40; - let expected_farming_token_balance = - rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out); - let expected_reward_per_share = 300_000; // from 400_000 -> 300_000 - fs_setup.claim_rewards( - farm_in_amount, + let full_position_base_rewards = 30; + let boosted_rewards_user = 10; + let half_position_expected_rewards = full_position_base_rewards / 2 + boosted_rewards_user; + let expected_farming_token_balance_user = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + half_position_expected_rewards); + + fs_setup.unstake_farm( + &user_address, + farm_in_amount / 2, 2, - expected_reward_token_out, - &expected_farming_token_balance, - &expected_farming_token_balance, + half_position_expected_rewards, + &expected_farming_token_balance_user, + &expected_farming_token_balance_user, 5, + farm_in_amount / 2, + &UnbondSftAttributes { + unlock_epoch: 8 + MIN_UNBOND_EPOCHS, + }, + ); + + fs_setup.set_block_nonce(20); + + // random user tx to collect rewards + + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &rand_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + fs_setup.set_user_energy(&rand_user, 1, 12, 1); + fs_setup.set_block_epoch(12); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 6, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(15); + + fs_setup.set_user_energy(&user_address, 10_000, 15, 10); + + let expected_rewards_amount = full_position_base_rewards / 2 * 2; // half remaining position * 2 times the 10 block period + let half_position_boosted_rewards = boosted_rewards_user / 2; + let remaining_expected_rewards = expected_rewards_amount + half_position_boosted_rewards; + let final_expected_farming_token_balance_user = + expected_farming_token_balance_user + rust_biguint!(remaining_expected_rewards); + let expected_reward_per_share = 600_000; + fs_setup.claim_rewards( + &user_address, + farm_in_amount / 2, + 2, + remaining_expected_rewards, + &final_expected_farming_token_balance_user, + &final_expected_farming_token_balance_user, + 8, expected_reward_per_share, ); - fs_setup.check_farm_token_supply(farm_in_amount); } #[test] @@ -157,13 +412,15 @@ fn farm_staking_claim_boosted_rewards_for_user_test() { let mut fs_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = fs_setup.user_address.clone(); + fs_setup.set_boosted_yields_factors(); fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); fs_setup.set_user_energy(&fs_setup.user_address.clone(), 10_000, 0, 10); let farm_in_amount = 100_000_000; - fs_setup.stake_farm(farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&user_address, farm_in_amount, &[], 1, 0, 0); fs_setup.check_farm_token_supply(farm_in_amount); // claim to get energy registered @@ -185,6 +442,7 @@ fn farm_staking_claim_boosted_rewards_for_user_test() { // random user tx to collect rewards let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + let user_address = fs_setup.user_address.clone(); fs_setup.b_mock.set_esdt_balance( &rand_user, FARMING_TOKEN_ID, @@ -224,7 +482,7 @@ fn farm_staking_claim_boosted_rewards_for_user_test() { fs_setup.set_block_epoch(8); - fs_setup.set_user_energy(&fs_setup.user_address.clone(), 10_000, 8, 10); + fs_setup.set_user_energy(&user_address, 10_000, 8, 10); // value taken from the "test_unstake_farm" test // originally, it was 40, but since 25% of the rewards go to boosted yields @@ -236,14 +494,30 @@ fn farm_staking_claim_boosted_rewards_for_user_test() { rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_boosted_reward_token_out); // Random_user claim boosted rewards for user - fs_setup.allow_external_claim_rewards(&fs_setup.user_address.clone()); + let rand_user_reward_balance = 4_999_999_990u64; + fs_setup.b_mock.check_esdt_balance( + &rand_user, + REWARD_TOKEN_ID, + &rust_biguint!(rand_user_reward_balance), + ); + fs_setup.allow_external_claim_rewards(&user_address, true); fs_setup.claim_boosted_rewards_for_user( - &fs_setup.user_address.clone(), + &user_address, &rand_user, expected_boosted_reward_token_out, &expected_farming_token_balance, ); + fs_setup.b_mock.check_esdt_balance( + &rand_user, + REWARD_TOKEN_ID, + &rust_biguint!(rand_user_reward_balance), + ); + fs_setup.check_farm_token_supply(farm_in_amount); + + // User removes the allowance of claim boosted rewards + fs_setup.allow_external_claim_rewards(&user_address, false); + fs_setup.claim_boosted_rewards_for_user_expect_error(&user_address, &rand_user); } #[test] @@ -252,14 +526,16 @@ fn farm_staking_full_position_boosted_rewards_test() { let mut fs_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = fs_setup.user_address.clone(); + fs_setup.set_boosted_yields_factors(); fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); fs_setup.set_user_energy(&fs_setup.user_address.clone(), 10_000, 0, 10); let farm_in_amount = 50_000_000; - fs_setup.stake_farm(farm_in_amount, &[], 1, 0, 0); - fs_setup.stake_farm(farm_in_amount, &[], 2, 0, 0); + fs_setup.stake_farm(&user_address, farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&user_address, farm_in_amount, &[], 2, 0, 0); fs_setup.check_farm_token_supply(farm_in_amount * 2); // claim to get energy registered @@ -334,6 +610,7 @@ fn farm_staking_full_position_boosted_rewards_test() { // Should receive half base rewards and full boosted rewards fs_setup.claim_rewards( + &user_address, farm_in_amount, 2, expected_base_rewards + expected_boosted_rewards, @@ -346,6 +623,7 @@ fn farm_staking_full_position_boosted_rewards_test() { // Should receive half base rewards and no boosted rewards expected_farming_token_balance += expected_base_rewards; fs_setup.claim_rewards( + &user_address, farm_in_amount, 3, expected_base_rewards, @@ -356,3 +634,295 @@ fn farm_staking_full_position_boosted_rewards_test() { ); fs_setup.check_farm_token_supply(farm_in_amount * 2); } + +#[test] +fn position_owner_change_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + let first_user = fs_setup.user_address.clone(); + let second_user = fs_setup.user_address2.clone(); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + fs_setup.set_user_energy(&first_user, 10_000, 0, 10); + fs_setup.set_user_energy(&second_user, 5_000, 0, 10); + + let farm_in_amount = 10_000_000; + let half_farm_in_amount = farm_in_amount / 2; + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 2, 0, 0); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 3, 0, 0); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 4, 0, 0); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 5, 0, 0); + + fs_setup.check_farm_token_supply(farm_in_amount * 5); + + fs_setup.check_user_total_farm_position(&first_user, farm_in_amount * 5); + fs_setup.check_user_total_farm_position(&second_user, 0); + + // First user transfers 5 position to second user + fs_setup.send_position(&first_user, &second_user, 1, farm_in_amount, 0); + fs_setup.send_position(&first_user, &second_user, 2, farm_in_amount, 0); + fs_setup.send_position(&first_user, &second_user, 3, farm_in_amount, 0); + fs_setup.send_position(&first_user, &second_user, 4, farm_in_amount, 0); + fs_setup.send_position(&first_user, &second_user, 5, farm_in_amount, 0); + + // Total farm position unchanged as users only transfered the farm positions + fs_setup.check_user_total_farm_position(&first_user, half_farm_in_amount * 10); + fs_setup.check_user_total_farm_position(&second_user, 0); + + let additional_farm_tokens = [TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: 1, + value: rust_biguint!(half_farm_in_amount), + }]; + + fs_setup.stake_farm( + &second_user, + farm_in_amount, + &additional_farm_tokens, + 6, + 0, + 0, + ); + + fs_setup.check_user_total_farm_position(&first_user, half_farm_in_amount * 9); + fs_setup.check_user_total_farm_position(&second_user, farm_in_amount + half_farm_in_amount); + + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &rand_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + // random user tx to collect rewards + + fs_setup.set_user_energy(&rand_user, 1, 5, 1); + fs_setup.set_block_epoch(5); + fs_setup.set_block_nonce(10); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 7, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(8); + + fs_setup.set_user_energy(&first_user, 10_000, 8, 10); + fs_setup.set_user_energy(&second_user, 5_000, 8, 10); + + // Second user claims with half position from first user + let mut rewards = 2; + let mut expected_farming_token_balance = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + rewards); + fs_setup.claim_rewards( + &second_user, + half_farm_in_amount, + 2, + rewards, + &expected_farming_token_balance, + &expected_farming_token_balance, + 9, + 250_000, + ); + + fs_setup.check_user_total_farm_position(&first_user, half_farm_in_amount * 8); + fs_setup.check_user_total_farm_position(&second_user, farm_in_amount + half_farm_in_amount * 2); + + // random user tx to collect rewards + fs_setup.set_user_energy(&rand_user, 1, 12, 1); + fs_setup.set_block_epoch(12); + fs_setup.set_block_nonce(20); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 10, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(15); + + fs_setup.set_user_energy(&first_user, 10_000, 15, 10); + fs_setup.set_user_energy(&second_user, 5_000, 15, 10); + + // Second user exits with half position from first user + fs_setup + .b_mock + .execute_esdt_transfer( + &second_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 3, + &rust_biguint!(half_farm_in_amount), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + rewards += 3; + expected_farming_token_balance = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + rewards); + fs_setup.b_mock.check_esdt_balance( + &second_user, + REWARD_TOKEN_ID, + &expected_farming_token_balance, + ); + + fs_setup.check_user_total_farm_position(&first_user, half_farm_in_amount * 7); + fs_setup.check_user_total_farm_position(&second_user, farm_in_amount + half_farm_in_amount * 2); + + // First user claim boosted rewards + let first_user_expected_boosted_reward_token_out = 5; + let first_user_expected_farming_token_balance = rust_biguint!( + USER_TOTAL_RIDE_TOKENS - farm_in_amount * 5 + first_user_expected_boosted_reward_token_out + ); + fs_setup.claim_boosted_rewards_for_user( + &first_user, + &first_user, + first_user_expected_boosted_reward_token_out, + &first_user_expected_farming_token_balance, + ); + + fs_setup.check_user_total_farm_position(&first_user, half_farm_in_amount * 7); + fs_setup.check_user_total_farm_position(&second_user, farm_in_amount + half_farm_in_amount * 2); + + // random user tx to collect rewards + fs_setup.set_user_energy(&rand_user, 1, 12, 1); + fs_setup.set_block_epoch(20); + fs_setup.set_block_nonce(30); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 13, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(22); + + fs_setup.set_user_energy(&first_user, 10_000, 22, 10); + fs_setup.set_user_energy(&second_user, 5_000, 22, 10); + + // Second user merges half own position with 2 x half position from first user + // We send the payment from first user first, + // to see that the original caller is correctly updated as second user + let farm_tokens = [ + TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: 4, + value: rust_biguint!(half_farm_in_amount), + }, + TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: 6, + value: rust_biguint!(half_farm_in_amount), + }, + TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: 5, + value: rust_biguint!(half_farm_in_amount), + }, + ]; + fs_setup + .b_mock + .execute_esdt_multi_transfer(&second_user, &fs_setup.farm_wrapper, &farm_tokens, |sc| { + let _ = sc.merge_farm_tokens_endpoint(); + }) + .assert_ok(); + + let expected_attributes = StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(0), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(half_farm_in_amount * 3), + original_owner: managed_address!(&second_user), // Check that second user is original owner + }; + fs_setup.b_mock.check_nft_balance( + &second_user, + FARM_TOKEN_ID, + 15, + &rust_biguint!(half_farm_in_amount * 3), + Some(&expected_attributes), + ); + rewards += 1; + expected_farming_token_balance = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + rewards); + fs_setup.b_mock.check_esdt_balance( + &second_user, + REWARD_TOKEN_ID, + &expected_farming_token_balance, + ); + + fs_setup.check_user_total_farm_position(&first_user, half_farm_in_amount * 5); + fs_setup.check_user_total_farm_position(&second_user, farm_in_amount + half_farm_in_amount * 4); +} diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index f9c2b5955..88192dc2f 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -53,6 +53,7 @@ where pub b_mock: BlockchainStateWrapper, pub owner_address: Address, pub user_address: Address, + pub user_address2: Address, pub farm_wrapper: ContractObjWrapper, FarmObjBuilder>, pub energy_factory_wrapper: ContractObjWrapper, EnergyFactoryBuilder>, @@ -145,11 +146,18 @@ where FARMING_TOKEN_ID, &rust_biguint!(USER_TOTAL_RIDE_TOKENS), ); + let user_addr2 = b_mock.create_user_account(&rust_biguint!(100_000_000)); + b_mock.set_esdt_balance( + &user_addr2, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); FarmStakingSetup { b_mock, owner_address: owner_addr, user_address: user_addr, + user_address2: user_addr2, farm_wrapper, energy_factory_wrapper, } @@ -157,6 +165,7 @@ where pub fn stake_farm( &mut self, + user: &Address, farm_in_amount: u64, additional_farm_tokens: &[TxTokenTransfer], expected_farm_token_nonce: u64, @@ -177,7 +186,7 @@ where } self.b_mock - .execute_esdt_multi_transfer(&self.user_address, &self.farm_wrapper, &payments, |sc| { + .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { let (new_farm_token_payment, _) = sc.stake_farm_endpoint(OptionalValue::None).into_tuple(); assert_eq!( @@ -199,10 +208,10 @@ where reward_per_share: managed_biguint!(expected_reward_per_share), compounded_reward: managed_biguint!(expected_compounded_reward), current_farm_amount: managed_biguint!(expected_total_out_amount), - original_owner: managed_address!(&self.user_address), + original_owner: managed_address!(&user), }; self.b_mock.check_nft_balance( - &self.user_address, + &user, FARM_TOKEN_ID, expected_farm_token_nonce, &rust_biguint!(expected_total_out_amount), @@ -210,9 +219,74 @@ where ); } + pub fn stake_farm_for_other_user( + &mut self, + user: &Address, + broker: &Address, + farm_in_amount: u64, + additional_farm_tokens: &[TxTokenTransfer], + ) -> TxResult { + let mut payments = Vec::with_capacity(1 + additional_farm_tokens.len()); + payments.push(TxTokenTransfer { + token_identifier: FARMING_TOKEN_ID.to_vec(), + nonce: 0, + value: rust_biguint!(farm_in_amount), + }); + payments.extend_from_slice(additional_farm_tokens); + + self.b_mock + .execute_esdt_multi_transfer(broker, &self.farm_wrapper, &payments, |sc| { + sc.stake_farm_endpoint(OptionalValue::Some(managed_address!(user))) + .into_tuple(); + }) + } + + pub fn claim_farm_for_other_user( + &mut self, + user: &Address, + broker: &Address, + farm_in_nonce: u64, + farm_in_amount: u64, + ) -> TxResult { + let mut payments = vec![]; + payments.push(TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: farm_in_nonce, + value: rust_biguint!(farm_in_amount), + }); + + self.b_mock + .execute_esdt_multi_transfer(broker, &self.farm_wrapper, &payments, |sc| { + sc.claim_rewards(OptionalValue::Some(managed_address!(user))) + .into_tuple(); + }) + } + + pub fn unstake_farm_for_other_user( + &mut self, + user: &Address, + broker: &Address, + farm_in_nonce: u64, + farm_in_amount: u64, + ) -> TxResult { + let mut payments = vec![]; + payments.push(TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: farm_in_nonce, + value: rust_biguint!(farm_in_amount), + }); + + self.b_mock + .execute_esdt_multi_transfer(broker, &self.farm_wrapper, &payments, |sc| { + sc.unstake_farm(OptionalValue::Some(managed_address!(user))) + .into_tuple(); + }) + } + #[allow(clippy::too_many_arguments)] pub fn claim_rewards( &mut self, + user: &Address, farm_token_amount: u64, farm_token_nonce: u64, expected_reward_token_out: u64, @@ -223,7 +297,7 @@ where ) { self.b_mock .execute_esdt_transfer( - &self.user_address, + user, &self.farm_wrapper, FARM_TOKEN_ID, farm_token_nonce, @@ -256,26 +330,20 @@ where reward_per_share: managed_biguint!(expected_reward_per_share), compounded_reward: managed_biguint!(0), current_farm_amount: managed_biguint!(farm_token_amount), - original_owner: managed_address!(&self.user_address), + original_owner: managed_address!(user), }; self.b_mock.check_nft_balance( - &self.user_address, + user, FARM_TOKEN_ID, expected_farm_token_nonce_out, &rust_biguint!(farm_token_amount), Some(&expected_attributes), ); - self.b_mock.check_esdt_balance( - &self.user_address, - REWARD_TOKEN_ID, - expected_user_reward_token_balance, - ); - self.b_mock.check_esdt_balance( - &self.user_address, - FARMING_TOKEN_ID, - expected_user_farming_token_balance, - ); + self.b_mock + .check_esdt_balance(user, REWARD_TOKEN_ID, expected_user_reward_token_balance); + self.b_mock + .check_esdt_balance(user, FARMING_TOKEN_ID, expected_user_farming_token_balance); } pub fn claim_boosted_rewards_for_user( @@ -309,9 +377,22 @@ where ); } + pub fn claim_boosted_rewards_for_user_expect_error( + &mut self, + owner: &Address, + broker: &Address, + ) { + self.b_mock + .execute_tx(broker, &self.farm_wrapper, &rust_biguint!(0), |sc| { + let _ = sc.claim_boosted_rewards(OptionalValue::Some(managed_address!(owner))); + }) + .assert_error(4, "Cannot claim rewards for this address"); + } + #[allow(clippy::too_many_arguments)] pub fn unstake_farm( &mut self, + user: &Address, farm_token_amount: u64, farm_token_nonce: u64, expected_rewards_out: u64, @@ -323,7 +404,7 @@ where ) { self.b_mock .execute_esdt_transfer( - &self.user_address, + user, &self.farm_wrapper, FARM_TOKEN_ID, farm_token_nonce, @@ -429,14 +510,10 @@ where .assert_ok(); } - pub fn allow_external_claim_rewards(&mut self, user: &Address) { + pub fn allow_external_claim_rewards(&mut self, user: &Address, allow_claim: bool) { self.b_mock .execute_tx(user, &self.farm_wrapper, &rust_biguint!(0), |sc| { - sc.user_total_farm_position(&managed_address!(user)).update( - |user_total_farm_position| { - user_total_farm_position.allow_external_claim_boosted_rewards = true; - }, - ); + sc.allow_external_claim_boosted_rewards(allow_claim); }) .assert_ok(); } @@ -534,4 +611,98 @@ where ) .assert_error(expected_status, expected_message) } + + pub fn send_position( + &mut self, + sender: &Address, + receiver: &Address, + nonce: u64, + amount: u64, + attr_reward_per_share: u64, + ) { + self.b_mock.check_nft_balance( + sender, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(amount), + Some(&StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }), + ); + + self.b_mock + .check_nft_balance::>( + receiver, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(0), + None, + ); + + self.b_mock.set_nft_balance( + sender, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(0), + &StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }, + ); + + self.b_mock.set_nft_balance( + receiver, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(amount), + &StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }, + ); + + self.b_mock + .check_nft_balance::>( + sender, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(0), + None, + ); + + self.b_mock.check_nft_balance( + receiver, + FARM_TOKEN_ID, + nonce, + &rust_biguint!(amount), + Some(&StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(attr_reward_per_share), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(amount), + original_owner: managed_address!(&sender), + }), + ); + } + + pub fn check_user_total_farm_position(&mut self, user_addr: &Address, expected_amount: u64) { + self.b_mock + .execute_query(&self.farm_wrapper, |sc| { + let user_total_farm_position_mapper = + sc.user_total_farm_position(&managed_address!(user_addr)); + if expected_amount > 0 && !user_total_farm_position_mapper.is_empty() { + assert_eq!( + managed_biguint!(expected_amount), + user_total_farm_position_mapper.get().total_farm_position + ); + } + }) + .assert_ok(); + } } diff --git a/farm-staking/farm-staking/tests/farm_staking_test.rs b/farm-staking/farm-staking/tests/farm_staking_test.rs index 89192a6a1..26a9d065b 100644 --- a/farm-staking/farm-staking/tests/farm_staking_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_test.rs @@ -20,9 +20,18 @@ fn test_enter_farm() { let mut farm_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = farm_setup.user_address.clone(); + let farm_in_amount = 100_000_000; let expected_farm_token_nonce = 1; - farm_setup.stake_farm(farm_in_amount, &[], expected_farm_token_nonce, 0, 0); + farm_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); farm_setup.check_farm_token_supply(farm_in_amount); } @@ -32,9 +41,18 @@ fn test_unstake_farm() { let mut farm_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = farm_setup.user_address.clone(); + let farm_in_amount = 100_000_000; let expected_farm_token_nonce = 1; - farm_setup.stake_farm(farm_in_amount, &[], expected_farm_token_nonce, 0, 0); + farm_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); farm_setup.check_farm_token_supply(farm_in_amount); let current_block = 10; @@ -54,6 +72,7 @@ fn test_unstake_farm() { let expected_ride_token_balance = rust_biguint!(USER_TOTAL_RIDE_TOKENS) - farm_in_amount + expected_rewards; farm_setup.unstake_farm( + &user_address, farm_in_amount, expected_farm_token_nonce, expected_rewards, @@ -74,9 +93,18 @@ fn test_claim_rewards() { let mut farm_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = farm_setup.user_address.clone(); + let farm_in_amount = 100_000_000; let expected_farm_token_nonce = 1; - farm_setup.stake_farm(farm_in_amount, &[], expected_farm_token_nonce, 0, 0); + farm_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); farm_setup.check_farm_token_supply(farm_in_amount); farm_setup.set_block_epoch(5); @@ -88,6 +116,7 @@ fn test_claim_rewards() { rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out); let expected_reward_per_share = 400_000; farm_setup.claim_rewards( + &user_address, farm_in_amount, expected_farm_token_nonce, expected_reward_token_out, @@ -109,9 +138,18 @@ where { let mut farm_setup = FarmStakingSetup::new(farm_builder, energy_factory_builder); + let user_address = farm_setup.user_address.clone(); + let farm_in_amount = 100_000_000; let expected_farm_token_nonce = 1; - farm_setup.stake_farm(farm_in_amount, &[], expected_farm_token_nonce, 0, 0); + farm_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); farm_setup.check_farm_token_supply(farm_in_amount); farm_setup.set_block_epoch(5); @@ -134,6 +172,7 @@ where / total_amount; farm_setup.stake_farm( + &user_address, second_farm_in_amount, &prev_farm_tokens, expected_farm_token_nonce + 1, @@ -156,6 +195,9 @@ fn test_exit_farm_after_enter_twice() { DebugApi::dummy(); let mut farm_setup = steps_enter_farm_twice(farm_staking::contract_obj, energy_factory::contract_obj); + + let user_address = farm_setup.user_address.clone(); + let farm_in_amount = 100_000_000; let second_farm_in_amount = 200_000_000; @@ -167,6 +209,7 @@ fn test_exit_farm_after_enter_twice() { rust_biguint!(USER_TOTAL_RIDE_TOKENS) - farm_in_amount - second_farm_in_amount + expected_rewards; farm_setup.unstake_farm( + &user_address, farm_in_amount, 2, expected_rewards, @@ -187,9 +230,18 @@ fn test_unbond() { let mut farm_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = farm_setup.user_address.clone(); + let farm_in_amount = 100_000_000; let expected_farm_token_nonce = 1; - farm_setup.stake_farm(farm_in_amount, &[], expected_farm_token_nonce, 0, 0); + farm_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); farm_setup.check_farm_token_supply(farm_in_amount); let current_block = 10; @@ -209,6 +261,7 @@ fn test_unbond() { let expected_ride_token_balance = rust_biguint!(USER_TOTAL_RIDE_TOKENS) - farm_in_amount + expected_rewards; farm_setup.unstake_farm( + &user_address, farm_in_amount, expected_farm_token_nonce, expected_rewards, @@ -254,12 +307,21 @@ fn test_withdraw_after_produced_rewards() { let mut farm_setup = FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + let user_address = farm_setup.user_address.clone(); + let initial_rewards_capacity = 1_000_000_000_000u64; farm_setup.check_rewards_capacity(initial_rewards_capacity); let farm_in_amount = 100_000_000; let expected_farm_token_nonce = 1; - farm_setup.stake_farm(farm_in_amount, &[], expected_farm_token_nonce, 0, 0); + farm_setup.stake_farm( + &user_address, + farm_in_amount, + &[], + expected_farm_token_nonce, + 0, + 0, + ); farm_setup.check_farm_token_supply(farm_in_amount); farm_setup.set_block_epoch(5); From 74c16af4fc574a92e10fdd7b4eb15f23b6cc0999 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 12 Apr 2024 03:18:43 +0300 Subject: [PATCH 020/103] use FarmStakingWrapper for merge endpoint --- farm-staking/farm-staking/src/lib.rs | 46 ++++++------------- .../tests/farm_staking_energy_test.rs | 2 +- .../tests/farm_staking_setup/mod.rs | 2 +- 3 files changed, 17 insertions(+), 33 deletions(-) diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index e4f0a6533..3d85132cf 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -117,46 +117,30 @@ pub trait FarmStaking: let boosted_rewards_payment = EsdtTokenPayment::new(self.reward_token_id().get(), 0, boosted_rewards); - let payments = self.get_non_empty_payments(); - let token_mapper = self.farm_token(); - - for farm_position in &payments { - if self.is_old_farm_position(farm_position.token_nonce) { - continue; - } - - let token_attributes: StakingFarmTokenAttributes = - token_mapper.get_token_attributes(farm_position.token_nonce); - - if token_attributes.original_owner != caller { - self.user_total_farm_position(&token_attributes.original_owner) - .update(|user_total_farm_position| { - if user_total_farm_position.total_farm_position > farm_position.amount { - user_total_farm_position.total_farm_position -= &farm_position.amount; - } else { - user_total_farm_position.total_farm_position = BigUint::zero(); - } - }); - self.user_total_farm_position(&caller) - .update(|user_total_farm_position| { - user_total_farm_position.total_farm_position += &farm_position.amount; - }); - } - } - - let mut output_attributes: StakingFarmTokenAttributes = - self.merge_from_payments_and_burn(payments, &token_mapper); + let mut output_attributes = self.merge_farm_tokens::>(); output_attributes.original_owner = caller.clone(); let new_token_amount = output_attributes.get_total_supply(); - - let merged_farm_token = token_mapper.nft_create(new_token_amount, &output_attributes); + let merged_farm_token = self + .farm_token() + .nft_create(new_token_amount, &output_attributes); self.send_payment_non_zero(&caller, &merged_farm_token); self.send_payment_non_zero(&caller, &boosted_rewards_payment); (merged_farm_token, boosted_rewards_payment).into() } + fn merge_farm_tokens>(&self) -> FC::AttributesType { + let payments = self.get_non_empty_payments(); + let token_mapper = self.farm_token(); + token_mapper.require_all_same_token(&payments); + + let caller = self.blockchain().get_caller(); + FC::check_and_update_user_farm_position(self, &caller, &payments); + + self.merge_from_payments_and_burn(payments, &token_mapper) + } + #[endpoint(setBoostedYieldsRewardsPercentage)] fn set_boosted_yields_rewards_percentage(&self, percentage: u64) { self.require_caller_has_admin_permissions(); diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index 8b51dee1b..b2c2f03ba 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -83,7 +83,7 @@ fn farm_staking_other_user_enter_negative_test() { let farm_in_amount = 100_000_000; fs_setup - .stake_farm_for_other_user(&rand_user, &user_address, farm_in_amount, &vec![]) + .stake_farm_for_other_user(&rand_user, &user_address, farm_in_amount, &[]) .assert_error(4, "Item not whitelisted"); let expected_farm_token_nonce = 1; diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index 88192dc2f..c0329a2f6 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -211,7 +211,7 @@ where original_owner: managed_address!(&user), }; self.b_mock.check_nft_balance( - &user, + user, FARM_TOKEN_ID, expected_farm_token_nonce, &rust_biguint!(expected_total_out_amount), From 4463206df3824fb6c82ebc12d57a1efeb266431e Mon Sep 17 00:00:00 2001 From: Andrei Marinica Date: Fri, 12 Apr 2024 10:23:37 +0300 Subject: [PATCH 021/103] upgrade annotation --- dex/farm-with-locked-rewards/src/lib.rs | 2 +- dex/farm/src/lib.rs | 2 +- dex/governance/src/lib.rs | 2 +- dex/pair/src/lib.rs | 2 +- dex/price-discovery/src/lib.rs | 2 +- dex/proxy-deployer/src/lib.rs | 2 +- dex/router/src/contract.rs | 2 +- energy-integration/energy-update/src/lib.rs | 2 +- energy-integration/fees-collector/src/lib.rs | 2 +- energy-integration/governance-v2/src/lib.rs | 2 +- farm-staking/farm-staking-proxy/src/lib.rs | 2 +- farm-staking/farm-staking/src/lib.rs | 2 +- farm-staking/metabonding-staking/src/lib.rs | 2 +- locked-asset/distribution/src/lib.rs | 2 +- locked-asset/energy-factory/src/lib.rs | 2 +- locked-asset/factory/src/lib.rs | 2 +- locked-asset/lkmex-transfer/src/lib.rs | 2 +- locked-asset/locked-token-wrapper/src/lib.rs | 2 +- locked-asset/proxy_dex/src/lib.rs | 2 +- locked-asset/simple-lock-whitelist/src/lib.rs | 2 +- locked-asset/simple-lock/src/lib.rs | 2 +- locked-asset/token-unstake/src/lib.rs | 2 +- pause-all/src/lib.rs | 2 +- 23 files changed, 23 insertions(+), 23 deletions(-) diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index cfe9838e5..6b5b334a2 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -82,7 +82,7 @@ pub trait Farm: self.try_set_farm_position_migration_nonce(farm_token_mapper); } - #[endpoint] + #[upgrade] fn upgrade(&self) { let current_epoch = self.blockchain().get_block_epoch(); self.first_week_start_epoch().set_if_empty(current_epoch); diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index a200881c6..97163efb0 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -85,7 +85,7 @@ pub trait Farm: self.try_set_farm_position_migration_nonce(farm_token_mapper); } - #[endpoint] + #[upgrade] fn upgrade(&self) { let current_epoch = self.blockchain().get_block_epoch(); self.first_week_start_epoch().set_if_empty(current_epoch); diff --git a/dex/governance/src/lib.rs b/dex/governance/src/lib.rs index e9d4147d3..460aabcda 100644 --- a/dex/governance/src/lib.rs +++ b/dex/governance/src/lib.rs @@ -49,7 +49,7 @@ pub trait Governance: self.try_change_price_providers(price_providers); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[payable("*")] diff --git a/dex/pair/src/lib.rs b/dex/pair/src/lib.rs index 090b66cf3..e67010d67 100644 --- a/dex/pair/src/lib.rs +++ b/dex/pair/src/lib.rs @@ -101,7 +101,7 @@ pub trait Pair: }; } - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[endpoint(setLpTokenIdentifier)] diff --git a/dex/price-discovery/src/lib.rs b/dex/price-discovery/src/lib.rs index 32a07acf0..b0c430e52 100644 --- a/dex/price-discovery/src/lib.rs +++ b/dex/price-discovery/src/lib.rs @@ -113,7 +113,7 @@ pub trait PriceDiscovery: self.set_locking_sc_address(locking_sc_address); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} /// Users can deposit either launched_token or accepted_token. diff --git a/dex/proxy-deployer/src/lib.rs b/dex/proxy-deployer/src/lib.rs index a05bab7b0..7f7f0c16a 100644 --- a/dex/proxy-deployer/src/lib.rs +++ b/dex/proxy-deployer/src/lib.rs @@ -16,6 +16,6 @@ pub trait ProxyDeployer: farm_deploy::FarmDeployModule { self.farm_template_address().set(&farm_template_address); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} } diff --git a/dex/router/src/contract.rs b/dex/router/src/contract.rs index 04b787a03..094e61f07 100644 --- a/dex/router/src/contract.rs +++ b/dex/router/src/contract.rs @@ -41,7 +41,7 @@ pub trait Router: self.owner().set(&self.blockchain().get_caller()); } - #[endpoint] + #[upgrade] fn upgrade(&self) { self.state().set(false); } diff --git a/energy-integration/energy-update/src/lib.rs b/energy-integration/energy-update/src/lib.rs index a8e10213f..6cb9a7520 100644 --- a/energy-integration/energy-update/src/lib.rs +++ b/energy-integration/energy-update/src/lib.rs @@ -9,7 +9,7 @@ pub trait EnergyUpdate { #[init] fn init(&self) {} - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[endpoint(updateFarmsEnergyForUser)] diff --git a/energy-integration/fees-collector/src/lib.rs b/energy-integration/fees-collector/src/lib.rs index b5a37d7fb..e78ed6812 100644 --- a/energy-integration/fees-collector/src/lib.rs +++ b/energy-integration/fees-collector/src/lib.rs @@ -44,7 +44,7 @@ pub trait FeesCollector: self.energy_factory_address().set(&energy_factory_address); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[endpoint(claimRewards)] diff --git a/energy-integration/governance-v2/src/lib.rs b/energy-integration/governance-v2/src/lib.rs index 0fcb53dca..2014b3a53 100644 --- a/energy-integration/governance-v2/src/lib.rs +++ b/energy-integration/governance-v2/src/lib.rs @@ -61,7 +61,7 @@ pub trait GovernanceV2: self.try_change_fee_token_id(fee_token); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} /// Propose a list of actions. diff --git a/farm-staking/farm-staking-proxy/src/lib.rs b/farm-staking/farm-staking-proxy/src/lib.rs index bd8ef7013..7bfc66bab 100644 --- a/farm-staking/farm-staking-proxy/src/lib.rs +++ b/farm-staking/farm-staking-proxy/src/lib.rs @@ -58,6 +58,6 @@ pub trait FarmStakingProxy: self.lp_token_id().set_if_empty(&lp_token_id); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} } diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index c210d080c..5d321d8ad 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -97,7 +97,7 @@ pub trait FarmStaking: self.try_set_farm_position_migration_nonce(farm_token_mapper); } - #[endpoint] + #[upgrade] fn upgrade(&self) { let current_epoch = self.blockchain().get_block_epoch(); self.first_week_start_epoch().set_if_empty(current_epoch); diff --git a/farm-staking/metabonding-staking/src/lib.rs b/farm-staking/metabonding-staking/src/lib.rs index 94be22193..d15ce3c90 100644 --- a/farm-staking/metabonding-staking/src/lib.rs +++ b/farm-staking/metabonding-staking/src/lib.rs @@ -26,7 +26,7 @@ pub trait MetabondingStaking: .set_if_empty(&locked_asset_factory_address); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[payable("*")] diff --git a/locked-asset/distribution/src/lib.rs b/locked-asset/distribution/src/lib.rs index 93187154e..b996701df 100644 --- a/locked-asset/distribution/src/lib.rs +++ b/locked-asset/distribution/src/lib.rs @@ -47,7 +47,7 @@ pub trait Distribution: global_op::GlobalOperationModule { .set_if_empty(&locked_asset_factory_address); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[only_owner] diff --git a/locked-asset/energy-factory/src/lib.rs b/locked-asset/energy-factory/src/lib.rs index d146566d6..f38c2e0e7 100644 --- a/locked-asset/energy-factory/src/lib.rs +++ b/locked-asset/energy-factory/src/lib.rs @@ -91,7 +91,7 @@ pub trait SimpleLockEnergy: self.set_paused(true); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} /// Locks a whitelisted token until `unlock_epoch` and receive meta ESDT LOCKED tokens diff --git a/locked-asset/factory/src/lib.rs b/locked-asset/factory/src/lib.rs index d8de993b4..b826bb14b 100644 --- a/locked-asset/factory/src/lib.rs +++ b/locked-asset/factory/src/lib.rs @@ -63,7 +63,7 @@ pub trait LockedAssetFactory: self.set_paused(true); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} fn set_extended_attributes_activation_nonce(&self, is_sc_upgrade: bool) { diff --git a/locked-asset/lkmex-transfer/src/lib.rs b/locked-asset/lkmex-transfer/src/lib.rs index 7c187882e..126e740b8 100644 --- a/locked-asset/lkmex-transfer/src/lib.rs +++ b/locked-asset/lkmex-transfer/src/lib.rs @@ -56,7 +56,7 @@ pub trait LkmexTransfer: self.add_permissions(caller, Permissions::OWNER); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[endpoint] diff --git a/locked-asset/locked-token-wrapper/src/lib.rs b/locked-asset/locked-token-wrapper/src/lib.rs index a6aa3e96f..5398cc42a 100644 --- a/locked-asset/locked-token-wrapper/src/lib.rs +++ b/locked-asset/locked-token-wrapper/src/lib.rs @@ -20,7 +20,7 @@ pub trait LockedTokenWrapper: self.energy_factory_address().set(&energy_factory_address); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[payable("*")] diff --git a/locked-asset/proxy_dex/src/lib.rs b/locked-asset/proxy_dex/src/lib.rs index 810cd3640..3e03c2f06 100644 --- a/locked-asset/proxy_dex/src/lib.rs +++ b/locked-asset/proxy_dex/src/lib.rs @@ -58,7 +58,7 @@ pub trait ProxyDexImpl: .set_if_empty(&energy_factory_address); } - #[endpoint] + #[upgrade] fn upgrade(&self, old_locked_token_id: TokenIdentifier, old_factory_address: ManagedAddress) { require!( old_locked_token_id.is_valid_esdt_identifier(), diff --git a/locked-asset/simple-lock-whitelist/src/lib.rs b/locked-asset/simple-lock-whitelist/src/lib.rs index 577671ede..7ed5b52ac 100644 --- a/locked-asset/simple-lock-whitelist/src/lib.rs +++ b/locked-asset/simple-lock-whitelist/src/lib.rs @@ -30,7 +30,7 @@ pub trait SimpleLockWhitelist: self.transfer_roles_not_set().set(true); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} /// Sets the transfer role for the given address. Defaults to own address. diff --git a/locked-asset/simple-lock/src/lib.rs b/locked-asset/simple-lock/src/lib.rs index 5db24f38e..fb59b792c 100644 --- a/locked-asset/simple-lock/src/lib.rs +++ b/locked-asset/simple-lock/src/lib.rs @@ -25,7 +25,7 @@ pub trait SimpleLock: #[init] fn init(&self) {} - #[endpoint] + #[upgrade] fn upgrade(&self) {} /// Locks any token (including EGLD) until `unlock_epoch` and receive meta ESDT LOCKED tokens. diff --git a/locked-asset/token-unstake/src/lib.rs b/locked-asset/token-unstake/src/lib.rs index 6295d46a2..985e91be9 100644 --- a/locked-asset/token-unstake/src/lib.rs +++ b/locked-asset/token-unstake/src/lib.rs @@ -42,6 +42,6 @@ pub trait TokenUnstakeModule: self.fees_burn_percentage().set(fees_burn_percentage); } - #[endpoint] + #[upgrade] fn upgrade(&self) {} } diff --git a/pause-all/src/lib.rs b/pause-all/src/lib.rs index 6e9bcd823..05f7fe541 100644 --- a/pause-all/src/lib.rs +++ b/pause-all/src/lib.rs @@ -28,7 +28,7 @@ pub trait PauseAll: #[init] fn init(&self) {} - #[endpoint] + #[upgrade] fn upgrade(&self) {} #[only_owner] From 0f92c4ff1a9d7596f4da41c918f7a782afab7539 Mon Sep 17 00:00:00 2001 From: Andrei Marinica Date: Fri, 12 Apr 2024 10:23:51 +0300 Subject: [PATCH 022/103] cargo fmt --- dex/pair/src/read_pair_storage.rs | 2 +- dex/router/src/multi_pair_swap.rs | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/dex/pair/src/read_pair_storage.rs b/dex/pair/src/read_pair_storage.rs index a14f862c3..2aeff0566 100644 --- a/dex/pair/src/read_pair_storage.rs +++ b/dex/pair/src/read_pair_storage.rs @@ -73,4 +73,4 @@ pub trait ReadPairStorageModule { SingleValueMapper::<_, _, ManagedAddress>::new_from_address(pair_address, storage_key) } -} \ No newline at end of file +} diff --git a/dex/router/src/multi_pair_swap.rs b/dex/router/src/multi_pair_swap.rs index e69350ecd..dc5492f9d 100644 --- a/dex/router/src/multi_pair_swap.rs +++ b/dex/router/src/multi_pair_swap.rs @@ -19,7 +19,10 @@ pub trait MultiPairSwap: { #[payable("*")] #[endpoint(multiPairSwap)] - fn multi_pair_swap(&self, swap_operations: MultiValueEncoded>) -> ManagedVec { + fn multi_pair_swap( + &self, + swap_operations: MultiValueEncoded>, + ) -> ManagedVec { require!(self.is_active(), "Not active"); let (token_id, nonce, amount) = self.call_value().single_esdt().into_tuple(); From 88ab1ca365e190dd9334820c739861aecd9cbcb4 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Sat, 13 Apr 2024 00:46:26 +0300 Subject: [PATCH 023/103] router fix after framework upgrade --- dex/router/src/config.rs | 7 ++++--- dex/router/src/contract.rs | 3 ++- dex/router/src/enable_swap_by_user.rs | 7 +++++-- dex/router/src/factory.rs | 3 ++- dex/router/src/multi_pair_swap.rs | 11 ++++++----- 5 files changed, 19 insertions(+), 12 deletions(-) diff --git a/dex/router/src/config.rs b/dex/router/src/config.rs index 388bc0a44..c4f89c440 100644 --- a/dex/router/src/config.rs +++ b/dex/router/src/config.rs @@ -2,16 +2,17 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use crate::{enable_swap_by_user::EnableSwapByUserConfig, factory::PairTokens}; +use pair::read_pair_storage; #[multiversx_sc::module] -pub trait ConfigModule { +pub trait ConfigModule: read_pair_storage::ReadPairStorageModule { fn is_active(&self) -> bool { self.state().get() } fn check_is_pair_sc(&self, pair_address: &ManagedAddress) { - let first_token_id = self.first_token_id().get_from_address(pair_address); - let second_token_id = self.second_token_id().get_from_address(pair_address); + let first_token_id = self.get_first_token_id_mapper(pair_address.clone()).get(); + let second_token_id = self.get_second_token_id_mapper(pair_address.clone()).get(); let pair_tokens = PairTokens { first_token_id: first_token_id.clone(), diff --git a/dex/router/src/contract.rs b/dex/router/src/contract.rs index 6c425aa6c..e23d0f12f 100644 --- a/dex/router/src/contract.rs +++ b/dex/router/src/contract.rs @@ -12,7 +12,7 @@ pub mod multi_pair_swap; use factory::PairTokens; use pair::config::ProxyTrait as _; use pair::fee::ProxyTrait as _; -use pair::ProxyTrait as _; +use pair::{read_pair_storage, ProxyTrait as _}; use pausable::ProxyTrait as _; const LP_TOKEN_DECIMALS: usize = 18; @@ -26,6 +26,7 @@ const USER_DEFINED_TOTAL_FEE_PERCENT: u64 = 1_000; #[multiversx_sc::contract] pub trait Router: config::ConfigModule + + read_pair_storage::ReadPairStorageModule + factory::FactoryModule + events::EventsModule + multi_pair_swap::MultiPairSwap diff --git a/dex/router/src/enable_swap_by_user.rs b/dex/router/src/enable_swap_by_user.rs index f5929f4f7..1a8c40770 100644 --- a/dex/router/src/enable_swap_by_user.rs +++ b/dex/router/src/enable_swap_by_user.rs @@ -1,7 +1,7 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); -use pair::{config::ProxyTrait as _, pair_actions::views::ProxyTrait as _}; +use pair::{config::ProxyTrait as _, pair_actions::views::ProxyTrait as _, read_pair_storage}; use pausable::{ProxyTrait as _, State}; use simple_lock::locked_token::LockedTokenAttributes; @@ -27,7 +27,10 @@ pub struct SafePriceResult { #[multiversx_sc::module] pub trait EnableSwapByUserModule: - config::ConfigModule + crate::factory::FactoryModule + crate::events::EventsModule + config::ConfigModule + + read_pair_storage::ReadPairStorageModule + + crate::factory::FactoryModule + + crate::events::EventsModule { #[only_owner] #[endpoint(configEnableByUserParameters)] diff --git a/dex/router/src/factory.rs b/dex/router/src/factory.rs index 37a476a8d..fea434703 100644 --- a/dex/router/src/factory.rs +++ b/dex/router/src/factory.rs @@ -2,6 +2,7 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use crate::config; +use pair::read_pair_storage; const TEMPORARY_OWNER_PERIOD_BLOCKS: u64 = 50; @@ -19,7 +20,7 @@ pub struct PairContractMetadata { } #[multiversx_sc::module] -pub trait FactoryModule: config::ConfigModule { +pub trait FactoryModule: config::ConfigModule + read_pair_storage::ReadPairStorageModule { #[proxy] fn pair_contract_deploy_proxy(&self) -> pair::Proxy; diff --git a/dex/router/src/multi_pair_swap.rs b/dex/router/src/multi_pair_swap.rs index dc5492f9d..1e47378f9 100644 --- a/dex/router/src/multi_pair_swap.rs +++ b/dex/router/src/multi_pair_swap.rs @@ -1,11 +1,9 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); -use pair::pair_actions::swap::ProxyTrait as _; - -use crate::config; - use super::factory; +use crate::config; +use pair::{pair_actions::swap::ProxyTrait as _, read_pair_storage}; type SwapOperationType = MultiValue4, ManagedBuffer, TokenIdentifier, BigUint>; @@ -15,7 +13,10 @@ pub const SWAP_TOKENS_FIXED_OUTPUT_FUNC_NAME: &[u8] = b"swapTokensFixedOutput"; #[multiversx_sc::module] pub trait MultiPairSwap: - config::ConfigModule + factory::FactoryModule + token_send::TokenSendModule + config::ConfigModule + + read_pair_storage::ReadPairStorageModule + + factory::FactoryModule + + token_send::TokenSendModule { #[payable("*")] #[endpoint(multiPairSwap)] From c572908d3070ef52ec814abe40fa38937c4ee0f5 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Sat, 13 Apr 2024 01:33:25 +0300 Subject: [PATCH 024/103] energy factory tests --- .../tests/energy_factory_setup/mod.rs | 11 ++++++- .../tests/simple_lock_energy_test.rs | 32 +++++++++++++++++-- 2 files changed, 40 insertions(+), 3 deletions(-) diff --git a/locked-asset/energy-factory/tests/energy_factory_setup/mod.rs b/locked-asset/energy-factory/tests/energy_factory_setup/mod.rs index de10068c0..7d2c17b79 100644 --- a/locked-asset/energy-factory/tests/energy_factory_setup/mod.rs +++ b/locked-asset/energy-factory/tests/energy_factory_setup/mod.rs @@ -173,6 +173,7 @@ where token_nonce: u64, amount: u64, lock_epochs: u64, + opt_address: Option
, ) -> TxResult { self.b_mock.execute_esdt_transfer( caller, @@ -181,7 +182,15 @@ where token_nonce, &rust_biguint!(amount), |sc| { - sc.lock_tokens_endpoint(lock_epochs, OptionalValue::None); + if opt_address.is_some() { + let address = opt_address.unwrap(); + sc.lock_tokens_endpoint( + lock_epochs, + OptionalValue::Some(managed_address!(&address)), + ); + } else { + sc.lock_tokens_endpoint(lock_epochs, OptionalValue::None); + } }, ) } diff --git a/locked-asset/energy-factory/tests/simple_lock_energy_test.rs b/locked-asset/energy-factory/tests/simple_lock_energy_test.rs index 823a8eb56..6d23bd1ef 100644 --- a/locked-asset/energy-factory/tests/simple_lock_energy_test.rs +++ b/locked-asset/energy-factory/tests/simple_lock_energy_test.rs @@ -315,6 +315,7 @@ fn reduce_lock_period_test() { fn extend_locking_period_test() { let mut setup = SimpleLockEnergySetup::new(energy_factory::contract_obj); let first_user = setup.first_user.clone(); + let random_user = setup.b_mock.create_user_account(&rust_biguint!(0u64)); let half_balance = USER_BALANCE / 2; let current_epoch = 1; @@ -329,7 +330,7 @@ fn extend_locking_period_test() { ) .assert_ok(); - // extend to 3 years - unsupported option + // extend to a random period - unsupported option setup .extend_locking_period( &first_user, @@ -337,10 +338,11 @@ fn extend_locking_period_test() { 1, half_balance, 3 * EPOCHS_IN_YEAR, + None, ) .assert_user_error("Invalid lock choice"); - // extend to 10 years + // extend to a whitelisted period, but for a different user setup .extend_locking_period( &first_user, @@ -348,8 +350,33 @@ fn extend_locking_period_test() { 1, half_balance, LOCK_OPTIONS[1], + Some(random_user), + ) + .assert_user_error("May not use the optional destination argument here"); + + // extend to the second option - should work as intended + // 1 epoch has passed + let energy_per_epoch = rust_biguint!(500_000_000_000_000_000u64); + let energy_before = setup.get_user_energy(&first_user); // 179_500_000_000_000_000_000 + assert_eq!( + energy_before, + LOCK_OPTIONS[0] * energy_per_epoch.clone() - energy_per_epoch.clone() + ); + setup + .extend_locking_period( + &first_user, + LOCKED_TOKEN_ID, + 1, + half_balance, + LOCK_OPTIONS[1], + None, ) .assert_ok(); + let energy_after = setup.get_user_energy(&first_user); // 359_500_000_000_000_000_000 + assert_eq!( + energy_after, + LOCK_OPTIONS[1] * energy_per_epoch.clone() - energy_per_epoch.clone() + ); let new_unlock_epoch = to_start_of_month(current_epoch + LOCK_OPTIONS[1]); setup.b_mock.check_nft_balance( @@ -376,6 +403,7 @@ fn extend_locking_period_test() { 2, half_balance, LOCK_OPTIONS[0], + None, ) .assert_user_error("New lock period must be longer than the current one"); } From ef126033b1d4c7276636561c96e65fa89c19796c Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 15 Apr 2024 14:07:14 +0300 Subject: [PATCH 025/103] remove unneeded check --- dex/router/src/config.rs | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/dex/router/src/config.rs b/dex/router/src/config.rs index c4f89c440..21a433084 100644 --- a/dex/router/src/config.rs +++ b/dex/router/src/config.rs @@ -19,15 +19,7 @@ pub trait ConfigModule: read_pair_storage::ReadPairStorageModule { second_token_id: second_token_id.clone(), }; - let mut pair_map_address_opt = self.pair_map().get(&pair_tokens); - if pair_map_address_opt.is_none() { - let reverse_pair_tokens = PairTokens { - first_token_id: second_token_id.clone(), - second_token_id: first_token_id.clone(), - }; - pair_map_address_opt = self.pair_map().get(&reverse_pair_tokens); - } - + let pair_map_address_opt = self.pair_map().get(&pair_tokens); require!(pair_map_address_opt.is_some(), "Not a pair SC"); unsafe { From 6b5442e49fea971c2d372d3015b18b647b7bea99 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 16 Apr 2024 00:44:36 +0300 Subject: [PATCH 026/103] total farm position through simple lock test --- dex/farm/tests/total_farm_position_test.rs | 240 ++++++++++++++++++++- 1 file changed, 238 insertions(+), 2 deletions(-) diff --git a/dex/farm/tests/total_farm_position_test.rs b/dex/farm/tests/total_farm_position_test.rs index 47518da0c..fd6c0fa15 100644 --- a/dex/farm/tests/total_farm_position_test.rs +++ b/dex/farm/tests/total_farm_position_test.rs @@ -8,9 +8,13 @@ use farm_setup::multi_user_farm_setup::{ MultiUserFarmSetup, NonceAmountPair, BOOSTED_YIELDS_PERCENTAGE, MAX_PERCENTAGE, PER_BLOCK_REWARD_AMOUNT, }; -use multiversx_sc_scenario::{managed_address, managed_biguint, rust_biguint, DebugApi}; +use multiversx_sc::types::EsdtLocalRole; +use multiversx_sc_scenario::{ + managed_address, managed_biguint, managed_token_id, rust_biguint, DebugApi, +}; +use sc_whitelist_module::SCWhitelistModule; -use crate::farm_setup::multi_user_farm_setup::{FARM_TOKEN_ID, REWARD_TOKEN_ID}; +use crate::farm_setup::multi_user_farm_setup::{FARMING_TOKEN_ID, FARM_TOKEN_ID, REWARD_TOKEN_ID}; #[test] fn total_farm_position_claim_test() { @@ -936,3 +940,235 @@ fn total_farm_position_owner_change_test() { farm_setup.check_user_total_farm_position(&first_user, farm_token_amount); farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 5); } + +#[test] +fn total_farm_position_through_simple_lock_test() { + use multiversx_sc::storage::mappers::StorageTokenWrapper; + use simple_lock::locked_token::LockedTokenModule; + use simple_lock::proxy_farm::ProxyFarmModule; + use simple_lock::proxy_farm::*; + use simple_lock::proxy_lp::{LpProxyTokenAttributes, ProxyLpModule}; + use simple_lock::SimpleLock; + + const LOCKED_TOKEN_ID: &[u8] = b"NOOOO-123456"; + const LOCKED_LP_TOKEN_ID: &[u8] = b"LKLP-123456"; + const FARM_PROXY_TOKEN_ID: &[u8] = b"PROXY-123456"; + const WEGLD_TOKEN_ID: &[u8] = b"WEGLD-abcdef"; + const MEX_TOKEN_ID: &[u8] = b"MEX-abcdef"; // reward token ID + + DebugApi::dummy(); + let mut farm_setup = MultiUserFarmSetup::new( + farm::contract_obj, + energy_factory_mock::contract_obj, + energy_update::contract_obj, + ); + let rust_zero = rust_biguint!(0); + + // setup simple lock SC + let lock_wrapper = farm_setup.b_mock.create_sc_account( + &rust_zero, + Some(&farm_setup.owner), + simple_lock::contract_obj, + "Simple Lock Path", + ); + + let farm_addr = farm_setup.farm_wrapper.address_ref().clone(); + farm_setup + .b_mock + .execute_tx(&farm_setup.owner, &lock_wrapper, &rust_zero, |sc| { + sc.init(); + sc.locked_token() + .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); + sc.lp_proxy_token() + .set_token_id(managed_token_id!(LOCKED_LP_TOKEN_ID)); + sc.farm_proxy_token() + .set_token_id(managed_token_id!(FARM_PROXY_TOKEN_ID)); + sc.add_farm_to_whitelist( + managed_address!(&farm_addr), + managed_token_id!(FARMING_TOKEN_ID), + FarmType::SimpleFarm, + ); + }) + .assert_ok(); + + // change farming token for farm + whitelist simple lock contract + farm_setup + .b_mock + .execute_tx( + &farm_setup.owner, + &farm_setup.farm_wrapper, + &rust_zero, + |sc| { + sc.farming_token_id() + .set(&managed_token_id!(FARMING_TOKEN_ID)); + sc.add_sc_address_to_whitelist(managed_address!(lock_wrapper.address_ref())); + }, + ) + .assert_ok(); + + farm_setup.b_mock.set_esdt_local_roles( + lock_wrapper.address_ref(), + LOCKED_LP_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + farm_setup.b_mock.set_esdt_local_roles( + lock_wrapper.address_ref(), + FARM_PROXY_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + + // user lock tokens + let user_addr = farm_setup.first_user.clone(); + + let lp_proxy_token_attributes: LpProxyTokenAttributes = LpProxyTokenAttributes { + lp_token_id: managed_token_id!(FARMING_TOKEN_ID), + first_token_id: managed_token_id!(WEGLD_TOKEN_ID), + first_token_locked_nonce: 1, + second_token_id: managed_token_id!(MEX_TOKEN_ID), + second_token_locked_nonce: 2, + }; + + farm_setup.b_mock.set_nft_balance( + &user_addr, + LOCKED_LP_TOKEN_ID, + 1, + &rust_biguint!(1_000_000_000), + &lp_proxy_token_attributes, + ); + + farm_setup.b_mock.set_esdt_balance( + lock_wrapper.address_ref(), + FARMING_TOKEN_ID, + &rust_biguint!(1_000_000_000), + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + let temp_user = farm_setup.third_user.clone(); + + farm_setup.check_user_total_farm_position(&user_addr, 0); + + // first user enter farm twice (normal & through simple lock contract) + // enter farm through simple lock contract + let farm_in_amount = 50_000_000; + farm_setup.last_farm_token_nonce += 1; + farm_setup + .b_mock + .execute_esdt_transfer( + &user_addr, + &lock_wrapper, + LOCKED_LP_TOKEN_ID, + 1, + &rust_biguint!(farm_in_amount), + |sc| { + let enter_farm_result = sc.enter_farm_locked_token(FarmType::SimpleFarm); + let (out_farm_token, _reward_token) = enter_farm_result.into_tuple(); + assert_eq!( + out_farm_token.token_identifier, + managed_token_id!(FARM_PROXY_TOKEN_ID) + ); + assert_eq!(out_farm_token.token_nonce, farm_setup.last_farm_token_nonce); + assert_eq!(out_farm_token.amount, managed_biguint!(farm_in_amount)); + }, + ) + .assert_ok(); + + farm_setup.b_mock.check_nft_balance( + &user_addr, + FARM_PROXY_TOKEN_ID, + 1, + &rust_biguint!(farm_in_amount), + Some(&FarmProxyTokenAttributes:: { + farm_type: FarmType::SimpleFarm, + farm_token_id: managed_token_id!(FARM_TOKEN_ID), + farm_token_nonce: 1, + farming_token_id: managed_token_id!(FARMING_TOKEN_ID), + farming_token_locked_nonce: 1, + }), + ); + + farm_setup.check_user_total_farm_position(&user_addr, farm_in_amount); + + // enter farm directly + farm_setup.set_user_energy(&user_addr, 1_000, 2, 1); + farm_setup.enter_farm(&user_addr, farm_in_amount); + + farm_setup.b_mock.check_nft_balance( + &user_addr, + FARM_TOKEN_ID, + farm_setup.last_farm_token_nonce, + &rust_biguint!(farm_in_amount), + Some(&FarmTokenAttributes:: { + reward_per_share: managed_biguint!(0), + compounded_reward: managed_biguint!(0), + entering_epoch: 2, + current_farm_amount: managed_biguint!(farm_in_amount), + original_owner: managed_address!(&user_addr), + }), + ); + + farm_setup.check_user_total_farm_position(&user_addr, farm_in_amount * 2); + farm_setup.check_farm_token_supply(farm_in_amount * 2); + + // users claim rewards to get their energy registered + let _ = farm_setup.claim_rewards(&user_addr, 2, farm_in_amount); + + // advance blocks - 10 blocks - 10 * 1_000 = 10_000 total rewards + // 7_500 base farm, 2_500 boosted yields + farm_setup.b_mock.set_block_nonce(10); + + // random tx on end of week 1, to cummulate rewards + farm_setup.b_mock.set_block_epoch(6); + farm_setup.set_user_energy(&user_addr, 1_000, 6, 1); + farm_setup.set_user_energy(&temp_user, 1, 6, 1); + farm_setup.enter_farm(&temp_user, 1); + farm_setup.exit_farm(&temp_user, 4, 1); + + // advance 1 week + farm_setup.b_mock.set_block_epoch(10); + farm_setup.set_user_energy(&user_addr, 1_000, 10, 1); + + let total_farm_tokens = farm_in_amount * 2; + + // first user claim with half total position + let first_base_farm_amt = farm_in_amount * 7_500 / total_farm_tokens; + + // Boosted yields rewards formula + // total_boosted_rewards * (energy_const * user_energy / total_energy + farm_const * user_farm / total_farm) / (energy_const + farm_const) + // (total_boosted_rewards * energy_const * user_energy / total_energy + total_boosted_rewards * farm_const * user_farm / total_farm) / (energy_const + farm_const) + // (2_500 * 3 * 1_000 / 1_000 + 2_500 * 2 * 100_000_000 / 100_000_000) / (3 + 2) + // (7_500 + 2_500) / (5) = 2_500 + let first_boosted_amt = 2_500; // 1000 energy & 100_000_000 farm tokens + let first_total_rewards = first_base_farm_amt + first_boosted_amt; + + let first_received_reward_amt = farm_setup.claim_rewards(&user_addr, 3, farm_in_amount); + + // Should be equal to half base generated rewards + full boosted generated rewards + assert_eq!(first_received_reward_amt, first_total_rewards); + + farm_setup + .b_mock + .check_nft_balance::>( + &user_addr, + FARM_TOKEN_ID, + 5, + &rust_biguint!(farm_in_amount), + None, + ); + + farm_setup.b_mock.check_esdt_balance( + &user_addr, + REWARD_TOKEN_ID, + &rust_biguint!(first_received_reward_amt), + ); +} From f9b5a0d19787e4eb636ca5e86e9578613b100554 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 16 Apr 2024 02:00:19 +0300 Subject: [PATCH 027/103] farm updated tests --- dex/farm/tests/total_farm_position_test.rs | 123 ++++++++++++--------- 1 file changed, 72 insertions(+), 51 deletions(-) diff --git a/dex/farm/tests/total_farm_position_test.rs b/dex/farm/tests/total_farm_position_test.rs index fd6c0fa15..b7ca1be7b 100644 --- a/dex/farm/tests/total_farm_position_test.rs +++ b/dex/farm/tests/total_farm_position_test.rs @@ -529,15 +529,20 @@ fn farm_total_position_on_claim_migration_test() { farm_setup.check_farm_token_supply(farm_in_amount * 2); // claim rewards with both positions - let total_farm_tokens = farm_in_amount * 2; + let first_payment_amount = farm_in_amount / 2; + let second_payment_amount = farm_in_amount / 4 * 3; + let total_farm_amount = farm_in_amount * 2; + let total_farm_position = farm_in_amount + first_payment_amount; // only the first is migrated by being an old position + let total_claim_payment = first_payment_amount + second_payment_amount; + let payments = vec![ NonceAmountPair { nonce: 1, - amount: farm_in_amount, + amount: first_payment_amount, }, NonceAmountPair { nonce: 2, - amount: farm_in_amount, + amount: second_payment_amount, }, ]; @@ -546,7 +551,7 @@ fn farm_total_position_on_claim_migration_test() { farm_setup.check_user_total_farm_position(&first_user, farm_in_amount); let _ = farm_setup.claim_rewards_with_multiple_payments(&first_user, payments); - farm_setup.check_user_total_farm_position(&first_user, total_farm_tokens); + farm_setup.check_user_total_farm_position(&first_user, total_farm_position); farm_setup .b_mock @@ -554,7 +559,7 @@ fn farm_total_position_on_claim_migration_test() { &first_user, FARM_TOKEN_ID, 3, - &rust_biguint!(total_farm_tokens), + &rust_biguint!(total_claim_payment), None, ); @@ -562,8 +567,8 @@ fn farm_total_position_on_claim_migration_test() { let expected_user_rewards = block_nonce * PER_BLOCK_REWARD_AMOUNT * (MAX_PERCENTAGE - BOOSTED_YIELDS_PERCENTAGE) - * farm_in_amount - / total_farm_tokens + * first_payment_amount + / total_farm_amount / MAX_PERCENTAGE; farm_setup.b_mock.check_esdt_balance( &first_user, @@ -617,31 +622,38 @@ fn farm_total_position_on_merge_migration_test() { farm_setup.check_farm_token_supply(total_farm_tokens); // merge all 4 farm positions + let first_payment_amount = farm_in_amount / 2; + let second_payment_amount = farm_in_amount / 4 * 3; + let third_payment_amount = farm_in_amount / 2; + let forth_payment_amount = farm_in_amount / 4; + let total_payment_amount = + first_payment_amount + second_payment_amount + third_payment_amount + forth_payment_amount; + let total_user_position = farm_in_amount * 2 + first_payment_amount + second_payment_amount; let payments = vec![ NonceAmountPair { nonce: 1, - amount: farm_in_amount, + amount: first_payment_amount, }, NonceAmountPair { nonce: 2, - amount: farm_in_amount, + amount: second_payment_amount, }, NonceAmountPair { nonce: 3, - amount: farm_in_amount, + amount: third_payment_amount, }, NonceAmountPair { nonce: 4, - amount: farm_in_amount, + amount: forth_payment_amount, }, ]; let block_nonce = 10; farm_setup.b_mock.set_block_nonce(block_nonce); - farm_setup.check_user_total_farm_position(&first_user, farm_in_amount * 2); + farm_setup.check_user_total_farm_position(&first_user, farm_in_amount * 2); // last 2 positions farm_setup.merge_farm_tokens(&first_user, payments); - farm_setup.check_user_total_farm_position(&first_user, total_farm_tokens); + farm_setup.check_user_total_farm_position(&first_user, total_user_position); farm_setup .b_mock @@ -649,7 +661,7 @@ fn farm_total_position_on_merge_migration_test() { &first_user, FARM_TOKEN_ID, 5, - &rust_biguint!(total_farm_tokens), + &rust_biguint!(total_payment_amount), None, ); @@ -754,6 +766,7 @@ fn total_farm_position_owner_change_test() { // first user enters farm 6 times let farm_token_amount = 10_000_000; + let half_token_amount = farm_token_amount / 2; let first_user = farm_setup.first_user.clone(); let second_user = farm_setup.second_user.clone(); let third_user = farm_setup.third_user.clone(); @@ -766,8 +779,10 @@ fn total_farm_position_owner_change_test() { farm_setup.enter_farm(&first_user, farm_token_amount); farm_setup.enter_farm(&first_user, farm_token_amount); - farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 6); - farm_setup.check_user_total_farm_position(&second_user, 0); + let mut first_user_total_position = farm_token_amount * 6; + let mut second_user_total_position = 0; + farm_setup.check_user_total_farm_position(&first_user, first_user_total_position); + farm_setup.check_user_total_farm_position(&second_user, second_user_total_position); assert_eq!(farm_setup.last_farm_token_nonce, 6); @@ -779,21 +794,23 @@ fn total_farm_position_owner_change_test() { farm_setup.send_farm_position(&first_user, &second_user, 5, farm_token_amount, 0, 2); // Total farm position unchanged as users only transfered the farm positions - farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 6); - farm_setup.check_user_total_farm_position(&second_user, 0); + farm_setup.check_user_total_farm_position(&first_user, first_user_total_position); + farm_setup.check_user_total_farm_position(&second_user, second_user_total_position); - // second user enter farm + // second user enter farm with LP token + 50% the position from another user farm_setup.set_user_energy(&second_user, 4_000, 2, 1); farm_setup.enter_farm_with_additional_payment( &second_user, farm_token_amount, 1, - farm_token_amount, + half_token_amount, ); - // 1 farm position was removed from first user and added to the second user (who entered the farm with a position of his own) - farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 5); - farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 2); + // 1 half farm position was removed from first user and added to the second user (who entered the farm with a position of his own) + first_user_total_position -= half_token_amount; + second_user_total_position += farm_token_amount + half_token_amount; + farm_setup.check_user_total_farm_position(&first_user, first_user_total_position); + farm_setup.check_user_total_farm_position(&second_user, second_user_total_position); // users claim rewards to get their energy registered let _ = farm_setup.claim_rewards(&first_user, 6, farm_token_amount); @@ -813,12 +830,12 @@ fn total_farm_position_owner_change_test() { farm_setup.set_user_energy(&first_user, 1_000, 10, 1); farm_setup.set_user_energy(&second_user, 4_000, 10, 1); - // Second user claims with a position from the first user - let base_rewards_amount = 1071; - let boosted_rewards_amount = 1485; + // Second user claims with half a position from the first user + let base_rewards_amount = 535; + let boosted_rewards_amount = 1414; let mut second_user_reward_balance = base_rewards_amount + boosted_rewards_amount; - let second_received_reward_amt = farm_setup.claim_rewards(&second_user, 2, farm_token_amount); + let second_received_reward_amt = farm_setup.claim_rewards(&second_user, 2, half_token_amount); assert_eq!(second_received_reward_amt, second_user_reward_balance); farm_setup.b_mock.check_esdt_balance( @@ -826,24 +843,25 @@ fn total_farm_position_owner_change_test() { REWARD_TOKEN_ID, &rust_biguint!(second_user_reward_balance), ); - farm_setup.b_mock.check_nft_balance( &second_user, FARM_TOKEN_ID, 11, - &rust_biguint!(farm_token_amount), + &rust_biguint!(half_token_amount), Some(&FarmTokenAttributes:: { reward_per_share: managed_biguint!(107142857), entering_epoch: 2, compounded_reward: managed_biguint!(0), - current_farm_amount: managed_biguint!(farm_token_amount), + current_farm_amount: managed_biguint!(half_token_amount), original_owner: managed_address!(&second_user), }), ); // Check users positions after claim - farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 4); - farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 3); + first_user_total_position -= half_token_amount; + second_user_total_position += half_token_amount; + farm_setup.check_user_total_farm_position(&first_user, first_user_total_position); + farm_setup.check_user_total_farm_position(&second_user, second_user_total_position); // random tx on end of week 2, to cummulate rewards farm_setup.b_mock.set_block_nonce(20); @@ -859,17 +877,18 @@ fn total_farm_position_owner_change_test() { farm_setup.set_user_energy(&first_user, 1_000, 15, 1); farm_setup.set_user_energy(&second_user, 4_000, 15, 1); - // Second user exits farm with a position previously owned by user 1 - second_user_reward_balance += 2142; // base rewards - second_user_reward_balance += 1630; // boosted rewards - farm_setup.exit_farm(&second_user, 3, farm_token_amount); + // Second user exits farm with half of a position previously owned by user 1 + second_user_reward_balance += 1071; // base rewards + second_user_reward_balance += 1487; // boosted rewards + farm_setup.exit_farm(&second_user, 3, half_token_amount); farm_setup .b_mock - .check_esdt_balance(&second_user, REWARD_TOKEN_ID, &rust_biguint!(6328)); + .check_esdt_balance(&second_user, REWARD_TOKEN_ID, &rust_biguint!(4507)); // Check users positions after exit - farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 3); - farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 3); + first_user_total_position -= half_token_amount; + farm_setup.check_user_total_farm_position(&first_user, first_user_total_position); + farm_setup.check_user_total_farm_position(&second_user, second_user_total_position); // random tx on end of week 3, to cummulate rewards farm_setup.b_mock.set_block_nonce(30); @@ -888,25 +907,25 @@ fn total_farm_position_owner_change_test() { // First user claims rewards let first_user_received_reward_amt = farm_setup.claim_rewards(&first_user, 8, farm_token_amount); - assert_eq!(first_user_received_reward_amt, 5642); + assert_eq!(first_user_received_reward_amt, 6167); // Check users positions after first user claim - farm_setup.check_user_total_farm_position(&first_user, farm_token_amount * 3); - farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 3); + farm_setup.check_user_total_farm_position(&first_user, first_user_total_position); + farm_setup.check_user_total_farm_position(&second_user, second_user_total_position); - // Second user merges his tokens with first user initial token + // Second user merges half from one of his original position with 2 position halves from the first user let farm_tokens = vec![ NonceAmountPair { nonce: 4, - amount: farm_token_amount, + amount: half_token_amount, }, NonceAmountPair { nonce: 5, - amount: farm_token_amount, + amount: half_token_amount, }, NonceAmountPair { nonce: 11, - amount: farm_token_amount, + amount: half_token_amount, }, ]; @@ -916,7 +935,7 @@ fn total_farm_position_owner_change_test() { &rust_biguint!(second_user_reward_balance), ); farm_setup.merge_farm_tokens(&second_user, farm_tokens); - second_user_reward_balance += 1703; // boosted rewards + second_user_reward_balance += 1510; // boosted rewards farm_setup.b_mock.check_esdt_balance( &second_user, REWARD_TOKEN_ID, @@ -926,19 +945,21 @@ fn total_farm_position_owner_change_test() { &second_user, FARM_TOKEN_ID, 15, - &rust_biguint!(farm_token_amount * 3), + &rust_biguint!(half_token_amount * 3), Some(&FarmTokenAttributes:: { reward_per_share: managed_biguint!(35714286), entering_epoch: 2, compounded_reward: managed_biguint!(0), - current_farm_amount: managed_biguint!(farm_token_amount * 3), + current_farm_amount: managed_biguint!(half_token_amount * 3), original_owner: managed_address!(&second_user), }), ); // Check users positions after merge - farm_setup.check_user_total_farm_position(&first_user, farm_token_amount); - farm_setup.check_user_total_farm_position(&second_user, farm_token_amount * 5); + first_user_total_position -= 2 * half_token_amount; + second_user_total_position += 2 * half_token_amount; + farm_setup.check_user_total_farm_position(&first_user, first_user_total_position); + farm_setup.check_user_total_farm_position(&second_user, second_user_total_position); } #[test] From ec4b55003a00f36d21522d7cdab0df24b2c6e39e Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 16 Apr 2024 12:25:59 +0300 Subject: [PATCH 028/103] add back the router reverse check pair logic --- dex/router/src/config.rs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/dex/router/src/config.rs b/dex/router/src/config.rs index 21a433084..c4f89c440 100644 --- a/dex/router/src/config.rs +++ b/dex/router/src/config.rs @@ -19,7 +19,15 @@ pub trait ConfigModule: read_pair_storage::ReadPairStorageModule { second_token_id: second_token_id.clone(), }; - let pair_map_address_opt = self.pair_map().get(&pair_tokens); + let mut pair_map_address_opt = self.pair_map().get(&pair_tokens); + if pair_map_address_opt.is_none() { + let reverse_pair_tokens = PairTokens { + first_token_id: second_token_id.clone(), + second_token_id: first_token_id.clone(), + }; + pair_map_address_opt = self.pair_map().get(&reverse_pair_tokens); + } + require!(pair_map_address_opt.is_some(), "Not a pair SC"); unsafe { From 954d65ce9e9bd888197392085a0db7fa5b2190d0 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 16 Apr 2024 13:45:56 +0300 Subject: [PATCH 029/103] code cleanup --- dex/router/src/config.rs | 9 --------- dex/router/wasm/src/lib.rs | 6 ++---- 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/dex/router/src/config.rs b/dex/router/src/config.rs index c4f89c440..830d301c8 100644 --- a/dex/router/src/config.rs +++ b/dex/router/src/config.rs @@ -83,13 +83,4 @@ pub trait ConfigModule: read_pair_storage::ReadPairStorageModule { #[view(getCommonTokensForUserPairs)] #[storage_mapper("commonTokensForUserPairs")] fn common_tokens_for_user_pairs(&self) -> UnorderedSetMapper; - - // read from other storage - #[view(getFirstTokenId)] - #[storage_mapper("first_token_id")] - fn first_token_id(&self) -> SingleValueMapper; - - #[view(getSecondTokenId)] - #[storage_mapper("second_token_id")] - fn second_token_id(&self) -> SingleValueMapper; } diff --git a/dex/router/wasm/src/lib.rs b/dex/router/wasm/src/lib.rs index ee22e6ba5..ee424764b 100644 --- a/dex/router/wasm/src/lib.rs +++ b/dex/router/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 32 +// Endpoints: 30 // Async Callback: 1 -// Total number of exported functions: 34 +// Total number of exported functions: 32 #![no_std] #![allow(internal_features)] @@ -39,8 +39,6 @@ multiversx_sc_wasm_adapter::endpoints! { getPairTemplateAddress => pair_template_address getTemporaryOwnerPeriod => temporary_owner_period getCommonTokensForUserPairs => common_tokens_for_user_pairs - getFirstTokenId => first_token_id - getSecondTokenId => second_token_id getAllPairsManagedAddresses => get_all_pairs_addresses getAllPairTokens => get_all_token_pairs getAllPairContractMetadata => get_all_pair_contract_metadata From 6c2a6083e797eca93ca711e7c1828247a91aa8cf Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 16 Apr 2024 23:04:29 +0300 Subject: [PATCH 030/103] farm staking proxy unit tests --- .../tests/staking_farm_with_lp.rs | 380 +++++++++++++++++- .../mod.rs | 189 ++++++++- .../mod.rs | 17 + 3 files changed, 583 insertions(+), 3 deletions(-) diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs index d7ee78e8d..03d7ce263 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs @@ -7,13 +7,21 @@ pub mod staking_farm_with_lp_staking_contract_setup; multiversx_sc::imports!(); +use config::ConfigModule; use constants::*; use farm_staking_proxy::dual_yield_token::DualYieldTokenAttributes; use farm_staking_proxy::proxy_actions::unstake::ProxyUnstakeModule; +use farm_staking::{ + claim_only_boosted_staking_rewards::ClaimOnlyBoostedStakingRewardsModule, FarmStaking, +}; +use farm_with_locked_rewards::Farm; use multiversx_sc::codec::Empty; -use multiversx_sc_scenario::{managed_biguint, managed_token_id, rust_biguint, DebugApi}; +use multiversx_sc_scenario::{ + managed_address, managed_biguint, managed_token_id, rust_biguint, DebugApi, +}; +use simple_lock::locked_token::LockedTokenAttributes; use staking_farm_with_lp_staking_contract_interactions::*; #[test] @@ -625,3 +633,373 @@ fn test_farm_stake_proxy_merging_boosted_rewards() { ) }); } + +#[test] +fn original_caller_negative_test() { + let mut setup = FarmStakingSetup::new( + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + farm_staking::contract_obj, + farm_staking_proxy::contract_obj, + ); + + let user = setup.user_addr.clone(); + let random_user = setup.b_mock.create_user_account(&rust_biguint!(0u64)); + setup + .stake_farm_for_other_user(&user, &random_user, 1, USER_TOTAL_LP_TOKENS) + .assert_error(4, "Item not whitelisted"); + + setup + .stake_farm_for_other_user(&user, &user, 1, USER_TOTAL_LP_TOKENS) + .assert_ok(); + + setup + .b_mock + .set_block_nonce(BLOCK_NONCE_AFTER_PAIR_SETUP + 20); + setup.b_mock.set_block_epoch(20); + + setup + .claim_dual_yield_for_other_user(&user, &random_user, 1, USER_TOTAL_LP_TOKENS) + .assert_error(4, "Item not whitelisted"); + + setup + .claim_dual_yield_for_other_user(&user, &user, 1, USER_TOTAL_LP_TOKENS) + .assert_ok(); + + setup + .unstake_dual_yield_for_other_user(&user, &random_user, 2, USER_TOTAL_LP_TOKENS) + .assert_error(4, "Item not whitelisted"); + + setup + .unstake_dual_yield_for_other_user(&user, &user, 2, USER_TOTAL_LP_TOKENS) + .assert_ok(); +} + +#[test] +fn claim_for_others_positive_test() { + let mut setup = FarmStakingSetup::new( + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + farm_staking::contract_obj, + farm_staking_proxy::contract_obj, + ); + + // Boosted rewards setup + setup + .b_mock + .execute_tx( + &setup.owner_addr, + &setup.staking_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + }, + ) + .assert_ok(); + + setup.set_lp_farm_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + let farm_amount = 50_000_000u64; + let user_address = setup.user_addr.clone(); + let temp_user = setup + .b_mock + .create_user_account(&rust_biguint!(100_000_000)); + setup.exit_lp_farm(&user_address, 1, USER_TOTAL_LP_TOKENS); + setup.b_mock.set_esdt_balance( + &setup.user_addr, + LP_TOKEN_ID, + &rust_biguint!(farm_amount * 2), + ); + setup + .b_mock + .set_esdt_balance(&temp_user, LP_TOKEN_ID, &rust_biguint!(1)); + + setup.b_mock.set_block_epoch(2); + + setup.set_user_energy(&user_address, 1_000, 2, 1); + let farm_token_nonce = setup.enter_lp_farm(&user_address, farm_amount); + + // User enters Metastaking + let first_dual_yield_token_nonce = + setup.stake_farm_lp_proxy(farm_token_nonce, farm_amount, 1, farm_amount); + setup.b_mock.execute_in_managed_environment(|| { + setup.b_mock.check_nft_balance( + &setup.user_addr, + DUAL_YIELD_TOKEN_ID, + first_dual_yield_token_nonce, + &rust_biguint!(farm_amount), + Some(&DualYieldTokenAttributes:: { + lp_farm_token_nonce: farm_token_nonce, + lp_farm_token_amount: managed_biguint!(farm_amount), + staking_farm_token_nonce: 1, + staking_farm_token_amount: managed_biguint!(farm_amount), + }), + ) + }); + // User claims rewards to get his energy registered + setup + .claim_dual_yield_for_other_user(&user_address, &user_address, 1, farm_amount) + .assert_ok(); + + // advance blocks - 10 blocks - 10 * 5_000 = 50_000 total rewards + // 37_500 base farm, 12_500 boosted yields + let boosted_rewards = 12_500u64; + setup.b_mock.set_block_nonce(110); + + // farm staking boosted rewards + let farm_staking_boosted_rewards = 10u64; + + // random tx on end of week 1, to cummulate rewards + setup.b_mock.set_block_epoch(6); + setup.set_user_energy(&user_address, 1_000, 6, 1); + setup.set_user_energy(&temp_user, 1, 6, 1); + let temp_user_farm_token_nonce = setup.enter_lp_farm(&temp_user, 1); + setup.exit_lp_farm(&temp_user, temp_user_farm_token_nonce, 1); + + setup.stake_farm(9000000, 9000000); + setup.staking_farm_unstake(3, 9000000, 0, 9000000); + + // advance 1 week + setup.b_mock.set_block_epoch(10); + setup.set_user_energy(&user_address, 1_000, 10, 1); + + // User allows claiming of boosted rewards by other users + setup + .b_mock + .execute_tx( + &user_address, + &setup.lp_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.allow_external_claim_boosted_rewards(true); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_tx( + &user_address, + &setup.staking_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.allow_external_claim_boosted_rewards(true); + }, + ) + .assert_ok(); + + // Random user claims boosted rewards for the user + let user_initial_farm_staking_tokens_balance = 990000000; + setup + .b_mock + .check_esdt_balance(&temp_user, RIDE_TOKEN_ID, &rust_biguint!(0)); + setup.b_mock.check_esdt_balance( + &user_address, + RIDE_TOKEN_ID, + &rust_biguint!(user_initial_farm_staking_tokens_balance), + ); + setup + .b_mock + .check_nft_balance::>( + &temp_user, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(0), + None, + ); + setup + .b_mock + .check_nft_balance::>( + &user_address, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(0), + None, + ); + + setup + .b_mock + .execute_tx( + &temp_user, + &setup.lp_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.claim_boosted_rewards(OptionalValue::Some(managed_address!(&user_address))); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_tx( + &temp_user, + &setup.staking_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.claim_boosted_rewards(OptionalValue::Some(managed_address!(&user_address))); + }, + ) + .assert_ok(); + + setup + .b_mock + .check_esdt_balance(&temp_user, RIDE_TOKEN_ID, &rust_biguint!(0)); + setup.b_mock.check_esdt_balance( + &user_address, + RIDE_TOKEN_ID, + &rust_biguint!(user_initial_farm_staking_tokens_balance + farm_staking_boosted_rewards), + ); + setup + .b_mock + .check_nft_balance::>( + &temp_user, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(0), + None, + ); + setup + .b_mock + .check_nft_balance::>( + &user_address, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(boosted_rewards), + None, + ); +} + +#[test] +fn stake_farm_through_proxy_migration_test() { + let mut setup = FarmStakingSetup::new( + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + farm_staking::contract_obj, + farm_staking_proxy::contract_obj, + ); + + let user = setup.user_addr.clone(); + let mut user_total_staking_farm_position = 0; + let mut user_total_lp_farm_position = 0; + let farm_amount = 100_000_000; + + setup.check_user_total_staking_farm_position(&user, user_total_staking_farm_position); + setup.check_user_total_lp_farm_position(&user, user_total_lp_farm_position); + let dual_yield_token_nonce1 = setup.stake_farm_lp_proxy(1, farm_amount, 1, farm_amount); + let dual_yield_token_nonce2 = setup.stake_farm_lp_proxy(1, farm_amount, 2, farm_amount); + let dual_yield_token_nonce3 = setup.stake_farm_lp_proxy(1, farm_amount, 3, farm_amount); + + setup.b_mock.execute_in_managed_environment(|| { + setup.b_mock.check_nft_balance( + &user, + DUAL_YIELD_TOKEN_ID, + dual_yield_token_nonce1, + &rust_biguint!(farm_amount), + Some(&DualYieldTokenAttributes:: { + lp_farm_token_nonce: 1, + lp_farm_token_amount: managed_biguint!(farm_amount), + staking_farm_token_nonce: 1, + staking_farm_token_amount: managed_biguint!(farm_amount), + }), + ) + }); + + user_total_staking_farm_position += farm_amount * 3; + user_total_lp_farm_position += 1001000000; + setup.check_user_total_staking_farm_position(&user, user_total_staking_farm_position); + setup.check_user_total_lp_farm_position(&user, user_total_lp_farm_position); + + // Simulate the current position as old positions + setup.set_user_total_staking_farm_position(&user, 0); + setup.set_user_total_lp_farm_position(&user, 0); + setup.set_staking_farm_migration_nonce(4); + setup.set_lp_farm_migration_nonce(2); + + user_total_staking_farm_position = 0; + user_total_lp_farm_position = 0; + setup.check_user_total_staking_farm_position(&user, user_total_staking_farm_position); + setup.check_user_total_lp_farm_position(&user, user_total_lp_farm_position); + + let dual_yield_token_payments = vec![NonceAmountPair { + nonce: dual_yield_token_nonce1, + amount: farm_amount, + }]; + + // User enters with new farming tokens + 1 old position + let enter_dual_yield_token_nonce = + setup.stake_farm_lp_proxy_multiple(1, farm_amount, dual_yield_token_payments); + + // check user staking farm tokens + setup.b_mock.execute_in_managed_environment(|| { + setup.b_mock.check_nft_balance( + &user, + DUAL_YIELD_TOKEN_ID, + enter_dual_yield_token_nonce, + &rust_biguint!(farm_amount * 2), + Some(&DualYieldTokenAttributes:: { + lp_farm_token_nonce: 2, + lp_farm_token_amount: managed_biguint!(farm_amount * 2), + staking_farm_token_nonce: 4, + staking_farm_token_amount: managed_biguint!(farm_amount * 2), + }), + ) + }); + + // check proxy SC tokens + setup.b_mock.execute_in_managed_environment(|| { + setup.b_mock.check_nft_balance::( + setup.proxy_wrapper.address_ref(), + LP_FARM_TOKEN_ID, + 2, + &rust_biguint!(farm_amount * 2), + None, //current attributes + ) + }); + + user_total_staking_farm_position += farm_amount * 2; + user_total_lp_farm_position += farm_amount * 2; + setup.check_user_total_staking_farm_position(&user, user_total_staking_farm_position); + setup.check_user_total_lp_farm_position(&user, user_total_lp_farm_position); + + // User claim with 1 old position + let claim_dual_yield_token_nonce = + setup.claim_rewards_proxy(dual_yield_token_nonce2, farm_amount, 0, 0, farm_amount); + + // check user staking farm tokens + setup.b_mock.execute_in_managed_environment(|| { + setup.b_mock.check_nft_balance( + &user, + DUAL_YIELD_TOKEN_ID, + claim_dual_yield_token_nonce, + &rust_biguint!(farm_amount), + Some(&DualYieldTokenAttributes:: { + lp_farm_token_nonce: 3, + lp_farm_token_amount: managed_biguint!(farm_amount), + staking_farm_token_nonce: 5, + staking_farm_token_amount: managed_biguint!(farm_amount), + }), + ) + }); + + user_total_staking_farm_position += farm_amount; + user_total_lp_farm_position += farm_amount; + setup.check_user_total_staking_farm_position(&user, user_total_staking_farm_position); + setup.check_user_total_lp_farm_position(&user, user_total_lp_farm_position); + + // User exits with 1 half old position + setup.unstake_proxy( + dual_yield_token_nonce3, + farm_amount / 2, + 49950000, + 0, + 0, + 49950000, + 10, + ); + + // Total positions should remain the same + setup.check_user_total_staking_farm_position(&user, user_total_staking_farm_position); + setup.check_user_total_lp_farm_position(&user, user_total_lp_farm_position); +} diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs index dca88dce5..703bfe2f7 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs @@ -1,5 +1,6 @@ #![allow(deprecated)] +use config::{ConfigModule, UserTotalFarmPosition}; use energy_factory::energy::EnergyModule; use energy_query::Energy; use farm_with_locked_rewards::Farm; @@ -9,6 +10,7 @@ use multiversx_sc::{ }; use multiversx_sc_scenario::{ managed_address, managed_biguint, managed_token_id, rust_biguint, + testing_framework::TxResult, whitebox_legacy::TxTokenTransfer, whitebox_legacy::{BlockchainStateWrapper, ContractObjWrapper}, DebugApi, @@ -111,8 +113,12 @@ where lp_farm_builder, USER_TOTAL_LP_TOKENS, ); - let staking_farm_wrapper = - setup_staking_farm(&owner_addr, &mut b_mock, staking_farm_builder); + let staking_farm_wrapper = setup_staking_farm( + &owner_addr, + energy_factory_wrapper.address_ref(), + &mut b_mock, + staking_farm_builder, + ); let proxy_wrapper = setup_proxy( &owner_addr, lp_farm_wrapper.address_ref(), @@ -518,6 +524,85 @@ where new_farm_token_nonce } + pub fn stake_farm_for_other_user( + &mut self, + caller: &Address, + original_caller: &Address, + lp_farm_token_nonce: u64, + lp_farm_token_stake_amount: u64, + ) -> TxResult { + self.b_mock.execute_esdt_transfer( + &caller, + &self.proxy_wrapper, + LP_FARM_TOKEN_ID, + lp_farm_token_nonce, + &rust_biguint!(lp_farm_token_stake_amount), + |sc| { + if caller == original_caller { + sc.stake_farm_tokens(OptionalValue::None); + } else { + sc.stake_farm_tokens(OptionalValue::Some(managed_address!(original_caller))); + } + }, + ) + } + + pub fn claim_dual_yield_for_other_user( + &mut self, + caller: &Address, + original_caller: &Address, + dual_yield_token_nonce: u64, + dual_yield_token_amount: u64, + ) -> TxResult { + self.b_mock.execute_esdt_transfer( + &caller, + &self.proxy_wrapper, + DUAL_YIELD_TOKEN_ID, + dual_yield_token_nonce, + &rust_biguint!(dual_yield_token_amount), + |sc| { + if caller == original_caller { + sc.claim_dual_yield_endpoint(OptionalValue::None); + } else { + sc.claim_dual_yield_endpoint(OptionalValue::Some(managed_address!( + original_caller + ))); + } + }, + ) + } + + pub fn unstake_dual_yield_for_other_user( + &mut self, + caller: &Address, + original_caller: &Address, + dual_yield_token_nonce: u64, + dual_yield_token_amount: u64, + ) -> TxResult { + self.b_mock.execute_esdt_transfer( + &caller, + &self.proxy_wrapper, + DUAL_YIELD_TOKEN_ID, + dual_yield_token_nonce, + &rust_biguint!(dual_yield_token_amount), + |sc| { + if caller == original_caller { + sc.unstake_farm_tokens( + managed_biguint!(1u64), + managed_biguint!(1u64), + OptionalValue::None, + ); + } else { + sc.unstake_farm_tokens( + managed_biguint!(1u64), + managed_biguint!(1u64), + OptionalValue::Some(managed_address!(original_caller)), + ); + } + }, + ) + } + pub fn set_user_energy( &mut self, user: &Address, @@ -556,4 +641,104 @@ where ) .assert_ok(); } + + pub fn set_staking_farm_migration_nonce(&mut self, migration_nonce: u64) { + self.b_mock + .execute_tx( + &self.owner_addr, + &self.staking_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.farm_position_migration_nonce().set(migration_nonce); + }, + ) + .assert_ok(); + } + + pub fn set_lp_farm_migration_nonce(&mut self, migration_nonce: u64) { + self.b_mock + .execute_tx( + &self.owner_addr, + &self.lp_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.farm_position_migration_nonce().set(migration_nonce); + }, + ) + .assert_ok(); + } + + pub fn set_user_total_staking_farm_position( + &mut self, + user_addr: &Address, + new_farm_position: u64, + ) { + self.b_mock + .execute_tx( + &self.owner_addr, + &self.staking_farm_wrapper, + &rust_biguint!(0), + |sc| { + let user_farm_position = UserTotalFarmPosition { + total_farm_position: managed_biguint!(new_farm_position), + ..Default::default() + }; + sc.user_total_farm_position(&managed_address!(user_addr)) + .set(user_farm_position); + }, + ) + .assert_ok(); + } + + pub fn set_user_total_lp_farm_position(&mut self, user_addr: &Address, new_farm_position: u64) { + self.b_mock + .execute_tx( + &self.owner_addr, + &self.lp_farm_wrapper, + &rust_biguint!(0), + |sc| { + let user_farm_position = UserTotalFarmPosition { + total_farm_position: managed_biguint!(new_farm_position), + ..Default::default() + }; + sc.user_total_farm_position(&managed_address!(user_addr)) + .set(user_farm_position); + }, + ) + .assert_ok(); + } + + pub fn check_user_total_staking_farm_position( + &mut self, + user_addr: &Address, + expected_amount: u64, + ) { + self.b_mock + .execute_query(&self.staking_farm_wrapper, |sc| { + let user_total_farm_position_mapper = + sc.user_total_farm_position(&managed_address!(user_addr)); + if expected_amount > 0 && !user_total_farm_position_mapper.is_empty() { + assert_eq!( + managed_biguint!(expected_amount), + user_total_farm_position_mapper.get().total_farm_position + ); + } + }) + .assert_ok(); + } + + pub fn check_user_total_lp_farm_position(&mut self, user_addr: &Address, expected_amount: u64) { + self.b_mock + .execute_query(&self.lp_farm_wrapper, |sc| { + let user_total_farm_position_mapper = + sc.user_total_farm_position(&managed_address!(user_addr)); + if expected_amount > 0 && !user_total_farm_position_mapper.is_empty() { + assert_eq!( + managed_biguint!(expected_amount), + user_total_farm_position_mapper.get().total_farm_position + ); + } + }) + .assert_ok(); + } } diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs index 2c67d2714..81bb78dbd 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs @@ -1,5 +1,7 @@ #![allow(deprecated)] +use energy_query::EnergyQueryModule; +use farm_boosted_yields::boosted_yields_factors::BoostedYieldsFactorsModule; use multiversx_sc::storage::mappers::StorageTokenWrapper; use multiversx_sc::types::{Address, EsdtLocalRole, ManagedAddress, MultiValueEncoded}; use multiversx_sc_scenario::{ @@ -24,6 +26,7 @@ use crate::constants::*; pub fn setup_staking_farm( owner_addr: &Address, + energy_factory_address: &Address, b_mock: &mut BlockchainStateWrapper, builder: StakingContractObjBuilder, ) -> ContractObjWrapper, StakingContractObjBuilder> @@ -49,6 +52,8 @@ where MultiValueEncoded::new(), ); + sc.energy_factory_address() + .set(managed_address!(energy_factory_address)); sc.farm_token() .set_token_id(managed_token_id!(STAKING_FARM_TOKEN_ID)); @@ -62,6 +67,18 @@ where }) .assert_ok(); + b_mock + .execute_tx(owner_addr, &farm_staking_wrapper, &rust_zero, |sc| { + sc.set_boosted_yields_factors( + managed_biguint!(USER_REWARDS_BASE_CONST), + managed_biguint!(USER_REWARDS_ENERGY_CONST), + managed_biguint!(USER_REWARDS_FARM_CONST), + managed_biguint!(MIN_ENERGY_AMOUNT_FOR_BOOSTED_YIELDS), + managed_biguint!(MIN_FARM_AMOUNT_FOR_BOOSTED_YIELDS), + ); + }) + .assert_ok(); + b_mock.set_esdt_balance( farm_staking_wrapper.address_ref(), STAKING_REWARD_TOKEN_ID, From 4544a92ed4f135e987b370b9764785e371b0254b Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 16 Apr 2024 23:44:07 +0300 Subject: [PATCH 031/103] merge logic update orig owner in a separate fn for safer future impl (audit request) --- dex/farm-with-locked-rewards/src/lib.rs | 17 ++++++++++------- dex/farm/src/lib.rs | 17 ++++++++++------- farm-staking/farm-staking/src/lib.rs | 16 ++++++++++------ 3 files changed, 30 insertions(+), 20 deletions(-) diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index 6b5b334a2..a8abdade2 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -199,13 +199,7 @@ pub trait Farm: self.migrate_old_farm_positions(&orig_caller); let boosted_rewards = self.claim_only_boosted_payment(&orig_caller); - let mut output_attributes = self.merge_and_return_attributes::>(); - output_attributes.original_owner = orig_caller.clone(); - - let new_token_amount = output_attributes.get_total_supply(); - let merged_farm_token = self - .farm_token() - .nft_create(new_token_amount, &output_attributes); + let merged_farm_token = self.merge_and_update_farm_tokens(orig_caller.clone()); self.send_payment_non_zero(&caller, &merged_farm_token); let locked_rewards_payment = self.send_to_lock_contract_non_zero( @@ -218,6 +212,15 @@ pub trait Farm: (merged_farm_token, locked_rewards_payment).into() } + fn merge_and_update_farm_tokens(&self, orig_caller: ManagedAddress) -> EsdtTokenPayment { + let mut output_attributes = self.merge_and_return_attributes::>(); + output_attributes.original_owner = orig_caller; + + let new_token_amount = output_attributes.get_total_supply(); + self.farm_token() + .nft_create(new_token_amount, &output_attributes) + } + #[endpoint(claimBoostedRewards)] fn claim_boosted_rewards( &self, diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 97163efb0..f7d69572b 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -196,13 +196,7 @@ pub trait Farm: let boosted_rewards_payment = EsdtTokenPayment::new(self.reward_token_id().get(), 0, boosted_rewards); - let mut output_attributes = self.merge_and_return_attributes::>(); - output_attributes.original_owner = orig_caller; - - let new_token_amount = output_attributes.get_total_supply(); - let merged_farm_token = self - .farm_token() - .nft_create(new_token_amount, &output_attributes); + let merged_farm_token = self.merge_and_update_farm_tokens(orig_caller); self.send_payment_non_zero(&caller, &merged_farm_token); self.send_payment_non_zero(&caller, &boosted_rewards_payment); @@ -210,6 +204,15 @@ pub trait Farm: (merged_farm_token, boosted_rewards_payment).into() } + fn merge_and_update_farm_tokens(&self, orig_caller: ManagedAddress) -> EsdtTokenPayment { + let mut output_attributes = self.merge_and_return_attributes::>(); + output_attributes.original_owner = orig_caller; + + let new_token_amount = output_attributes.get_total_supply(); + self.farm_token() + .nft_create(new_token_amount, &output_attributes) + } + #[endpoint(claimBoostedRewards)] fn claim_boosted_rewards( &self, diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index 60e398256..ddc12f53b 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -117,19 +117,23 @@ pub trait FarmStaking: let boosted_rewards_payment = EsdtTokenPayment::new(self.reward_token_id().get(), 0, boosted_rewards); - let mut output_attributes = self.merge_farm_tokens::>(); - output_attributes.original_owner = caller.clone(); + let merged_farm_token = self.merge_and_update_farm_tokens(caller.clone()); - let new_token_amount = output_attributes.get_total_supply(); - let merged_farm_token = self - .farm_token() - .nft_create(new_token_amount, &output_attributes); self.send_payment_non_zero(&caller, &merged_farm_token); self.send_payment_non_zero(&caller, &boosted_rewards_payment); (merged_farm_token, boosted_rewards_payment).into() } + fn merge_and_update_farm_tokens(&self, orig_caller: ManagedAddress) -> EsdtTokenPayment { + let mut output_attributes = self.merge_farm_tokens::>(); + output_attributes.original_owner = orig_caller; + + let new_token_amount = output_attributes.get_total_supply(); + self.farm_token() + .nft_create(new_token_amount, &output_attributes) + } + fn merge_farm_tokens>(&self) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); From ee10fe1faa0f340f7590d53fc267466d91a4b10b Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 19 Apr 2024 01:35:09 +0300 Subject: [PATCH 032/103] clippy fixes --- .../mod.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs index 703bfe2f7..151a4f5ec 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs @@ -532,7 +532,7 @@ where lp_farm_token_stake_amount: u64, ) -> TxResult { self.b_mock.execute_esdt_transfer( - &caller, + caller, &self.proxy_wrapper, LP_FARM_TOKEN_ID, lp_farm_token_nonce, @@ -555,7 +555,7 @@ where dual_yield_token_amount: u64, ) -> TxResult { self.b_mock.execute_esdt_transfer( - &caller, + caller, &self.proxy_wrapper, DUAL_YIELD_TOKEN_ID, dual_yield_token_nonce, @@ -580,7 +580,7 @@ where dual_yield_token_amount: u64, ) -> TxResult { self.b_mock.execute_esdt_transfer( - &caller, + caller, &self.proxy_wrapper, DUAL_YIELD_TOKEN_ID, dual_yield_token_nonce, From fe7e92d30049e6fa642ee73ff04063e809d9a6ba Mon Sep 17 00:00:00 2001 From: Costin Carabas Date: Tue, 23 Apr 2024 09:25:08 +0300 Subject: [PATCH 033/103] Proxy-dex: farm: original caller negative test --- .../proxy_dex/tests/proxy_farm_test.rs | 99 +++++++++++++++++++ 1 file changed, 99 insertions(+) diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index af6c5f6c4..612bd7093 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -1486,3 +1486,102 @@ fn increase_proxy_farm_proxy_lp_energy() { }), ); } + + + +#[test] +fn original_caller_negative_test() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let farm_addr = setup.farm_locked_wrapper.address_ref().clone(); + let user_balance = rust_biguint!(USER_BALANCE); + setup + .b_mock + .set_esdt_balance(&first_user, MEX_TOKEN_ID, &user_balance); + + // users lock tokens + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.simple_lock_wrapper, + MEX_TOKEN_ID, + 0, + &user_balance, + |sc| { + let user_payment = sc.lock_tokens_endpoint(LOCK_OPTIONS[1], OptionalValue::None); + assert_eq!(user_payment.token_nonce, 2); + assert_eq!(user_payment.amount, managed_biguint!(USER_BALANCE)); + }, + ) + .assert_ok(); + + //////////////////////////////////////////// ENTER FARM ///////////////////////////////////// + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), Some(managed_address!(&first_user)).into()); + }, + ) + .assert_error(4, "Item not whitelisted"); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + + // claim rewards with half position + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE / 2), + |sc| { + sc.claim_rewards_proxy(managed_address!(&farm_addr), Some(managed_address!(&first_user)).into()); + }, + ) + .assert_error(4, "Item not whitelisted"); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + let output = sc.exit_farm_proxy(managed_address!(&farm_addr), Some(managed_address!(&first_user)).into()); + let output_lp_token = output.0 .0; + assert_eq!(output_lp_token.token_nonce, 1); + assert_eq!(output_lp_token.amount, USER_BALANCE); + }, + ) + .assert_error(4, "Item not whitelisted"); + +} \ No newline at end of file From e993235d059d074dc6941be6e21cc201be3a7cdc Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 23 Apr 2024 22:56:02 +0300 Subject: [PATCH 034/103] original caller merge fix --- dex/farm-with-locked-rewards/src/lib.rs | 3 ++- dex/farm/src/base_functions.rs | 8 +++++--- dex/farm/src/lib.rs | 2 +- farm-staking/farm-staking/src/lib.rs | 11 +++++++---- 4 files changed, 15 insertions(+), 9 deletions(-) diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index a8abdade2..d704a80df 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -213,7 +213,8 @@ pub trait Farm: } fn merge_and_update_farm_tokens(&self, orig_caller: ManagedAddress) -> EsdtTokenPayment { - let mut output_attributes = self.merge_and_return_attributes::>(); + let mut output_attributes = + self.merge_and_return_attributes::>(&orig_caller); output_attributes.original_owner = orig_caller; let new_token_amount = output_attributes.get_total_supply(); diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index be97f7e80..48a59ac56 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -182,13 +182,15 @@ pub trait BaseFunctionsModule: } } - fn merge_and_return_attributes>(&self) -> FC::AttributesType { + fn merge_and_return_attributes>( + &self, + orig_caller: &ManagedAddress, + ) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); token_mapper.require_all_same_token(&payments); - let caller = self.blockchain().get_caller(); - FC::check_and_update_user_farm_position(self, &caller, &payments); + FC::check_and_update_user_farm_position(self, orig_caller, &payments); self.merge_from_payments_and_burn(payments, &token_mapper) } diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index f7d69572b..1a35c1631 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -205,7 +205,7 @@ pub trait Farm: } fn merge_and_update_farm_tokens(&self, orig_caller: ManagedAddress) -> EsdtTokenPayment { - let mut output_attributes = self.merge_and_return_attributes::>(); + let mut output_attributes = self.merge_and_return_attributes::>(&orig_caller); output_attributes.original_owner = orig_caller; let new_token_amount = output_attributes.get_total_supply(); diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index ddc12f53b..5fd2b28d6 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -126,7 +126,8 @@ pub trait FarmStaking: } fn merge_and_update_farm_tokens(&self, orig_caller: ManagedAddress) -> EsdtTokenPayment { - let mut output_attributes = self.merge_farm_tokens::>(); + let mut output_attributes = + self.merge_farm_tokens::>(&orig_caller); output_attributes.original_owner = orig_caller; let new_token_amount = output_attributes.get_total_supply(); @@ -134,13 +135,15 @@ pub trait FarmStaking: .nft_create(new_token_amount, &output_attributes) } - fn merge_farm_tokens>(&self) -> FC::AttributesType { + fn merge_farm_tokens>( + &self, + orig_caller: &ManagedAddress, + ) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); token_mapper.require_all_same_token(&payments); - let caller = self.blockchain().get_caller(); - FC::check_and_update_user_farm_position(self, &caller, &payments); + FC::check_and_update_user_farm_position(self, orig_caller, &payments); self.merge_from_payments_and_burn(payments, &token_mapper) } From 031b36a976aa1ef487d39937fb43f3ee8c41b421 Mon Sep 17 00:00:00 2001 From: Costin Carabas Date: Wed, 24 Apr 2024 00:55:53 +0300 Subject: [PATCH 035/103] proxy_dex: more unit tests --- .../proxy_dex/tests/proxy_farm_test.rs | 466 ++++++++++++++++++ locked-asset/proxy_dex/tests/proxy_lp_test.rs | 447 +++++++++++++++++ 2 files changed, 913 insertions(+) diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index 612bd7093..9692a945b 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -1487,6 +1487,472 @@ fn increase_proxy_farm_proxy_lp_energy() { ); } +#[test] +fn increase_proxy_farm_proxy_lp_energy_unlocked_tokens() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + + setup + .b_mock + .execute_tx( + &setup.owner, + &setup.farm_locked_wrapper, + &rust_biguint!(0), + |sc| { + sc.farming_token_id().set(&managed_token_id!(LP_TOKEN_ID)); + + // set produce rewards to false for easier calculation + sc.produce_rewards_enabled().set(false); + }, + ) + .assert_ok(); + + setup.b_mock.set_esdt_local_roles( + setup.farm_locked_wrapper.address_ref(), + LP_TOKEN_ID, + &[EsdtLocalRole::Burn], + ); + + let first_user = setup.first_user.clone(); + let locked_token_amount = rust_biguint!(1_000_000_000); + let other_token_amount = rust_biguint!(500_000_000); + let expected_lp_token_amount = rust_biguint!(499_999_000); + + // set the price to 1 EGLD = 2 MEX + let payments = vec![ + TxTokenTransfer { + token_identifier: LOCKED_TOKEN_ID.to_vec(), + nonce: 1, + value: locked_token_amount.clone(), + }, + TxTokenTransfer { + token_identifier: WEGLD_TOKEN_ID.to_vec(), + nonce: 0, + value: other_token_amount.clone(), + }, + ]; + + // add liquidity twice, to have 2 nonces + let pair_addr = setup.pair_wrapper.address_ref().clone(); + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.add_liquidity_proxy( + managed_address!(&pair_addr), + managed_biguint!(locked_token_amount.to_u64().unwrap() / 2), + managed_biguint!(other_token_amount.to_u64().unwrap() / 2), + ); + }) + .assert_ok(); + + let pair_addr = setup.pair_wrapper.address_ref().clone(); + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.add_liquidity_proxy( + managed_address!(&pair_addr), + managed_biguint!(locked_token_amount.to_u64().unwrap() / 2), + managed_biguint!(other_token_amount.to_u64().unwrap() / 2), + ); + }) + .assert_ok(); + + let mut block_epoch = 1u64; + let user_balance = USER_BALANCE; + + // check energy before + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let unlock_epoch = LOCK_OPTIONS[0]; + let lock_epochs = unlock_epoch - block_epoch; + let expected_energy_amount = + BigInt::from((user_balance) as i64) * BigInt::from(lock_epochs as i64); + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(user_balance), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); + + let farm_locked_addr = setup.farm_locked_wrapper.address_ref().clone(); + + //////////////////////////////////////////// ENTER FARM ///////////////////////////////////// + + // Enter multiple times, to distribute the nonces + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 1, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 2, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 1, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 2, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + ////////////////////////////// Wait for tokens to unlock ///////////////////////////////////// + block_epoch += LOCK_OPTIONS[0]; + setup.b_mock.set_block_epoch(block_epoch); + + + //////////////////////////////////////////// INCREASE ENERGY ///////////////////////////////////// + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 4, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.increase_proxy_farm_token_energy_endpoint(LOCK_OPTIONS[1]); + }, + ) + .assert_ok(); + + // check energy after + // lp tokens recharged = total tokens / 4 - 500 + let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap() / 4 - 500; + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; + let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) + * BigInt::from(first_lock_epochs as i64) + + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) + * second_lock_epochs; + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); + + // check user token after increase energy + // new farm token was created + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_FARM_TOKEN_ID, + 5, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + Some(&WrappedFarmTokenAttributes:: { + proxy_farming_token: EsdtTokenPayment { + token_identifier: managed_token_id!(WRAPPED_LP_TOKEN_ID), + token_nonce: 3, + amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 4u64), + }, + farm_token: EsdtTokenPayment { + token_identifier: managed_token_id!(FARM_LOCKED_TOKEN_ID), + token_nonce: 4, + amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 4u64), + }, + }), + ); +} + + + +#[test] +fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + + setup + .b_mock + .execute_tx( + &setup.owner, + &setup.farm_locked_wrapper, + &rust_biguint!(0), + |sc| { + sc.farming_token_id().set(&managed_token_id!(LP_TOKEN_ID)); + + // set produce rewards to false for easier calculation + sc.produce_rewards_enabled().set(false); + }, + ) + .assert_ok(); + + setup.b_mock.set_esdt_local_roles( + setup.farm_locked_wrapper.address_ref(), + LP_TOKEN_ID, + &[EsdtLocalRole::Burn], + ); + + let first_user = setup.first_user.clone(); + let locked_token_amount = rust_biguint!(1_000_000_000); + let other_token_amount = rust_biguint!(500_000_000); + let expected_lp_token_amount = rust_biguint!(499_999_000); + + // set the price to 1 EGLD = 2 MEX + let payments = vec![ + TxTokenTransfer { + token_identifier: LOCKED_TOKEN_ID.to_vec(), + nonce: 1, + value: locked_token_amount.clone(), + }, + TxTokenTransfer { + token_identifier: WEGLD_TOKEN_ID.to_vec(), + nonce: 0, + value: other_token_amount.clone(), + }, + ]; + + // add liquidity twice, to have 2 nonces + let pair_addr = setup.pair_wrapper.address_ref().clone(); + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.add_liquidity_proxy( + managed_address!(&pair_addr), + managed_biguint!(locked_token_amount.to_u64().unwrap() / 2), + managed_biguint!(other_token_amount.to_u64().unwrap() / 2), + ); + }) + .assert_ok(); + + let pair_addr = setup.pair_wrapper.address_ref().clone(); + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.add_liquidity_proxy( + managed_address!(&pair_addr), + managed_biguint!(locked_token_amount.to_u64().unwrap() / 2), + managed_biguint!(other_token_amount.to_u64().unwrap() / 2), + ); + }) + .assert_ok(); + + let mut block_epoch = 1u64; + let user_balance = USER_BALANCE; + + // check energy before + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let unlock_epoch = LOCK_OPTIONS[0]; + let lock_epochs = unlock_epoch - block_epoch; + let expected_energy_amount = + BigInt::from((user_balance) as i64) * BigInt::from(lock_epochs as i64); + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(user_balance), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); + + let farm_locked_addr = setup.farm_locked_wrapper.address_ref().clone(); + + //////////////////////////////////////////// ENTER FARM ///////////////////////////////////// + + // Enter multiple times, to distribute the nonces + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 1, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 2, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 1, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 2, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_locked_addr), + OptionalValue::None, + ); + }, + ) + .assert_ok(); + + ////////////////////////////// Wait for tokens to unlock ///////////////////////////////////// + block_epoch += LOCK_OPTIONS[0] / 2; + setup.b_mock.set_block_epoch(block_epoch); + + + //////////////////////////////////////////// INCREASE ENERGY ///////////////////////////////////// + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 4, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + |sc| { + sc.increase_proxy_farm_token_energy_endpoint(LOCK_OPTIONS[1]); + }, + ) + .assert_ok(); + + // check energy after + // lp tokens recharged = total tokens / 4 - 500 + let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap() / 4 - 500; + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; + let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) + * BigInt::from(first_lock_epochs as i64) + + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) + * second_lock_epochs; + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); + + // check user token after increase energy + // new farm token was created + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_FARM_TOKEN_ID, + 5, + &(&expected_lp_token_amount / &rust_biguint!(4u64)), + Some(&WrappedFarmTokenAttributes:: { + proxy_farming_token: EsdtTokenPayment { + token_identifier: managed_token_id!(WRAPPED_LP_TOKEN_ID), + token_nonce: 3, + amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 4u64), + }, + farm_token: EsdtTokenPayment { + token_identifier: managed_token_id!(FARM_LOCKED_TOKEN_ID), + token_nonce: 4, + amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 4u64), + }, + }), + ); +} + #[test] diff --git a/locked-asset/proxy_dex/tests/proxy_lp_test.rs b/locked-asset/proxy_dex/tests/proxy_lp_test.rs index 9c3710bb7..90e511568 100644 --- a/locked-asset/proxy_dex/tests/proxy_lp_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_lp_test.rs @@ -941,3 +941,450 @@ fn increase_proxy_lp_token_energy() { }) .assert_ok(); } + +#[test] +fn increase_proxy_lp_token_energy_unlocked_tokens() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let full_balance = rust_biguint!(USER_BALANCE); + let locked_token_amount = rust_biguint!(1_000_000_000); + let other_token_amount = rust_biguint!(500_000_000); + let expected_lp_token_amount = rust_biguint!(499_999_000); + + // set the price to 1 EGLD = 2 MEX + let payments = vec![ + TxTokenTransfer { + token_identifier: LOCKED_TOKEN_ID.to_vec(), + nonce: 1, + value: locked_token_amount.clone(), + }, + TxTokenTransfer { + token_identifier: WEGLD_TOKEN_ID.to_vec(), + nonce: 0, + value: other_token_amount.clone(), + }, + ]; + + // add liquidity + let pair_addr = setup.pair_wrapper.address_ref().clone(); + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.add_liquidity_proxy( + managed_address!(&pair_addr), + managed_biguint!(locked_token_amount.to_u64().unwrap()), + managed_biguint!(other_token_amount.to_u64().unwrap()), + ); + }) + .assert_ok(); + + // check user's balance + setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_TOKEN_ID, + 1, + &(&full_balance - &locked_token_amount), + None, + ); + setup.b_mock.check_esdt_balance( + &first_user, + WEGLD_TOKEN_ID, + &(&full_balance - &other_token_amount), + ); + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_LP_TOKEN_ID, + 1, + &expected_lp_token_amount, + Some(&WrappedLpTokenAttributes:: { + locked_tokens: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 1, + amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), + }, + lp_token_id: managed_token_id!(LP_TOKEN_ID), + lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap()), + }), + ); + + let mut block_epoch = 1; + let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap(); + + // check user energy before + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let lock_epochs = LOCK_OPTIONS[0] - block_epoch; + let expected_energy_amount = + BigInt::from((USER_BALANCE) as i64) * BigInt::from(lock_epochs as i64); + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); + + + // Wait for tokens to unlock + block_epoch += LOCK_OPTIONS[0]; + + setup.b_mock.set_block_epoch(block_epoch); + + + // call increase energy + setup + .b_mock + .execute_esdt_transfer( + &setup.first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 1, + &expected_lp_token_amount, + |sc| { + let _ = sc.increase_proxy_pair_token_energy_endpoint(LOCK_OPTIONS[1]); + }, + ) + .assert_ok(); + + // chceck new wrapped lp token + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_LP_TOKEN_ID, + 2, + &expected_lp_token_amount, + Some(&WrappedLpTokenAttributes:: { + locked_tokens: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + // Nonce increases + token_nonce: 3, + amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), + }, + lp_token_id: managed_token_id!(LP_TOKEN_ID), + lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap()), + }), + ); + + // check user energy after + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; + let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + + let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) + * BigInt::from(first_lock_epochs as i64) + + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) * second_lock_epochs; + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); +} + +#[test] +fn increase_proxy_lp_token_energy_partially_unlocked_tokens() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let full_balance = rust_biguint!(USER_BALANCE); + let locked_token_amount = rust_biguint!(1_000_000_000); + let other_token_amount = rust_biguint!(500_000_000); + let expected_lp_token_amount = rust_biguint!(499_999_000); + + // set the price to 1 EGLD = 2 MEX + let payments = vec![ + TxTokenTransfer { + token_identifier: LOCKED_TOKEN_ID.to_vec(), + nonce: 1, + value: locked_token_amount.clone(), + }, + TxTokenTransfer { + token_identifier: WEGLD_TOKEN_ID.to_vec(), + nonce: 0, + value: other_token_amount.clone(), + }, + ]; + + // add liquidity + let pair_addr = setup.pair_wrapper.address_ref().clone(); + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.add_liquidity_proxy( + managed_address!(&pair_addr), + managed_biguint!(locked_token_amount.to_u64().unwrap()), + managed_biguint!(other_token_amount.to_u64().unwrap()), + ); + }) + .assert_ok(); + + // check user's balance + setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_TOKEN_ID, + 1, + &(&full_balance - &locked_token_amount), + None, + ); + setup.b_mock.check_esdt_balance( + &first_user, + WEGLD_TOKEN_ID, + &(&full_balance - &other_token_amount), + ); + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_LP_TOKEN_ID, + 1, + &expected_lp_token_amount, + Some(&WrappedLpTokenAttributes:: { + locked_tokens: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 1, + amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), + }, + lp_token_id: managed_token_id!(LP_TOKEN_ID), + lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap()), + }), + ); + + let mut block_epoch = 1; + let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap(); + + // check user energy before + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let lock_epochs = LOCK_OPTIONS[0] - block_epoch; + let expected_energy_amount = + BigInt::from((USER_BALANCE) as i64) * BigInt::from(lock_epochs as i64); + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); + + + // Wait for tokens to unlock + block_epoch += LOCK_OPTIONS[0] / 2; + + setup.b_mock.set_block_epoch(block_epoch); + + + // call increase energy + setup + .b_mock + .execute_esdt_transfer( + &setup.first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 1, + &expected_lp_token_amount, + |sc| { + let _ = sc.increase_proxy_pair_token_energy_endpoint(LOCK_OPTIONS[1]); + }, + ) + .assert_ok(); + + // chceck new wrapped lp token + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_LP_TOKEN_ID, + 2, + &expected_lp_token_amount, + Some(&WrappedLpTokenAttributes:: { + locked_tokens: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + // Nonce increases + token_nonce: 3, + amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), + }, + lp_token_id: managed_token_id!(LP_TOKEN_ID), + lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap()), + }), + ); + + // check user energy after + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; + let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + + let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) + * BigInt::from(first_lock_epochs as i64) + + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) * second_lock_epochs; + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); +} + + + +#[test] +fn increase_proxy_lp_legacy_token_energy() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let full_balance = rust_biguint!(USER_BALANCE); + let locked_token_amount = rust_biguint!(1_000_000_000); + let other_token_amount = rust_biguint!(500_000_000); + let expected_lp_token_amount = rust_biguint!(499_999_000); + + // set the price to 1 EGLD = 2 MEX + let payments = vec![ + TxTokenTransfer { + token_identifier: LOCKED_TOKEN_ID.to_vec(), + nonce: 1, + value: locked_token_amount.clone(), + }, + TxTokenTransfer { + token_identifier: WEGLD_TOKEN_ID.to_vec(), + nonce: 0, + value: other_token_amount.clone(), + }, + ]; + + // add liquidity + let pair_addr = setup.pair_wrapper.address_ref().clone(); + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.add_liquidity_proxy( + managed_address!(&pair_addr), + managed_biguint!(locked_token_amount.to_u64().unwrap()), + managed_biguint!(other_token_amount.to_u64().unwrap()), + ); + }) + .assert_ok(); + + // check user's balance + setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_TOKEN_ID, + 1, + &(&full_balance - &locked_token_amount), + None, + ); + setup.b_mock.check_esdt_balance( + &first_user, + WEGLD_TOKEN_ID, + &(&full_balance - &other_token_amount), + ); + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_LP_TOKEN_ID, + 1, + &expected_lp_token_amount, + Some(&WrappedLpTokenAttributes:: { + locked_tokens: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 1, + amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), + }, + lp_token_id: managed_token_id!(LP_TOKEN_ID), + lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap()), + }), + ); + + let block_epoch = 1; + let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap(); + + // check user energy before + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let lock_epochs = LOCK_OPTIONS[0] - block_epoch; + let expected_energy_amount = + BigInt::from((USER_BALANCE) as i64) * BigInt::from(lock_epochs as i64); + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); + + // call increase energy + setup + .b_mock + .execute_esdt_transfer( + &setup.first_user, + &setup.proxy_wrapper, + WRAPPED_LP_TOKEN_ID, + 1, + &expected_lp_token_amount, + |sc| { + let _ = sc.increase_proxy_pair_token_energy_endpoint(LOCK_OPTIONS[1]); + }, + ) + .assert_ok(); + + // chceck new wrapped lp token + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_LP_TOKEN_ID, + 2, + &expected_lp_token_amount, + Some(&WrappedLpTokenAttributes:: { + locked_tokens: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 2, + amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), + }, + lp_token_id: managed_token_id!(LP_TOKEN_ID), + lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap()), + }), + ); + + // check user energy after + setup + .b_mock + .execute_query(&setup.simple_lock_wrapper, |sc| { + let first_lock_epochs = LOCK_OPTIONS[1] - block_epoch; + let second_lock_epochs = LOCK_OPTIONS[0] - block_epoch; + let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) + * BigInt::from(first_lock_epochs as i64) + + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) + * BigInt::from(second_lock_epochs as i64); + let expected_energy = Energy::new( + expected_energy_amount, + block_epoch, + managed_biguint!(USER_BALANCE), + ); + let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + assert_eq!(expected_energy, actual_energy); + }) + .assert_ok(); +} \ No newline at end of file From 6516b3608d8195b63d77612bbeccccb132fc135c Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 24 Apr 2024 04:00:59 +0300 Subject: [PATCH 036/103] farm staking additional tests --- .../tests/farm_staking_energy_test.rs | 539 +++++++++++++++++- .../tests/farm_staking_setup/mod.rs | 70 +++ 2 files changed, 592 insertions(+), 17 deletions(-) diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index b2c2f03ba..124272884 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1,6 +1,7 @@ #![allow(deprecated)] pub mod farm_staking_setup; +use config::ConfigModule; use farm_staking::{ claim_stake_farm_rewards::ClaimStakeFarmRewardsModule, stake_farm::StakeFarmModule, @@ -127,8 +128,8 @@ fn farm_staking_boosted_rewards_with_energy_test() { fs_setup.set_boosted_yields_factors(); fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); - fs_setup.set_user_energy(&user_address, 10_000, 0, 10); - fs_setup.set_user_energy(&user_address2, 5_000, 0, 10); + fs_setup.set_user_energy(&user_address, 9_800, 0, 100); + fs_setup.set_user_energy(&user_address2, 4_900, 0, 350); let farm_in_amount = 100_000_000; fs_setup.stake_farm(&user_address, farm_in_amount, &[], 1, 0, 0); @@ -164,10 +165,7 @@ fn farm_staking_boosted_rewards_with_energy_test() { ) .assert_ok(); - fs_setup.set_block_nonce(10); - - // random user tx to collect rewards - + // random user tx to collect rewards - week 1 let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); fs_setup.b_mock.set_esdt_balance( &rand_user, @@ -175,8 +173,9 @@ fn farm_staking_boosted_rewards_with_energy_test() { &rust_biguint!(USER_TOTAL_RIDE_TOKENS), ); - fs_setup.set_user_energy(&rand_user, 1, 5, 1); - fs_setup.set_block_epoch(5); + fs_setup.set_user_energy(&rand_user, 1, 6, 1); + fs_setup.set_block_epoch(6); + fs_setup.set_block_nonce(10); fs_setup .b_mock @@ -206,21 +205,119 @@ fn farm_staking_boosted_rewards_with_energy_test() { ) .assert_ok(); - fs_setup.set_block_epoch(8); + // random user tx to collect rewards - week 2 + fs_setup.set_user_energy(&rand_user, 1, 13, 1); + fs_setup.set_block_epoch(13); + fs_setup.set_block_nonce(20); - fs_setup.set_user_energy(&user_address, 10_000, 8, 10); - fs_setup.set_user_energy(&user_address2, 5_000, 8, 10); + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 7, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + // random user tx to collect rewards - week 3 + fs_setup.set_user_energy(&rand_user, 1, 20, 1); + fs_setup.set_block_epoch(20); + fs_setup.set_block_nonce(30); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 9, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); - let base_rewards = 34; - let boosted_rewards_user = 13; - let boosted_rewards_user2 = 8; + // random user tx to collect rewards - week 4 + fs_setup.set_user_energy(&rand_user, 1, 27, 1); + fs_setup.set_block_epoch(27); + fs_setup.set_block_nonce(40); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 11, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(28); + fs_setup.update_energy_for_user(&user_address); + fs_setup.update_energy_for_user(&user_address2); + + let base_rewards = 136; + let boosted_rewards_user = 61; + let boosted_rewards_user2 = 15; // ~ 1/4 rewards than user1 (half the energy for only 2 weeks) let expected_reward_token_out_user = base_rewards + boosted_rewards_user; let expected_reward_token_out_user2 = base_rewards + boosted_rewards_user2; let expected_farming_token_balance_user = rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out_user); let expected_farming_token_balance_user2 = rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out_user2); - let expected_reward_per_share = 340_000; + let expected_reward_per_share = 1_360_000; fs_setup.claim_rewards( &user_address, farm_in_amount, @@ -228,7 +325,7 @@ fn farm_staking_boosted_rewards_with_energy_test() { expected_reward_token_out_user, &expected_farming_token_balance_user, &expected_farming_token_balance_user, - 7, + 13, expected_reward_per_share, ); fs_setup.claim_rewards( @@ -238,7 +335,7 @@ fn farm_staking_boosted_rewards_with_energy_test() { expected_reward_token_out_user2, &expected_farming_token_balance_user2, &expected_farming_token_balance_user2, - 8, + 14, expected_reward_per_share, ); fs_setup.check_farm_token_supply(farm_in_amount * 2); @@ -926,3 +1023,411 @@ fn position_owner_change_test() { fs_setup.check_user_total_farm_position(&first_user, half_farm_in_amount * 5); fs_setup.check_user_total_farm_position(&second_user, farm_in_amount + half_farm_in_amount * 4); } + +#[test] +fn farm_staking_farm_position_migration_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + let user = fs_setup.user_address.clone(); + + let farm_in_amount = 10_000_000; + let half_farm_in_amount = farm_in_amount / 2; + fs_setup.stake_farm(&user, farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&user, farm_in_amount, &[], 2, 0, 0); + fs_setup.stake_farm(&user, farm_in_amount, &[], 3, 0, 0); + fs_setup.stake_farm(&user, farm_in_amount, &[], 4, 0, 0); + fs_setup.check_user_total_farm_position(&user, farm_in_amount * 4); + + // Simulate migration by resetting the user total farm position + fs_setup + .b_mock + .execute_esdt_transfer( + &user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let mut user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&user)); + user_total_farm_position.total_farm_position = managed_biguint!(0u64); + let _ = sc + .user_total_farm_position(&managed_address!(&user)) + .set(user_total_farm_position); + + sc.farm_position_migration_nonce().set(5); + }, + ) + .assert_ok(); + + fs_setup.check_user_total_farm_position(&user, 0); + + let mut expected_total_farm_position = 0u64; + let additional_farm_tokens = [TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: 1, + value: rust_biguint!(half_farm_in_amount), + }]; + + // Check enter farm with half old position additional payment + fs_setup.stake_farm(&user, farm_in_amount, &additional_farm_tokens, 5, 0, 0); + expected_total_farm_position += farm_in_amount + half_farm_in_amount; + fs_setup.check_user_total_farm_position(&user, expected_total_farm_position); + + // Check claim with half old position + let expected_farming_token_balance = rust_biguint!(4_949_999_990u64); + fs_setup.claim_rewards( + &user, + half_farm_in_amount, + 2, + 0, + &expected_farming_token_balance, + &expected_farming_token_balance, + 6, + 0, + ); + expected_total_farm_position += half_farm_in_amount; + fs_setup.check_user_total_farm_position(&user, expected_total_farm_position); + + // Check exit with half old position + fs_setup.unstake_farm( + &user, + half_farm_in_amount, + 3, + 0, + &expected_farming_token_balance, + &expected_farming_token_balance, + 7, + half_farm_in_amount, + &UnbondSftAttributes { + unlock_epoch: MIN_UNBOND_EPOCHS, + }, + ); + fs_setup.check_user_total_farm_position(&user, expected_total_farm_position); + + // Check compound with half old position + fs_setup.compound_rewards( + &user, + 4, + half_farm_in_amount, + &[], + 8, + half_farm_in_amount, + 0, + 0, + ); + expected_total_farm_position += half_farm_in_amount; + fs_setup.check_user_total_farm_position(&user, expected_total_farm_position); +} + +#[test] +fn boosted_rewards_config_change_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + let first_user = fs_setup.user_address.clone(); + let second_user = fs_setup.user_address2.clone(); + let third_user = fs_setup + .b_mock + .create_user_account(&rust_biguint!(100_000_000)); + fs_setup.b_mock.set_esdt_balance( + &third_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + let mut first_user_total_rewards = 0u64; + let mut second_user_total_rewards = 0u64; + let mut third_user_total_rewards = 0u64; + + let farm_in_amount = 10_000_000; + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&second_user, farm_in_amount, &[], 2, 0, 0); + fs_setup.stake_farm(&third_user, farm_in_amount, &[], 3, 0, 0); + + fs_setup.set_user_energy(&first_user, 10_000, 0, 10); + fs_setup.set_user_energy(&second_user, 10_000, 0, 10); + fs_setup.set_user_energy(&third_user, 10_000, 0, 10); + + // claim to get energy registered + fs_setup + .b_mock + .execute_esdt_transfer( + &first_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 1, + &rust_biguint!(farm_in_amount), + |sc| { + let _ = sc.claim_rewards(OptionalValue::None); + }, + ) + .assert_ok(); + fs_setup + .b_mock + .execute_esdt_transfer( + &second_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 2, + &rust_biguint!(farm_in_amount), + |sc| { + let _ = sc.claim_rewards(OptionalValue::None); + }, + ) + .assert_ok(); + fs_setup + .b_mock + .execute_esdt_transfer( + &third_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 3, + &rust_biguint!(farm_in_amount), + |sc| { + let _ = sc.claim_rewards(OptionalValue::None); + }, + ) + .assert_ok(); + + // random user tx to collect rewards + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &rand_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + fs_setup.set_user_energy(&rand_user, 1, 6, 1); + fs_setup.set_block_epoch(6); + fs_setup.set_block_nonce(100); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 7, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(7); + fs_setup.set_user_energy(&first_user, 10_000, 7, 10); + fs_setup.set_user_energy(&second_user, 10_000, 7, 10); + fs_setup.set_user_energy(&third_user, 10_000, 7, 10); + + // First user claims + let mut base_rewards1 = 33; + let mut boosted_rewards1 = 0; + let mut expected_reward_token_out = base_rewards1 + boosted_rewards1; + first_user_total_rewards += expected_reward_token_out; + let mut expected_farming_token_balance = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out); + let mut expected_reward_per_share = 3_333_333u64; + fs_setup.claim_rewards( + &first_user, + farm_in_amount, + 4, + expected_reward_token_out, + &expected_farming_token_balance, + &expected_farming_token_balance, + 9, + expected_reward_per_share, + ); + + // Boosted rewards config is added + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + // random user tx to collect rewards + fs_setup.set_user_energy(&rand_user, 1, 13, 1); + fs_setup.set_block_epoch(13); + fs_setup.set_block_nonce(200); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 10, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(14); + fs_setup.set_user_energy(&first_user, 10_000, 14, 10); + fs_setup.set_user_energy(&second_user, 10_000, 14, 10); + fs_setup.set_user_energy(&third_user, 10_000, 14, 10); + + // First and second users claim + base_rewards1 = 25; + boosted_rewards1 = 8; + expected_reward_token_out = base_rewards1 + boosted_rewards1; + first_user_total_rewards += expected_reward_token_out; + expected_farming_token_balance += expected_reward_token_out; + expected_reward_per_share = 5_833_333u64; + fs_setup.claim_rewards( + &first_user, + farm_in_amount, + 9, + expected_reward_token_out, + &expected_farming_token_balance, + &expected_farming_token_balance, + 12, + expected_reward_per_share, + ); + + let mut base_rewards2 = 33 + 25; + let mut boosted_rewards2 = 8; + let mut expected_reward_token_out2 = base_rewards2 + boosted_rewards2; + second_user_total_rewards += expected_reward_token_out2; + let mut expected_farming_token_balance2 = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out2); + fs_setup.claim_rewards( + &second_user, + farm_in_amount, + 5, + expected_reward_token_out2, + &expected_farming_token_balance2, + &expected_farming_token_balance2, + 13, + expected_reward_per_share, + ); + + // Boosted rewards config is updated + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE * 2); // 50% + + // random user tx to collect rewards + fs_setup.set_user_energy(&rand_user, 1, 20, 1); + fs_setup.set_block_epoch(20); + fs_setup.set_block_nonce(300); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARMING_TOKEN_ID, + 0, + &rust_biguint!(10), + |sc| { + let _ = sc.stake_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup + .b_mock + .execute_esdt_transfer( + &rand_user, + &fs_setup.farm_wrapper, + FARM_TOKEN_ID, + 14, + &rust_biguint!(10), + |sc| { + let _ = sc.unstake_farm(OptionalValue::None); + }, + ) + .assert_ok(); + + fs_setup.set_block_epoch(21); + fs_setup.set_user_energy(&first_user, 10_000, 21, 10); + fs_setup.set_user_energy(&second_user, 10_000, 21, 10); + fs_setup.set_user_energy(&third_user, 10_000, 21, 10); + + // All users claim - boosted rewards 50% + base_rewards1 = 16; + boosted_rewards1 = 16; + expected_reward_token_out = base_rewards1 + boosted_rewards1; + first_user_total_rewards += expected_reward_token_out; + expected_farming_token_balance += expected_reward_token_out; + expected_reward_per_share = 7_499_999u64; + fs_setup.claim_rewards( + &first_user, + farm_in_amount, + 12, + expected_reward_token_out, + &expected_farming_token_balance, + &expected_farming_token_balance, + 16, + expected_reward_per_share, + ); + + base_rewards2 = 16; + boosted_rewards2 = 16; + expected_reward_token_out2 = base_rewards2 + boosted_rewards2; + second_user_total_rewards += expected_reward_token_out2; + expected_farming_token_balance2 += expected_reward_token_out2; + fs_setup.claim_rewards( + &second_user, + farm_in_amount, + 13, + expected_reward_token_out2, + &expected_farming_token_balance2, + &expected_farming_token_balance2, + 17, + expected_reward_per_share, + ); + + let base_rewards3 = 74; + let boosted_rewards3 = 24; + let expected_reward_token_out3 = base_rewards3 + boosted_rewards3; + third_user_total_rewards += expected_reward_token_out3; + let expected_farming_token_balance3 = + rust_biguint!(USER_TOTAL_RIDE_TOKENS - farm_in_amount + expected_reward_token_out3); + fs_setup.claim_rewards( + &third_user, + farm_in_amount, + 6, + expected_reward_token_out3, + &expected_farming_token_balance3, + &expected_farming_token_balance3, + 18, + expected_reward_per_share, + ); + + assert!( + first_user_total_rewards == second_user_total_rewards + && first_user_total_rewards == third_user_total_rewards + ); +} diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index c0329a2f6..7bcab9d85 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -1,6 +1,7 @@ #![allow(deprecated)] use farm_staking::claim_only_boosted_staking_rewards::ClaimOnlyBoostedStakingRewardsModule; +use farm_staking::compound_stake_farm_rewards::CompoundStakeFarmRewardsModule; use multiversx_sc::codec::multi_types::OptionalValue; use multiversx_sc::storage::mappers::StorageTokenWrapper; use multiversx_sc::types::{Address, BigInt, EsdtLocalRole, ManagedAddress, MultiValueEncoded}; @@ -389,6 +390,60 @@ where .assert_error(4, "Cannot claim rewards for this address"); } + pub fn compound_rewards( + &mut self, + user: &Address, + farm_in_nonce: u64, + farm_in_amount: u64, + additional_farm_tokens: &[TxTokenTransfer], + expected_farm_token_nonce: u64, + expected_farm_token_amount: u64, + expected_reward_per_share: u64, + expected_compounded_reward: u64, + ) { + let mut payments = Vec::with_capacity(1 + additional_farm_tokens.len()); + payments.push(TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: farm_in_nonce, + value: rust_biguint!(farm_in_amount), + }); + payments.extend_from_slice(additional_farm_tokens); + + self.b_mock + .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { + let new_farm_token_payment = sc.compound_rewards(); + assert_eq!( + new_farm_token_payment.token_identifier, + managed_token_id!(FARM_TOKEN_ID) + ); + assert_eq!( + new_farm_token_payment.token_nonce, + expected_farm_token_nonce + ); + assert_eq!( + new_farm_token_payment.amount, + managed_biguint!(expected_farm_token_amount) + ); + }) + .assert_ok(); + + let expected_attributes = StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(expected_reward_per_share), + compounded_reward: managed_biguint!(expected_compounded_reward), + current_farm_amount: managed_biguint!( + expected_farm_token_amount + expected_compounded_reward + ), + original_owner: managed_address!(&user), + }; + self.b_mock.check_nft_balance( + user, + FARM_TOKEN_ID, + expected_farm_token_nonce, + &rust_biguint!(expected_farm_token_amount + expected_compounded_reward), + Some(&expected_attributes), + ); + } + #[allow(clippy::too_many_arguments)] pub fn unstake_farm( &mut self, @@ -705,4 +760,19 @@ where }) .assert_ok(); } + + pub fn update_energy_for_user(&mut self, user_addr: &Address) { + self.b_mock + .execute_tx( + user_addr, + &self.energy_factory_wrapper, + &rust_biguint!(0), + |sc| { + let user_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(user_addr)); + sc.set_energy_entry(&managed_address!(user_addr), user_energy); + }, + ) + .assert_ok(); + } } From 6eb71131f3be086fd9ee1f4b3401bbfa610106de Mon Sep 17 00:00:00 2001 From: Costin Carabas Date: Wed, 24 Apr 2024 10:15:05 +0300 Subject: [PATCH 037/103] proxy_dex: more unit tests --- .../tests/proxy_dex_test_setup/mod.rs | 22 ++- .../proxy_dex/tests/proxy_farm_test.rs | 180 ++++++++++++++++++ locked-asset/proxy_dex/tests/proxy_lp_test.rs | 52 +---- 3 files changed, 208 insertions(+), 46 deletions(-) diff --git a/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs b/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs index 2ab0326d4..322fedd61 100644 --- a/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs +++ b/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs @@ -1,5 +1,6 @@ #![allow(deprecated)] +use common_structs::{LockedAssetTokenAttributesEx, UnlockMilestoneEx, UnlockScheduleEx}; use config::ConfigModule; use energy_factory::{locked_token_transfer::LockedTokenTransferModule, SimpleLockEnergy}; use energy_query::EnergyQueryModule; @@ -11,7 +12,7 @@ use multiversx_sc::{ codec::multi_types::OptionalValue, contract_base::{CallableContract, ContractBase}, storage::mappers::StorageTokenWrapper, - types::{Address, EsdtLocalRole, ManagedAddress, MultiValueEncoded}, + types::{Address, EsdtLocalRole, ManagedAddress, ManagedVec, MultiValueEncoded}, }; use multiversx_sc_modules::pause::PauseModule; use multiversx_sc_scenario::{ @@ -151,6 +152,25 @@ where b_mock.set_esdt_balance(&second_user, MEX_TOKEN_ID, &user_balance); b_mock.set_esdt_balance(&second_user, WEGLD_TOKEN_ID, &user_balance); + let mut unlock_milestones = ManagedVec::::new(); + unlock_milestones.push(UnlockMilestoneEx { + unlock_percent: 10_000, + unlock_epoch: LOCK_OPTIONS[0], + }); + + let old_token_attributes = LockedAssetTokenAttributesEx { + is_merged: false, + unlock_schedule: UnlockScheduleEx { unlock_milestones }, + }; + b_mock.set_nft_balance( + &first_user, + LEGACY_LOCKED_TOKEN_ID, + 3, // higher random nonce to avoid nonce caching conflicts + &rust_biguint!(USER_BALANCE), + &old_token_attributes, + ); + + // users lock tokens b_mock .execute_esdt_transfer( diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index 9692a945b..5af54011c 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -1181,6 +1181,186 @@ fn different_farm_locked_token_nonce_merging_test() { ); } + + +#[test] +fn total_farm_mechanism_test() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let farm_addr = setup.farm_locked_wrapper.address_ref().clone(); + let user_balance = rust_biguint!(USER_BALANCE); + setup + .b_mock + .set_esdt_balance(&first_user, MEX_TOKEN_ID, &user_balance); + + // users lock tokens + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.simple_lock_wrapper, + MEX_TOKEN_ID, + 0, + &user_balance, + |sc| { + let user_payment = sc.lock_tokens_endpoint(LOCK_OPTIONS[1], OptionalValue::None); + assert_eq!(user_payment.token_nonce, 2); + assert_eq!(user_payment.amount, managed_biguint!(USER_BALANCE)); + }, + ) + .assert_ok(); + + let mut block_epoch = 1; + setup.b_mock.set_block_epoch(block_epoch); + + //////////////////////////////////////////// ENTER FARM ///////////////////////////////////// + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + block_epoch += 7; + setup.b_mock.set_block_epoch(block_epoch); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_FARM_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + Some(&WrappedFarmTokenAttributes:: { + proxy_farming_token: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 1, + amount: managed_biguint!(USER_BALANCE), + }, + farm_token: EsdtTokenPayment { + token_identifier: managed_token_id!(FARM_LOCKED_TOKEN_ID), + token_nonce: 1, + amount: managed_biguint!(USER_BALANCE), + }, + }), + ); + + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_FARM_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + Some(&WrappedFarmTokenAttributes:: { + proxy_farming_token: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 2, + amount: managed_biguint!(USER_BALANCE), + }, + farm_token: EsdtTokenPayment { + token_identifier: managed_token_id!(FARM_LOCKED_TOKEN_ID), + token_nonce: 2, + amount: managed_biguint!(USER_BALANCE), + }, + }), + ); + + //////////////////////////////////////////// CLAIM REWARDS ///////////////////////////////////// + + // claim rewards + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.claim_rewards_proxy(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + // check user balance + setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(0), + None, + ); + setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(0), + None, + ); + + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_FARM_TOKEN_ID, + 3, + &rust_biguint!(USER_BALANCE), + Some(&WrappedFarmTokenAttributes:: { + proxy_farming_token: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 1, + amount: managed_biguint!(USER_BALANCE), + }, + farm_token: EsdtTokenPayment { + token_identifier: managed_token_id!(FARM_LOCKED_TOKEN_ID), + token_nonce: 3, + amount: managed_biguint!(USER_BALANCE), + }, + }), + ); + // new NFT + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_FARM_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + Some(&WrappedFarmTokenAttributes:: { + proxy_farming_token: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 2, + amount: managed_biguint!(USER_BALANCE), + }, + farm_token: EsdtTokenPayment { + token_identifier: managed_token_id!(FARM_LOCKED_TOKEN_ID), + token_nonce: 2, + amount: managed_biguint!(USER_BALANCE), + }, + }), + ); +} + #[test] fn increase_proxy_farm_lkmex_energy() { let mut setup = ProxySetup::new( diff --git a/locked-asset/proxy_dex/tests/proxy_lp_test.rs b/locked-asset/proxy_dex/tests/proxy_lp_test.rs index 90e511568..4dab8b14a 100644 --- a/locked-asset/proxy_dex/tests/proxy_lp_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_lp_test.rs @@ -1263,8 +1263,8 @@ fn increase_proxy_lp_legacy_token_energy() { // set the price to 1 EGLD = 2 MEX let payments = vec![ TxTokenTransfer { - token_identifier: LOCKED_TOKEN_ID.to_vec(), - nonce: 1, + token_identifier: LEGACY_LOCKED_TOKEN_ID.to_vec(), + nonce: 3, value: locked_token_amount.clone(), }, TxTokenTransfer { @@ -1290,8 +1290,8 @@ fn increase_proxy_lp_legacy_token_energy() { // check user's balance setup.b_mock.check_nft_balance::( &first_user, - LOCKED_TOKEN_ID, - 1, + LEGACY_LOCKED_TOKEN_ID, + 3, &(&full_balance - &locked_token_amount), None, ); @@ -1307,8 +1307,8 @@ fn increase_proxy_lp_legacy_token_energy() { &expected_lp_token_amount, Some(&WrappedLpTokenAttributes:: { locked_tokens: EsdtTokenPayment { - token_identifier: managed_token_id!(LOCKED_TOKEN_ID), - token_nonce: 1, + token_identifier: managed_token_id!(LEGACY_LOCKED_TOKEN_ID), + token_nonce: 3, amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), }, lp_token_id: managed_token_id!(LP_TOKEN_ID), @@ -1317,7 +1317,6 @@ fn increase_proxy_lp_legacy_token_energy() { ); let block_epoch = 1; - let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap(); // check user energy before setup @@ -1349,42 +1348,5 @@ fn increase_proxy_lp_legacy_token_energy() { let _ = sc.increase_proxy_pair_token_energy_endpoint(LOCK_OPTIONS[1]); }, ) - .assert_ok(); - - // chceck new wrapped lp token - setup.b_mock.check_nft_balance( - &first_user, - WRAPPED_LP_TOKEN_ID, - 2, - &expected_lp_token_amount, - Some(&WrappedLpTokenAttributes:: { - locked_tokens: EsdtTokenPayment { - token_identifier: managed_token_id!(LOCKED_TOKEN_ID), - token_nonce: 2, - amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), - }, - lp_token_id: managed_token_id!(LP_TOKEN_ID), - lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap()), - }), - ); - - // check user energy after - setup - .b_mock - .execute_query(&setup.simple_lock_wrapper, |sc| { - let first_lock_epochs = LOCK_OPTIONS[1] - block_epoch; - let second_lock_epochs = LOCK_OPTIONS[0] - block_epoch; - let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) - * BigInt::from(first_lock_epochs as i64) - + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) - * BigInt::from(second_lock_epochs as i64); - let expected_energy = Energy::new( - expected_energy_amount, - block_epoch, - managed_biguint!(USER_BALANCE), - ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); - assert_eq!(expected_energy, actual_energy); - }) - .assert_ok(); + .assert_error(4, "Invalid payment"); } \ No newline at end of file From 1a1f27684ac49680c5c655da86b9a732f6469f80 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 25 Apr 2024 00:13:33 +0300 Subject: [PATCH 038/103] code coverage update --- .github/workflows/actions.yml | 58 ++--------------------------------- 1 file changed, 3 insertions(+), 55 deletions(-) diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml index afa63aa92..84a8b5a86 100644 --- a/.github/workflows/actions.yml +++ b/.github/workflows/actions.yml @@ -20,61 +20,9 @@ permissions: jobs: contracts: name: Contracts - uses: multiversx/mx-sc-actions/.github/workflows/contracts.yml@v2.3.5 + uses: multiversx/mx-sc-actions/.github/workflows/contracts.yml@v3.1.0 with: rust-toolchain: nightly-2023-12-11 - vmtools-version: v1.5.24 + coverage-args: --ignore-filename-regex='/.cargo/git' --output ./coverage.md secrets: - token: ${{ secrets.GITHUB_TOKEN }} - - # TEMPORARY: Remove this job when we can upgrade to mx-sc-actions v3+ - test_coverage: - name: Test Coverage - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - - name: Install rust - uses: actions-rust-lang/setup-rust-toolchain@v1 - with: - toolchain: nightly-2023-12-11 - target: wasm32-unknown-unknown - - - name: Install prerequisites - run: | - rustup component add llvm-tools-preview - dirname $(find ~/.rustup -name llvm-cov) >> $GITHUB_PATH - - echo $(dirname $(find ~/.rustup -name llvm-cov)) - - cargo install multiversx-sc-meta --locked - - - name: Run tests and generate report - env: - RUSTFLAGS: "" - run: | - sc-meta test-coverage --output ./coverage.md - - - name: Upload the report - uses: actions/upload-artifact@v3 - with: - name: coverage - path: coverage.md - - - name: Find the comment containing the report - id: fc - uses: peter-evans/find-comment@v2 - if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository - with: - issue-number: ${{ github.event.pull_request.number }} - comment-author: "github-actions[bot]" - body-includes: "Coverage Summary" - - - name: Create or update the report comment - uses: peter-evans/create-or-update-comment@v2 - if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository - with: - comment-id: ${{ steps.fc.outputs.comment-id }} - issue-number: ${{ github.event.pull_request.number }} - body-file: ./coverage.md - edit-mode: replace + token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From 9c04db53fe3240c002283f8ae7b3d7d43d154501 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 29 Apr 2024 12:23:27 +0300 Subject: [PATCH 039/103] clippy fixes --- farm-staking/farm-staking/tests/farm_staking_energy_test.rs | 3 +-- farm-staking/farm-staking/tests/farm_staking_setup/mod.rs | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index 124272884..facc2025f 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1053,8 +1053,7 @@ fn farm_staking_farm_position_migration_test() { let mut user_total_farm_position = sc.get_user_total_farm_position(&managed_address!(&user)); user_total_farm_position.total_farm_position = managed_biguint!(0u64); - let _ = sc - .user_total_farm_position(&managed_address!(&user)) + sc.user_total_farm_position(&managed_address!(&user)) .set(user_total_farm_position); sc.farm_position_migration_nonce().set(5); diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index 7bcab9d85..369b029bd 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -390,6 +390,7 @@ where .assert_error(4, "Cannot claim rewards for this address"); } + #[allow(clippy::too_many_arguments)] pub fn compound_rewards( &mut self, user: &Address, From effd81cd5b7327a14e2e1c19c4bb4dba1bc94d51 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 29 Apr 2024 12:39:08 +0300 Subject: [PATCH 040/103] force rebuild github actions --- .github/workflows/actions.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml index 84a8b5a86..eb7e44644 100644 --- a/.github/workflows/actions.yml +++ b/.github/workflows/actions.yml @@ -25,4 +25,4 @@ jobs: rust-toolchain: nightly-2023-12-11 coverage-args: --ignore-filename-regex='/.cargo/git' --output ./coverage.md secrets: - token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file + token: ${{ secrets.GITHUB_TOKEN }} From 1761d5413fc8b6972f1a5c80b6b9618e8b776f54 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 29 Apr 2024 17:00:35 +0300 Subject: [PATCH 041/103] Total farm position test in proxy dex --- .../proxy_dex/tests/proxy_farm_test.rs | 196 +++++++++++++++--- 1 file changed, 168 insertions(+), 28 deletions(-) diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index 5af54011c..6fe7c59b9 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -1181,8 +1181,6 @@ fn different_farm_locked_token_nonce_merging_test() { ); } - - #[test] fn total_farm_mechanism_test() { let mut setup = ProxySetup::new( @@ -1310,9 +1308,9 @@ fn total_farm_mechanism_test() { setup.b_mock.check_nft_balance::( &first_user, LOCKED_TOKEN_ID, - 2, - &rust_biguint!(0), - None, + 2, + &rust_biguint!(0), + None, ); setup.b_mock.check_nft_balance::( &first_user, @@ -1835,10 +1833,9 @@ fn increase_proxy_farm_proxy_lp_energy_unlocked_tokens() { ) .assert_ok(); - ////////////////////////////// Wait for tokens to unlock ///////////////////////////////////// - block_epoch += LOCK_OPTIONS[0]; - setup.b_mock.set_block_epoch(block_epoch); - + ////////////////////////////// Wait for tokens to unlock ///////////////////////////////////// + block_epoch += LOCK_OPTIONS[0]; + setup.b_mock.set_block_epoch(block_epoch); //////////////////////////////////////////// INCREASE ENERGY ///////////////////////////////////// setup @@ -1862,7 +1859,8 @@ fn increase_proxy_farm_proxy_lp_energy_unlocked_tokens() { .b_mock .execute_query(&setup.simple_lock_wrapper, |sc| { let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; - let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + let second_lock_epochs = + BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) * BigInt::from(first_lock_epochs as i64) + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) @@ -1899,8 +1897,6 @@ fn increase_proxy_farm_proxy_lp_energy_unlocked_tokens() { ); } - - #[test] fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { let mut setup = ProxySetup::new( @@ -2069,10 +2065,9 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { ) .assert_ok(); - ////////////////////////////// Wait for tokens to unlock ///////////////////////////////////// - block_epoch += LOCK_OPTIONS[0] / 2; - setup.b_mock.set_block_epoch(block_epoch); - + ////////////////////////////// Wait for tokens to unlock ///////////////////////////////////// + block_epoch += LOCK_OPTIONS[0] / 2; + setup.b_mock.set_block_epoch(block_epoch); //////////////////////////////////////////// INCREASE ENERGY ///////////////////////////////////// setup @@ -2096,7 +2091,8 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { .b_mock .execute_query(&setup.simple_lock_wrapper, |sc| { let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; - let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + let second_lock_epochs = + BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) * BigInt::from(first_lock_epochs as i64) + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) @@ -2133,8 +2129,6 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { ); } - - #[test] fn original_caller_negative_test() { let mut setup = ProxySetup::new( @@ -2178,12 +2172,15 @@ fn original_caller_negative_test() { 1, &rust_biguint!(USER_BALANCE), |sc| { - sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), Some(managed_address!(&first_user)).into()); + sc.enter_farm_proxy_endpoint( + managed_address!(&farm_addr), + Some(managed_address!(&first_user)).into(), + ); }, ) .assert_error(4, "Item not whitelisted"); - setup + setup .b_mock .execute_esdt_transfer( &first_user, @@ -2197,9 +2194,8 @@ fn original_caller_negative_test() { ) .assert_ok(); - - // claim rewards with half position - setup + // claim rewards with half position + setup .b_mock .execute_esdt_transfer( &first_user, @@ -2208,12 +2204,15 @@ fn original_caller_negative_test() { 1, &rust_biguint!(USER_BALANCE / 2), |sc| { - sc.claim_rewards_proxy(managed_address!(&farm_addr), Some(managed_address!(&first_user)).into()); + sc.claim_rewards_proxy( + managed_address!(&farm_addr), + Some(managed_address!(&first_user)).into(), + ); }, ) .assert_error(4, "Item not whitelisted"); - setup + setup .b_mock .execute_esdt_transfer( &first_user, @@ -2222,12 +2221,153 @@ fn original_caller_negative_test() { 1, &rust_biguint!(USER_BALANCE), |sc| { - let output = sc.exit_farm_proxy(managed_address!(&farm_addr), Some(managed_address!(&first_user)).into()); + let output = sc.exit_farm_proxy( + managed_address!(&farm_addr), + Some(managed_address!(&first_user)).into(), + ); let output_lp_token = output.0 .0; assert_eq!(output_lp_token.token_nonce, 1); assert_eq!(output_lp_token.amount, USER_BALANCE); }, ) .assert_error(4, "Item not whitelisted"); +} + +#[test] +fn total_farm_position_migration_through_proxy_dex_test() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let farm_addr = setup.farm_locked_wrapper.address_ref().clone(); + let user_balance = rust_biguint!(USER_BALANCE); + setup + .b_mock + .set_esdt_balance(&first_user, MEX_TOKEN_ID, &user_balance); + + // user locks tokens + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.simple_lock_wrapper, + MEX_TOKEN_ID, + 0, + &user_balance, + |sc| { + let user_payment = sc.lock_tokens_endpoint(LOCK_OPTIONS[1], OptionalValue::None); + assert_eq!(user_payment.token_nonce, 2); + assert_eq!(user_payment.amount, managed_biguint!(USER_BALANCE)); + }, + ) + .assert_ok(); + + // User enter farm before migration + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + // Simulate contract upgrade - total farm position is reset and migration nonce set + setup + .b_mock + .execute_tx( + &setup.owner, + &setup.farm_locked_wrapper, + &rust_biguint!(0), + |sc| { + let mut first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + first_user_total_farm_position.total_farm_position = managed_biguint!(0u64); + + sc.user_total_farm_position(&managed_address!(&first_user)) + .set(first_user_total_farm_position); + sc.farm_position_migration_nonce().set(2u64); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(0) + ); + }) + .assert_ok(); + + // User enters farm again after migration + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(USER_BALANCE) + ); + }) + .assert_ok(); + + // Merge user tokens + let payments = vec![ + TxTokenTransfer { + token_identifier: WRAPPED_FARM_TOKEN_ID.to_vec(), + nonce: 1, + value: rust_biguint!(USER_BALANCE), + }, + TxTokenTransfer { + token_identifier: WRAPPED_FARM_TOKEN_ID.to_vec(), + nonce: 2, + value: rust_biguint!(USER_BALANCE), + }, + ]; + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &payments, |sc| { + sc.merge_wrapped_farm_tokens_endpoint(managed_address!(&farm_addr)); + }) + .assert_ok(); -} \ No newline at end of file + // Total farm position should be correct + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(USER_BALANCE * 2) + ); + }) + .assert_ok(); +} From 8e8d180e9d5d4ec1047f9b54598a5d9a74d84123 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 2 May 2024 02:21:14 +0300 Subject: [PATCH 042/103] Metastaking claim total farm position fix --- .../tests/staking_farm_with_lp.rs | 211 ++++++++++++++++++ .../src/claim_stake_farm_rewards.rs | 6 + 2 files changed, 217 insertions(+) diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs index 03d7ce263..34fbe059e 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs @@ -21,6 +21,7 @@ use multiversx_sc::codec::Empty; use multiversx_sc_scenario::{ managed_address, managed_biguint, managed_token_id, rust_biguint, DebugApi, }; +use pair::pair_actions::swap::SwapModule; use simple_lock::locked_token::LockedTokenAttributes; use staking_farm_with_lp_staking_contract_interactions::*; @@ -1003,3 +1004,213 @@ fn stake_farm_through_proxy_migration_test() { setup.check_user_total_staking_farm_position(&user, user_total_staking_farm_position); setup.check_user_total_lp_farm_position(&user, user_total_lp_farm_position); } + +#[test] +fn total_farm_position_after_claim_and_exit_metastaking_test() { + let mut setup = FarmStakingSetup::new( + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + farm_staking::contract_obj, + farm_staking_proxy::contract_obj, + ); + + // Boosted rewards setup + setup + .b_mock + .execute_tx( + &setup.owner_addr, + &setup.staking_farm_wrapper, + &rust_biguint!(0), + |sc| { + sc.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + }, + ) + .assert_ok(); + + setup.set_lp_farm_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + let farm_amount = 100_000_000u64; + let user_address = setup.user_addr.clone(); + let temp_user = setup + .b_mock + .create_user_account(&rust_biguint!(farm_amount)); + setup.exit_lp_farm(&user_address, 1, USER_TOTAL_LP_TOKENS); + setup + .b_mock + .set_esdt_balance(&setup.user_addr, LP_TOKEN_ID, &rust_biguint!(farm_amount)); + setup + .b_mock + .set_esdt_balance(&temp_user, LP_TOKEN_ID, &rust_biguint!(1)); + + setup.b_mock.set_block_epoch(2); + + setup.set_user_energy(&user_address, 1_000, 2, 1); + let farm_token_nonce = setup.enter_lp_farm(&user_address, farm_amount); + + setup.check_user_total_staking_farm_position(&user_address, 0); + + // User enters Metastaking + setup.stake_farm_lp_proxy(farm_token_nonce, farm_amount, 1, farm_amount); + + // User has his total position saved + setup.check_user_total_staking_farm_position(&user_address, farm_amount); + + // User claims rewards to get his energy registered + setup + .claim_dual_yield_for_other_user(&user_address, &user_address, 1, farm_amount) + .assert_ok(); + + // User total farm position should be the same, as no swaps happened + setup.check_user_total_staking_farm_position(&user_address, farm_amount); + + // Random swaps to change the LP ratio + setup + .b_mock + .set_esdt_balance(&temp_user, WEGLD_TOKEN_ID, &rust_biguint!(300_000_000u64)); + + setup.b_mock.set_block_nonce(700); + setup.b_mock.set_block_round(700); + setup + .b_mock + .execute_esdt_transfer( + &temp_user, + &setup.pair_wrapper, + WEGLD_TOKEN_ID, + 0, + &rust_biguint!(100_000_000u64), + |sc| { + sc.swap_tokens_fixed_input(managed_token_id!(RIDE_TOKEN_ID), managed_biguint!(1)); + }, + ) + .assert_ok(); + + setup.b_mock.set_block_nonce(800); + setup.b_mock.set_block_round(800); + setup + .b_mock + .execute_esdt_transfer( + &temp_user, + &setup.pair_wrapper, + WEGLD_TOKEN_ID, + 0, + &rust_biguint!(100_000_000u64), + |sc| { + sc.swap_tokens_fixed_input(managed_token_id!(RIDE_TOKEN_ID), managed_biguint!(1)); + }, + ) + .assert_ok(); + + setup.b_mock.set_block_nonce(1250); + setup.b_mock.set_block_round(1250); + setup + .b_mock + .execute_esdt_transfer( + &temp_user, + &setup.pair_wrapper, + WEGLD_TOKEN_ID, + 0, + &rust_biguint!(100_000_000u64), + |sc| { + sc.swap_tokens_fixed_input(managed_token_id!(RIDE_TOKEN_ID), managed_biguint!(1)); + }, + ) + .assert_ok(); + + // random tx on end of week 1, to cummulate rewards + setup.b_mock.set_block_epoch(6); + setup.set_user_energy(&user_address, 1_000, 6, 1); + setup.set_user_energy(&temp_user, 1, 6, 1); + let temp_user_farm_token_nonce = setup.enter_lp_farm(&temp_user, 1); + setup.exit_lp_farm(&temp_user, temp_user_farm_token_nonce, 1); + + setup.stake_farm(9000000, 9000000); + setup.staking_farm_unstake(3, 9000000, 0, 9000000); + + // advance 1 week + setup.b_mock.set_block_epoch(10); + setup.set_user_energy(&user_address, 1_000, 10, 1); + + // User total farm position should still be the same + setup.check_user_total_staking_farm_position(&user_address, farm_amount); + + // User claims rewards + setup + .b_mock + .check_nft_balance::>( + &user_address, + DUAL_YIELD_TOKEN_ID, + 2, + &rust_biguint!(farm_amount), + None, + ); + + setup + .claim_dual_yield_for_other_user(&user_address, &user_address, 2, farm_amount) + .assert_ok(); + + // Total farm position should be updated after claim, as a few swaps happened + let new_expected_token_amount = 92_416_406u64; + setup.check_user_total_staking_farm_position(&user_address, new_expected_token_amount); + + // User does not have any dual yield tokens with the before the claim token nonce + setup + .b_mock + .check_nft_balance::>( + &user_address, + DUAL_YIELD_TOKEN_ID, + 2, + &rust_biguint!(0), + None, + ); + + setup + .b_mock + .check_nft_balance::>( + &user_address, + DUAL_YIELD_TOKEN_ID, + 3, + &rust_biguint!(new_expected_token_amount), + None, + ); + + // User exits with partial position + let user_remaining_position = 50_000_000u64; + setup + .unstake_dual_yield_for_other_user( + &user_address, + &user_address, + 3, + new_expected_token_amount - user_remaining_position, + ) + .assert_ok(); + + setup + .b_mock + .check_nft_balance::>( + &user_address, + DUAL_YIELD_TOKEN_ID, + 3, + &rust_biguint!(user_remaining_position), + None, + ); + + setup.check_user_total_staking_farm_position(&user_address, user_remaining_position); + + // User exits with remaining position + setup + .unstake_dual_yield_for_other_user(&user_address, &user_address, 3, user_remaining_position) + .assert_ok(); + + setup + .b_mock + .check_nft_balance::>( + &user_address, + DUAL_YIELD_TOKEN_ID, + 3, + &rust_biguint!(0), + None, + ); + + // Total farm position should be 0 after full unstake + setup.check_user_total_staking_farm_position(&user_address, 0); +} diff --git a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs index e3d0b1dc4..93d4802ea 100644 --- a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs @@ -74,6 +74,12 @@ pub trait ClaimStakeFarmRewardsModule: claim_result.storage_cache.farm_token_supply -= &virtual_farm_token.payment.amount; claim_result.storage_cache.farm_token_supply += &new_amount; + let mut user_total_farm_position = self.get_user_total_farm_position(&original_caller); + user_total_farm_position.total_farm_position -= &virtual_farm_token.payment.amount; + user_total_farm_position.total_farm_position += &new_amount; + self.user_total_farm_position(&original_caller) + .set(user_total_farm_position); + virtual_farm_token.payment.amount = new_amount.clone(); virtual_farm_token.attributes.current_farm_amount = new_amount; From 067064bc48f6cc6081b7c09bf73bf1263924c106 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 8 May 2024 00:45:01 +0300 Subject: [PATCH 043/103] Energy factory unit test audit update --- .../tests/simple_lock_energy_test.rs | 80 ++++++++++++++++++- 1 file changed, 79 insertions(+), 1 deletion(-) diff --git a/locked-asset/energy-factory/tests/simple_lock_energy_test.rs b/locked-asset/energy-factory/tests/simple_lock_energy_test.rs index 6d23bd1ef..8c0655476 100644 --- a/locked-asset/energy-factory/tests/simple_lock_energy_test.rs +++ b/locked-asset/energy-factory/tests/simple_lock_energy_test.rs @@ -2,7 +2,9 @@ mod energy_factory_setup; -use energy_factory::energy::EnergyModule; +use energy_factory::{ + energy::EnergyModule, locked_token_transfer::LockedTokenTransferModule, SimpleLockEnergy, +}; use energy_factory_setup::*; use multiversx_sc::types::BigUint; use simple_lock::locked_token::LockedTokenAttributes; @@ -489,3 +491,79 @@ fn energy_deplete_test() { }) .assert_ok(); } + +#[test] +fn extend_lock_period_endpoint_test() { + let mut setup = SimpleLockEnergySetup::new(energy_factory::contract_obj); + let first_user = setup.first_user.clone(); + let random_user = setup.b_mock.create_user_account(&rust_biguint!(0u64)); + + let current_epoch = 1; + setup.b_mock.set_block_epoch(current_epoch); + + setup + .lock( + &first_user, + BASE_ASSET_TOKEN_ID, + USER_BALANCE, + LOCK_OPTIONS[0], + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.sc_wrapper, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.extend_lock_period(100, managed_address!(&first_user)); + }, + ) + .assert_user_error("Invalid lock choice"); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.sc_wrapper, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.extend_lock_period(LOCK_OPTIONS[0], managed_address!(&first_user)); + }, + ) + .assert_user_error("May not call this endpoint. Use lockTokens instead"); + + let energy_per_epoch = rust_biguint!(USER_BALANCE); + let energy_before = setup.get_user_energy(&first_user); + assert_eq!( + energy_before, + LOCK_OPTIONS[0] * energy_per_epoch.clone() - energy_per_epoch.clone() + ); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.sc_wrapper, + LOCKED_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.token_transfer_whitelist() + .add(&managed_address!(&first_user)); + sc.extend_lock_period(LOCK_OPTIONS[1], managed_address!(&first_user)); + }, + ) + .assert_ok(); + + let energy_after = setup.get_user_energy(&first_user); + assert_eq!( + energy_after, + LOCK_OPTIONS[1] * energy_per_epoch.clone() - energy_per_epoch.clone() + ); +} From 867a88d82192d515d9a3c01b6324073d700febec Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 9 May 2024 17:15:59 +0300 Subject: [PATCH 044/103] clippy fix --- locked-asset/energy-factory/tests/simple_lock_energy_test.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/locked-asset/energy-factory/tests/simple_lock_energy_test.rs b/locked-asset/energy-factory/tests/simple_lock_energy_test.rs index 8c0655476..202630958 100644 --- a/locked-asset/energy-factory/tests/simple_lock_energy_test.rs +++ b/locked-asset/energy-factory/tests/simple_lock_energy_test.rs @@ -496,7 +496,6 @@ fn energy_deplete_test() { fn extend_lock_period_endpoint_test() { let mut setup = SimpleLockEnergySetup::new(energy_factory::contract_obj); let first_user = setup.first_user.clone(); - let random_user = setup.b_mock.create_user_account(&rust_biguint!(0u64)); let current_epoch = 1; setup.b_mock.set_block_epoch(current_epoch); From c8f3f213f78f54656a3eda2ed22b9c1f96e2ad4e Mon Sep 17 00:00:00 2001 From: Dorin Marian Iancu Date: Mon, 13 May 2024 12:07:10 +0300 Subject: [PATCH 045/103] farm energy fix --- common/common_structs/src/farm_types.rs | 7 +++ .../contexts/src/claim_rewards_context.rs | 30 +++++++--- .../farm/contexts/src/enter_farm_context.rs | 28 +++++++-- common/modules/farm/events/src/events.rs | 4 +- .../farm_base_impl/src/base_traits_impl.rs | 34 ++++------- .../farm/farm_base_impl/src/claim_rewards.rs | 12 +++- .../farm_base_impl/src/compound_rewards.rs | 10 +++- .../farm/farm_base_impl/src/enter_farm.rs | 7 ++- .../farm/farm_base_impl/src/exit_farm.rs | 2 +- common/modules/utils/src/lib.rs | 24 +++++--- dex/farm-with-locked-rewards/src/lib.rs | 2 - dex/farm/src/base_functions.rs | 45 +++++++++++++- dex/farm/src/lib.rs | 2 - .../farm-boosted-yields/src/lib.rs | 2 +- .../farm-staking/src/base_impl_wrapper.rs | 58 ------------------- .../src/claim_stake_farm_rewards.rs | 5 ++ .../src/compound_stake_farm_rewards.rs | 5 ++ .../farm-staking/src/delete_energy.rs | 43 ++++++++++++++ farm-staking/farm-staking/src/lib.rs | 15 ++++- farm-staking/farm-staking/src/stake_farm.rs | 5 ++ .../farm-staking/src/token_attributes.rs | 4 ++ farm-staking/farm-staking/src/unstake_farm.rs | 6 +- 22 files changed, 230 insertions(+), 120 deletions(-) create mode 100644 farm-staking/farm-staking/src/delete_energy.rs diff --git a/common/common_structs/src/farm_types.rs b/common/common_structs/src/farm_types.rs index d7d85e20b..676b26e36 100644 --- a/common/common_structs/src/farm_types.rs +++ b/common/common_structs/src/farm_types.rs @@ -80,6 +80,8 @@ pub trait FarmToken { fn get_compounded_rewards(&self) -> BigUint; fn get_initial_farming_tokens(&self) -> BigUint; + + fn get_original_owner(&self) -> ManagedAddress; } impl FarmToken for FarmTokenAttributes { @@ -97,4 +99,9 @@ impl FarmToken for FarmTokenAttributes { fn get_initial_farming_tokens(&self) -> BigUint { &self.current_farm_amount - &self.compounded_reward } + + #[inline] + fn get_original_owner(&self) -> ManagedAddress { + self.original_owner.clone() + } } diff --git a/common/modules/farm/contexts/src/claim_rewards_context.rs b/common/modules/farm/contexts/src/claim_rewards_context.rs index 653c6b2e6..78b8f4e67 100644 --- a/common/modules/farm/contexts/src/claim_rewards_context.rs +++ b/common/modules/farm/contexts/src/claim_rewards_context.rs @@ -2,26 +2,28 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use common_errors::{ERROR_BAD_PAYMENTS, ERROR_EMPTY_PAYMENTS}; -use common_structs::PaymentAttributesPair; +use common_structs::{PaymentAttributesPair, PaymentsVec}; use multiversx_sc::api::BlockchainApi; use multiversx_sc::contract_base::BlockchainWrapper; pub struct ClaimRewardsContext where M: ManagedTypeApi, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, { pub first_farm_token: PaymentAttributesPair, - pub additional_payments: ManagedVec>, + pub additional_payments: PaymentsVec, + pub additional_attributes: ManagedVec, + pub all_attributes: ManagedVec, } impl ClaimRewardsContext where M: ManagedTypeApi + BlockchainApi, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, { pub fn new( - mut payments: ManagedVec>, + mut payments: PaymentsVec, farm_token_id: &TokenIdentifier, api_wrapper: BlockchainWrapper, ) -> Self { @@ -29,22 +31,32 @@ where M::error_api_impl().signal_error(ERROR_EMPTY_PAYMENTS); } + let own_sc_address = api_wrapper.get_sc_address(); + let mut all_attributes = ManagedVec::new(); for p in &payments { if &p.token_identifier != farm_token_id { M::error_api_impl().signal_error(ERROR_BAD_PAYMENTS); } + + let token_data = + api_wrapper.get_esdt_token_data(&own_sc_address, farm_token_id, p.token_nonce); + let token_attributes: T = token_data.decode_attributes(); + all_attributes.push(token_attributes); } let first_payment = payments.get(0); payments.remove(0); - let own_sc_address = api_wrapper.get_sc_address(); - let token_data = api_wrapper.get_esdt_token_data( + // dumb framework errors otherwise + let first_token_data = api_wrapper.get_esdt_token_data( &own_sc_address, farm_token_id, first_payment.token_nonce, ); - let first_token_attributes: T = token_data.decode_attributes(); + let first_token_attributes: T = first_token_data.decode_attributes(); + + let mut additional_attributes = all_attributes.clone(); + additional_attributes.remove(0); ClaimRewardsContext { first_farm_token: PaymentAttributesPair { @@ -52,6 +64,8 @@ where attributes: first_token_attributes, }, additional_payments: payments, + additional_attributes, + all_attributes, } } } diff --git a/common/modules/farm/contexts/src/enter_farm_context.rs b/common/modules/farm/contexts/src/enter_farm_context.rs index 9da789d9a..27a060015 100644 --- a/common/modules/farm/contexts/src/enter_farm_context.rs +++ b/common/modules/farm/contexts/src/enter_farm_context.rs @@ -2,17 +2,28 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use common_errors::{ERROR_BAD_PAYMENTS, ERROR_EMPTY_PAYMENTS}; +use common_structs::PaymentsVec; +use multiversx_sc::{api::BlockchainApi, contract_base::BlockchainWrapper}; -pub struct EnterFarmContext { +pub struct EnterFarmContext< + M: ManagedTypeApi, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, +> { pub farming_token_payment: EsdtTokenPayment, - pub additional_farm_tokens: ManagedVec>, + pub additional_farm_tokens: PaymentsVec, + pub additional_attributes: ManagedVec, } -impl EnterFarmContext { +impl< + M: ManagedTypeApi + BlockchainApi, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + > EnterFarmContext +{ pub fn new( - mut payments: ManagedVec>, + mut payments: PaymentsVec, farming_token_id: &TokenIdentifier, farm_token_id: &TokenIdentifier, + api_wrapper: BlockchainWrapper, ) -> Self { if payments.is_empty() { M::error_api_impl().signal_error(ERROR_EMPTY_PAYMENTS); @@ -24,15 +35,24 @@ impl EnterFarmContext { } payments.remove(0); + + let own_sc_address = api_wrapper.get_sc_address(); + let mut additional_attributes = ManagedVec::new(); for p in &payments { if &p.token_identifier != farm_token_id { M::error_api_impl().signal_error(ERROR_BAD_PAYMENTS); } + + let token_data = + api_wrapper.get_esdt_token_data(&own_sc_address, farm_token_id, p.token_nonce); + let token_attributes: T = token_data.decode_attributes(); + additional_attributes.push(token_attributes); } EnterFarmContext { farming_token_payment, additional_farm_tokens: payments, + additional_attributes, } } } diff --git a/common/modules/farm/events/src/events.rs b/common/modules/farm/events/src/events.rs index c32988130..6b55fed0c 100644 --- a/common/modules/farm/events/src/events.rs +++ b/common/modules/farm/events/src/events.rs @@ -142,7 +142,7 @@ pub trait EventsModule { fn emit_claim_rewards_event< 'a, C: FarmContracTraitBounds, - AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, + AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, >( &self, original_caller: &ManagedAddress, @@ -189,7 +189,7 @@ pub trait EventsModule { fn emit_compound_rewards_event< 'a, C: FarmContracTraitBounds, - AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, + AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, >( self, original_caller: &ManagedAddress, diff --git a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs index f2ccc293c..7fdb6cdc3 100644 --- a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs +++ b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs @@ -1,12 +1,11 @@ multiversx_sc::imports!(); -use common_structs::{FarmToken, FarmTokenAttributes, Nonce}; +use common_structs::{FarmToken, FarmTokenAttributes, Nonce, PaymentsVec}; use config::ConfigModule; use contexts::storage_cache::StorageCache; use core::marker::PhantomData; use fixed_supply_token::FixedSupplyToken; use mergeable::Mergeable; -use multiversx_sc_modules::transfer_role_proxy::PaymentsVec; use rewards::RewardsModule; pub trait AllBaseFarmImplTraits = @@ -30,8 +29,8 @@ pub trait FarmContract { + FixedSupplyToken<::Api> + FarmToken<::Api> + From::Api>> - + Into::Api>> = - FarmTokenAttributes<::Api>; + + Into::Api>> + + ManagedVecItem = FarmTokenAttributes<::Api>; #[inline] fn mint_rewards( @@ -192,27 +191,21 @@ pub trait FarmContract { fn check_and_update_user_farm_position( sc: &Self::FarmSc, user: &ManagedAddress<::Api>, - farm_positions: &PaymentsVec<::Api>, + farm_tokens: &PaymentsVec<::Api>, + farm_attributes: &ManagedVec<::Api, Self::AttributesType>, ) { - let farm_token_mapper = sc.farm_token(); - for farm_position in farm_positions { - farm_token_mapper.require_same_token(&farm_position.token_identifier); - - if sc.is_old_farm_position(farm_position.token_nonce) { + for (attr, farm_token) in farm_attributes.into_iter().zip(farm_tokens.iter()) { + if sc.is_old_farm_position(farm_token.token_nonce) { continue; } - let token_attributes: FarmTokenAttributes<::Api> = - farm_token_mapper.get_token_attributes(farm_position.token_nonce); - - if &token_attributes.original_owner != user { - Self::decrease_user_farm_position(sc, &farm_position); - Self::increase_user_farm_position(sc, user, &farm_position.amount); + if &attr.get_original_owner() != user { + Self::decrease_user_farm_position(sc, &farm_token, &attr); + Self::increase_user_farm_position(sc, user, &farm_token.amount); } } } - #[inline] fn increase_user_farm_position( sc: &Self::FarmSc, user: &ManagedAddress<::Api>, @@ -227,16 +220,13 @@ pub trait FarmContract { fn decrease_user_farm_position( sc: &Self::FarmSc, farm_position: &EsdtTokenPayment<::Api>, + attributes: &Self::AttributesType, ) { if sc.is_old_farm_position(farm_position.token_nonce) { return; } - let farm_token_mapper = sc.farm_token(); - let token_attributes: FarmTokenAttributes<::Api> = - farm_token_mapper.get_token_attributes(farm_position.token_nonce); - - sc.user_total_farm_position(&token_attributes.original_owner) + sc.user_total_farm_position(&attributes.get_original_owner()) .update(|user_total_farm_position| { if user_total_farm_position.total_farm_position > farm_position.amount { user_total_farm_position.total_farm_position -= &farm_position.amount; diff --git a/common/modules/farm/farm_base_impl/src/claim_rewards.rs b/common/modules/farm/farm_base_impl/src/claim_rewards.rs index d9dfe293e..30b943089 100644 --- a/common/modules/farm/farm_base_impl/src/claim_rewards.rs +++ b/common/modules/farm/farm_base_impl/src/claim_rewards.rs @@ -11,7 +11,7 @@ use fixed_supply_token::FixedSupplyToken; pub struct InternalClaimRewardsResult<'a, C, T> where C: FarmContracTraitBounds, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, { pub context: ClaimRewardsContext, pub storage_cache: StorageCache<'a, C>, @@ -81,7 +81,12 @@ pub trait BaseClaimRewardsModule: ); storage_cache.reward_reserve -= &reward; - FC::check_and_update_user_farm_position(self, &caller, &payments); + FC::check_and_update_user_farm_position( + self, + &caller, + &payments, + &claim_rewards_context.all_attributes, + ); let farm_token_mapper = self.farm_token(); let base_attributes = FC::create_claim_rewards_initial_attributes( @@ -90,10 +95,11 @@ pub trait BaseClaimRewardsModule: token_attributes, storage_cache.reward_per_share.clone(), ); + let new_token_attributes = self.merge_attributes_from_payments( base_attributes, + &claim_rewards_context.additional_attributes, &claim_rewards_context.additional_payments, - &farm_token_mapper, ); let new_farm_token = PaymentAttributesPair { payment: EsdtTokenPayment::new( diff --git a/common/modules/farm/farm_base_impl/src/compound_rewards.rs b/common/modules/farm/farm_base_impl/src/compound_rewards.rs index 06e52585c..530f732c0 100644 --- a/common/modules/farm/farm_base_impl/src/compound_rewards.rs +++ b/common/modules/farm/farm_base_impl/src/compound_rewards.rs @@ -12,7 +12,7 @@ use fixed_supply_token::FixedSupplyToken; pub struct InternalCompoundRewardsResult<'a, C, T> where C: FarmContracTraitBounds, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, { pub context: CompoundRewardsContext, pub storage_cache: StorageCache<'a, C>, @@ -70,7 +70,12 @@ pub trait BaseCompoundRewardsModule: storage_cache.reward_reserve -= &reward; storage_cache.farm_token_supply += &reward; - FC::check_and_update_user_farm_position(self, &caller, &payments); + FC::check_and_update_user_farm_position( + self, + &caller, + &payments, + &compound_rewards_context.all_attributes, + ); let farm_token_mapper = self.farm_token(); let base_attributes = FC::create_compound_rewards_initial_attributes( @@ -82,6 +87,7 @@ pub trait BaseCompoundRewardsModule: ); let new_farm_token = self.merge_and_create_token( base_attributes, + &compound_rewards_context.additional_attributes, &compound_rewards_context.additional_payments, &farm_token_mapper, ); diff --git a/common/modules/farm/farm_base_impl/src/enter_farm.rs b/common/modules/farm/farm_base_impl/src/enter_farm.rs index 02e20d42a..850606829 100644 --- a/common/modules/farm/farm_base_impl/src/enter_farm.rs +++ b/common/modules/farm/farm_base_impl/src/enter_farm.rs @@ -10,9 +10,9 @@ use contexts::{ pub struct InternalEnterFarmResult<'a, C, T> where C: FarmContracTraitBounds, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, { - pub context: EnterFarmContext, + pub context: EnterFarmContext, pub storage_cache: StorageCache<'a, C>, pub new_farm_token: PaymentAttributesPair, pub created_with_merge: bool, @@ -42,6 +42,7 @@ pub trait BaseEnterFarmModule: payments, &storage_cache.farming_token_id, &storage_cache.farm_token_id, + self.blockchain(), ); // The order is important - first check and update, then increase position @@ -49,6 +50,7 @@ pub trait BaseEnterFarmModule: self, &caller, &enter_farm_context.additional_farm_tokens, + &enter_farm_context.additional_attributes, ); FC::increase_user_farm_position( self, @@ -69,6 +71,7 @@ pub trait BaseEnterFarmModule: ); let new_farm_token = self.merge_and_create_token( base_attributes, + &enter_farm_context.additional_attributes, &enter_farm_context.additional_farm_tokens, &farm_token_mapper, ); diff --git a/common/modules/farm/farm_base_impl/src/exit_farm.rs b/common/modules/farm/farm_base_impl/src/exit_farm.rs index 315abe421..30d420787 100644 --- a/common/modules/farm/farm_base_impl/src/exit_farm.rs +++ b/common/modules/farm/farm_base_impl/src/exit_farm.rs @@ -62,7 +62,7 @@ pub trait BaseExitFarmModule: ); storage_cache.reward_reserve -= &reward; - FC::decrease_user_farm_position(self, &payment); + FC::decrease_user_farm_position(self, &payment, &exit_farm_context.farm_token.attributes); let farming_token_amount = token_attributes.get_total_supply(); let farming_token_payment = EsdtTokenPayment::new( diff --git a/common/modules/utils/src/lib.rs b/common/modules/utils/src/lib.rs index 990b88329..9077b7203 100644 --- a/common/modules/utils/src/lib.rs +++ b/common/modules/utils/src/lib.rs @@ -57,7 +57,7 @@ pub trait UtilsModule { } fn merge_from_payments_and_burn< - T: FixedSupplyToken + Mergeable + TopDecode, + T: FixedSupplyToken + Mergeable + TopDecode + ManagedVecItem, >( &self, mut payments: PaymentsVec, @@ -68,23 +68,29 @@ pub trait UtilsModule { self.get_attributes_as_part_of_fixed_supply(&first_payment, mapper); mapper.nft_burn(first_payment.token_nonce, &first_payment.amount); + let mut other_attributes = ManagedVec::new(); + for payment in &payments { + let attr = mapper.get_token_attributes(payment.token_nonce); + other_attributes.push(attr); + } + let output_attributes = - self.merge_attributes_from_payments(base_attributes, &payments, mapper); + self.merge_attributes_from_payments(base_attributes, &other_attributes, &payments); self.send().esdt_local_burn_multi(&payments); output_attributes } fn merge_attributes_from_payments< - T: FixedSupplyToken + Mergeable + TopDecode, + T: FixedSupplyToken + Mergeable + TopDecode + ManagedVecItem, >( &self, mut base_attributes: T, + other_attributes: &ManagedVec, payments: &PaymentsVec, - mapper: &NonFungibleTokenMapper, ) -> T { - for payment in payments { - let attributes: T = self.get_attributes_as_part_of_fixed_supply(&payment, mapper); + for (attr, payment) in other_attributes.into_iter().zip(payments.iter()) { + let attributes = attr.into_part(&payment.amount); base_attributes.merge_with(attributes); } @@ -98,15 +104,17 @@ pub trait UtilsModule { + TopEncode + TopDecode + NestedEncode - + NestedDecode, + + NestedDecode + + ManagedVecItem, >( &self, base_attributes: T, + other_attributes: &ManagedVec, payments: &PaymentsVec, mapper: &NonFungibleTokenMapper, ) -> PaymentAttributesPair { let output_attributes = - self.merge_attributes_from_payments(base_attributes, payments, mapper); + self.merge_attributes_from_payments(base_attributes, other_attributes, payments); let new_token_amount = output_attributes.get_total_supply(); let new_token_payment = mapper.nft_create(new_token_amount, &output_attributes); diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index d704a80df..34600f80b 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -182,8 +182,6 @@ pub trait Farm: orig_caller.clone(), ); - self.clear_user_energy_if_needed(&orig_caller); - (exit_farm_result.farming_tokens, locked_rewards_payment).into() } diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index 48a59ac56..510887aa6 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -7,6 +7,7 @@ multiversx_sc::derive_imports!(); use core::marker::PhantomData; use common_errors::ERROR_ZERO_AMOUNT; +use common_structs::FarmToken; use common_structs::FarmTokenAttributes; use contexts::storage_cache::StorageCache; @@ -81,6 +82,10 @@ pub trait BaseFunctionsModule: &base_enter_farm_result.storage_cache.farm_token_supply, ); + self.delete_user_energy_if_needed::( + &base_enter_farm_result.context.additional_attributes, + ); + self.emit_enter_farm_event( &caller, base_enter_farm_result.context.farming_token_payment, @@ -106,6 +111,8 @@ pub trait BaseFunctionsModule: &base_claim_rewards_result.storage_cache.farm_token_supply, ); + self.delete_user_energy_if_needed::(&base_claim_rewards_result.context.all_attributes); + self.emit_claim_rewards_event( &caller, base_claim_rewards_result.context, @@ -135,6 +142,10 @@ pub trait BaseFunctionsModule: &base_compound_rewards_result.storage_cache.farm_token_supply, ); + self.delete_user_energy_if_needed::( + &base_compound_rewards_result.context.all_attributes, + ); + self.emit_compound_rewards_event( &caller, base_compound_rewards_result.context, @@ -161,6 +172,10 @@ pub trait BaseFunctionsModule: &base_exit_farm_result.storage_cache.farm_token_supply, ); + self.delete_user_energy_if_needed::(&ManagedVec::from_single_item( + base_exit_farm_result.context.farm_token.attributes.clone(), + )); + FC::apply_penalty( self, &mut farming_token_payment.amount, @@ -188,9 +203,18 @@ pub trait BaseFunctionsModule: ) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); - token_mapper.require_all_same_token(&payments); - FC::check_and_update_user_farm_position(self, orig_caller, &payments); + let mut all_attributes = ManagedVec::new(); + for payment in &payments { + token_mapper.require_same_token(&payment.token_identifier); + + let attr = token_mapper.get_token_attributes(payment.token_nonce); + all_attributes.push(attr); + } + + self.delete_user_energy_if_needed::(&all_attributes); + + FC::check_and_update_user_farm_position(self, orig_caller, &payments, &all_attributes); self.merge_from_payments_and_burn(payments, &token_mapper) } @@ -253,6 +277,23 @@ pub trait BaseFunctionsModule: self.per_block_reward_amount().set(&per_block_amount); } + fn delete_user_energy_if_needed>( + &self, + all_attributes: &ManagedVec, + ) { + let mut processed_users = ManagedMap::new(); + for attr in all_attributes { + let original_owner = attr.get_original_owner(); + if processed_users.contains(original_owner.as_managed_buffer()) { + continue; + } + + self.clear_user_energy_if_needed(&original_owner); + + processed_users.put(original_owner.as_managed_buffer(), &ManagedBuffer::new()); + } + } + fn require_queried(&self) { let caller = self.blockchain().get_caller(); let sc_address = self.blockchain().get_sc_address(); diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 1a35c1631..5bf5dba64 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -177,8 +177,6 @@ pub trait Farm: self.send_payment_non_zero(&caller, &exit_farm_result.farming_tokens); self.send_payment_non_zero(&caller, &exit_farm_result.rewards); - self.clear_user_energy_if_needed(&orig_caller); - (exit_farm_result.farming_tokens, exit_farm_result.rewards).into() } diff --git a/energy-integration/farm-boosted-yields/src/lib.rs b/energy-integration/farm-boosted-yields/src/lib.rs index 09bacc676..78ec0fb4e 100644 --- a/energy-integration/farm-boosted-yields/src/lib.rs +++ b/energy-integration/farm-boosted-yields/src/lib.rs @@ -123,8 +123,8 @@ pub trait FarmBoostedYieldsModule: fn clear_user_energy_if_needed(&self, original_caller: &ManagedAddress) { let opt_config = self.try_get_boosted_yields_config(); - let user_total_farm_position = self.get_user_total_farm_position(original_caller); if let Some(config) = opt_config { + let user_total_farm_position = self.get_user_total_farm_position(original_caller); let boosted_yields_factors = config.get_latest_factors(); self.clear_user_energy( original_caller, diff --git a/farm-staking/farm-staking/src/base_impl_wrapper.rs b/farm-staking/farm-staking/src/base_impl_wrapper.rs index 2b671677f..da30a1c84 100644 --- a/farm-staking/farm-staking/src/base_impl_wrapper.rs +++ b/farm-staking/farm-staking/src/base_impl_wrapper.rs @@ -5,7 +5,6 @@ use core::marker::PhantomData; use common_structs::FarmToken; use contexts::storage_cache::StorageCache; use farm_base_impl::base_traits_impl::FarmContract; -use multiversx_sc_modules::transfer_role_proxy::PaymentsVec; use crate::token_attributes::StakingFarmTokenAttributes; @@ -184,61 +183,4 @@ where original_owner: caller, } } - - fn check_and_update_user_farm_position( - sc: &Self::FarmSc, - user: &ManagedAddress<::Api>, - farm_positions: &PaymentsVec<::Api>, - ) { - let farm_token_mapper = sc.farm_token(); - for farm_position in farm_positions { - if sc.is_old_farm_position(farm_position.token_nonce) { - continue; - } - - farm_token_mapper.require_same_token(&farm_position.token_identifier); - - let token_attributes: StakingFarmTokenAttributes<::Api> = - farm_token_mapper.get_token_attributes(farm_position.token_nonce); - - if &token_attributes.original_owner != user { - Self::decrease_user_farm_position(sc, &farm_position); - Self::increase_user_farm_position(sc, user, &farm_position.amount); - } - } - } - - #[inline] - fn increase_user_farm_position( - sc: &Self::FarmSc, - user: &ManagedAddress<::Api>, - increase_farm_position_amount: &BigUint<::Api>, - ) { - let mut user_total_farm_position = sc.get_user_total_farm_position(user); - user_total_farm_position.total_farm_position += increase_farm_position_amount; - sc.user_total_farm_position(user) - .set(user_total_farm_position); - } - - fn decrease_user_farm_position( - sc: &Self::FarmSc, - farm_position: &EsdtTokenPayment<::Api>, - ) { - if sc.is_old_farm_position(farm_position.token_nonce) { - return; - } - - let farm_token_mapper = sc.farm_token(); - let token_attributes: StakingFarmTokenAttributes<::Api> = - farm_token_mapper.get_token_attributes(farm_position.token_nonce); - - sc.user_total_farm_position(&token_attributes.original_owner) - .update(|user_total_farm_position| { - if user_total_farm_position.total_farm_position > farm_position.amount { - user_total_farm_position.total_farm_position -= &farm_position.amount; - } else { - user_total_farm_position.total_farm_position = BigUint::zero(); - } - }); - } } diff --git a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs index 93d4802ea..4fb4de268 100644 --- a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs @@ -30,6 +30,7 @@ pub trait ClaimStakeFarmRewardsModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule + + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(claimRewards)] @@ -86,6 +87,10 @@ pub trait ClaimStakeFarmRewardsModule: self.set_farm_supply_for_current_week(&claim_result.storage_cache.farm_token_supply); } + self.delete_user_energy_if_needed::>( + &claim_result.context.all_attributes, + ); + self.update_energy_and_progress(&original_caller); let new_farm_token_nonce = self.send().esdt_nft_create_compact( diff --git a/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs b/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs index a7d83d574..bb0c2906d 100644 --- a/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs @@ -28,6 +28,7 @@ pub trait CompoundStakeFarmRewardsModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule + + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(compoundRewards)] @@ -43,6 +44,10 @@ pub trait CompoundStakeFarmRewardsModule: self.set_farm_supply_for_current_week(&compound_result.storage_cache.farm_token_supply); + self.delete_user_energy_if_needed::>( + &compound_result.context.all_attributes, + ); + self.emit_compound_rewards_event( &caller, compound_result.context, diff --git a/farm-staking/farm-staking/src/delete_energy.rs b/farm-staking/farm-staking/src/delete_energy.rs new file mode 100644 index 000000000..ddb8c9d52 --- /dev/null +++ b/farm-staking/farm-staking/src/delete_energy.rs @@ -0,0 +1,43 @@ +use common_structs::FarmToken; +use farm_base_impl::base_traits_impl::FarmContract; + +multiversx_sc::imports!(); + +#[multiversx_sc::module] +pub trait DeleteEnergyModule: + rewards::RewardsModule + + config::ConfigModule + + token_send::TokenSendModule + + farm_token::FarmTokenModule + + pausable::PausableModule + + permissions_module::PermissionsModule + + events::EventsModule + + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule + + utils::UtilsModule + + farm_boosted_yields::FarmBoostedYieldsModule + + farm_boosted_yields::boosted_yields_factors::BoostedYieldsFactorsModule + + week_timekeeping::WeekTimekeepingModule + + weekly_rewards_splitting::WeeklyRewardsSplittingModule + + weekly_rewards_splitting::events::WeeklyRewardsSplittingEventsModule + + weekly_rewards_splitting::global_info::WeeklyRewardsGlobalInfo + + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + + energy_query::EnergyQueryModule +{ + fn delete_user_energy_if_needed>( + &self, + all_attributes: &ManagedVec, + ) { + let mut processed_users = ManagedMap::new(); + for attr in all_attributes { + let original_owner = attr.get_original_owner(); + if processed_users.contains(original_owner.as_managed_buffer()) { + continue; + } + + self.clear_user_energy_if_needed(&original_owner); + + processed_users.put(original_owner.as_managed_buffer(), &ManagedBuffer::new()); + } + } +} diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index 5fd2b28d6..f7aa53f70 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -19,6 +19,7 @@ pub mod claim_only_boosted_staking_rewards; pub mod claim_stake_farm_rewards; pub mod compound_stake_farm_rewards; pub mod custom_rewards; +pub mod delete_energy; pub mod farm_token_roles; pub mod stake_farm; pub mod token_attributes; @@ -60,6 +61,7 @@ pub trait FarmStaking: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule + + delete_energy::DeleteEnergyModule { #[init] fn init( @@ -141,9 +143,18 @@ pub trait FarmStaking: ) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); - token_mapper.require_all_same_token(&payments); - FC::check_and_update_user_farm_position(self, orig_caller, &payments); + let mut all_attributes = ManagedVec::new(); + for payment in &payments { + token_mapper.require_same_token(&payment.token_identifier); + + let attr = token_mapper.get_token_attributes(payment.token_nonce); + all_attributes.push(attr); + } + + self.delete_user_energy_if_needed::(&all_attributes); + + FC::check_and_update_user_farm_position(self, orig_caller, &payments, &all_attributes); self.merge_from_payments_and_burn(payments, &token_mapper) } diff --git a/farm-staking/farm-staking/src/stake_farm.rs b/farm-staking/farm-staking/src/stake_farm.rs index 7ab3dea1c..5dfa8ca53 100644 --- a/farm-staking/farm-staking/src/stake_farm.rs +++ b/farm-staking/farm-staking/src/stake_farm.rs @@ -31,6 +31,7 @@ pub trait StakeFarmModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule + + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(stakeFarmThroughProxy)] @@ -86,6 +87,10 @@ pub trait StakeFarmModule: self.set_farm_supply_for_current_week(&enter_result.storage_cache.farm_token_supply); + self.delete_user_energy_if_needed::>( + &enter_result.context.additional_attributes, + ); + self.update_energy_and_progress(&original_caller); self.emit_enter_farm_event( diff --git a/farm-staking/farm-staking/src/token_attributes.rs b/farm-staking/farm-staking/src/token_attributes.rs index 59f8c6326..0fcabeba3 100644 --- a/farm-staking/farm-staking/src/token_attributes.rs +++ b/farm-staking/farm-staking/src/token_attributes.rs @@ -82,6 +82,10 @@ impl FarmToken for StakingFarmTokenAttributes { fn get_initial_farming_tokens(&self) -> BigUint { &self.current_farm_amount - &self.compounded_reward } + + fn get_original_owner(&self) -> ManagedAddress { + self.original_owner.clone() + } } impl FixedSupplyToken for StakingFarmTokenAttributes { diff --git a/farm-staking/farm-staking/src/unstake_farm.rs b/farm-staking/farm-staking/src/unstake_farm.rs index e40642b4f..6b87d9782 100644 --- a/farm-staking/farm-staking/src/unstake_farm.rs +++ b/farm-staking/farm-staking/src/unstake_farm.rs @@ -30,6 +30,7 @@ pub trait UnstakeFarmModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule + + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(unstakeFarm)] @@ -89,9 +90,12 @@ pub trait UnstakeFarmModule: self.send_payment_non_zero(&caller, &exit_result.reward_payment); - self.clear_user_energy_if_needed(&original_caller); self.set_farm_supply_for_current_week(&exit_result.storage_cache.farm_token_supply); + self.delete_user_energy_if_needed::>( + &ManagedVec::from_single_item(exit_result.context.farm_token.attributes.clone()), + ); + self.emit_exit_farm_event( &caller, exit_result.context, From d8a5d6f004b50b4e111bec7dc0a1bdf29bcfa9bd Mon Sep 17 00:00:00 2001 From: Dorin Marian Iancu Date: Mon, 13 May 2024 12:49:12 +0300 Subject: [PATCH 046/103] more fixes + test --- dex/farm/tests/energy_update_test.rs | 133 ++++++++++++++++++ .../farm-boosted-yields/src/lib.rs | 24 ++-- 2 files changed, 148 insertions(+), 9 deletions(-) diff --git a/dex/farm/tests/energy_update_test.rs b/dex/farm/tests/energy_update_test.rs index 1d8f78a98..e091a028e 100644 --- a/dex/farm/tests/energy_update_test.rs +++ b/dex/farm/tests/energy_update_test.rs @@ -2,7 +2,14 @@ mod farm_setup; +use common_structs::FarmTokenAttributes; +use farm::Farm; use farm_setup::multi_user_farm_setup::*; +use multiversx_sc::imports::OptionalValue; +use multiversx_sc_scenario::{ + managed_biguint, rust_biguint, whitebox_legacy::TxTokenTransfer, DebugApi, +}; +use weekly_rewards_splitting::global_info::WeeklyRewardsGlobalInfo; #[test] fn test_farm_setup() { @@ -53,3 +60,129 @@ fn test_energy_update_no_claim_current_week() { farm_setup.update_energy_for_user(); farm_setup.check_farm_claim_progress_energy(0); } + +#[test] +fn enter_farm_other_users_pos_test() { + DebugApi::dummy(); + + let mut farm_setup = MultiUserFarmSetup::new( + farm::contract_obj, + energy_factory_mock::contract_obj, + energy_update::contract_obj, + ); + + let first_farm_token_amount = 100_000_000; + let first_user = farm_setup.first_user.clone(); + let second_user = farm_setup.second_user.clone(); + + let first_user_energy_amount = 1_000; + let second_user_energy_amount = 5_000; + farm_setup.set_user_energy(&first_user, first_user_energy_amount, 13, 1); + farm_setup.set_user_energy(&second_user, second_user_energy_amount, 13, 1); + + farm_setup.enter_farm(&first_user, first_farm_token_amount); + + let token_attributes: FarmTokenAttributes = farm_setup + .b_mock + .get_nft_attributes(&first_user, FARM_TOKEN_ID, 1) + .unwrap(); + + // first user transfer pos to second user + farm_setup.b_mock.set_nft_balance( + &second_user, + FARM_TOKEN_ID, + 1, + &rust_biguint!(first_farm_token_amount), + &token_attributes, + ); + farm_setup.b_mock.set_nft_balance( + &first_user, + FARM_TOKEN_ID, + 1, + &rust_biguint!(0), + &token_attributes, + ); + + let transfers = [ + TxTokenTransfer { + token_identifier: FARMING_TOKEN_ID.to_vec(), + nonce: 0, + value: rust_biguint!(1_000), + }, + TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: 1, + value: rust_biguint!(first_farm_token_amount), + }, + ]; + + farm_setup + .b_mock + .execute_esdt_multi_transfer(&second_user, &farm_setup.farm_wrapper, &transfers, |sc| { + sc.enter_farm_endpoint(OptionalValue::None); + + let actual_energy = sc.total_energy_for_week(1).get(); + assert_eq!(actual_energy, managed_biguint!(second_user_energy_amount)); + }) + .assert_ok(); +} + +#[test] +fn exit_other_users_pos_test() { + DebugApi::dummy(); + + let mut farm_setup = MultiUserFarmSetup::new( + farm::contract_obj, + energy_factory_mock::contract_obj, + energy_update::contract_obj, + ); + + let first_farm_token_amount = 100_000_000; + let first_user = farm_setup.first_user.clone(); + let second_user = farm_setup.second_user.clone(); + + let first_user_energy_amount = 1_000; + let second_user_energy_amount = 200; + farm_setup.set_user_energy(&first_user, first_user_energy_amount, 13, 1); + farm_setup.set_user_energy(&second_user, second_user_energy_amount, 13, 1); + + farm_setup.enter_farm(&first_user, first_farm_token_amount); + + let token_attributes: FarmTokenAttributes = farm_setup + .b_mock + .get_nft_attributes(&first_user, FARM_TOKEN_ID, 1) + .unwrap(); + + // first user transfer pos to second user + farm_setup.b_mock.set_nft_balance( + &second_user, + FARM_TOKEN_ID, + 1, + &rust_biguint!(first_farm_token_amount), + &token_attributes, + ); + farm_setup.b_mock.set_nft_balance( + &first_user, + FARM_TOKEN_ID, + 1, + &rust_biguint!(0), + &token_attributes, + ); + + farm_setup + .b_mock + .execute_esdt_transfer( + &second_user, + &farm_setup.farm_wrapper, + FARM_TOKEN_ID, + 1, + &rust_biguint!(first_farm_token_amount), + |sc| { + sc.exit_farm_endpoint(OptionalValue::None); + + let actual_energy = sc.total_energy_for_week(1).get(); + assert_eq!(actual_energy, managed_biguint!(0)); + }, + ) + .assert_ok(); +} diff --git a/energy-integration/farm-boosted-yields/src/lib.rs b/energy-integration/farm-boosted-yields/src/lib.rs index 78ec0fb4e..0c8543132 100644 --- a/energy-integration/farm-boosted-yields/src/lib.rs +++ b/energy-integration/farm-boosted-yields/src/lib.rs @@ -15,6 +15,7 @@ use weekly_rewards_splitting::{ pub mod boosted_yields_factors; const MAX_PERCENT: u64 = 10_000; +const DEFAULT_MIN_FARM_AMT: u64 = 1; pub struct SplitReward { pub base_farm: BigUint, @@ -123,15 +124,20 @@ pub trait FarmBoostedYieldsModule: fn clear_user_energy_if_needed(&self, original_caller: &ManagedAddress) { let opt_config = self.try_get_boosted_yields_config(); - if let Some(config) = opt_config { - let user_total_farm_position = self.get_user_total_farm_position(original_caller); - let boosted_yields_factors = config.get_latest_factors(); - self.clear_user_energy( - original_caller, - &user_total_farm_position.total_farm_position, - &boosted_yields_factors.min_farm_amount, - ); - } + let user_total_farm_position = self.get_user_total_farm_position(original_caller); + let min_farm_amount = match opt_config { + Some(config) => { + let boosted_yields_factors = config.get_latest_factors(); + boosted_yields_factors.min_farm_amount.clone() + } + None => BigUint::from(DEFAULT_MIN_FARM_AMT), + }; + + self.clear_user_energy( + original_caller, + &user_total_farm_position.total_farm_position, + &min_farm_amount, + ); } #[view(getBoostedYieldsRewardsPercentage)] From 457831115b775283fba97d5df5d18c9fbb51665a Mon Sep 17 00:00:00 2001 From: Dorin Marian Iancu Date: Mon, 13 May 2024 13:06:33 +0300 Subject: [PATCH 047/103] fix for old users --- dex/farm/src/base_functions.rs | 33 +++++++++++++------ .../src/claim_stake_farm_rewards.rs | 4 ++- .../src/compound_stake_farm_rewards.rs | 6 ++-- .../farm-staking/src/delete_energy.rs | 9 +++-- farm-staking/farm-staking/src/lib.rs | 2 +- farm-staking/farm-staking/src/stake_farm.rs | 1 + farm-staking/farm-staking/src/unstake_farm.rs | 5 +-- 7 files changed, 41 insertions(+), 19 deletions(-) diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index 510887aa6..16704331d 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -9,6 +9,7 @@ use core::marker::PhantomData; use common_errors::ERROR_ZERO_AMOUNT; use common_structs::FarmToken; use common_structs::FarmTokenAttributes; +use common_structs::PaymentsVec; use contexts::storage_cache::StorageCache; use farm_base_impl::base_traits_impl::{DefaultFarmWrapper, FarmContract}; @@ -83,6 +84,7 @@ pub trait BaseFunctionsModule: ); self.delete_user_energy_if_needed::( + &base_enter_farm_result.context.additional_farm_tokens, &base_enter_farm_result.context.additional_attributes, ); @@ -102,7 +104,8 @@ pub trait BaseFunctionsModule: caller: ManagedAddress, ) -> ClaimRewardsResultWrapper { let payments = self.call_value().all_esdt_transfers().clone_value(); - let base_claim_rewards_result = self.claim_rewards_base::(caller.clone(), payments); + let base_claim_rewards_result = + self.claim_rewards_base::(caller.clone(), payments.clone()); let output_farm_token_payment = base_claim_rewards_result.new_farm_token.payment.clone(); let rewards_payment = base_claim_rewards_result.rewards; @@ -111,7 +114,10 @@ pub trait BaseFunctionsModule: &base_claim_rewards_result.storage_cache.farm_token_supply, ); - self.delete_user_energy_if_needed::(&base_claim_rewards_result.context.all_attributes); + self.delete_user_energy_if_needed::( + &payments, + &base_claim_rewards_result.context.all_attributes, + ); self.emit_claim_rewards_event( &caller, @@ -134,7 +140,7 @@ pub trait BaseFunctionsModule: ) -> EsdtTokenPayment { let payments = self.call_value().all_esdt_transfers().clone_value(); let base_compound_rewards_result = - self.compound_rewards_base::(caller.clone(), payments); + self.compound_rewards_base::(caller.clone(), payments.clone()); let output_farm_token_payment = base_compound_rewards_result.new_farm_token.payment.clone(); @@ -143,6 +149,7 @@ pub trait BaseFunctionsModule: ); self.delete_user_energy_if_needed::( + &payments, &base_compound_rewards_result.context.all_attributes, ); @@ -163,7 +170,7 @@ pub trait BaseFunctionsModule: caller: ManagedAddress, payment: EsdtTokenPayment, ) -> ExitFarmResultWrapper { - let base_exit_farm_result = self.exit_farm_base::(caller.clone(), payment); + let base_exit_farm_result = self.exit_farm_base::(caller.clone(), payment.clone()); let mut farming_token_payment = base_exit_farm_result.farming_token_payment; let reward_payment = base_exit_farm_result.reward_payment; @@ -172,9 +179,12 @@ pub trait BaseFunctionsModule: &base_exit_farm_result.storage_cache.farm_token_supply, ); - self.delete_user_energy_if_needed::(&ManagedVec::from_single_item( - base_exit_farm_result.context.farm_token.attributes.clone(), - )); + self.delete_user_energy_if_needed::( + &ManagedVec::from_single_item(payment), + &ManagedVec::from_single_item( + base_exit_farm_result.context.farm_token.attributes.clone(), + ), + ); FC::apply_penalty( self, @@ -212,7 +222,7 @@ pub trait BaseFunctionsModule: all_attributes.push(attr); } - self.delete_user_energy_if_needed::(&all_attributes); + self.delete_user_energy_if_needed::(&payments, &all_attributes); FC::check_and_update_user_farm_position(self, orig_caller, &payments, &all_attributes); @@ -279,12 +289,15 @@ pub trait BaseFunctionsModule: fn delete_user_energy_if_needed>( &self, + payments: &PaymentsVec, all_attributes: &ManagedVec, ) { let mut processed_users = ManagedMap::new(); - for attr in all_attributes { + for (payment, attr) in payments.iter().zip(all_attributes.into_iter()) { let original_owner = attr.get_original_owner(); - if processed_users.contains(original_owner.as_managed_buffer()) { + if processed_users.contains(original_owner.as_managed_buffer()) + || self.is_old_farm_position(payment.token_nonce) + { continue; } diff --git a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs index 4fb4de268..53050ba98 100644 --- a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs @@ -63,11 +63,12 @@ pub trait ClaimStakeFarmRewardsModule: opt_new_farming_amount: Option, ) -> ClaimRewardsResultType { self.migrate_old_farm_positions(&original_caller); + let payment = self.call_value().single_esdt(); let mut claim_result = self .claim_rewards_base_no_farm_token_mint::>( original_caller.clone(), - ManagedVec::from_single_item(payment), + ManagedVec::from_single_item(payment.clone()), ); let mut virtual_farm_token = claim_result.new_farm_token.clone(); @@ -88,6 +89,7 @@ pub trait ClaimStakeFarmRewardsModule: } self.delete_user_energy_if_needed::>( + &ManagedVec::from_single_item(payment), &claim_result.context.all_attributes, ); diff --git a/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs b/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs index bb0c2906d..cd8df29a9 100644 --- a/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs @@ -35,9 +35,10 @@ pub trait CompoundStakeFarmRewardsModule: fn compound_rewards(&self) -> EsdtTokenPayment { let caller = self.blockchain().get_caller(); self.migrate_old_farm_positions(&caller); + let payments = self.get_non_empty_payments(); - let compound_result = - self.compound_rewards_base::>(caller.clone(), payments); + let compound_result = self + .compound_rewards_base::>(caller.clone(), payments.clone()); let new_farm_token = compound_result.new_farm_token.payment.clone(); self.send_payment_non_zero(&caller, &new_farm_token); @@ -45,6 +46,7 @@ pub trait CompoundStakeFarmRewardsModule: self.set_farm_supply_for_current_week(&compound_result.storage_cache.farm_token_supply); self.delete_user_energy_if_needed::>( + &payments, &compound_result.context.all_attributes, ); diff --git a/farm-staking/farm-staking/src/delete_energy.rs b/farm-staking/farm-staking/src/delete_energy.rs index ddb8c9d52..7c80412eb 100644 --- a/farm-staking/farm-staking/src/delete_energy.rs +++ b/farm-staking/farm-staking/src/delete_energy.rs @@ -1,4 +1,4 @@ -use common_structs::FarmToken; +use common_structs::{FarmToken, PaymentsVec}; use farm_base_impl::base_traits_impl::FarmContract; multiversx_sc::imports!(); @@ -26,12 +26,15 @@ pub trait DeleteEnergyModule: { fn delete_user_energy_if_needed>( &self, + payments: &PaymentsVec, all_attributes: &ManagedVec, ) { let mut processed_users = ManagedMap::new(); - for attr in all_attributes { + for (payment, attr) in payments.iter().zip(all_attributes.into_iter()) { let original_owner = attr.get_original_owner(); - if processed_users.contains(original_owner.as_managed_buffer()) { + if processed_users.contains(original_owner.as_managed_buffer()) + || self.is_old_farm_position(payment.token_nonce) + { continue; } diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index f7aa53f70..589748364 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -152,7 +152,7 @@ pub trait FarmStaking: all_attributes.push(attr); } - self.delete_user_energy_if_needed::(&all_attributes); + self.delete_user_energy_if_needed::(&payments, &all_attributes); FC::check_and_update_user_farm_position(self, orig_caller, &payments, &all_attributes); diff --git a/farm-staking/farm-staking/src/stake_farm.rs b/farm-staking/farm-staking/src/stake_farm.rs index 5dfa8ca53..a022b689d 100644 --- a/farm-staking/farm-staking/src/stake_farm.rs +++ b/farm-staking/farm-staking/src/stake_farm.rs @@ -88,6 +88,7 @@ pub trait StakeFarmModule: self.set_farm_supply_for_current_week(&enter_result.storage_cache.farm_token_supply); self.delete_user_energy_if_needed::>( + &enter_result.context.additional_farm_tokens, &enter_result.context.additional_attributes, ); diff --git a/farm-staking/farm-staking/src/unstake_farm.rs b/farm-staking/farm-staking/src/unstake_farm.rs index 6b87d9782..1d40cfd15 100644 --- a/farm-staking/farm-staking/src/unstake_farm.rs +++ b/farm-staking/farm-staking/src/unstake_farm.rs @@ -75,8 +75,8 @@ pub trait UnstakeFarmModule: ) -> ExitFarmWithPartialPosResultType { let migrated_amount = self.migrate_old_farm_positions(&original_caller); - let exit_result = - self.exit_farm_base::>(original_caller.clone(), payment); + let exit_result = self + .exit_farm_base::>(original_caller.clone(), payment.clone()); self.decrease_old_farm_positions(migrated_amount, &original_caller); @@ -93,6 +93,7 @@ pub trait UnstakeFarmModule: self.set_farm_supply_for_current_week(&exit_result.storage_cache.farm_token_supply); self.delete_user_energy_if_needed::>( + &ManagedVec::from_single_item(payment), &ManagedVec::from_single_item(exit_result.context.farm_token.attributes.clone()), ); From 9803759e81fb54d9b8e044b9af21396346234a3f Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 14 May 2024 03:00:15 +0300 Subject: [PATCH 048/103] proxy dex unit tests audit update --- .../proxy_dex/tests/proxy_farm_test.rs | 422 +++++++++++++++++- locked-asset/proxy_dex/tests/proxy_lp_test.rs | 118 +++-- 2 files changed, 493 insertions(+), 47 deletions(-) diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index 6fe7c59b9..af054dc93 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -355,7 +355,8 @@ fn farm_with_wrapped_lp_test() { block_epoch, managed_biguint!(user_balance), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1216,6 +1217,19 @@ fn total_farm_mechanism_test() { let mut block_epoch = 1; setup.b_mock.set_block_epoch(block_epoch); + // Check total farm position + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(0) + ); + }) + .assert_ok(); + //////////////////////////////////////////// ENTER FARM ///////////////////////////////////// setup @@ -1232,6 +1246,19 @@ fn total_farm_mechanism_test() { ) .assert_ok(); + // Check total farm position + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(USER_BALANCE) + ); + }) + .assert_ok(); + block_epoch += 7; setup.b_mock.set_block_epoch(block_epoch); @@ -1249,6 +1276,19 @@ fn total_farm_mechanism_test() { ) .assert_ok(); + // Check total farm position + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(USER_BALANCE * 2) + ); + }) + .assert_ok(); + setup.b_mock.check_nft_balance( &first_user, WRAPPED_FARM_TOKEN_ID, @@ -1304,6 +1344,19 @@ fn total_farm_mechanism_test() { ) .assert_ok(); + // Check total farm position + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(USER_BALANCE * 2) + ); + }) + .assert_ok(); + // check user balance setup.b_mock.check_nft_balance::( &first_user, @@ -1400,7 +1453,8 @@ fn increase_proxy_farm_lkmex_energy() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1432,7 +1486,8 @@ fn increase_proxy_farm_lkmex_energy() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1528,7 +1583,8 @@ fn increase_proxy_farm_proxy_lp_energy() { block_epoch, managed_biguint!(user_balance), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1621,6 +1677,17 @@ fn increase_proxy_farm_proxy_lp_energy() { ) .assert_ok(); + // check old tokens were burned + setup + .b_mock + .check_nft_balance::>( + setup.proxy_wrapper.address_ref(), + WRAPPED_FARM_TOKEN_ID, + 4, + &rust_biguint!(0u64), + None, + ); + // check energy after // lp tokens recharged = total tokens / 4 - 500 let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap() / 4 - 500; @@ -1638,7 +1705,8 @@ fn increase_proxy_farm_proxy_lp_energy() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1755,7 +1823,8 @@ fn increase_proxy_farm_proxy_lp_energy_unlocked_tokens() { block_epoch, managed_biguint!(user_balance), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1852,6 +1921,17 @@ fn increase_proxy_farm_proxy_lp_energy_unlocked_tokens() { ) .assert_ok(); + // check old tokens were burned + setup + .b_mock + .check_nft_balance::>( + setup.proxy_wrapper.address_ref(), + WRAPPED_FARM_TOKEN_ID, + 4, + &rust_biguint!(0u64), + None, + ); + // check energy after // lp tokens recharged = total tokens / 4 - 500 let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap() / 4 - 500; @@ -1870,7 +1950,8 @@ fn increase_proxy_farm_proxy_lp_energy_unlocked_tokens() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1971,7 +2052,7 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { }) .assert_ok(); - let mut block_epoch = 1u64; + let block_epoch = 1u64; let user_balance = USER_BALANCE; // check energy before @@ -1987,7 +2068,8 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { block_epoch, managed_biguint!(user_balance), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -2065,10 +2147,6 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { ) .assert_ok(); - ////////////////////////////// Wait for tokens to unlock ///////////////////////////////////// - block_epoch += LOCK_OPTIONS[0] / 2; - setup.b_mock.set_block_epoch(block_epoch); - //////////////////////////////////////////// INCREASE ENERGY ///////////////////////////////////// setup .b_mock @@ -2084,6 +2162,17 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { ) .assert_ok(); + // check old tokens were burned + setup + .b_mock + .check_nft_balance::>( + setup.proxy_wrapper.address_ref(), + WRAPPED_FARM_TOKEN_ID, + 4, + &rust_biguint!(0u64), + None, + ); + // check energy after // lp tokens recharged = total tokens / 4 - 500 let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap() / 4 - 500; @@ -2102,7 +2191,8 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -2371,3 +2461,307 @@ fn total_farm_position_migration_through_proxy_dex_test() { }) .assert_ok(); } + +#[test] +fn increase_proxy_farm_legacy_token_energy_negative_test() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let farm_addr = setup.farm_locked_wrapper.address_ref().clone(); + + //////////////////////////////////////////// ENTER FARM ///////////////////////////////////// + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LEGACY_LOCKED_TOKEN_ID, + 3, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + //////////////////////////////////////////// INCREASE ENERGY ///////////////////////////////////// + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 1, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.increase_proxy_farm_token_energy_endpoint(LOCK_OPTIONS[1]); + }, + ) + .assert_user_error("Invalid payments"); +} + +#[test] +fn total_farm_position_migration_mechanism_test() { + let mut setup = ProxySetup::new( + proxy_dex::contract_obj, + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + let first_user = setup.first_user.clone(); + let farm_addr = setup.farm_locked_wrapper.address_ref().clone(); + let user_balance = rust_biguint!(USER_BALANCE * 6); + setup + .b_mock + .set_esdt_balance(&first_user, MEX_TOKEN_ID, &user_balance); + + // user locks tokens + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.simple_lock_wrapper, + MEX_TOKEN_ID, + 0, + &user_balance, + |sc| { + let user_payment = sc.lock_tokens_endpoint(LOCK_OPTIONS[1], OptionalValue::None); + assert_eq!(user_payment.token_nonce, 2); + assert_eq!(user_payment.amount, managed_biguint!(USER_BALANCE * 6)); + }, + ) + .assert_ok(); + + // User enter farm 5 times before migration + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + LOCKED_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE), + |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + // Simulate contract upgrade - total farm position is reset and migration nonce set + setup + .b_mock + .execute_tx( + &setup.owner, + &setup.farm_locked_wrapper, + &rust_biguint!(0), + |sc| { + let mut first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + first_user_total_farm_position.total_farm_position = managed_biguint!(0u64); + + sc.user_total_farm_position(&managed_address!(&first_user)) + .set(first_user_total_farm_position); + sc.farm_position_migration_nonce().set(6u64); + }, + ) + .assert_ok(); + + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(0) + ); + }) + .assert_ok(); + + // User enters farm again after migration + let enter_payments = vec![ + TxTokenTransfer { + token_identifier: LOCKED_TOKEN_ID.to_vec(), + nonce: 2, + value: rust_biguint!(USER_BALANCE), + }, + TxTokenTransfer { + token_identifier: WRAPPED_FARM_TOKEN_ID.to_vec(), + nonce: 1, + value: rust_biguint!(USER_BALANCE / 2), + }, + ]; + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &enter_payments, |sc| { + sc.enter_farm_proxy_endpoint(managed_address!(&farm_addr), OptionalValue::None); + }) + .assert_ok(); + + // Check total farm position + let mut user_total_farm_position = USER_BALANCE + (USER_BALANCE / 2); + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(user_total_farm_position) + ); + }) + .assert_ok(); + + // Claim rewards with half old position + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 2, + &rust_biguint!(USER_BALANCE / 2), + |sc| { + sc.claim_rewards_proxy(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + // Check total farm position + user_total_farm_position += USER_BALANCE / 2; + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(user_total_farm_position) + ); + }) + .assert_ok(); + + // Exit farm with half old position + setup + .b_mock + .execute_esdt_transfer( + &first_user, + &setup.proxy_wrapper, + WRAPPED_FARM_TOKEN_ID, + 3, + &rust_biguint!(USER_BALANCE / 2), + |sc| { + sc.exit_farm_proxy(managed_address!(&farm_addr), OptionalValue::None); + }, + ) + .assert_ok(); + + // Total farm position stays the same + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(user_total_farm_position) + ); + }) + .assert_ok(); + + // Merge 2 partial old farm positions + let merge_payments = vec![ + TxTokenTransfer { + token_identifier: WRAPPED_FARM_TOKEN_ID.to_vec(), + nonce: 4, + value: rust_biguint!(USER_BALANCE / 2), + }, + TxTokenTransfer { + token_identifier: WRAPPED_FARM_TOKEN_ID.to_vec(), + nonce: 5, + value: rust_biguint!(USER_BALANCE / 4 * 3), + }, + ]; + setup + .b_mock + .execute_esdt_multi_transfer(&first_user, &setup.proxy_wrapper, &merge_payments, |sc| { + sc.merge_wrapped_farm_tokens_endpoint(managed_address!(&farm_addr)); + }) + .assert_ok(); + + // Check final total farm position + user_total_farm_position += USER_BALANCE / 2; + user_total_farm_position += USER_BALANCE / 4 * 3; + setup + .b_mock + .execute_query(&setup.farm_locked_wrapper, |sc| { + let first_user_total_farm_position = + sc.get_user_total_farm_position(&managed_address!(&first_user)); + assert_eq!( + first_user_total_farm_position.total_farm_position, + managed_biguint!(user_total_farm_position) + ); + }) + .assert_ok(); +} diff --git a/locked-asset/proxy_dex/tests/proxy_lp_test.rs b/locked-asset/proxy_dex/tests/proxy_lp_test.rs index 4dab8b14a..5d524ba3a 100644 --- a/locked-asset/proxy_dex/tests/proxy_lp_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_lp_test.rs @@ -133,7 +133,8 @@ fn add_remove_liquidity_proxy_test() { block_epoch, managed_biguint!(user_balance), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -190,7 +191,8 @@ fn add_remove_liquidity_proxy_test() { block_epoch, managed_biguint!(user_balance), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -884,7 +886,8 @@ fn increase_proxy_lp_token_energy() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -904,6 +907,17 @@ fn increase_proxy_lp_token_energy() { ) .assert_ok(); + // check old tokens were burned + setup + .b_mock + .check_nft_balance::>( + setup.proxy_wrapper.address_ref(), + WRAPPED_LP_TOKEN_ID, + 1, + &rust_biguint!(0u64), + None, + ); + // chceck new wrapped lp token setup.b_mock.check_nft_balance( &first_user, @@ -936,7 +950,8 @@ fn increase_proxy_lp_token_energy() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1027,18 +1042,17 @@ fn increase_proxy_lp_token_energy_unlocked_tokens() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); - // Wait for tokens to unlock block_epoch += LOCK_OPTIONS[0]; setup.b_mock.set_block_epoch(block_epoch); - // call increase energy setup .b_mock @@ -1054,7 +1068,7 @@ fn increase_proxy_lp_token_energy_unlocked_tokens() { ) .assert_ok(); - // chceck new wrapped lp token + // check new wrapped lp token setup.b_mock.check_nft_balance( &first_user, WRAPPED_LP_TOKEN_ID, @@ -1072,22 +1086,36 @@ fn increase_proxy_lp_token_energy_unlocked_tokens() { }), ); + // check old tokens were burned + setup + .b_mock + .check_nft_balance::>( + setup.proxy_wrapper.address_ref(), + WRAPPED_LP_TOKEN_ID, + 1, + &rust_biguint!(0u64), + None, + ); + // check user energy after setup .b_mock .execute_query(&setup.simple_lock_wrapper, |sc| { let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; - let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + let second_lock_epochs = + BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) * BigInt::from(first_lock_epochs as i64) - + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) * second_lock_epochs; + + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) + * second_lock_epochs; let expected_energy = Energy::new( expected_energy_amount, block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1163,7 +1191,7 @@ fn increase_proxy_lp_token_energy_partially_unlocked_tokens() { }), ); - let mut block_epoch = 1; + let block_epoch = 1; let user_locked_tokens_in_lp = locked_token_amount.to_u64().unwrap(); // check user energy before @@ -1178,18 +1206,12 @@ fn increase_proxy_lp_token_energy_partially_unlocked_tokens() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); - - // Wait for tokens to unlock - block_epoch += LOCK_OPTIONS[0] / 2; - - setup.b_mock.set_block_epoch(block_epoch); - - // call increase energy setup .b_mock @@ -1198,24 +1220,35 @@ fn increase_proxy_lp_token_energy_partially_unlocked_tokens() { &setup.proxy_wrapper, WRAPPED_LP_TOKEN_ID, 1, - &expected_lp_token_amount, + &(&expected_lp_token_amount / 2u64), |sc| { let _ = sc.increase_proxy_pair_token_energy_endpoint(LOCK_OPTIONS[1]); }, ) .assert_ok(); - // chceck new wrapped lp token + // check old tokens were burned + setup + .b_mock + .check_nft_balance::>( + setup.proxy_wrapper.address_ref(), + WRAPPED_LP_TOKEN_ID, + 1, + &rust_biguint!(0u64), + None, + ); + + // check remaining old wrapped lp token setup.b_mock.check_nft_balance( &first_user, WRAPPED_LP_TOKEN_ID, - 2, - &expected_lp_token_amount, + 1, + &(&expected_lp_token_amount / 2u64), Some(&WrappedLpTokenAttributes:: { locked_tokens: EsdtTokenPayment { token_identifier: managed_token_id!(LOCKED_TOKEN_ID), // Nonce increases - token_nonce: 3, + token_nonce: 1, amount: managed_biguint!(locked_token_amount.to_u64().unwrap()), }, lp_token_id: managed_token_id!(LP_TOKEN_ID), @@ -1223,29 +1256,47 @@ fn increase_proxy_lp_token_energy_partially_unlocked_tokens() { }), ); + // check new wrapped lp token + setup.b_mock.check_nft_balance( + &first_user, + WRAPPED_LP_TOKEN_ID, + 2, + &(&expected_lp_token_amount / 2u64), + Some(&WrappedLpTokenAttributes:: { + locked_tokens: EsdtTokenPayment { + token_identifier: managed_token_id!(LOCKED_TOKEN_ID), + token_nonce: 2, + amount: managed_biguint!(locked_token_amount.to_u64().unwrap() / 2u64), + }, + lp_token_id: managed_token_id!(LP_TOKEN_ID), + lp_token_amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 2u64), + }), + ); + // check user energy after setup .b_mock .execute_query(&setup.simple_lock_wrapper, |sc| { let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; - let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); + let second_lock_epochs = + BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); - let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) + let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp / 2u64) as i64) * BigInt::from(first_lock_epochs as i64) - + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) * second_lock_epochs; + + BigInt::from((USER_BALANCE) as i64) * second_lock_epochs.clone() + - BigInt::from((user_locked_tokens_in_lp / 2u64) as i64) * second_lock_epochs; let expected_energy = Energy::new( expected_energy_amount, block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); } - - #[test] fn increase_proxy_lp_legacy_token_energy() { let mut setup = ProxySetup::new( @@ -1330,7 +1381,8 @@ fn increase_proxy_lp_legacy_token_energy() { block_epoch, managed_biguint!(USER_BALANCE), ); - let actual_energy = sc.user_energy(&managed_address!(&first_user)).get(); + let actual_energy = + sc.get_updated_energy_entry_for_user(&managed_address!(&first_user)); assert_eq!(expected_energy, actual_energy); }) .assert_ok(); @@ -1349,4 +1401,4 @@ fn increase_proxy_lp_legacy_token_energy() { }, ) .assert_error(4, "Invalid payment"); -} \ No newline at end of file +} From 55088f88a9c755561a7459df2a17be3be10b9aa2 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 14 May 2024 15:33:01 +0300 Subject: [PATCH 049/103] proxy dex unit test scenario improvement --- locked-asset/proxy_dex/tests/proxy_farm_test.rs | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index af054dc93..7f7a23b60 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -2155,7 +2155,7 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { &setup.proxy_wrapper, WRAPPED_FARM_TOKEN_ID, 4, - &(&expected_lp_token_amount / &rust_biguint!(4u64)), + &(&expected_lp_token_amount / &rust_biguint!(8u64)), |sc| { sc.increase_proxy_farm_token_energy_endpoint(LOCK_OPTIONS[1]); }, @@ -2182,10 +2182,11 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { let first_lock_epochs = LOCK_OPTIONS[1] - 1u64; let second_lock_epochs = BigInt::from(LOCK_OPTIONS[0] as i64) - BigInt::from(block_epoch as i64); - let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp) as i64) + let expected_energy_amount = BigInt::from((user_locked_tokens_in_lp / 2) as i64) * BigInt::from(first_lock_epochs as i64) - + BigInt::from((USER_BALANCE - user_locked_tokens_in_lp) as i64) - * second_lock_epochs; + + BigInt::from((USER_BALANCE) as i64) * second_lock_epochs.clone() + - BigInt::from((user_locked_tokens_in_lp / 2u64) as i64) * second_lock_epochs; + let expected_energy = Energy::new( expected_energy_amount, block_epoch, @@ -2203,17 +2204,17 @@ fn increase_proxy_farm_proxy_lp_energy_partially_unlocked_tokens() { &first_user, WRAPPED_FARM_TOKEN_ID, 5, - &(&expected_lp_token_amount / &rust_biguint!(4u64)), + &(&expected_lp_token_amount / &rust_biguint!(8u64)), Some(&WrappedFarmTokenAttributes:: { proxy_farming_token: EsdtTokenPayment { token_identifier: managed_token_id!(WRAPPED_LP_TOKEN_ID), token_nonce: 3, - amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 4u64), + amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 8u64), }, farm_token: EsdtTokenPayment { token_identifier: managed_token_id!(FARM_LOCKED_TOKEN_ID), token_nonce: 4, - amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 4u64), + amount: managed_biguint!(expected_lp_token_amount.to_u64().unwrap() / 8u64), }, }), ); From b9ed86c1a76f2331225f349aab898df4b464f36b Mon Sep 17 00:00:00 2001 From: Sorin Petreasca <90727972+psorinionut@users.noreply.github.com> Date: Mon, 20 May 2024 11:29:50 +0300 Subject: [PATCH 050/103] Revert "farm energy fix" --- common/common_structs/src/farm_types.rs | 7 - .../contexts/src/claim_rewards_context.rs | 30 ++-- .../farm/contexts/src/enter_farm_context.rs | 28 +--- common/modules/farm/events/src/events.rs | 4 +- .../farm_base_impl/src/base_traits_impl.rs | 34 +++-- .../farm/farm_base_impl/src/claim_rewards.rs | 12 +- .../farm_base_impl/src/compound_rewards.rs | 10 +- .../farm/farm_base_impl/src/enter_farm.rs | 7 +- .../farm/farm_base_impl/src/exit_farm.rs | 2 +- common/modules/utils/src/lib.rs | 24 ++-- dex/farm-with-locked-rewards/src/lib.rs | 2 + dex/farm/src/base_functions.rs | 64 +-------- dex/farm/src/lib.rs | 2 + dex/farm/tests/energy_update_test.rs | 133 ------------------ .../farm-boosted-yields/src/lib.rs | 22 ++- .../farm-staking/src/base_impl_wrapper.rs | 58 ++++++++ .../src/claim_stake_farm_rewards.rs | 9 +- .../src/compound_stake_farm_rewards.rs | 11 +- .../farm-staking/src/delete_energy.rs | 46 ------ farm-staking/farm-staking/src/lib.rs | 15 +- farm-staking/farm-staking/src/stake_farm.rs | 6 - .../farm-staking/src/token_attributes.rs | 4 - farm-staking/farm-staking/src/unstake_farm.rs | 11 +- 23 files changed, 135 insertions(+), 406 deletions(-) delete mode 100644 farm-staking/farm-staking/src/delete_energy.rs diff --git a/common/common_structs/src/farm_types.rs b/common/common_structs/src/farm_types.rs index 676b26e36..d7d85e20b 100644 --- a/common/common_structs/src/farm_types.rs +++ b/common/common_structs/src/farm_types.rs @@ -80,8 +80,6 @@ pub trait FarmToken { fn get_compounded_rewards(&self) -> BigUint; fn get_initial_farming_tokens(&self) -> BigUint; - - fn get_original_owner(&self) -> ManagedAddress; } impl FarmToken for FarmTokenAttributes { @@ -99,9 +97,4 @@ impl FarmToken for FarmTokenAttributes { fn get_initial_farming_tokens(&self) -> BigUint { &self.current_farm_amount - &self.compounded_reward } - - #[inline] - fn get_original_owner(&self) -> ManagedAddress { - self.original_owner.clone() - } } diff --git a/common/modules/farm/contexts/src/claim_rewards_context.rs b/common/modules/farm/contexts/src/claim_rewards_context.rs index 78b8f4e67..653c6b2e6 100644 --- a/common/modules/farm/contexts/src/claim_rewards_context.rs +++ b/common/modules/farm/contexts/src/claim_rewards_context.rs @@ -2,28 +2,26 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use common_errors::{ERROR_BAD_PAYMENTS, ERROR_EMPTY_PAYMENTS}; -use common_structs::{PaymentAttributesPair, PaymentsVec}; +use common_structs::PaymentAttributesPair; use multiversx_sc::api::BlockchainApi; use multiversx_sc::contract_base::BlockchainWrapper; pub struct ClaimRewardsContext where M: ManagedTypeApi, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, { pub first_farm_token: PaymentAttributesPair, - pub additional_payments: PaymentsVec, - pub additional_attributes: ManagedVec, - pub all_attributes: ManagedVec, + pub additional_payments: ManagedVec>, } impl ClaimRewardsContext where M: ManagedTypeApi + BlockchainApi, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, { pub fn new( - mut payments: PaymentsVec, + mut payments: ManagedVec>, farm_token_id: &TokenIdentifier, api_wrapper: BlockchainWrapper, ) -> Self { @@ -31,32 +29,22 @@ where M::error_api_impl().signal_error(ERROR_EMPTY_PAYMENTS); } - let own_sc_address = api_wrapper.get_sc_address(); - let mut all_attributes = ManagedVec::new(); for p in &payments { if &p.token_identifier != farm_token_id { M::error_api_impl().signal_error(ERROR_BAD_PAYMENTS); } - - let token_data = - api_wrapper.get_esdt_token_data(&own_sc_address, farm_token_id, p.token_nonce); - let token_attributes: T = token_data.decode_attributes(); - all_attributes.push(token_attributes); } let first_payment = payments.get(0); payments.remove(0); - // dumb framework errors otherwise - let first_token_data = api_wrapper.get_esdt_token_data( + let own_sc_address = api_wrapper.get_sc_address(); + let token_data = api_wrapper.get_esdt_token_data( &own_sc_address, farm_token_id, first_payment.token_nonce, ); - let first_token_attributes: T = first_token_data.decode_attributes(); - - let mut additional_attributes = all_attributes.clone(); - additional_attributes.remove(0); + let first_token_attributes: T = token_data.decode_attributes(); ClaimRewardsContext { first_farm_token: PaymentAttributesPair { @@ -64,8 +52,6 @@ where attributes: first_token_attributes, }, additional_payments: payments, - additional_attributes, - all_attributes, } } } diff --git a/common/modules/farm/contexts/src/enter_farm_context.rs b/common/modules/farm/contexts/src/enter_farm_context.rs index 27a060015..9da789d9a 100644 --- a/common/modules/farm/contexts/src/enter_farm_context.rs +++ b/common/modules/farm/contexts/src/enter_farm_context.rs @@ -2,28 +2,17 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use common_errors::{ERROR_BAD_PAYMENTS, ERROR_EMPTY_PAYMENTS}; -use common_structs::PaymentsVec; -use multiversx_sc::{api::BlockchainApi, contract_base::BlockchainWrapper}; -pub struct EnterFarmContext< - M: ManagedTypeApi, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, -> { +pub struct EnterFarmContext { pub farming_token_payment: EsdtTokenPayment, - pub additional_farm_tokens: PaymentsVec, - pub additional_attributes: ManagedVec, + pub additional_farm_tokens: ManagedVec>, } -impl< - M: ManagedTypeApi + BlockchainApi, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, - > EnterFarmContext -{ +impl EnterFarmContext { pub fn new( - mut payments: PaymentsVec, + mut payments: ManagedVec>, farming_token_id: &TokenIdentifier, farm_token_id: &TokenIdentifier, - api_wrapper: BlockchainWrapper, ) -> Self { if payments.is_empty() { M::error_api_impl().signal_error(ERROR_EMPTY_PAYMENTS); @@ -35,24 +24,15 @@ impl< } payments.remove(0); - - let own_sc_address = api_wrapper.get_sc_address(); - let mut additional_attributes = ManagedVec::new(); for p in &payments { if &p.token_identifier != farm_token_id { M::error_api_impl().signal_error(ERROR_BAD_PAYMENTS); } - - let token_data = - api_wrapper.get_esdt_token_data(&own_sc_address, farm_token_id, p.token_nonce); - let token_attributes: T = token_data.decode_attributes(); - additional_attributes.push(token_attributes); } EnterFarmContext { farming_token_payment, additional_farm_tokens: payments, - additional_attributes, } } } diff --git a/common/modules/farm/events/src/events.rs b/common/modules/farm/events/src/events.rs index 6b55fed0c..c32988130 100644 --- a/common/modules/farm/events/src/events.rs +++ b/common/modules/farm/events/src/events.rs @@ -142,7 +142,7 @@ pub trait EventsModule { fn emit_claim_rewards_event< 'a, C: FarmContracTraitBounds, - AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, >( &self, original_caller: &ManagedAddress, @@ -189,7 +189,7 @@ pub trait EventsModule { fn emit_compound_rewards_event< 'a, C: FarmContracTraitBounds, - AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + AttributesType: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, >( self, original_caller: &ManagedAddress, diff --git a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs index 7fdb6cdc3..f2ccc293c 100644 --- a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs +++ b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs @@ -1,11 +1,12 @@ multiversx_sc::imports!(); -use common_structs::{FarmToken, FarmTokenAttributes, Nonce, PaymentsVec}; +use common_structs::{FarmToken, FarmTokenAttributes, Nonce}; use config::ConfigModule; use contexts::storage_cache::StorageCache; use core::marker::PhantomData; use fixed_supply_token::FixedSupplyToken; use mergeable::Mergeable; +use multiversx_sc_modules::transfer_role_proxy::PaymentsVec; use rewards::RewardsModule; pub trait AllBaseFarmImplTraits = @@ -29,8 +30,8 @@ pub trait FarmContract { + FixedSupplyToken<::Api> + FarmToken<::Api> + From::Api>> - + Into::Api>> - + ManagedVecItem = FarmTokenAttributes<::Api>; + + Into::Api>> = + FarmTokenAttributes<::Api>; #[inline] fn mint_rewards( @@ -191,21 +192,27 @@ pub trait FarmContract { fn check_and_update_user_farm_position( sc: &Self::FarmSc, user: &ManagedAddress<::Api>, - farm_tokens: &PaymentsVec<::Api>, - farm_attributes: &ManagedVec<::Api, Self::AttributesType>, + farm_positions: &PaymentsVec<::Api>, ) { - for (attr, farm_token) in farm_attributes.into_iter().zip(farm_tokens.iter()) { - if sc.is_old_farm_position(farm_token.token_nonce) { + let farm_token_mapper = sc.farm_token(); + for farm_position in farm_positions { + farm_token_mapper.require_same_token(&farm_position.token_identifier); + + if sc.is_old_farm_position(farm_position.token_nonce) { continue; } - if &attr.get_original_owner() != user { - Self::decrease_user_farm_position(sc, &farm_token, &attr); - Self::increase_user_farm_position(sc, user, &farm_token.amount); + let token_attributes: FarmTokenAttributes<::Api> = + farm_token_mapper.get_token_attributes(farm_position.token_nonce); + + if &token_attributes.original_owner != user { + Self::decrease_user_farm_position(sc, &farm_position); + Self::increase_user_farm_position(sc, user, &farm_position.amount); } } } + #[inline] fn increase_user_farm_position( sc: &Self::FarmSc, user: &ManagedAddress<::Api>, @@ -220,13 +227,16 @@ pub trait FarmContract { fn decrease_user_farm_position( sc: &Self::FarmSc, farm_position: &EsdtTokenPayment<::Api>, - attributes: &Self::AttributesType, ) { if sc.is_old_farm_position(farm_position.token_nonce) { return; } - sc.user_total_farm_position(&attributes.get_original_owner()) + let farm_token_mapper = sc.farm_token(); + let token_attributes: FarmTokenAttributes<::Api> = + farm_token_mapper.get_token_attributes(farm_position.token_nonce); + + sc.user_total_farm_position(&token_attributes.original_owner) .update(|user_total_farm_position| { if user_total_farm_position.total_farm_position > farm_position.amount { user_total_farm_position.total_farm_position -= &farm_position.amount; diff --git a/common/modules/farm/farm_base_impl/src/claim_rewards.rs b/common/modules/farm/farm_base_impl/src/claim_rewards.rs index 30b943089..d9dfe293e 100644 --- a/common/modules/farm/farm_base_impl/src/claim_rewards.rs +++ b/common/modules/farm/farm_base_impl/src/claim_rewards.rs @@ -11,7 +11,7 @@ use fixed_supply_token::FixedSupplyToken; pub struct InternalClaimRewardsResult<'a, C, T> where C: FarmContracTraitBounds, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, { pub context: ClaimRewardsContext, pub storage_cache: StorageCache<'a, C>, @@ -81,12 +81,7 @@ pub trait BaseClaimRewardsModule: ); storage_cache.reward_reserve -= &reward; - FC::check_and_update_user_farm_position( - self, - &caller, - &payments, - &claim_rewards_context.all_attributes, - ); + FC::check_and_update_user_farm_position(self, &caller, &payments); let farm_token_mapper = self.farm_token(); let base_attributes = FC::create_claim_rewards_initial_attributes( @@ -95,11 +90,10 @@ pub trait BaseClaimRewardsModule: token_attributes, storage_cache.reward_per_share.clone(), ); - let new_token_attributes = self.merge_attributes_from_payments( base_attributes, - &claim_rewards_context.additional_attributes, &claim_rewards_context.additional_payments, + &farm_token_mapper, ); let new_farm_token = PaymentAttributesPair { payment: EsdtTokenPayment::new( diff --git a/common/modules/farm/farm_base_impl/src/compound_rewards.rs b/common/modules/farm/farm_base_impl/src/compound_rewards.rs index 530f732c0..06e52585c 100644 --- a/common/modules/farm/farm_base_impl/src/compound_rewards.rs +++ b/common/modules/farm/farm_base_impl/src/compound_rewards.rs @@ -12,7 +12,7 @@ use fixed_supply_token::FixedSupplyToken; pub struct InternalCompoundRewardsResult<'a, C, T> where C: FarmContracTraitBounds, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, { pub context: CompoundRewardsContext, pub storage_cache: StorageCache<'a, C>, @@ -70,12 +70,7 @@ pub trait BaseCompoundRewardsModule: storage_cache.reward_reserve -= &reward; storage_cache.farm_token_supply += &reward; - FC::check_and_update_user_farm_position( - self, - &caller, - &payments, - &compound_rewards_context.all_attributes, - ); + FC::check_and_update_user_farm_position(self, &caller, &payments); let farm_token_mapper = self.farm_token(); let base_attributes = FC::create_compound_rewards_initial_attributes( @@ -87,7 +82,6 @@ pub trait BaseCompoundRewardsModule: ); let new_farm_token = self.merge_and_create_token( base_attributes, - &compound_rewards_context.additional_attributes, &compound_rewards_context.additional_payments, &farm_token_mapper, ); diff --git a/common/modules/farm/farm_base_impl/src/enter_farm.rs b/common/modules/farm/farm_base_impl/src/enter_farm.rs index 850606829..02e20d42a 100644 --- a/common/modules/farm/farm_base_impl/src/enter_farm.rs +++ b/common/modules/farm/farm_base_impl/src/enter_farm.rs @@ -10,9 +10,9 @@ use contexts::{ pub struct InternalEnterFarmResult<'a, C, T> where C: FarmContracTraitBounds, - T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode + ManagedVecItem, + T: Clone + TopEncode + TopDecode + NestedEncode + NestedDecode, { - pub context: EnterFarmContext, + pub context: EnterFarmContext, pub storage_cache: StorageCache<'a, C>, pub new_farm_token: PaymentAttributesPair, pub created_with_merge: bool, @@ -42,7 +42,6 @@ pub trait BaseEnterFarmModule: payments, &storage_cache.farming_token_id, &storage_cache.farm_token_id, - self.blockchain(), ); // The order is important - first check and update, then increase position @@ -50,7 +49,6 @@ pub trait BaseEnterFarmModule: self, &caller, &enter_farm_context.additional_farm_tokens, - &enter_farm_context.additional_attributes, ); FC::increase_user_farm_position( self, @@ -71,7 +69,6 @@ pub trait BaseEnterFarmModule: ); let new_farm_token = self.merge_and_create_token( base_attributes, - &enter_farm_context.additional_attributes, &enter_farm_context.additional_farm_tokens, &farm_token_mapper, ); diff --git a/common/modules/farm/farm_base_impl/src/exit_farm.rs b/common/modules/farm/farm_base_impl/src/exit_farm.rs index 30d420787..315abe421 100644 --- a/common/modules/farm/farm_base_impl/src/exit_farm.rs +++ b/common/modules/farm/farm_base_impl/src/exit_farm.rs @@ -62,7 +62,7 @@ pub trait BaseExitFarmModule: ); storage_cache.reward_reserve -= &reward; - FC::decrease_user_farm_position(self, &payment, &exit_farm_context.farm_token.attributes); + FC::decrease_user_farm_position(self, &payment); let farming_token_amount = token_attributes.get_total_supply(); let farming_token_payment = EsdtTokenPayment::new( diff --git a/common/modules/utils/src/lib.rs b/common/modules/utils/src/lib.rs index 9077b7203..990b88329 100644 --- a/common/modules/utils/src/lib.rs +++ b/common/modules/utils/src/lib.rs @@ -57,7 +57,7 @@ pub trait UtilsModule { } fn merge_from_payments_and_burn< - T: FixedSupplyToken + Mergeable + TopDecode + ManagedVecItem, + T: FixedSupplyToken + Mergeable + TopDecode, >( &self, mut payments: PaymentsVec, @@ -68,29 +68,23 @@ pub trait UtilsModule { self.get_attributes_as_part_of_fixed_supply(&first_payment, mapper); mapper.nft_burn(first_payment.token_nonce, &first_payment.amount); - let mut other_attributes = ManagedVec::new(); - for payment in &payments { - let attr = mapper.get_token_attributes(payment.token_nonce); - other_attributes.push(attr); - } - let output_attributes = - self.merge_attributes_from_payments(base_attributes, &other_attributes, &payments); + self.merge_attributes_from_payments(base_attributes, &payments, mapper); self.send().esdt_local_burn_multi(&payments); output_attributes } fn merge_attributes_from_payments< - T: FixedSupplyToken + Mergeable + TopDecode + ManagedVecItem, + T: FixedSupplyToken + Mergeable + TopDecode, >( &self, mut base_attributes: T, - other_attributes: &ManagedVec, payments: &PaymentsVec, + mapper: &NonFungibleTokenMapper, ) -> T { - for (attr, payment) in other_attributes.into_iter().zip(payments.iter()) { - let attributes = attr.into_part(&payment.amount); + for payment in payments { + let attributes: T = self.get_attributes_as_part_of_fixed_supply(&payment, mapper); base_attributes.merge_with(attributes); } @@ -104,17 +98,15 @@ pub trait UtilsModule { + TopEncode + TopDecode + NestedEncode - + NestedDecode - + ManagedVecItem, + + NestedDecode, >( &self, base_attributes: T, - other_attributes: &ManagedVec, payments: &PaymentsVec, mapper: &NonFungibleTokenMapper, ) -> PaymentAttributesPair { let output_attributes = - self.merge_attributes_from_payments(base_attributes, other_attributes, payments); + self.merge_attributes_from_payments(base_attributes, payments, mapper); let new_token_amount = output_attributes.get_total_supply(); let new_token_payment = mapper.nft_create(new_token_amount, &output_attributes); diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index 34600f80b..d704a80df 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -182,6 +182,8 @@ pub trait Farm: orig_caller.clone(), ); + self.clear_user_energy_if_needed(&orig_caller); + (exit_farm_result.farming_tokens, locked_rewards_payment).into() } diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index 16704331d..48a59ac56 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -7,9 +7,7 @@ multiversx_sc::derive_imports!(); use core::marker::PhantomData; use common_errors::ERROR_ZERO_AMOUNT; -use common_structs::FarmToken; use common_structs::FarmTokenAttributes; -use common_structs::PaymentsVec; use contexts::storage_cache::StorageCache; use farm_base_impl::base_traits_impl::{DefaultFarmWrapper, FarmContract}; @@ -83,11 +81,6 @@ pub trait BaseFunctionsModule: &base_enter_farm_result.storage_cache.farm_token_supply, ); - self.delete_user_energy_if_needed::( - &base_enter_farm_result.context.additional_farm_tokens, - &base_enter_farm_result.context.additional_attributes, - ); - self.emit_enter_farm_event( &caller, base_enter_farm_result.context.farming_token_payment, @@ -104,8 +97,7 @@ pub trait BaseFunctionsModule: caller: ManagedAddress, ) -> ClaimRewardsResultWrapper { let payments = self.call_value().all_esdt_transfers().clone_value(); - let base_claim_rewards_result = - self.claim_rewards_base::(caller.clone(), payments.clone()); + let base_claim_rewards_result = self.claim_rewards_base::(caller.clone(), payments); let output_farm_token_payment = base_claim_rewards_result.new_farm_token.payment.clone(); let rewards_payment = base_claim_rewards_result.rewards; @@ -114,11 +106,6 @@ pub trait BaseFunctionsModule: &base_claim_rewards_result.storage_cache.farm_token_supply, ); - self.delete_user_energy_if_needed::( - &payments, - &base_claim_rewards_result.context.all_attributes, - ); - self.emit_claim_rewards_event( &caller, base_claim_rewards_result.context, @@ -140,7 +127,7 @@ pub trait BaseFunctionsModule: ) -> EsdtTokenPayment { let payments = self.call_value().all_esdt_transfers().clone_value(); let base_compound_rewards_result = - self.compound_rewards_base::(caller.clone(), payments.clone()); + self.compound_rewards_base::(caller.clone(), payments); let output_farm_token_payment = base_compound_rewards_result.new_farm_token.payment.clone(); @@ -148,11 +135,6 @@ pub trait BaseFunctionsModule: &base_compound_rewards_result.storage_cache.farm_token_supply, ); - self.delete_user_energy_if_needed::( - &payments, - &base_compound_rewards_result.context.all_attributes, - ); - self.emit_compound_rewards_event( &caller, base_compound_rewards_result.context, @@ -170,7 +152,7 @@ pub trait BaseFunctionsModule: caller: ManagedAddress, payment: EsdtTokenPayment, ) -> ExitFarmResultWrapper { - let base_exit_farm_result = self.exit_farm_base::(caller.clone(), payment.clone()); + let base_exit_farm_result = self.exit_farm_base::(caller.clone(), payment); let mut farming_token_payment = base_exit_farm_result.farming_token_payment; let reward_payment = base_exit_farm_result.reward_payment; @@ -179,13 +161,6 @@ pub trait BaseFunctionsModule: &base_exit_farm_result.storage_cache.farm_token_supply, ); - self.delete_user_energy_if_needed::( - &ManagedVec::from_single_item(payment), - &ManagedVec::from_single_item( - base_exit_farm_result.context.farm_token.attributes.clone(), - ), - ); - FC::apply_penalty( self, &mut farming_token_payment.amount, @@ -213,18 +188,9 @@ pub trait BaseFunctionsModule: ) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); + token_mapper.require_all_same_token(&payments); - let mut all_attributes = ManagedVec::new(); - for payment in &payments { - token_mapper.require_same_token(&payment.token_identifier); - - let attr = token_mapper.get_token_attributes(payment.token_nonce); - all_attributes.push(attr); - } - - self.delete_user_energy_if_needed::(&payments, &all_attributes); - - FC::check_and_update_user_farm_position(self, orig_caller, &payments, &all_attributes); + FC::check_and_update_user_farm_position(self, orig_caller, &payments); self.merge_from_payments_and_burn(payments, &token_mapper) } @@ -287,26 +253,6 @@ pub trait BaseFunctionsModule: self.per_block_reward_amount().set(&per_block_amount); } - fn delete_user_energy_if_needed>( - &self, - payments: &PaymentsVec, - all_attributes: &ManagedVec, - ) { - let mut processed_users = ManagedMap::new(); - for (payment, attr) in payments.iter().zip(all_attributes.into_iter()) { - let original_owner = attr.get_original_owner(); - if processed_users.contains(original_owner.as_managed_buffer()) - || self.is_old_farm_position(payment.token_nonce) - { - continue; - } - - self.clear_user_energy_if_needed(&original_owner); - - processed_users.put(original_owner.as_managed_buffer(), &ManagedBuffer::new()); - } - } - fn require_queried(&self) { let caller = self.blockchain().get_caller(); let sc_address = self.blockchain().get_sc_address(); diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 5bf5dba64..1a35c1631 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -177,6 +177,8 @@ pub trait Farm: self.send_payment_non_zero(&caller, &exit_farm_result.farming_tokens); self.send_payment_non_zero(&caller, &exit_farm_result.rewards); + self.clear_user_energy_if_needed(&orig_caller); + (exit_farm_result.farming_tokens, exit_farm_result.rewards).into() } diff --git a/dex/farm/tests/energy_update_test.rs b/dex/farm/tests/energy_update_test.rs index e091a028e..1d8f78a98 100644 --- a/dex/farm/tests/energy_update_test.rs +++ b/dex/farm/tests/energy_update_test.rs @@ -2,14 +2,7 @@ mod farm_setup; -use common_structs::FarmTokenAttributes; -use farm::Farm; use farm_setup::multi_user_farm_setup::*; -use multiversx_sc::imports::OptionalValue; -use multiversx_sc_scenario::{ - managed_biguint, rust_biguint, whitebox_legacy::TxTokenTransfer, DebugApi, -}; -use weekly_rewards_splitting::global_info::WeeklyRewardsGlobalInfo; #[test] fn test_farm_setup() { @@ -60,129 +53,3 @@ fn test_energy_update_no_claim_current_week() { farm_setup.update_energy_for_user(); farm_setup.check_farm_claim_progress_energy(0); } - -#[test] -fn enter_farm_other_users_pos_test() { - DebugApi::dummy(); - - let mut farm_setup = MultiUserFarmSetup::new( - farm::contract_obj, - energy_factory_mock::contract_obj, - energy_update::contract_obj, - ); - - let first_farm_token_amount = 100_000_000; - let first_user = farm_setup.first_user.clone(); - let second_user = farm_setup.second_user.clone(); - - let first_user_energy_amount = 1_000; - let second_user_energy_amount = 5_000; - farm_setup.set_user_energy(&first_user, first_user_energy_amount, 13, 1); - farm_setup.set_user_energy(&second_user, second_user_energy_amount, 13, 1); - - farm_setup.enter_farm(&first_user, first_farm_token_amount); - - let token_attributes: FarmTokenAttributes = farm_setup - .b_mock - .get_nft_attributes(&first_user, FARM_TOKEN_ID, 1) - .unwrap(); - - // first user transfer pos to second user - farm_setup.b_mock.set_nft_balance( - &second_user, - FARM_TOKEN_ID, - 1, - &rust_biguint!(first_farm_token_amount), - &token_attributes, - ); - farm_setup.b_mock.set_nft_balance( - &first_user, - FARM_TOKEN_ID, - 1, - &rust_biguint!(0), - &token_attributes, - ); - - let transfers = [ - TxTokenTransfer { - token_identifier: FARMING_TOKEN_ID.to_vec(), - nonce: 0, - value: rust_biguint!(1_000), - }, - TxTokenTransfer { - token_identifier: FARM_TOKEN_ID.to_vec(), - nonce: 1, - value: rust_biguint!(first_farm_token_amount), - }, - ]; - - farm_setup - .b_mock - .execute_esdt_multi_transfer(&second_user, &farm_setup.farm_wrapper, &transfers, |sc| { - sc.enter_farm_endpoint(OptionalValue::None); - - let actual_energy = sc.total_energy_for_week(1).get(); - assert_eq!(actual_energy, managed_biguint!(second_user_energy_amount)); - }) - .assert_ok(); -} - -#[test] -fn exit_other_users_pos_test() { - DebugApi::dummy(); - - let mut farm_setup = MultiUserFarmSetup::new( - farm::contract_obj, - energy_factory_mock::contract_obj, - energy_update::contract_obj, - ); - - let first_farm_token_amount = 100_000_000; - let first_user = farm_setup.first_user.clone(); - let second_user = farm_setup.second_user.clone(); - - let first_user_energy_amount = 1_000; - let second_user_energy_amount = 200; - farm_setup.set_user_energy(&first_user, first_user_energy_amount, 13, 1); - farm_setup.set_user_energy(&second_user, second_user_energy_amount, 13, 1); - - farm_setup.enter_farm(&first_user, first_farm_token_amount); - - let token_attributes: FarmTokenAttributes = farm_setup - .b_mock - .get_nft_attributes(&first_user, FARM_TOKEN_ID, 1) - .unwrap(); - - // first user transfer pos to second user - farm_setup.b_mock.set_nft_balance( - &second_user, - FARM_TOKEN_ID, - 1, - &rust_biguint!(first_farm_token_amount), - &token_attributes, - ); - farm_setup.b_mock.set_nft_balance( - &first_user, - FARM_TOKEN_ID, - 1, - &rust_biguint!(0), - &token_attributes, - ); - - farm_setup - .b_mock - .execute_esdt_transfer( - &second_user, - &farm_setup.farm_wrapper, - FARM_TOKEN_ID, - 1, - &rust_biguint!(first_farm_token_amount), - |sc| { - sc.exit_farm_endpoint(OptionalValue::None); - - let actual_energy = sc.total_energy_for_week(1).get(); - assert_eq!(actual_energy, managed_biguint!(0)); - }, - ) - .assert_ok(); -} diff --git a/energy-integration/farm-boosted-yields/src/lib.rs b/energy-integration/farm-boosted-yields/src/lib.rs index 0c8543132..09bacc676 100644 --- a/energy-integration/farm-boosted-yields/src/lib.rs +++ b/energy-integration/farm-boosted-yields/src/lib.rs @@ -15,7 +15,6 @@ use weekly_rewards_splitting::{ pub mod boosted_yields_factors; const MAX_PERCENT: u64 = 10_000; -const DEFAULT_MIN_FARM_AMT: u64 = 1; pub struct SplitReward { pub base_farm: BigUint, @@ -125,19 +124,14 @@ pub trait FarmBoostedYieldsModule: fn clear_user_energy_if_needed(&self, original_caller: &ManagedAddress) { let opt_config = self.try_get_boosted_yields_config(); let user_total_farm_position = self.get_user_total_farm_position(original_caller); - let min_farm_amount = match opt_config { - Some(config) => { - let boosted_yields_factors = config.get_latest_factors(); - boosted_yields_factors.min_farm_amount.clone() - } - None => BigUint::from(DEFAULT_MIN_FARM_AMT), - }; - - self.clear_user_energy( - original_caller, - &user_total_farm_position.total_farm_position, - &min_farm_amount, - ); + if let Some(config) = opt_config { + let boosted_yields_factors = config.get_latest_factors(); + self.clear_user_energy( + original_caller, + &user_total_farm_position.total_farm_position, + &boosted_yields_factors.min_farm_amount, + ); + } } #[view(getBoostedYieldsRewardsPercentage)] diff --git a/farm-staking/farm-staking/src/base_impl_wrapper.rs b/farm-staking/farm-staking/src/base_impl_wrapper.rs index da30a1c84..2b671677f 100644 --- a/farm-staking/farm-staking/src/base_impl_wrapper.rs +++ b/farm-staking/farm-staking/src/base_impl_wrapper.rs @@ -5,6 +5,7 @@ use core::marker::PhantomData; use common_structs::FarmToken; use contexts::storage_cache::StorageCache; use farm_base_impl::base_traits_impl::FarmContract; +use multiversx_sc_modules::transfer_role_proxy::PaymentsVec; use crate::token_attributes::StakingFarmTokenAttributes; @@ -183,4 +184,61 @@ where original_owner: caller, } } + + fn check_and_update_user_farm_position( + sc: &Self::FarmSc, + user: &ManagedAddress<::Api>, + farm_positions: &PaymentsVec<::Api>, + ) { + let farm_token_mapper = sc.farm_token(); + for farm_position in farm_positions { + if sc.is_old_farm_position(farm_position.token_nonce) { + continue; + } + + farm_token_mapper.require_same_token(&farm_position.token_identifier); + + let token_attributes: StakingFarmTokenAttributes<::Api> = + farm_token_mapper.get_token_attributes(farm_position.token_nonce); + + if &token_attributes.original_owner != user { + Self::decrease_user_farm_position(sc, &farm_position); + Self::increase_user_farm_position(sc, user, &farm_position.amount); + } + } + } + + #[inline] + fn increase_user_farm_position( + sc: &Self::FarmSc, + user: &ManagedAddress<::Api>, + increase_farm_position_amount: &BigUint<::Api>, + ) { + let mut user_total_farm_position = sc.get_user_total_farm_position(user); + user_total_farm_position.total_farm_position += increase_farm_position_amount; + sc.user_total_farm_position(user) + .set(user_total_farm_position); + } + + fn decrease_user_farm_position( + sc: &Self::FarmSc, + farm_position: &EsdtTokenPayment<::Api>, + ) { + if sc.is_old_farm_position(farm_position.token_nonce) { + return; + } + + let farm_token_mapper = sc.farm_token(); + let token_attributes: StakingFarmTokenAttributes<::Api> = + farm_token_mapper.get_token_attributes(farm_position.token_nonce); + + sc.user_total_farm_position(&token_attributes.original_owner) + .update(|user_total_farm_position| { + if user_total_farm_position.total_farm_position > farm_position.amount { + user_total_farm_position.total_farm_position -= &farm_position.amount; + } else { + user_total_farm_position.total_farm_position = BigUint::zero(); + } + }); + } } diff --git a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs index 53050ba98..93d4802ea 100644 --- a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs @@ -30,7 +30,6 @@ pub trait ClaimStakeFarmRewardsModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule - + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(claimRewards)] @@ -63,12 +62,11 @@ pub trait ClaimStakeFarmRewardsModule: opt_new_farming_amount: Option, ) -> ClaimRewardsResultType { self.migrate_old_farm_positions(&original_caller); - let payment = self.call_value().single_esdt(); let mut claim_result = self .claim_rewards_base_no_farm_token_mint::>( original_caller.clone(), - ManagedVec::from_single_item(payment.clone()), + ManagedVec::from_single_item(payment), ); let mut virtual_farm_token = claim_result.new_farm_token.clone(); @@ -88,11 +86,6 @@ pub trait ClaimStakeFarmRewardsModule: self.set_farm_supply_for_current_week(&claim_result.storage_cache.farm_token_supply); } - self.delete_user_energy_if_needed::>( - &ManagedVec::from_single_item(payment), - &claim_result.context.all_attributes, - ); - self.update_energy_and_progress(&original_caller); let new_farm_token_nonce = self.send().esdt_nft_create_compact( diff --git a/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs b/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs index cd8df29a9..a7d83d574 100644 --- a/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/compound_stake_farm_rewards.rs @@ -28,28 +28,21 @@ pub trait CompoundStakeFarmRewardsModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule - + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(compoundRewards)] fn compound_rewards(&self) -> EsdtTokenPayment { let caller = self.blockchain().get_caller(); self.migrate_old_farm_positions(&caller); - let payments = self.get_non_empty_payments(); - let compound_result = self - .compound_rewards_base::>(caller.clone(), payments.clone()); + let compound_result = + self.compound_rewards_base::>(caller.clone(), payments); let new_farm_token = compound_result.new_farm_token.payment.clone(); self.send_payment_non_zero(&caller, &new_farm_token); self.set_farm_supply_for_current_week(&compound_result.storage_cache.farm_token_supply); - self.delete_user_energy_if_needed::>( - &payments, - &compound_result.context.all_attributes, - ); - self.emit_compound_rewards_event( &caller, compound_result.context, diff --git a/farm-staking/farm-staking/src/delete_energy.rs b/farm-staking/farm-staking/src/delete_energy.rs deleted file mode 100644 index 7c80412eb..000000000 --- a/farm-staking/farm-staking/src/delete_energy.rs +++ /dev/null @@ -1,46 +0,0 @@ -use common_structs::{FarmToken, PaymentsVec}; -use farm_base_impl::base_traits_impl::FarmContract; - -multiversx_sc::imports!(); - -#[multiversx_sc::module] -pub trait DeleteEnergyModule: - rewards::RewardsModule - + config::ConfigModule - + token_send::TokenSendModule - + farm_token::FarmTokenModule - + pausable::PausableModule - + permissions_module::PermissionsModule - + events::EventsModule - + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule - + utils::UtilsModule - + farm_boosted_yields::FarmBoostedYieldsModule - + farm_boosted_yields::boosted_yields_factors::BoostedYieldsFactorsModule - + week_timekeeping::WeekTimekeepingModule - + weekly_rewards_splitting::WeeklyRewardsSplittingModule - + weekly_rewards_splitting::events::WeeklyRewardsSplittingEventsModule - + weekly_rewards_splitting::global_info::WeeklyRewardsGlobalInfo - + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule - + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule - + energy_query::EnergyQueryModule -{ - fn delete_user_energy_if_needed>( - &self, - payments: &PaymentsVec, - all_attributes: &ManagedVec, - ) { - let mut processed_users = ManagedMap::new(); - for (payment, attr) in payments.iter().zip(all_attributes.into_iter()) { - let original_owner = attr.get_original_owner(); - if processed_users.contains(original_owner.as_managed_buffer()) - || self.is_old_farm_position(payment.token_nonce) - { - continue; - } - - self.clear_user_energy_if_needed(&original_owner); - - processed_users.put(original_owner.as_managed_buffer(), &ManagedBuffer::new()); - } - } -} diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index 589748364..5fd2b28d6 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -19,7 +19,6 @@ pub mod claim_only_boosted_staking_rewards; pub mod claim_stake_farm_rewards; pub mod compound_stake_farm_rewards; pub mod custom_rewards; -pub mod delete_energy; pub mod farm_token_roles; pub mod stake_farm; pub mod token_attributes; @@ -61,7 +60,6 @@ pub trait FarmStaking: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule - + delete_energy::DeleteEnergyModule { #[init] fn init( @@ -143,18 +141,9 @@ pub trait FarmStaking: ) -> FC::AttributesType { let payments = self.get_non_empty_payments(); let token_mapper = self.farm_token(); + token_mapper.require_all_same_token(&payments); - let mut all_attributes = ManagedVec::new(); - for payment in &payments { - token_mapper.require_same_token(&payment.token_identifier); - - let attr = token_mapper.get_token_attributes(payment.token_nonce); - all_attributes.push(attr); - } - - self.delete_user_energy_if_needed::(&payments, &all_attributes); - - FC::check_and_update_user_farm_position(self, orig_caller, &payments, &all_attributes); + FC::check_and_update_user_farm_position(self, orig_caller, &payments); self.merge_from_payments_and_burn(payments, &token_mapper) } diff --git a/farm-staking/farm-staking/src/stake_farm.rs b/farm-staking/farm-staking/src/stake_farm.rs index a022b689d..7ab3dea1c 100644 --- a/farm-staking/farm-staking/src/stake_farm.rs +++ b/farm-staking/farm-staking/src/stake_farm.rs @@ -31,7 +31,6 @@ pub trait StakeFarmModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule - + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(stakeFarmThroughProxy)] @@ -87,11 +86,6 @@ pub trait StakeFarmModule: self.set_farm_supply_for_current_week(&enter_result.storage_cache.farm_token_supply); - self.delete_user_energy_if_needed::>( - &enter_result.context.additional_farm_tokens, - &enter_result.context.additional_attributes, - ); - self.update_energy_and_progress(&original_caller); self.emit_enter_farm_event( diff --git a/farm-staking/farm-staking/src/token_attributes.rs b/farm-staking/farm-staking/src/token_attributes.rs index 0fcabeba3..59f8c6326 100644 --- a/farm-staking/farm-staking/src/token_attributes.rs +++ b/farm-staking/farm-staking/src/token_attributes.rs @@ -82,10 +82,6 @@ impl FarmToken for StakingFarmTokenAttributes { fn get_initial_farming_tokens(&self) -> BigUint { &self.current_farm_amount - &self.compounded_reward } - - fn get_original_owner(&self) -> ManagedAddress { - self.original_owner.clone() - } } impl FixedSupplyToken for StakingFarmTokenAttributes { diff --git a/farm-staking/farm-staking/src/unstake_farm.rs b/farm-staking/farm-staking/src/unstake_farm.rs index 1d40cfd15..e40642b4f 100644 --- a/farm-staking/farm-staking/src/unstake_farm.rs +++ b/farm-staking/farm-staking/src/unstake_farm.rs @@ -30,7 +30,6 @@ pub trait UnstakeFarmModule: + weekly_rewards_splitting::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + weekly_rewards_splitting::update_claim_progress_energy::UpdateClaimProgressEnergyModule + energy_query::EnergyQueryModule - + crate::delete_energy::DeleteEnergyModule { #[payable("*")] #[endpoint(unstakeFarm)] @@ -75,8 +74,8 @@ pub trait UnstakeFarmModule: ) -> ExitFarmWithPartialPosResultType { let migrated_amount = self.migrate_old_farm_positions(&original_caller); - let exit_result = self - .exit_farm_base::>(original_caller.clone(), payment.clone()); + let exit_result = + self.exit_farm_base::>(original_caller.clone(), payment); self.decrease_old_farm_positions(migrated_amount, &original_caller); @@ -90,13 +89,9 @@ pub trait UnstakeFarmModule: self.send_payment_non_zero(&caller, &exit_result.reward_payment); + self.clear_user_energy_if_needed(&original_caller); self.set_farm_supply_for_current_week(&exit_result.storage_cache.farm_token_supply); - self.delete_user_energy_if_needed::>( - &ManagedVec::from_single_item(payment), - &ManagedVec::from_single_item(exit_result.context.farm_token.attributes.clone()), - ); - self.emit_exit_farm_event( &caller, exit_result.context, From 497a61f246f1b5b8bd903d138f537e04c9f013c3 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 20 May 2024 12:44:56 +0300 Subject: [PATCH 051/103] framework upgrade 0.48.1 --- Cargo.lock | 28 +++++++++---------- common/common_errors/Cargo.toml | 2 +- common/common_structs/Cargo.toml | 2 +- common/modules/farm/config/Cargo.toml | 2 +- common/modules/farm/contexts/Cargo.toml | 4 +-- common/modules/farm/events/Cargo.toml | 2 +- common/modules/farm/farm_base_impl/Cargo.toml | 6 ++-- common/modules/farm/farm_token/Cargo.toml | 4 +-- .../modules/farm/farm_token_merge/Cargo.toml | 4 +-- common/modules/farm/rewards/Cargo.toml | 4 +-- .../legacy_token_decode_module/Cargo.toml | 2 +- common/modules/locking_module/Cargo.toml | 2 +- common/modules/math/Cargo.toml | 2 +- common/modules/pausable/Cargo.toml | 2 +- common/modules/permissions_module/Cargo.toml | 2 +- common/modules/sc_whitelist_module/Cargo.toml | 2 +- common/modules/token_merge_helper/Cargo.toml | 2 +- common/modules/token_send/Cargo.toml | 2 +- common/modules/utils/Cargo.toml | 2 +- common/traits/fixed-supply-token/Cargo.toml | 2 +- common/traits/mergeable/Cargo.toml | 2 +- common/traits/unwrappable/Cargo.toml | 2 +- dex/Cargo.toml | 6 ++-- dex/farm-with-locked-rewards/Cargo.toml | 6 ++-- dex/farm-with-locked-rewards/meta/Cargo.toml | 2 +- dex/farm-with-locked-rewards/wasm/Cargo.lock | 24 ++++++++-------- dex/farm-with-locked-rewards/wasm/Cargo.toml | 2 +- dex/farm/Cargo.toml | 6 ++-- dex/farm/meta/Cargo.toml | 2 +- dex/farm/wasm/Cargo.lock | 24 ++++++++-------- dex/farm/wasm/Cargo.toml | 2 +- dex/fuzz/Cargo.toml | 4 +-- dex/governance/Cargo.toml | 4 +-- dex/governance/meta/Cargo.toml | 2 +- dex/governance/wasm/Cargo.lock | 20 ++++++------- dex/governance/wasm/Cargo.toml | 2 +- dex/pair-mock/Cargo.toml | 4 +-- dex/pair-mock/meta/Cargo.toml | 2 +- dex/pair-mock/wasm/Cargo.lock | 20 ++++++------- dex/pair-mock/wasm/Cargo.toml | 2 +- dex/pair/Cargo.toml | 4 +-- dex/pair/meta/Cargo.toml | 2 +- dex/pair/wasm-pair-full/Cargo.lock | 24 ++++++++-------- dex/pair/wasm-pair-full/Cargo.toml | 2 +- dex/pair/wasm-safe-price-view/Cargo.lock | 24 ++++++++-------- dex/pair/wasm-safe-price-view/Cargo.toml | 2 +- dex/pair/wasm/Cargo.lock | 24 ++++++++-------- dex/pair/wasm/Cargo.toml | 2 +- dex/price-discovery/Cargo.toml | 6 ++-- dex/price-discovery/meta/Cargo.toml | 2 +- dex/price-discovery/wasm/Cargo.lock | 24 ++++++++-------- dex/price-discovery/wasm/Cargo.toml | 2 +- dex/proxy-deployer/Cargo.toml | 4 +-- dex/proxy-deployer/meta/Cargo.toml | 2 +- dex/proxy-deployer/wasm/Cargo.lock | 24 ++++++++-------- dex/proxy-deployer/wasm/Cargo.toml | 2 +- dex/router/Cargo.toml | 4 +-- dex/router/meta/Cargo.toml | 2 +- dex/router/wasm/Cargo.lock | 24 ++++++++-------- dex/router/wasm/Cargo.toml | 2 +- .../common-modules/energy-query/Cargo.toml | 2 +- .../week-timekeeping/Cargo.toml | 2 +- .../weekly-rewards-splitting/Cargo.toml | 2 +- energy-integration/common-types/Cargo.toml | 2 +- .../energy-factory-mock/Cargo.toml | 4 +-- .../energy-factory-mock/meta/Cargo.toml | 2 +- .../energy-factory-mock/wasm/Cargo.lock | 24 ++++++++-------- .../energy-factory-mock/wasm/Cargo.toml | 2 +- energy-integration/energy-update/Cargo.toml | 6 ++-- .../energy-update/meta/Cargo.toml | 2 +- .../energy-update/wasm/Cargo.lock | 24 ++++++++-------- .../energy-update/wasm/Cargo.toml | 2 +- .../farm-boosted-yields/Cargo.toml | 2 +- energy-integration/fees-collector/Cargo.toml | 6 ++-- .../fees-collector/meta/Cargo.toml | 2 +- .../fees-collector/wasm/Cargo.lock | 24 ++++++++-------- .../fees-collector/wasm/Cargo.toml | 2 +- energy-integration/governance-v2/Cargo.toml | 4 +-- .../governance-v2/meta/Cargo.toml | 2 +- .../governance-v2/wasm/Cargo.lock | 24 ++++++++-------- .../governance-v2/wasm/Cargo.toml | 2 +- farm-staking/farm-staking-proxy/Cargo.toml | 6 ++-- .../farm-staking-proxy/meta/Cargo.toml | 2 +- .../farm-staking-proxy/wasm/Cargo.lock | 24 ++++++++-------- .../farm-staking-proxy/wasm/Cargo.toml | 2 +- farm-staking/farm-staking/Cargo.toml | 6 ++-- farm-staking/farm-staking/meta/Cargo.toml | 2 +- farm-staking/farm-staking/wasm/Cargo.lock | 24 ++++++++-------- farm-staking/farm-staking/wasm/Cargo.toml | 2 +- farm-staking/metabonding-staking/Cargo.toml | 6 ++-- .../metabonding-staking/meta/Cargo.toml | 2 +- .../metabonding-staking/wasm/Cargo.lock | 24 ++++++++-------- .../metabonding-staking/wasm/Cargo.toml | 2 +- locked-asset/Cargo.toml | 6 ++-- locked-asset/distribution/Cargo.toml | 4 +-- locked-asset/distribution/meta/Cargo.toml | 2 +- locked-asset/distribution/wasm/Cargo.lock | 24 ++++++++-------- locked-asset/distribution/wasm/Cargo.toml | 2 +- locked-asset/energy-factory/Cargo.toml | 6 ++-- locked-asset/energy-factory/meta/Cargo.toml | 2 +- locked-asset/energy-factory/wasm/Cargo.lock | 24 ++++++++-------- locked-asset/energy-factory/wasm/Cargo.toml | 2 +- locked-asset/factory/Cargo.toml | 6 ++-- locked-asset/factory/meta/Cargo.toml | 2 +- locked-asset/factory/wasm/Cargo.lock | 24 ++++++++-------- locked-asset/factory/wasm/Cargo.toml | 2 +- locked-asset/lkmex-transfer/Cargo.toml | 6 ++-- locked-asset/lkmex-transfer/meta/Cargo.toml | 2 +- locked-asset/lkmex-transfer/wasm/Cargo.lock | 24 ++++++++-------- locked-asset/lkmex-transfer/wasm/Cargo.toml | 2 +- locked-asset/locked-token-wrapper/Cargo.toml | 6 ++-- .../locked-token-wrapper/meta/Cargo.toml | 2 +- .../locked-token-wrapper/wasm/Cargo.lock | 24 ++++++++-------- .../locked-token-wrapper/wasm/Cargo.toml | 2 +- locked-asset/proxy_dex/Cargo.toml | 6 ++-- locked-asset/proxy_dex/meta/Cargo.toml | 2 +- locked-asset/proxy_dex/wasm/Cargo.lock | 24 ++++++++-------- locked-asset/proxy_dex/wasm/Cargo.toml | 2 +- locked-asset/simple-lock-whitelist/Cargo.toml | 6 ++-- .../simple-lock-whitelist/meta/Cargo.toml | 2 +- .../simple-lock-whitelist/wasm/Cargo.lock | 24 ++++++++-------- .../simple-lock-whitelist/wasm/Cargo.toml | 2 +- locked-asset/simple-lock/Cargo.toml | 6 ++-- locked-asset/simple-lock/meta/Cargo.toml | 2 +- locked-asset/simple-lock/wasm/Cargo.lock | 24 ++++++++-------- locked-asset/simple-lock/wasm/Cargo.toml | 2 +- locked-asset/token-unstake/Cargo.toml | 6 ++-- locked-asset/token-unstake/meta/Cargo.toml | 2 +- locked-asset/token-unstake/wasm/Cargo.lock | 24 ++++++++-------- locked-asset/token-unstake/wasm/Cargo.toml | 2 +- pause-all/Cargo.toml | 6 ++-- pause-all/meta/Cargo.toml | 2 +- pause-all/wasm/Cargo.lock | 24 ++++++++-------- pause-all/wasm/Cargo.toml | 2 +- 134 files changed, 493 insertions(+), 493 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 6f7637b31..f673c68fc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1598,9 +1598,9 @@ checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags 2.4.2", "hex-literal 0.4.1", @@ -1611,9 +1611,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -1622,9 +1622,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -1634,9 +1634,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -1647,9 +1647,9 @@ dependencies = [ [[package]] name = "multiversx-sc-meta" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "add1bda75ed39bdb246097e5233a4ed7af6587f7c06a7e5084742199d685f6ab" +checksum = "4ce1f4557894ea3b556d3376d4a12c0494b8085a69c7f02def42bed0702ade58" dependencies = [ "clap", "colored", @@ -1674,18 +1674,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-scenario" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42dea5dcc79ef692e907d919ca6bffc81a07c84af977e98b4192c2fd4ff2c67f" +checksum = "fa109d85d90599c232c2c4ac19a0f6c12a558ad72aa04f4b40ff9e23365b1897" dependencies = [ "base64", "bech32", diff --git a/common/common_errors/Cargo.toml b/common/common_errors/Cargo.toml index 09ba443fb..64926a87a 100644 --- a/common/common_errors/Cargo.toml +++ b/common/common_errors/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/common_structs/Cargo.toml b/common/common_structs/Cargo.toml index 80c4d6b33..7379b6b97 100644 --- a/common/common_structs/Cargo.toml +++ b/common/common_structs/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] diff --git a/common/modules/farm/config/Cargo.toml b/common/modules/farm/config/Cargo.toml index f7f478234..89f943416 100644 --- a/common/modules/farm/config/Cargo.toml +++ b/common/modules/farm/config/Cargo.toml @@ -23,5 +23,5 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/contexts/Cargo.toml b/common/modules/farm/contexts/Cargo.toml index 033d99987..fc43fa5e1 100644 --- a/common/modules/farm/contexts/Cargo.toml +++ b/common/modules/farm/contexts/Cargo.toml @@ -35,8 +35,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" diff --git a/common/modules/farm/events/Cargo.toml b/common/modules/farm/events/Cargo.toml index 1c4a763d4..96af56178 100644 --- a/common/modules/farm/events/Cargo.toml +++ b/common/modules/farm/events/Cargo.toml @@ -14,5 +14,5 @@ path = "../../../common_structs" path = "../contexts" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/farm_base_impl/Cargo.toml b/common/modules/farm/farm_base_impl/Cargo.toml index 119d39c53..ff33b5860 100644 --- a/common/modules/farm/farm_base_impl/Cargo.toml +++ b/common/modules/farm/farm_base_impl/Cargo.toml @@ -50,11 +50,11 @@ path = "../../../traits/mergeable" path = "../../../traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/common/modules/farm/farm_token/Cargo.toml b/common/modules/farm/farm_token/Cargo.toml index d66aef7ed..eaf015a78 100644 --- a/common/modules/farm/farm_token/Cargo.toml +++ b/common/modules/farm/farm_token/Cargo.toml @@ -26,8 +26,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" diff --git a/common/modules/farm/farm_token_merge/Cargo.toml b/common/modules/farm/farm_token_merge/Cargo.toml index 07e671721..1b8ec9ee2 100644 --- a/common/modules/farm/farm_token_merge/Cargo.toml +++ b/common/modules/farm/farm_token_merge/Cargo.toml @@ -23,11 +23,11 @@ path = "../../token_merge_helper" path = "../farm_token" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/common/modules/farm/rewards/Cargo.toml b/common/modules/farm/rewards/Cargo.toml index d11286d68..115cd04b3 100644 --- a/common/modules/farm/rewards/Cargo.toml +++ b/common/modules/farm/rewards/Cargo.toml @@ -29,8 +29,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" diff --git a/common/modules/legacy_token_decode_module/Cargo.toml b/common/modules/legacy_token_decode_module/Cargo.toml index 54c96c1ca..5c12ba15d 100644 --- a/common/modules/legacy_token_decode_module/Cargo.toml +++ b/common/modules/legacy_token_decode_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/modules/locking_module/Cargo.toml b/common/modules/locking_module/Cargo.toml index 5be58100d..07b8719b7 100644 --- a/common/modules/locking_module/Cargo.toml +++ b/common/modules/locking_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.simple-lock] diff --git a/common/modules/math/Cargo.toml b/common/modules/math/Cargo.toml index 987f0021e..830764e08 100644 --- a/common/modules/math/Cargo.toml +++ b/common/modules/math/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/pausable/Cargo.toml b/common/modules/pausable/Cargo.toml index 271081564..3668c2822 100644 --- a/common/modules/pausable/Cargo.toml +++ b/common/modules/pausable/Cargo.toml @@ -11,5 +11,5 @@ path = "src/pausable.rs" path = "../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/permissions_module/Cargo.toml b/common/modules/permissions_module/Cargo.toml index 85d7e9b3c..af71e2aef 100644 --- a/common/modules/permissions_module/Cargo.toml +++ b/common/modules/permissions_module/Cargo.toml @@ -17,5 +17,5 @@ bitflags = "2.4.1" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/sc_whitelist_module/Cargo.toml b/common/modules/sc_whitelist_module/Cargo.toml index 1c0fdd874..82e3e103a 100644 --- a/common/modules/sc_whitelist_module/Cargo.toml +++ b/common/modules/sc_whitelist_module/Cargo.toml @@ -11,5 +11,5 @@ path = "src/sc_whitelist_module.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_merge_helper/Cargo.toml b/common/modules/token_merge_helper/Cargo.toml index 216bf3ebf..46795b0fc 100644 --- a/common/modules/token_merge_helper/Cargo.toml +++ b/common/modules/token_merge_helper/Cargo.toml @@ -11,5 +11,5 @@ path = "src/lib.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_send/Cargo.toml b/common/modules/token_send/Cargo.toml index 17b83882c..714272dea 100644 --- a/common/modules/token_send/Cargo.toml +++ b/common/modules/token_send/Cargo.toml @@ -14,5 +14,5 @@ path = "../../common_structs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/utils/Cargo.toml b/common/modules/utils/Cargo.toml index c17c30212..cc25d8fb1 100644 --- a/common/modules/utils/Cargo.toml +++ b/common/modules/utils/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/traits/fixed-supply-token/Cargo.toml b/common/traits/fixed-supply-token/Cargo.toml index bc26dc17d..951361da3 100644 --- a/common/traits/fixed-supply-token/Cargo.toml +++ b/common/traits/fixed-supply-token/Cargo.toml @@ -8,4 +8,4 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" diff --git a/common/traits/mergeable/Cargo.toml b/common/traits/mergeable/Cargo.toml index d0e86244d..5d21bb032 100644 --- a/common/traits/mergeable/Cargo.toml +++ b/common/traits/mergeable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/traits/unwrappable/Cargo.toml b/common/traits/unwrappable/Cargo.toml index fd10b42e4..abfe07baa 100644 --- a/common/traits/unwrappable/Cargo.toml +++ b/common/traits/unwrappable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/dex/Cargo.toml b/dex/Cargo.toml index 7b517a030..15911dec5 100644 --- a/dex/Cargo.toml +++ b/dex/Cargo.toml @@ -5,17 +5,17 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.config] path = "../common/modules/farm/config" diff --git a/dex/farm-with-locked-rewards/Cargo.toml b/dex/farm-with-locked-rewards/Cargo.toml index 4471c010d..2f7981506 100644 --- a/dex/farm-with-locked-rewards/Cargo.toml +++ b/dex/farm-with-locked-rewards/Cargo.toml @@ -75,17 +75,17 @@ path = "../../locked-asset/energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.simple-lock] path = "../../locked-asset/simple-lock" diff --git a/dex/farm-with-locked-rewards/meta/Cargo.toml b/dex/farm-with-locked-rewards/meta/Cargo.toml index 453251275..804328648 100644 --- a/dex/farm-with-locked-rewards/meta/Cargo.toml +++ b/dex/farm-with-locked-rewards/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.lock b/dex/farm-with-locked-rewards/wasm/Cargo.lock index 04273a9ea..8cdfe8576 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.lock +++ b/dex/farm-with-locked-rewards/wasm/Cargo.lock @@ -315,9 +315,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -328,9 +328,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -338,9 +338,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -350,9 +350,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -363,18 +363,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.toml b/dex/farm-with-locked-rewards/wasm/Cargo.toml index 701179e7f..6a907bd28 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.toml +++ b/dex/farm-with-locked-rewards/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/farm/Cargo.toml b/dex/farm/Cargo.toml index 8563b6fa5..411855d62 100644 --- a/dex/farm/Cargo.toml +++ b/dex/farm/Cargo.toml @@ -69,11 +69,11 @@ path = "../../energy-integration/common-modules/weekly-rewards-splitting" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies] num-bigint = "0.4.2" @@ -82,7 +82,7 @@ num-bigint = "0.4.2" path = "../../energy-integration/energy-update" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.energy-factory-mock] path = "../../energy-integration/energy-factory-mock" diff --git a/dex/farm/meta/Cargo.toml b/dex/farm/meta/Cargo.toml index 28f681018..396e12099 100644 --- a/dex/farm/meta/Cargo.toml +++ b/dex/farm/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/farm/wasm/Cargo.lock b/dex/farm/wasm/Cargo.lock index 2dacef823..98035925c 100644 --- a/dex/farm/wasm/Cargo.lock +++ b/dex/farm/wasm/Cargo.lock @@ -285,9 +285,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -298,9 +298,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -308,9 +308,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -320,9 +320,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -333,18 +333,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/farm/wasm/Cargo.toml b/dex/farm/wasm/Cargo.toml index 1fa20b905..f2c3e3d7b 100644 --- a/dex/farm/wasm/Cargo.toml +++ b/dex/farm/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/fuzz/Cargo.toml b/dex/fuzz/Cargo.toml index 391a4c7c1..c88fdb5fe 100644 --- a/dex/fuzz/Cargo.toml +++ b/dex/fuzz/Cargo.toml @@ -12,11 +12,11 @@ num-bigint = "0.4.2" rand = "0.8.4" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dependencies.pausable] path = "../../common/modules/pausable" diff --git a/dex/governance/Cargo.toml b/dex/governance/Cargo.toml index 61ba59e59..8488415a5 100644 --- a/dex/governance/Cargo.toml +++ b/dex/governance/Cargo.toml @@ -9,14 +9,14 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.pair-mock] path = "../pair-mock" diff --git a/dex/governance/meta/Cargo.toml b/dex/governance/meta/Cargo.toml index e99c24667..89991cea1 100644 --- a/dex/governance/meta/Cargo.toml +++ b/dex/governance/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/governance/wasm/Cargo.lock b/dex/governance/wasm/Cargo.lock index 5104abd3f..9fff7d29b 100644 --- a/dex/governance/wasm/Cargo.lock +++ b/dex/governance/wasm/Cargo.lock @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -68,9 +68,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -78,9 +78,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -90,9 +90,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -103,9 +103,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/governance/wasm/Cargo.toml b/dex/governance/wasm/Cargo.toml index 7b1d0521f..773f97944 100644 --- a/dex/governance/wasm/Cargo.toml +++ b/dex/governance/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/pair-mock/Cargo.toml b/dex/pair-mock/Cargo.toml index 4854f150c..e723b6cb2 100644 --- a/dex/pair-mock/Cargo.toml +++ b/dex/pair-mock/Cargo.toml @@ -12,7 +12,7 @@ path = "src/pair.rs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.itertools] @@ -20,4 +20,4 @@ version = "0.10.1" default-features = false [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/dex/pair-mock/meta/Cargo.toml b/dex/pair-mock/meta/Cargo.toml index 8f2d3b0ca..6be30bffe 100644 --- a/dex/pair-mock/meta/Cargo.toml +++ b/dex/pair-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/pair-mock/wasm/Cargo.lock b/dex/pair-mock/wasm/Cargo.lock index 6e83ea775..e792a0986 100644 --- a/dex/pair-mock/wasm/Cargo.lock +++ b/dex/pair-mock/wasm/Cargo.lock @@ -62,9 +62,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -75,9 +75,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -85,9 +85,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -97,9 +97,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -110,9 +110,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair-mock/wasm/Cargo.toml b/dex/pair-mock/wasm/Cargo.toml index 2bbacc718..76349235f 100644 --- a/dex/pair-mock/wasm/Cargo.toml +++ b/dex/pair-mock/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/pair/Cargo.toml b/dex/pair/Cargo.toml index 7fc6998a8..145fc58af 100644 --- a/dex/pair/Cargo.toml +++ b/dex/pair/Cargo.toml @@ -37,11 +37,11 @@ version = "0.10.1" default-features = false [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/dex/pair/meta/Cargo.toml b/dex/pair/meta/Cargo.toml index 508ad1a44..cb381e44d 100644 --- a/dex/pair/meta/Cargo.toml +++ b/dex/pair/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/pair/wasm-pair-full/Cargo.lock b/dex/pair/wasm-pair-full/Cargo.lock index 9ca48d0d0..31a1865f1 100644 --- a/dex/pair/wasm-pair-full/Cargo.lock +++ b/dex/pair/wasm-pair-full/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair/wasm-pair-full/Cargo.toml b/dex/pair/wasm-pair-full/Cargo.toml index 702f1a1fd..96ee5d5db 100644 --- a/dex/pair/wasm-pair-full/Cargo.toml +++ b/dex/pair/wasm-pair-full/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/pair/wasm-safe-price-view/Cargo.lock b/dex/pair/wasm-safe-price-view/Cargo.lock index 929875e3f..4357069de 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.lock +++ b/dex/pair/wasm-safe-price-view/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair/wasm-safe-price-view/Cargo.toml b/dex/pair/wasm-safe-price-view/Cargo.toml index 035a097bf..2ded396fe 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.toml +++ b/dex/pair/wasm-safe-price-view/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/pair/wasm/Cargo.lock b/dex/pair/wasm/Cargo.lock index 26d648185..42713d696 100644 --- a/dex/pair/wasm/Cargo.lock +++ b/dex/pair/wasm/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair/wasm/Cargo.toml b/dex/pair/wasm/Cargo.toml index 8114353ef..7ab7c8901 100644 --- a/dex/pair/wasm/Cargo.toml +++ b/dex/pair/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/price-discovery/Cargo.toml b/dex/price-discovery/Cargo.toml index 7eecf6dd9..74efd78a8 100644 --- a/dex/price-discovery/Cargo.toml +++ b/dex/price-discovery/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.locking_module] path = "../../common/modules/locking_module" @@ -30,4 +30,4 @@ hex = "0.4" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/dex/price-discovery/meta/Cargo.toml b/dex/price-discovery/meta/Cargo.toml index c6955d199..c6a8b19d7 100644 --- a/dex/price-discovery/meta/Cargo.toml +++ b/dex/price-discovery/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/price-discovery/wasm/Cargo.lock b/dex/price-discovery/wasm/Cargo.lock index 65c5b9037..ae8611c4d 100644 --- a/dex/price-discovery/wasm/Cargo.lock +++ b/dex/price-discovery/wasm/Cargo.lock @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -142,9 +142,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -167,18 +167,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/price-discovery/wasm/Cargo.toml b/dex/price-discovery/wasm/Cargo.toml index e1d773a07..0969e1b66 100644 --- a/dex/price-discovery/wasm/Cargo.toml +++ b/dex/price-discovery/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/proxy-deployer/Cargo.toml b/dex/proxy-deployer/Cargo.toml index f4efe45d6..f50a038ff 100644 --- a/dex/proxy-deployer/Cargo.toml +++ b/dex/proxy-deployer/Cargo.toml @@ -21,11 +21,11 @@ path = "../../common/modules/farm/config" path = "../../common/modules/farm/farm_token" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/dex/proxy-deployer/meta/Cargo.toml b/dex/proxy-deployer/meta/Cargo.toml index 9a516a7c0..ddae9ccb9 100644 --- a/dex/proxy-deployer/meta/Cargo.toml +++ b/dex/proxy-deployer/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/proxy-deployer/wasm/Cargo.lock b/dex/proxy-deployer/wasm/Cargo.lock index 02b775cc5..e3585e359 100644 --- a/dex/proxy-deployer/wasm/Cargo.lock +++ b/dex/proxy-deployer/wasm/Cargo.lock @@ -277,9 +277,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -290,9 +290,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -300,9 +300,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -312,9 +312,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -325,18 +325,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/proxy-deployer/wasm/Cargo.toml b/dex/proxy-deployer/wasm/Cargo.toml index 1a9bc3b4f..33d489855 100644 --- a/dex/proxy-deployer/wasm/Cargo.toml +++ b/dex/proxy-deployer/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/dex/router/Cargo.toml b/dex/router/Cargo.toml index f70fa5c04..a70a9ba1d 100644 --- a/dex/router/Cargo.toml +++ b/dex/router/Cargo.toml @@ -15,7 +15,7 @@ path = "../../common/modules/token_send" path = "../../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.pair] @@ -28,4 +28,4 @@ path = "../../common/modules/locking_module" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/dex/router/meta/Cargo.toml b/dex/router/meta/Cargo.toml index 8966e7476..744ea5d49 100644 --- a/dex/router/meta/Cargo.toml +++ b/dex/router/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/dex/router/wasm/Cargo.lock b/dex/router/wasm/Cargo.lock index 6b2344040..4b5559753 100644 --- a/dex/router/wasm/Cargo.lock +++ b/dex/router/wasm/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/dex/router/wasm/Cargo.toml b/dex/router/wasm/Cargo.toml index 678a87da6..32fa69d41 100644 --- a/dex/router/wasm/Cargo.toml +++ b/dex/router/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/energy-integration/common-modules/energy-query/Cargo.toml b/energy-integration/common-modules/energy-query/Cargo.toml index adefb3769..71d7eae02 100644 --- a/energy-integration/common-modules/energy-query/Cargo.toml +++ b/energy-integration/common-modules/energy-query/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-factory] diff --git a/energy-integration/common-modules/week-timekeeping/Cargo.toml b/energy-integration/common-modules/week-timekeeping/Cargo.toml index b4af11ce3..9fd1da07a 100644 --- a/energy-integration/common-modules/week-timekeeping/Cargo.toml +++ b/energy-integration/common-modules/week-timekeeping/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.common-types] diff --git a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml index 36bb5efe2..5492ba8cb 100644 --- a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml +++ b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-query] diff --git a/energy-integration/common-types/Cargo.toml b/energy-integration/common-types/Cargo.toml index a368f9f75..1f8d53b0a 100644 --- a/energy-integration/common-types/Cargo.toml +++ b/energy-integration/common-types/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] diff --git a/energy-integration/energy-factory-mock/Cargo.toml b/energy-integration/energy-factory-mock/Cargo.toml index 1c919df1f..d7f9bcec9 100644 --- a/energy-integration/energy-factory-mock/Cargo.toml +++ b/energy-integration/energy-factory-mock/Cargo.toml @@ -12,8 +12,8 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/energy-integration/energy-factory-mock/meta/Cargo.toml b/energy-integration/energy-factory-mock/meta/Cargo.toml index a2872b370..0806b3834 100644 --- a/energy-integration/energy-factory-mock/meta/Cargo.toml +++ b/energy-integration/energy-factory-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.lock b/energy-integration/energy-factory-mock/wasm/Cargo.lock index 63470f3ab..a0351871d 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.lock +++ b/energy-integration/energy-factory-mock/wasm/Cargo.lock @@ -128,9 +128,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -141,9 +141,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -151,9 +151,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -163,9 +163,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -176,18 +176,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.toml b/energy-integration/energy-factory-mock/wasm/Cargo.toml index 0d381efb7..eb5ced1a1 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.toml +++ b/energy-integration/energy-factory-mock/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/energy-integration/energy-update/Cargo.toml b/energy-integration/energy-update/Cargo.toml index c7a8d41c8..e090da980 100644 --- a/energy-integration/energy-update/Cargo.toml +++ b/energy-integration/energy-update/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.farm] path = "../../dex/farm" @@ -25,4 +25,4 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/energy-integration/energy-update/meta/Cargo.toml b/energy-integration/energy-update/meta/Cargo.toml index 627514dae..cb055bb36 100644 --- a/energy-integration/energy-update/meta/Cargo.toml +++ b/energy-integration/energy-update/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/energy-integration/energy-update/wasm/Cargo.lock b/energy-integration/energy-update/wasm/Cargo.lock index 9d23276fc..e167135ea 100644 --- a/energy-integration/energy-update/wasm/Cargo.lock +++ b/energy-integration/energy-update/wasm/Cargo.lock @@ -295,9 +295,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -308,9 +308,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -318,9 +318,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -330,9 +330,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -343,18 +343,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/energy-update/wasm/Cargo.toml b/energy-integration/energy-update/wasm/Cargo.toml index 5042edb22..7b47001ca 100644 --- a/energy-integration/energy-update/wasm/Cargo.toml +++ b/energy-integration/energy-update/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/energy-integration/farm-boosted-yields/Cargo.toml b/energy-integration/farm-boosted-yields/Cargo.toml index afd011e84..2cd9dd558 100644 --- a/energy-integration/farm-boosted-yields/Cargo.toml +++ b/energy-integration/farm-boosted-yields/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.config] diff --git a/energy-integration/fees-collector/Cargo.toml b/energy-integration/fees-collector/Cargo.toml index 09b6525d5..0a978dfb8 100644 --- a/energy-integration/fees-collector/Cargo.toml +++ b/energy-integration/fees-collector/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.energy-query] path = "../common-modules/energy-query" @@ -49,7 +49,7 @@ path = "../../common/common_errors" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.sc_whitelist_module] path = "../../common/modules/sc_whitelist_module" diff --git a/energy-integration/fees-collector/meta/Cargo.toml b/energy-integration/fees-collector/meta/Cargo.toml index f4cd4b07f..319511b83 100644 --- a/energy-integration/fees-collector/meta/Cargo.toml +++ b/energy-integration/fees-collector/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/energy-integration/fees-collector/wasm/Cargo.lock b/energy-integration/fees-collector/wasm/Cargo.lock index c91a53592..695f4de4b 100644 --- a/energy-integration/fees-collector/wasm/Cargo.lock +++ b/energy-integration/fees-collector/wasm/Cargo.lock @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -167,9 +167,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -177,9 +177,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -189,9 +189,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -202,18 +202,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/fees-collector/wasm/Cargo.toml b/energy-integration/fees-collector/wasm/Cargo.toml index cf5c52d0b..0d9804acf 100644 --- a/energy-integration/fees-collector/wasm/Cargo.toml +++ b/energy-integration/fees-collector/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/energy-integration/governance-v2/Cargo.toml b/energy-integration/governance-v2/Cargo.toml index 606b40d8c..aec8974fb 100644 --- a/energy-integration/governance-v2/Cargo.toml +++ b/energy-integration/governance-v2/Cargo.toml @@ -12,7 +12,7 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.permissions_module] @@ -28,7 +28,7 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.energy-factory-mock] path = "../energy-factory-mock" diff --git a/energy-integration/governance-v2/meta/Cargo.toml b/energy-integration/governance-v2/meta/Cargo.toml index 3187a47ce..cb33b5197 100644 --- a/energy-integration/governance-v2/meta/Cargo.toml +++ b/energy-integration/governance-v2/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/energy-integration/governance-v2/wasm/Cargo.lock b/energy-integration/governance-v2/wasm/Cargo.lock index 6ff033cc1..cfe51a0c6 100644 --- a/energy-integration/governance-v2/wasm/Cargo.lock +++ b/energy-integration/governance-v2/wasm/Cargo.lock @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -178,9 +178,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -188,9 +188,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -200,9 +200,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -213,18 +213,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/governance-v2/wasm/Cargo.toml b/energy-integration/governance-v2/wasm/Cargo.toml index 3615366fb..090b2e76b 100644 --- a/energy-integration/governance-v2/wasm/Cargo.toml +++ b/energy-integration/governance-v2/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/farm-staking/farm-staking-proxy/Cargo.toml b/farm-staking/farm-staking-proxy/Cargo.toml index fb3c4b339..a4fa7e84b 100644 --- a/farm-staking/farm-staking-proxy/Cargo.toml +++ b/farm-staking/farm-staking-proxy/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.farm] path = "../../dex/farm" @@ -67,7 +67,7 @@ path = "../../energy-integration/common-modules/energy-query" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.farm_token] path = "../../common/modules/farm/farm_token" diff --git a/farm-staking/farm-staking-proxy/meta/Cargo.toml b/farm-staking/farm-staking-proxy/meta/Cargo.toml index 1c7a0f9fe..62566f32c 100644 --- a/farm-staking/farm-staking-proxy/meta/Cargo.toml +++ b/farm-staking/farm-staking-proxy/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.lock b/farm-staking/farm-staking-proxy/wasm/Cargo.lock index 4462d4205..eed21c778 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.lock +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.lock @@ -376,9 +376,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -389,9 +389,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -399,9 +399,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -411,9 +411,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -424,18 +424,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.toml b/farm-staking/farm-staking-proxy/wasm/Cargo.toml index ee87f5eee..7656441fa 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.toml +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/farm-staking/farm-staking/Cargo.toml b/farm-staking/farm-staking/Cargo.toml index b4e81589f..988da5f65 100644 --- a/farm-staking/farm-staking/Cargo.toml +++ b/farm-staking/farm-staking/Cargo.toml @@ -78,14 +78,14 @@ path = "../../common/common_structs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/farm-staking/farm-staking/meta/Cargo.toml b/farm-staking/farm-staking/meta/Cargo.toml index 49357bd4a..ec34dd897 100644 --- a/farm-staking/farm-staking/meta/Cargo.toml +++ b/farm-staking/farm-staking/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/farm-staking/farm-staking/wasm/Cargo.lock b/farm-staking/farm-staking/wasm/Cargo.lock index 79a0f410b..61f912ed6 100644 --- a/farm-staking/farm-staking/wasm/Cargo.lock +++ b/farm-staking/farm-staking/wasm/Cargo.lock @@ -316,9 +316,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -329,9 +329,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -339,9 +339,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -351,9 +351,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -364,18 +364,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/farm-staking/farm-staking/wasm/Cargo.toml b/farm-staking/farm-staking/wasm/Cargo.toml index 7068d3f6e..3c20c8125 100644 --- a/farm-staking/farm-staking/wasm/Cargo.toml +++ b/farm-staking/farm-staking/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/farm-staking/metabonding-staking/Cargo.toml b/farm-staking/metabonding-staking/Cargo.toml index ee8282db3..b0cfbd186 100644 --- a/farm-staking/metabonding-staking/Cargo.toml +++ b/farm-staking/metabonding-staking/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.factory] path = "../../locked-asset/factory" @@ -22,7 +22,7 @@ path = "../../locked-asset/factory" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.common_structs] path = "../../common/common_structs" diff --git a/farm-staking/metabonding-staking/meta/Cargo.toml b/farm-staking/metabonding-staking/meta/Cargo.toml index 2e049a4d6..ed0656799 100644 --- a/farm-staking/metabonding-staking/meta/Cargo.toml +++ b/farm-staking/metabonding-staking/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/farm-staking/metabonding-staking/wasm/Cargo.lock b/farm-staking/metabonding-staking/wasm/Cargo.lock index 21aba28e9..80567369d 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.lock +++ b/farm-staking/metabonding-staking/wasm/Cargo.lock @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -183,9 +183,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -193,9 +193,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -205,9 +205,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -218,18 +218,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/farm-staking/metabonding-staking/wasm/Cargo.toml b/farm-staking/metabonding-staking/wasm/Cargo.toml index 79b5e4fc0..35311134a 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.toml +++ b/farm-staking/metabonding-staking/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/Cargo.toml b/locked-asset/Cargo.toml index 443d0040d..ad5a5986f 100644 --- a/locked-asset/Cargo.toml +++ b/locked-asset/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.farm] @@ -50,7 +50,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/distribution/Cargo.toml b/locked-asset/distribution/Cargo.toml index a966c5af6..f17a090c9 100644 --- a/locked-asset/distribution/Cargo.toml +++ b/locked-asset/distribution/Cargo.toml @@ -14,8 +14,8 @@ path = "../../common/common_structs" path = "../factory" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/distribution/meta/Cargo.toml b/locked-asset/distribution/meta/Cargo.toml index de2ca6868..596ee0e76 100644 --- a/locked-asset/distribution/meta/Cargo.toml +++ b/locked-asset/distribution/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/distribution/wasm/Cargo.lock b/locked-asset/distribution/wasm/Cargo.lock index a66da5bfb..f942da7bf 100644 --- a/locked-asset/distribution/wasm/Cargo.lock +++ b/locked-asset/distribution/wasm/Cargo.lock @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -183,9 +183,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -193,9 +193,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -205,9 +205,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -218,18 +218,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/distribution/wasm/Cargo.toml b/locked-asset/distribution/wasm/Cargo.toml index e63900a72..b878ac51b 100644 --- a/locked-asset/distribution/wasm/Cargo.toml +++ b/locked-asset/distribution/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/energy-factory/Cargo.toml b/locked-asset/energy-factory/Cargo.toml index 2e2f62dc6..8b88fa231 100644 --- a/locked-asset/energy-factory/Cargo.toml +++ b/locked-asset/energy-factory/Cargo.toml @@ -33,11 +33,11 @@ path = "../../common/traits/unwrappable" path = "../../common/modules/legacy_token_decode_module" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies] num-bigint = "0.4.2" @@ -45,4 +45,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/energy-factory/meta/Cargo.toml b/locked-asset/energy-factory/meta/Cargo.toml index 5516a213f..2329f08ed 100644 --- a/locked-asset/energy-factory/meta/Cargo.toml +++ b/locked-asset/energy-factory/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/energy-factory/wasm/Cargo.lock b/locked-asset/energy-factory/wasm/Cargo.lock index d25961008..ea350f025 100644 --- a/locked-asset/energy-factory/wasm/Cargo.lock +++ b/locked-asset/energy-factory/wasm/Cargo.lock @@ -112,9 +112,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -125,9 +125,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -135,9 +135,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -147,9 +147,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -160,18 +160,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/energy-factory/wasm/Cargo.toml b/locked-asset/energy-factory/wasm/Cargo.toml index 05c44897a..195fec384 100644 --- a/locked-asset/energy-factory/wasm/Cargo.toml +++ b/locked-asset/energy-factory/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/factory/Cargo.toml b/locked-asset/factory/Cargo.toml index 2fb4cc002..bebae0fe8 100644 --- a/locked-asset/factory/Cargo.toml +++ b/locked-asset/factory/Cargo.toml @@ -26,11 +26,11 @@ path = "../../common/modules/token_merge_helper" path = "../energy-factory" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.arrayvec] version = "0.7.1" @@ -49,4 +49,4 @@ hex = "0.4" path = "../simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/factory/meta/Cargo.toml b/locked-asset/factory/meta/Cargo.toml index 4bc27087e..a18aa81f1 100644 --- a/locked-asset/factory/meta/Cargo.toml +++ b/locked-asset/factory/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/factory/wasm/Cargo.lock b/locked-asset/factory/wasm/Cargo.lock index 26e60cd35..499ad138f 100644 --- a/locked-asset/factory/wasm/Cargo.lock +++ b/locked-asset/factory/wasm/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -174,9 +174,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -196,9 +196,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -209,18 +209,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/factory/wasm/Cargo.toml b/locked-asset/factory/wasm/Cargo.toml index e3d3cf466..5b7a5a327 100644 --- a/locked-asset/factory/wasm/Cargo.toml +++ b/locked-asset/factory/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/lkmex-transfer/Cargo.toml b/locked-asset/lkmex-transfer/Cargo.toml index 2f4631f56..dbfa97c2b 100644 --- a/locked-asset/lkmex-transfer/Cargo.toml +++ b/locked-asset/lkmex-transfer/Cargo.toml @@ -30,14 +30,14 @@ path = "../energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/lkmex-transfer/meta/Cargo.toml b/locked-asset/lkmex-transfer/meta/Cargo.toml index 78211a21e..9ed81bd18 100644 --- a/locked-asset/lkmex-transfer/meta/Cargo.toml +++ b/locked-asset/lkmex-transfer/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.lock b/locked-asset/lkmex-transfer/wasm/Cargo.lock index b1689bd61..68f71358d 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.lock +++ b/locked-asset/lkmex-transfer/wasm/Cargo.lock @@ -134,9 +134,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -147,9 +147,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -157,9 +157,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -169,9 +169,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -182,18 +182,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.toml b/locked-asset/lkmex-transfer/wasm/Cargo.toml index 474ebc202..53407e6a3 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.toml +++ b/locked-asset/lkmex-transfer/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/locked-token-wrapper/Cargo.toml b/locked-asset/locked-token-wrapper/Cargo.toml index 941f8aa52..47ae7ce44 100644 --- a/locked-asset/locked-token-wrapper/Cargo.toml +++ b/locked-asset/locked-token-wrapper/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.utils] path = "../../common/modules/utils" @@ -44,4 +44,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/locked-token-wrapper/meta/Cargo.toml b/locked-asset/locked-token-wrapper/meta/Cargo.toml index 400316ce3..9f28fba35 100644 --- a/locked-asset/locked-token-wrapper/meta/Cargo.toml +++ b/locked-asset/locked-token-wrapper/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.lock b/locked-asset/locked-token-wrapper/wasm/Cargo.lock index cf219a208..b4acc31d9 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.lock +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.lock @@ -158,9 +158,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -171,9 +171,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -181,9 +181,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -193,9 +193,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -206,18 +206,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.toml b/locked-asset/locked-token-wrapper/wasm/Cargo.toml index 87150c0ca..ed6d0c360 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.toml +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/proxy_dex/Cargo.toml b/locked-asset/proxy_dex/Cargo.toml index f598598eb..a36ca0338 100644 --- a/locked-asset/proxy_dex/Cargo.toml +++ b/locked-asset/proxy_dex/Cargo.toml @@ -45,11 +45,11 @@ path = "../../common/traits/mergeable" path = "../../common/traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.energy-factory] path = "../energy-factory" @@ -69,7 +69,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.pausable] path = "../../common/modules/pausable" diff --git a/locked-asset/proxy_dex/meta/Cargo.toml b/locked-asset/proxy_dex/meta/Cargo.toml index 3a3e9de3e..3cec85ec8 100644 --- a/locked-asset/proxy_dex/meta/Cargo.toml +++ b/locked-asset/proxy_dex/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/proxy_dex/wasm/Cargo.lock b/locked-asset/proxy_dex/wasm/Cargo.lock index d601aa1f1..6194e8070 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.lock +++ b/locked-asset/proxy_dex/wasm/Cargo.lock @@ -307,9 +307,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -320,9 +320,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -330,9 +330,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -342,9 +342,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -355,18 +355,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/proxy_dex/wasm/Cargo.toml b/locked-asset/proxy_dex/wasm/Cargo.toml index 6101d9e7a..294ba0f8a 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.toml +++ b/locked-asset/proxy_dex/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/simple-lock-whitelist/Cargo.toml b/locked-asset/simple-lock-whitelist/Cargo.toml index e49600a9a..4a32dcedd 100644 --- a/locked-asset/simple-lock-whitelist/Cargo.toml +++ b/locked-asset/simple-lock-whitelist/Cargo.toml @@ -15,11 +15,11 @@ path = "../simple-lock" path = "../../common/modules/utils" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies] num-bigint = "0.4.2" @@ -27,4 +27,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/simple-lock-whitelist/meta/Cargo.toml b/locked-asset/simple-lock-whitelist/meta/Cargo.toml index e5efe2245..85ac1d568 100644 --- a/locked-asset/simple-lock-whitelist/meta/Cargo.toml +++ b/locked-asset/simple-lock-whitelist/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/simple-lock-whitelist/wasm/Cargo.lock b/locked-asset/simple-lock-whitelist/wasm/Cargo.lock index 34b1df932..d6632d0df 100644 --- a/locked-asset/simple-lock-whitelist/wasm/Cargo.lock +++ b/locked-asset/simple-lock-whitelist/wasm/Cargo.lock @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -85,9 +85,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -95,9 +95,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -107,9 +107,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -120,18 +120,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/simple-lock-whitelist/wasm/Cargo.toml b/locked-asset/simple-lock-whitelist/wasm/Cargo.toml index 57d2e8645..7af4d7079 100644 --- a/locked-asset/simple-lock-whitelist/wasm/Cargo.toml +++ b/locked-asset/simple-lock-whitelist/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/simple-lock/Cargo.toml b/locked-asset/simple-lock/Cargo.toml index 08a745214..5a2205d17 100644 --- a/locked-asset/simple-lock/Cargo.toml +++ b/locked-asset/simple-lock/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/simple-lock/meta/Cargo.toml b/locked-asset/simple-lock/meta/Cargo.toml index ade748c64..e8398e175 100644 --- a/locked-asset/simple-lock/meta/Cargo.toml +++ b/locked-asset/simple-lock/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/simple-lock/wasm/Cargo.lock b/locked-asset/simple-lock/wasm/Cargo.lock index 102bb0d32..b09697870 100644 --- a/locked-asset/simple-lock/wasm/Cargo.lock +++ b/locked-asset/simple-lock/wasm/Cargo.lock @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -85,9 +85,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -95,9 +95,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -107,9 +107,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -120,18 +120,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/simple-lock/wasm/Cargo.toml b/locked-asset/simple-lock/wasm/Cargo.toml index c52eb04df..df38efee7 100644 --- a/locked-asset/simple-lock/wasm/Cargo.toml +++ b/locked-asset/simple-lock/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/locked-asset/token-unstake/Cargo.toml b/locked-asset/token-unstake/Cargo.toml index 9f05894e6..e98adb1a8 100644 --- a/locked-asset/token-unstake/Cargo.toml +++ b/locked-asset/token-unstake/Cargo.toml @@ -9,7 +9,7 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] @@ -39,7 +39,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" diff --git a/locked-asset/token-unstake/meta/Cargo.toml b/locked-asset/token-unstake/meta/Cargo.toml index 035037168..217e2f67f 100644 --- a/locked-asset/token-unstake/meta/Cargo.toml +++ b/locked-asset/token-unstake/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/locked-asset/token-unstake/wasm/Cargo.lock b/locked-asset/token-unstake/wasm/Cargo.lock index 415f82989..87bea6198 100644 --- a/locked-asset/token-unstake/wasm/Cargo.lock +++ b/locked-asset/token-unstake/wasm/Cargo.lock @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -142,9 +142,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -167,18 +167,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/token-unstake/wasm/Cargo.toml b/locked-asset/token-unstake/wasm/Cargo.toml index f7753f8de..cba43e2e5 100644 --- a/locked-asset/token-unstake/wasm/Cargo.toml +++ b/locked-asset/token-unstake/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] diff --git a/pause-all/Cargo.toml b/pause-all/Cargo.toml index becbee8e1..4428bd4ea 100644 --- a/pause-all/Cargo.toml +++ b/pause-all/Cargo.toml @@ -12,14 +12,14 @@ path = "src/lib.rs" path = "../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.48.0" +version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.0" +version = "=0.48.1" [dev-dependencies.farm] path = "../dex/farm" diff --git a/pause-all/meta/Cargo.toml b/pause-all/meta/Cargo.toml index cec738238..204a54967 100644 --- a/pause-all/meta/Cargo.toml +++ b/pause-all/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.0" +version = "0.48.1" default-features = false diff --git a/pause-all/wasm/Cargo.lock b/pause-all/wasm/Cargo.lock index 0972422cf..1f61fcf8f 100644 --- a/pause-all/wasm/Cargo.lock +++ b/pause-all/wasm/Cargo.lock @@ -47,9 +47,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1291e3712731f4e34775254e9a9b8ff70132d15414f2e51f9bc82c23faf48c" +checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" dependencies = [ "bitflags", "hex-literal", @@ -60,9 +60,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1da6db65170105c9495848c5e4ba388abb1f9201ff2ca362056c9328f36b7760" +checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -70,9 +70,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.6" +version = "0.18.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "631c4d4b37fc94659c8d6cf559c21b68c68899095201de2e1b779fccad7b0b03" +checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" dependencies = [ "hex", "proc-macro2", @@ -82,9 +82,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95f0331893be2b757401b2deaf7d8b8c90745fa69114000d83fe26d8487d35a5" +checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" dependencies = [ "hex", "proc-macro2", @@ -95,18 +95,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e507a180afcab409cc3d920bc12f3852cf481a6657428879d1a70f6c2666c94" +checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.0" +version = "0.48.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6bd18dbc72c83aa2e9ad3f4a00dcc27c03ada66c13f9056001dc9157055d616" +checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" dependencies = [ "multiversx-sc", ] diff --git a/pause-all/wasm/Cargo.toml b/pause-all/wasm/Cargo.toml index 3fcca5422..6bbe809bc 100644 --- a/pause-all/wasm/Cargo.toml +++ b/pause-all/wasm/Cargo.toml @@ -25,7 +25,7 @@ overflow-checks = false path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.0" +version = "=0.48.1" [workspace] members = ["."] From 9867ab2b3a282b3366997a0769a5140ee5adcce7 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 21 May 2024 18:10:46 +0300 Subject: [PATCH 052/103] Simple lock legacy contract --- Cargo.lock | 25 +- Cargo.toml | 5 +- .../simple-lock-legacy}/.gitignore | 0 .../simple-lock-legacy}/Cargo.toml | 13 +- .../simple-lock-legacy}/meta/Cargo.toml | 6 +- .../simple-lock-legacy/meta/src/main.rs | 3 + .../simple-lock-legacy}/multiversx.json | 0 .../src/basic_lock_unlock.rs | 61 ++ .../simple-lock-legacy/src/error_messages.rs | 2 + .../simple-lock-legacy/src/lib.rs | 41 ++ .../simple-lock-legacy/src/locked_token.rs | 16 + .../simple-lock-legacy/src/proxy_farm.rs | 97 +++ .../simple-lock-legacy/src/proxy_lp.rs | 83 +++ .../simple-lock-legacy}/wasm/Cargo.lock | 26 +- .../simple-lock-legacy}/wasm/Cargo.toml | 4 +- .../simple-lock-legacy/wasm/src/lib.rs | 34 + .../simple-lock-whitelist/meta/src/main.rs | 3 - .../scenarios/factory_old.wasm | Bin 34481 -> 0 bytes .../scenarios/old-farm.wasm | Bin 35969 -> 0 bytes .../scenarios/old-farm_locked_rewards.wasm | Bin 37790 -> 0 bytes .../scenarios/simple_lock_whitelist.scen.json | 605 ------------------ locked-asset/simple-lock-whitelist/src/lib.rs | 157 ----- .../simple-lock-whitelist/testnet.toml | 0 .../tests/whitelist_test.rs | 99 --- .../simple-lock-whitelist/wasm/src/lib.rs | 52 -- 25 files changed, 365 insertions(+), 967 deletions(-) rename {locked-asset/simple-lock-whitelist => legacy-contracts/simple-lock-legacy}/.gitignore (100%) rename {locked-asset/simple-lock-whitelist => legacy-contracts/simple-lock-legacy}/Cargo.toml (66%) rename {locked-asset/simple-lock-whitelist => legacy-contracts/simple-lock-legacy}/meta/Cargo.toml (54%) create mode 100644 legacy-contracts/simple-lock-legacy/meta/src/main.rs rename {locked-asset/simple-lock-whitelist => legacy-contracts/simple-lock-legacy}/multiversx.json (100%) create mode 100644 legacy-contracts/simple-lock-legacy/src/basic_lock_unlock.rs create mode 100644 legacy-contracts/simple-lock-legacy/src/error_messages.rs create mode 100644 legacy-contracts/simple-lock-legacy/src/lib.rs create mode 100644 legacy-contracts/simple-lock-legacy/src/locked_token.rs create mode 100644 legacy-contracts/simple-lock-legacy/src/proxy_farm.rs create mode 100644 legacy-contracts/simple-lock-legacy/src/proxy_lp.rs rename {locked-asset/simple-lock-whitelist => legacy-contracts/simple-lock-legacy}/wasm/Cargo.lock (93%) rename {locked-asset/simple-lock-whitelist => legacy-contracts/simple-lock-legacy}/wasm/Cargo.toml (87%) create mode 100644 legacy-contracts/simple-lock-legacy/wasm/src/lib.rs delete mode 100644 locked-asset/simple-lock-whitelist/meta/src/main.rs delete mode 100644 locked-asset/simple-lock-whitelist/scenarios/factory_old.wasm delete mode 100644 locked-asset/simple-lock-whitelist/scenarios/old-farm.wasm delete mode 100644 locked-asset/simple-lock-whitelist/scenarios/old-farm_locked_rewards.wasm delete mode 100644 locked-asset/simple-lock-whitelist/scenarios/simple_lock_whitelist.scen.json delete mode 100644 locked-asset/simple-lock-whitelist/src/lib.rs delete mode 100644 locked-asset/simple-lock-whitelist/testnet.toml delete mode 100644 locked-asset/simple-lock-whitelist/tests/whitelist_test.rs delete mode 100644 locked-asset/simple-lock-whitelist/wasm/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index f673c68fc..515bb376b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2568,33 +2568,32 @@ dependencies = [ ] [[package]] -name = "simple-lock-meta" -version = "0.0.0" -dependencies = [ - "multiversx-sc-meta", - "simple-lock", -] - -[[package]] -name = "simple-lock-whitelist" +name = "simple-lock-legacy" version = "0.0.0" dependencies = [ + "common_structs", "hex", "multiversx-sc", "multiversx-sc-modules", "multiversx-sc-scenario", "num-bigint", "num-traits", - "simple-lock", - "utils", ] [[package]] -name = "simple-lock-whitelist-meta" +name = "simple-lock-legacy-meta" version = "0.0.0" dependencies = [ "multiversx-sc-meta", - "simple-lock-whitelist", + "simple-lock-legacy", +] + +[[package]] +name = "simple-lock-meta" +version = "0.0.0" +dependencies = [ + "multiversx-sc-meta", + "simple-lock", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index dbdd0d3ec..0944e273b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -37,6 +37,9 @@ members = [ "farm-staking/metabonding-staking", "farm-staking/metabonding-staking/meta", + "legacy-contracts/simple-lock-legacy", + "legacy-contracts/simple-lock-legacy/meta", + "locked-asset/", "locked-asset/distribution", "locked-asset/distribution/meta", @@ -50,8 +53,6 @@ members = [ "locked-asset/factory/meta", "locked-asset/simple-lock", "locked-asset/simple-lock/meta", - "locked-asset/simple-lock-whitelist", - "locked-asset/simple-lock-whitelist/meta", "locked-asset/energy-factory", "locked-asset/energy-factory/meta", "locked-asset/token-unstake", diff --git a/locked-asset/simple-lock-whitelist/.gitignore b/legacy-contracts/simple-lock-legacy/.gitignore similarity index 100% rename from locked-asset/simple-lock-whitelist/.gitignore rename to legacy-contracts/simple-lock-legacy/.gitignore diff --git a/locked-asset/simple-lock-whitelist/Cargo.toml b/legacy-contracts/simple-lock-legacy/Cargo.toml similarity index 66% rename from locked-asset/simple-lock-whitelist/Cargo.toml rename to legacy-contracts/simple-lock-legacy/Cargo.toml index 4a32dcedd..fb660121e 100644 --- a/locked-asset/simple-lock-whitelist/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/Cargo.toml @@ -1,19 +1,13 @@ [package] -name = "simple-lock-whitelist" +name = "simple-lock-legacy" version = "0.0.0" -authors = ["Dorin Iancu "] +authors = ["MultiversX "] edition = "2021" publish = false [lib] path = "src/lib.rs" -[dependencies.simple-lock] -path = "../simple-lock" - -[dependencies.utils] -path = "../../common/modules/utils" - [dependencies.multiversx-sc] version = "=0.48.1" features = ["esdt-token-payment-legacy-decode"] @@ -21,6 +15,9 @@ features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] version = "=0.48.1" +[dependencies.common_structs] +path = "../../common/common_structs" + [dev-dependencies] num-bigint = "0.4.2" num-traits = "0.2" diff --git a/locked-asset/simple-lock-whitelist/meta/Cargo.toml b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml similarity index 54% rename from locked-asset/simple-lock-whitelist/meta/Cargo.toml rename to legacy-contracts/simple-lock-legacy/meta/Cargo.toml index 85ac1d568..d9ce41012 100644 --- a/locked-asset/simple-lock-whitelist/meta/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml @@ -1,11 +1,11 @@ [package] -name = "simple-lock-whitelist-meta" +name = "simple-lock-legacy-meta" version = "0.0.0" edition = "2021" publish = false -authors = ["Dorin Iancu "] +authors = ["MultiversX "] -[dependencies.simple-lock-whitelist] +[dependencies.simple-lock-legacy] path = ".." [dependencies.multiversx-sc-meta] diff --git a/legacy-contracts/simple-lock-legacy/meta/src/main.rs b/legacy-contracts/simple-lock-legacy/meta/src/main.rs new file mode 100644 index 000000000..8f84e327a --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/locked-asset/simple-lock-whitelist/multiversx.json b/legacy-contracts/simple-lock-legacy/multiversx.json similarity index 100% rename from locked-asset/simple-lock-whitelist/multiversx.json rename to legacy-contracts/simple-lock-legacy/multiversx.json diff --git a/legacy-contracts/simple-lock-legacy/src/basic_lock_unlock.rs b/legacy-contracts/simple-lock-legacy/src/basic_lock_unlock.rs new file mode 100644 index 000000000..0585da9a6 --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/src/basic_lock_unlock.rs @@ -0,0 +1,61 @@ +multiversx_sc::imports!(); + +use crate::{ + error_messages::{CANNOT_UNLOCK_YET_ERR_MSG, NO_PAYMENT_ERR_MSG}, + locked_token::LockedTokenAttributes, +}; + +#[multiversx_sc::module] +pub trait BasicLockUnlock: + crate::locked_token::LockedTokenModule +{ + fn unlock_and_send( + &self, + to: &ManagedAddress, + payment: EsdtTokenPayment, + ) -> EgldOrEsdtTokenPayment { + let out_payment = self.unlock_tokens(payment); + self.send().direct( + to, + &out_payment.token_identifier, + out_payment.token_nonce, + &out_payment.amount, + ); + + out_payment + } + + fn unlock_tokens( + &self, + payment: EsdtTokenPayment, + ) -> EgldOrEsdtTokenPayment { + let locked_token_mapper = self.locked_token(); + locked_token_mapper.require_same_token(&payment.token_identifier); + + let attributes: LockedTokenAttributes = + locked_token_mapper.get_token_attributes(payment.token_nonce); + let current_epoch = self.blockchain().get_block_epoch(); + require!( + current_epoch >= attributes.unlock_epoch, + CANNOT_UNLOCK_YET_ERR_MSG + ); + + locked_token_mapper.nft_burn(payment.token_nonce, &payment.amount); + + self.unlock_tokens_unchecked(payment, &attributes) + } + + fn unlock_tokens_unchecked( + &self, + payment: EsdtTokenPayment, + attributes: &LockedTokenAttributes, + ) -> EgldOrEsdtTokenPayment { + require!(payment.amount > 0, NO_PAYMENT_ERR_MSG); + + EgldOrEsdtTokenPayment::new( + attributes.original_token_id.clone(), + attributes.original_token_nonce, + payment.amount, + ) + } +} diff --git a/legacy-contracts/simple-lock-legacy/src/error_messages.rs b/legacy-contracts/simple-lock-legacy/src/error_messages.rs new file mode 100644 index 000000000..345e5a015 --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/src/error_messages.rs @@ -0,0 +1,2 @@ +pub static NO_PAYMENT_ERR_MSG: &[u8] = b"No payment"; +pub static CANNOT_UNLOCK_YET_ERR_MSG: &[u8] = b"Cannot unlock yet"; diff --git a/legacy-contracts/simple-lock-legacy/src/lib.rs b/legacy-contracts/simple-lock-legacy/src/lib.rs new file mode 100644 index 000000000..14bf6f447 --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/src/lib.rs @@ -0,0 +1,41 @@ +#![no_std] + +multiversx_sc::imports!(); + +pub mod basic_lock_unlock; +pub mod error_messages; +pub mod locked_token; +pub mod proxy_farm; +pub mod proxy_lp; + +#[multiversx_sc::contract] +pub trait SimpleLock: + basic_lock_unlock::BasicLockUnlock + + locked_token::LockedTokenModule + + proxy_lp::ProxyLpModule + + proxy_farm::ProxyFarmModule +{ + #[init] + fn init(&self) {} + + #[upgrade] + fn upgrade(&self) {} + + #[payable("*")] + #[endpoint(unlockTokens)] + fn unlock_tokens_endpoint( + &self, + opt_destination: OptionalValue, + ) -> EgldOrEsdtTokenPayment { + let payment = self.call_value().single_esdt(); + let dest_address = self.dest_from_optional(opt_destination); + self.unlock_and_send(&dest_address, payment) + } + + fn dest_from_optional(&self, opt_destination: OptionalValue) -> ManagedAddress { + match opt_destination { + OptionalValue::Some(dest) => dest, + OptionalValue::None => self.blockchain().get_caller(), + } + } +} diff --git a/legacy-contracts/simple-lock-legacy/src/locked_token.rs b/legacy-contracts/simple-lock-legacy/src/locked_token.rs new file mode 100644 index 000000000..69c20142c --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/src/locked_token.rs @@ -0,0 +1,16 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +#[derive(TypeAbi, TopEncode, TopDecode, NestedDecode, NestedEncode, PartialEq, Debug, Clone)] +pub struct LockedTokenAttributes { + pub original_token_id: EgldOrEsdtTokenIdentifier, + pub original_token_nonce: u64, + pub unlock_epoch: u64, +} + +#[multiversx_sc::module] +pub trait LockedTokenModule { + #[view(getLockedTokenId)] + #[storage_mapper("lockedTokenId")] + fn locked_token(&self) -> NonFungibleTokenMapper; +} diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs b/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs new file mode 100644 index 000000000..c17cdfd7f --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs @@ -0,0 +1,97 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use crate::error_messages::*; + +#[derive( + TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq, Debug, Clone, Copy, +)] +pub enum FarmType { + SimpleFarm, + FarmWithLockedRewards, +} + +#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq, Debug)] +pub struct FarmProxyTokenAttributes { + pub farm_type: FarmType, + pub farm_token_id: TokenIdentifier, + pub farm_token_nonce: u64, + pub farming_token_id: TokenIdentifier, + pub farming_token_locked_nonce: u64, +} + +#[multiversx_sc::module] +pub trait ProxyFarmModule: + crate::locked_token::LockedTokenModule + crate::proxy_lp::ProxyLpModule +{ + /// Output payments: the underlying farm tokens + #[payable("*")] + #[endpoint(exitFarmLockedToken)] + fn exit_farm_locked_token(&self) -> EsdtTokenPayment { + let payment: EsdtTokenPayment = self.call_value().single_esdt(); + let caller = self.blockchain().get_caller(); + + let farm_proxy_token_attributes: FarmProxyTokenAttributes = + self.validate_payment_and_get_farm_proxy_token_attributes(&payment); + + let _ = self.check_and_get_unlocked_lp_token( + &self.lp_proxy_token().get_token_id(), + farm_proxy_token_attributes.farming_token_locked_nonce, + ); + + self.send().esdt_local_burn( + &self.lp_proxy_token().get_token_id(), + farm_proxy_token_attributes.farming_token_locked_nonce, + &payment.amount, + ); + + self.send().esdt_local_burn( + &payment.token_identifier, + payment.token_nonce, + &payment.amount, + ); + + let output_token_payment = EsdtTokenPayment::new( + farm_proxy_token_attributes.farm_token_id, + farm_proxy_token_attributes.farm_token_nonce, + payment.amount, + ); + + self.send().direct_esdt( + &caller, + &output_token_payment.token_identifier, + output_token_payment.token_nonce, + &output_token_payment.amount, + ); + + output_token_payment + } + + /// Output payments: the underlying farm tokens + #[payable("*")] + #[endpoint(farmClaimRewardsLockedToken)] + fn farm_claim_rewards_locked_token(&self) -> EsdtTokenPayment { + self.exit_farm_locked_token() + } + + fn validate_payment_and_get_farm_proxy_token_attributes( + &self, + payment: &EsdtTokenPayment, + ) -> FarmProxyTokenAttributes { + require!(payment.amount > 0, NO_PAYMENT_ERR_MSG); + + let farm_proxy_token_mapper = self.farm_proxy_token(); + farm_proxy_token_mapper.require_same_token(&payment.token_identifier); + + let farm_proxy_token_attributes: FarmProxyTokenAttributes = + farm_proxy_token_mapper.get_token_attributes(payment.token_nonce); + + farm_proxy_token_mapper.nft_burn(payment.token_nonce, &payment.amount); + + farm_proxy_token_attributes + } + + #[view(getFarmProxyTokenId)] + #[storage_mapper("farmProxyTokenId")] + fn farm_proxy_token(&self) -> NonFungibleTokenMapper; +} diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs new file mode 100644 index 000000000..4f5f120eb --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs @@ -0,0 +1,83 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use crate::{error_messages::CANNOT_UNLOCK_YET_ERR_MSG, locked_token::LockedTokenAttributes}; + +#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq, Debug)] +pub struct LpProxyTokenAttributes { + pub lp_token_id: TokenIdentifier, + pub first_token_id: TokenIdentifier, + pub first_token_locked_nonce: u64, + pub second_token_id: TokenIdentifier, + pub second_token_locked_nonce: u64, +} + +#[multiversx_sc::module] +pub trait ProxyLpModule: crate::locked_token::LockedTokenModule { + #[payable("*")] + #[endpoint(removeLiquidityLockedToken)] + fn remove_liquidity_locked_token(&self) -> EsdtTokenPayment { + let payment = self.call_value().single_esdt(); + let caller = self.blockchain().get_caller(); + + let unlocked_lp_token_id = + self.check_and_get_unlocked_lp_token(&payment.token_identifier, payment.token_nonce); + + self.send().esdt_local_burn( + &payment.token_identifier, + payment.token_nonce, + &payment.amount, + ); + + let output_token_payment = EsdtTokenPayment::new(unlocked_lp_token_id, 0, payment.amount); + + self.send().direct_esdt( + &caller, + &output_token_payment.token_identifier, + output_token_payment.token_nonce, + &output_token_payment.amount, + ); + + output_token_payment + } + + fn check_and_get_unlocked_lp_token( + &self, + token_id: &TokenIdentifier, + token_nonce: u64, + ) -> TokenIdentifier { + let lp_proxy_token_mapper: NonFungibleTokenMapper = self.lp_proxy_token(); + lp_proxy_token_mapper.require_same_token(token_id); + + let lp_proxy_token_attributes: LpProxyTokenAttributes = + lp_proxy_token_mapper.get_token_attributes(token_nonce); + + let current_epoch = self.blockchain().get_block_epoch(); + if lp_proxy_token_attributes.first_token_locked_nonce > 0 { + let token_attributes: LockedTokenAttributes = self + .locked_token() + .get_token_attributes(lp_proxy_token_attributes.first_token_locked_nonce); + + require!( + token_attributes.unlock_epoch >= current_epoch, + CANNOT_UNLOCK_YET_ERR_MSG + ); + } + if lp_proxy_token_attributes.second_token_locked_nonce > 0 { + let token_attributes: LockedTokenAttributes = self + .locked_token() + .get_token_attributes(lp_proxy_token_attributes.second_token_locked_nonce); + + require!( + token_attributes.unlock_epoch >= current_epoch, + CANNOT_UNLOCK_YET_ERR_MSG + ); + } + + lp_proxy_token_attributes.lp_token_id + } + + #[view(getLpProxyTokenId)] + #[storage_mapper("lpProxyTokenId")] + fn lp_proxy_token(&self) -> NonFungibleTokenMapper; +} diff --git a/locked-asset/simple-lock-whitelist/wasm/Cargo.lock b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock similarity index 93% rename from locked-asset/simple-lock-whitelist/wasm/Cargo.lock rename to legacy-contracts/simple-lock-legacy/wasm/Cargo.lock index d6632d0df..0a3d09bf3 100644 --- a/locked-asset/simple-lock-whitelist/wasm/Cargo.lock +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock @@ -183,7 +183,7 @@ dependencies = [ ] [[package]] -name = "simple-lock" +name = "simple-lock-legacy" version = "0.0.0" dependencies = [ "common_structs", @@ -192,21 +192,11 @@ dependencies = [ ] [[package]] -name = "simple-lock-whitelist" -version = "0.0.0" -dependencies = [ - "multiversx-sc", - "multiversx-sc-modules", - "simple-lock", - "utils", -] - -[[package]] -name = "simple-lock-whitelist-wasm" +name = "simple-lock-legacy-wasm" version = "0.0.0" dependencies = [ "multiversx-sc-wasm-adapter", - "simple-lock-whitelist", + "simple-lock-legacy", ] [[package]] @@ -238,13 +228,3 @@ version = "0.0.0" dependencies = [ "multiversx-sc", ] - -[[package]] -name = "utils" -version = "0.0.0" -dependencies = [ - "common_structs", - "fixed-supply-token", - "mergeable", - "multiversx-sc", -] diff --git a/locked-asset/simple-lock-whitelist/wasm/Cargo.toml b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml similarity index 87% rename from locked-asset/simple-lock-whitelist/wasm/Cargo.toml rename to legacy-contracts/simple-lock-legacy/wasm/Cargo.toml index 7af4d7079..258af6806 100644 --- a/locked-asset/simple-lock-whitelist/wasm/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml @@ -5,7 +5,7 @@ # ########################################## [package] -name = "simple-lock-whitelist-wasm" +name = "simple-lock-legacy-wasm" version = "0.0.0" edition = "2021" publish = false @@ -21,7 +21,7 @@ debug = false panic = "abort" overflow-checks = false -[dependencies.simple-lock-whitelist] +[dependencies.simple-lock-legacy] path = ".." [dependencies.multiversx-sc-wasm-adapter] diff --git a/legacy-contracts/simple-lock-legacy/wasm/src/lib.rs b/legacy-contracts/simple-lock-legacy/wasm/src/lib.rs new file mode 100644 index 000000000..59effebc7 --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/wasm/src/lib.rs @@ -0,0 +1,34 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 8 +// Async Callback (empty): 1 +// Total number of exported functions: 10 + +#![no_std] +#![allow(internal_features)] +#![feature(lang_items)] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + simple_lock_legacy + ( + init => init + upgrade => upgrade + unlockTokens => unlock_tokens_endpoint + getLockedTokenId => locked_token + removeLiquidityLockedToken => remove_liquidity_locked_token + getLpProxyTokenId => lp_proxy_token + exitFarmLockedToken => exit_farm_locked_token + farmClaimRewardsLockedToken => farm_claim_rewards_locked_token + getFarmProxyTokenId => farm_proxy_token + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/locked-asset/simple-lock-whitelist/meta/src/main.rs b/locked-asset/simple-lock-whitelist/meta/src/main.rs deleted file mode 100644 index c58ebf7a8..000000000 --- a/locked-asset/simple-lock-whitelist/meta/src/main.rs +++ /dev/null @@ -1,3 +0,0 @@ -fn main() { - multiversx_sc_meta::cli_main::(); -} diff --git a/locked-asset/simple-lock-whitelist/scenarios/factory_old.wasm b/locked-asset/simple-lock-whitelist/scenarios/factory_old.wasm deleted file mode 100644 index 3c6ca8c4ed094c96eb655b614f8c7996dfd6960b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 34481 zcmc(o3!EL-UEk--+~>|d&dQR#dL)^9Bg#5hsSQR_g&{j@OS0l;VmWbKinQLnmi8^} zUdeXqNNZbhl*D#SG2oB@ArR~mLP7~8$%LRwM?k5bdLsZB%N@9%$R z?(WJ~2%k@Az1E$XGw1O?|MP#H|M{OY(Zuq+i=xQA=)Ue~eD-W~)SY!_b;oZM9Zk-L zwCHF=LWL)?D6xD}Hg`s)&QR(MkNhgj88TMSa#2=ptfcBaqw*mOzf`H5v3{J2I}%eX zXJtsPQ3wC=E(x{O^~kN2pxHBeS5u2IUp<|uy&8Oz`rDLa*xE$4#Iza09+~VZy{u7In$D=-_ zHSd}}c4(n{bLXDuQa$(0kDt2x?#_}DtdK7f4tBaXb{39xk4Mh(QP;tVQT{3f*j|hD*Q*I9FSTmnIgL zL1KaTVcuBs;%sN(=Ea4{PC!{-sQ>VF)29Ov1yHx0x+^>v8EykX0ixaruB%10+o&F% zp6@JoC+1It+Dj}2K*LZB6^ME3(sZ|Tn<*VHeEU)zc2FNc5Oa2wbWT& z-hjMoY05^p#7R-Xjf)dg;YGVBZ=+CRMX0#>z~TM(b|z1CJJFDkS2mO{-?uQSp^EA@ zDn)svbe2NnmlSEY+_TVG+5pyN#Ty2!hwkepx)afe>bkTyntFKwIrt4jG%?=^_}*UB zSb}Z@v;pukN0E5T!gY+nwTlbg&b{4etJ>XE)S*!N#-`UD(O(Nxz?t+%BG~2fWNrjtkO;W_u6_Zn%C(*ZR*^w%6u6^NUOO#Zd*p){U-i zOu_@>6O*&iZGLj8Gtuqj3sVOcm+qNZnu?C^xG?G3Q_J1O`CB_n(~DElvh+c|yxi#? zmIyjD6`k!T<=P2!$8FPZ??ex{OL@MobN2+|^7aMkh@$8@x05&f@9iS&5YpZ5()3+$ z?Q%ZZojyI$on9;i+Pj@y+%>s>6S4!*5@G3xc8xT*On(NT<+YTHKQt*9N^sUDcX>-%d-OiNQZ)su@wf9}F zPkphLmZR@+m(F*Vjv@FqHoqKwuNztF98=+?3tvV*=Z2OTiqoB53(>0U2bXJ|{TJ?4 zJX3OF?#+vHo#mI+@oR2~3>y&pFWq*MjsU2siX$DmeB{`~@{u{~^sl@AQ#K9-?7!if z_mn-1{+;VPa%2k0c7#z$Tzcfl@y^7FBX>f)J z7Qed{XVIwgjK){^Jz12+yW^`f=l52|`29P6pZ}Kq+)`zJ^^Ct}cf6Ooy)*t>{kM&; ze*d%Hzrm0BnBSc2-mlSA%1J??n$BYihpB(tKzG>tj7qM4o1P@4afcT(j(|K=#oAJOeD z-40RM`ZeuO`~T|F*Ex3+z&k?*K~Tfa-wEJ?2+E5qz(+wo2YNXICqLXp%0Vi!zwSQyomeVxKKP^(&;_GRjQokn_ASt(W z{%_~e8`Dp_7(phQ8k=c58gmQ`l+hm$7zyVinG*z?m9#tdLU}yKgQGovL+0oVkq`>D_V09b_4Sy|)0v|8cDfm*-r|itJUns}E|#c12fK#`2ZNftX@Z z{shuAkM>0xzr24YQ?dIDLk@xyVuti4o5??d9ERXQ!q2!kJ{zk)SI(+G04ij+<3L3s zGkWCn2!ga;Sw}&t5t4&KNN&vdPtm>0laX=vW<&H#?qvSC$e_%xv@vJY$dI*@w+wK% zD;jM_~^oqu=i-*J`6uITSwf>4Q)zZ{iXUzZb!OHN;sXbd^xe_(@RUO7_r;3ek(ss zLW0z1-5xR4Z9C&YWX9zI{8r;yK6uKoRqz#neG+m%6Bmf87`Z!NZCCTg4RB;-Jlc~ms5!S;b(X#$ zao_Ls=JKS`j>ktI9$&HlR$q!9%Hr|851-?Aq)7ej8ulKIIkiv4C&Q~ z?!Q!jNa>^8e>t&A&YwGXt`(2FRsua{u|NO?dlH%r=-lsOBw-u5=MTnbGj}U&KhUb= zPa-ei8?l!EZI`DcJxWrFq)0&S^}a?$6(o1!Z`zjrgmcw(B!a4;rF<`iT&rsAT*;%G zVMs_I-+S_7=bviTkPTy5RjkGM9~yA}X@|^4?c{Ly{sFg5>9-72fI+Gtp2=#+9}*ob zodZdgx*D^sN)Xf_Ry2ngZurMU=?tg+0Hogz4O)MPQfo$XnT|E0^v9|J^5=sZkH`FB z=;nK3Nht;=Mv79Ir08ZYL5h0r_RfH_7%7_gw~BWB9j!{CQ7Uu^d`e-z6;=ZW1(5Mr z25+D?N8{^E#qEm5E-GdHoeT+t-%m{@570qi!T((qN4LkSjimhZ5=X=S+f7I*;iX_@ zeER^j3=l$#|9dL6H+KgI;3p(DxKY1G<7-;ZgKEp@Lgjn+Tc*!O$X^=+mjPXGkv2{Ovkp-J~j zO_KPPnoQK6#NVlA#6pw(vD#yF*7PHSAoi1taz`yzS`3$N80@3|ZcrcP41qtUa?i`S zNp}QZjr=#{Kl#Y2>7X{*{8mZ1p+YW}&)>ka5qVWMgh-Z(jhOaD5&|TaqBWgxm4bU^ zc0|y!G%_@g?kH$JptF@Q1QavYg0LzcGeJUeCjVnWG-Sq)aU%AhN=s&EmGm29xd?+D zWu{F54LSO;N6-_0pbl63y+xU)(t|y*ZHAXxDb>csWHH@CKA74WmiRD*VK!I=5s>~s zA*C=!f-Q$BWTHx?GW40mmhMMp+STG-7f+HTkcKZ~FstpF|1Psx3dJm)Dm@ovHPajU z4(RIgB-#^+t~O&X^&YUDs^vo#W7qD9AOkaG=y9n&q^OKNBgqMqYLJfLF05$Hmf)yhS8-MGU3_Mpwqy{y6rD!b^`8fY@Y~n8n zpba#0m2+q4T*0o>zS(xB!2F$vw2)fT`WaRCRN45G1 ziI>4VG7~63BwXG#%DW=Le_cBsaH*FH0@l_oh+K8B4kpE1i4f`_EzL|!@$`dM)NSP3 zS(M%z*bayor_!FOn;xmgV_^S{pn!3wQ{ylZ2E*UlMoX|@tsK(Zc@g`MIR7yer)bWo z!fTi}`=4->t`$Xp(rpuo2$uA>T{(M&M%GPUrQ#TB2@5}iiS_Xyi>Eyr7jR~6Lh;i| zOc}&xt4>B3!}&QOy+25X28x*{DiI8O{Co>A{DN?;BoN{k!8pPgY{mYBW{8>&wrkQ< z;IE#c+5Ji8pG&+DH8QRHq3z*sP%*6f54 z`i=KmEfC~jlz~)6JMyn*C}ig6PpfBjdUh(k+Q{FarLvnbab1;>{NLxuvBe*ia!SP+ zGEFtoNYg0o4Q`7XTQGC}9@W_N^|lLk#K!Ej2{L|(x(=rD9{|s}Sk@0S;Isn-L0;Ao z2F#GvP{qI9U+drL{NHbZCr!xu!z)SjI?{ok1|tV1tKjc`@ClHn&Ja3u5%Gfw=HEd+ z6OP~OdNRkvvL++^6_XL}K!Ht0G|thk$oubf@t9Rv&f_Eq(c$Mc&B~b)2!PoCPocY* z|NNm;rP?pvz2HeS}KuJaeO>!OS~@6M7bR75ne7 zI;p&#tA6!iUN*&5ThJMq6c23o?gvQSDx>YS5iOmDU8;F@klqDm$$$J&GI%c$A2EM4 zJV*X@2;KB5o@}52FZLgdDO5mE*a}uC zMA)YPrI6=A%P~es5at6j=B3C?t&d2YTrjb6HnDOWCRT3a#EQq>#EOi)i4|296Dumw z#7g9oK&}h}ROBBwwH#zG>Ch8%KmP$ICKMr=76wGH9I_S~T=YyXBZUet(O5|^2qYB1 z=$QY6d&l^zAACpJ4cuB9Fkxb>sV_uV7QOJ{;Y{K1egGz|EO!PRhx-AYx%DM zc*Ot*=HEf6-a#TR%LEBu(M(GJBz>L8<2t%5DZVqw#S7`)AJo zi8LVK;0eu|{+E%Rb@~N~aZg)Jz}i(+q}~8ZyFw+8suHSK`Trysg5o<$7LAlqo|&Bp zVF0{5Il3n~fq?i^knjJS17{WgXD(}gOup2Bq$K|X@%{+2=Lc0|z!qo_!6)G6aX|wB z_VC|ByFyWgchAeQaRGK3wC4X@Rh0;;uR~BQf~jRB2|-nuobu?L#s&mc3j{T!-lR3^ zh9IsP_Ujsg5Pm{XqeM)da>a1QW)hT`5mN+HeFJ6$D?J7?>dpUPL<}>L2-4p!Vl8d1 ze8tJ4`q4P9oK4F005rCbTS!E-KAMf+Cbiw(>I2Omk-r_<${M)5(VfIR6oeGapij5q#0g6>7v5(H-3jG#Ir z(Bb@-n9X3JV7|PDtS*1e3@YX?bce{{&93M*m@uf**+QLSfq9AJewi=4Zd}ZKafTsz z`%5$8y%@ev7ZYn=POKXquddJ+Jof%Q zF02xL!udWq;MKz}DxY*;KHa6&qV=WAr6ln}k3k+&m8@B)=*N2$Q_k?90GZECv!gQ2 z?$*n9V+e^nq`DF2=G}2YqP~rm9EqU|e1HsKF$(<>(PE7CRJ}74hN?5(St|}aa6iIY z0Pb`D4|rf%P!zrs3Re|EVfv|JA`&LUYK?gp@I22P8EuA*&eVcu6b*!55#dXB*)rx1 z21pitVtyBa^d;VfD@Kd}FKl(qi?Ir^(+>`ih55`y2tD{iXo7innBjp0%_qZLem(Jj zeQ%;x_^I|qLlleiA#vRw0(2m~g_4I0>#ZQZ-vhp{lJtI%y4Ed(6{IJbyN>XnK3T}= zhYOzUjlakW|0xJ(sc^xDM?@><>YE<9Jqn5s5MN5 zlYrINshPt3aVmoAzBflHCMOb6%tz)?(WMYYF~Fhbc#VV;VAGr)6wOO?`n*_!&wuq@ ztD5mMEkdJ1g5&hu-%6WMB*Os--Y!{`10gO8XVWe7v8-Me4+o3j@z$`yO*5@NjaL4&0rMolD8sJkQ!cNf4r2b` zw`#s+Hs3-!W0r@OVRc16*Yq;4N(AAvBWIZ0t+EuR=JrLrlGGCvc~$jbt*bB=6YKAmT?4R6 zI|uhgAKaATG+1+fS8XAZgkm9*XBHwQq@PsI;qmCrx$EwW9@kSp6sIe*sq^;Ma19Gd z&Hb9-p!>hVRYv8iGeQ9Oq=P??z`>z#z8#j{YXa|)P5wjBJz_u$8lwo8H7sW;okKoQdv4lQQAuEDiz-U*-0Y%=8pVpzsUB=1LpN zLrAp*m0B96+dmBMh$RUz2?h-QS^rd6{xV2h{su)ZxZoBQalVdf=!xK>8VTtbT~`@n zjt+i}>ESW6nks$}nG}z&p8Hmx*nJI5g9LS%!HNA)9=)+xYgO0JzfR=aWwi7fS=7eW z3#z0}0Uos}-O?C;{L|4&HhjOTP?zxaRW-iZ@H<)>p~op!q1dKd2M`FYVF`dti*=F3 z*udE`EHTy&nE(-m!5knPxEfUIK+doldGH6oeJoxPe@RWI|4b<$BXxDuoza~j2Rtpg+G1urcLLTtB?qLPm1;a&z) zPz321=hWO=Q22mDmqhso#k#x5jErpKUW+mu4u!Bov~3V}8$}`>xN;q_Vxp9ULX`3> zQHn^BD9s<)WV}wm8FO$`ERj5Uj{u;ScFwoWKLssF)2@gnU{_2}U*eAi2Tp=a6LC^Be4$=^T&>|4-+=#d zr|2D9pcQ^3aBw+5^+A+}B_iIGt*K>e^Cy%Ydv7Qk^dEN_^T7CwUNHxxKE#U=sI0I` zFDwd&WGYbnPa>xx|BswlL~XXAre2#r<+5N9J^ngOe5Q=gJ-VvEs}KSp;*fl#ptPtM z7wMomzEB^rojtgM&bz458wGn)zNYItr+> z;XAC{3vy#v_x~{^M&o;1Ty{nG2WG@)R=oWglJx?8`kdX4#wT{i&vGksY-Y_cA&sEX+c%A1}4L?UD zlqudP+E_B=gHagM(HLdh|5w>mK~TgSWr?w~^h%qd3X&kn`u#uA$R(icXTwdZ6d+!2 zaMA2>wLK?sE5?O~FO(D-y^_B!woY#>{#j~{dzRE_d{i}0A!UL{!2Kuhmu1BuDh?%5+P`4KQ zm;d=g+}c9pkGio0uZiSRh4q!X`H{K^5@^aUJV|&u=uQEiKx{V84y% zv;YD6t7((e)eiZg5y1FrF`h9`fzEC}2wC-Wk2Gs=sT)Vg&4Jr6*ml*tn(m9_=C_$f z5!_0p{u{NFxE8TW6dEE{%tX!D;))!ol=CTW*3YMkc(9+1T@B|~mY639z=v3e&!Oho zJUQ7$L}N;2ig3aNOvZo@Z;=_&LG$95jpX}|h>LLn8PPSOm%-pQ*@JOqeRFTXVa2aN&S^YHg3>@ILEG|jVB?u3>95SMv zH7?O1ninry3n0Oa8Vm{QxkzrAbID0Y7}q;Z@+j`i5;M5C!Np_!L>n1I>-$+O?%&&s zlMLY{G{sbdCZz=Nh^gLYa13KYa16LdF(AjlCifCNma!{ zB$b4PNF+`W5oS8oFKDZ7ZPholRo~bakG;0Y*lUZbingdEv=xnG{70-Xh(gVI*C*_Q zf4?i;giA-p3o{ZWFdextX){UJ_c%q4A0*|9heuYN{1{K0F#$?7KS0E)9XK~gL*{9k z6|%@`^qGEkOT77PMe8ol$FptLU2;rX{td-r`a?ohv!RnM;^mPjQLEpQ8u^w(M2c6m zcF@S(X}JeAKdk0wCG}W{v4{B3K!Y{KMy}~M)5EI&VQesoQxaLd`GK%(qqUoUTt^>{ zHJ7LsFF#BKhSiG{vPsBLueC3~^wLZ9ldWcc7EsR$g4tuIQSOaaEwp<;S*?w%Ig?3< z4Ro{GGBUK551$U#YM1NDb|1hs`0Kl2`>epDO$4;m8wjLZgoUwQl*gyrs1wXYYH;1K zU{uSKIa@)JPP$Rq%&=k6Xm|V>)^ddMXLPm2sNFI4kM5t*06Y^@=~ar*vLvnE->P@4 zHL`}MEhs)P_CaTMiq6`pA*5tQcn?*O2Ij=;PYqp0PX!WVg)vZAzfo9e>(;iUN zMPHWADByK48vtSIk`_u^TOl0QNzERuWm}C18T$5sG?8ZoP^**nB%wKwd0p@yNjwFaPu0eo--g;Ygw zS>uN7^c*l}SRx#zH99St5#o5Aig;NYQO#PVZ8w46I&mjKYGi5T--upRMF+STfdL|v zY;--kk*--j)V%SBMDkhr>O)5IJKKXf%)ufnp8R%7EA6cr7k>w7soe=*sW8MUZG?-U z#?we?-=|aveg=h~W**D`2y`h!F?bMTN@&lv9@f~9165C05u%`$ZITQKgVA5LKF;D0 zC`aiMai&J495oGwjRGFdu=R+Z69C=cWCxM)N!D!D>d(9Y;r1|yMnNl=XfMiqKq0(g3C=%di297&C?M%M&9k{a>%bf%%mVKyywz@Ef-(LY zr`A?Tl(A%VFqN{J4fP=X(HI8=fkVw2w`P6hXGpVJ3pO7p>7bBy=}o)|qQ_9v+E&uz z)@<8h%pxc~AXL@ZTQuab?zb}nMmQx(`!s@>V7fih>hDJ?^=Wj}oK+B+j7;?cdA1RuN_Yi?B8?1(mk5WK zW|x#W94rvsloU74aM_?4v#mjKhPd0PONem%4T9<|0FJ5I4Z;FtQ7y1J_?57Ehp=gs zv_)bK%V99Hn*0yi@cZ^=0khf0kR7THzK5+f(EO8=Y)FZlvdyigu>cVmsG0on>`?nM z`4Qpp(>xP)14#^J!-v}aV1D4xQajxaMWs-~Cf@XKr;cjob>pp%g6ed8(`?I&?VNn+6C^iXTqsBO~$=mlXS7fQhu!$x7*);njIYKDO_E}<$~rz&s-6{CAZ*3t;= znn^2QP;HRpy4nVc+73%#cgIoyCVGU zG6po%LqR@oGvMI?y*#^Y??tJiN?E+L1nrI#Dg9L2M^$OBs^Z0nWiB2>tTfy&xdfsE zX}T&UheX?bf#yScmbQjiWdjp%|13XX=D_wa(loS*6wqFzG&2onF%;5kWF}TPDQ<{` zqRI9Ez!^fHjb}heQyq|SRhNkUusam5xVz}EIvV(M8*P>WK52lnFY7M~Gf0;w&#?K2 z&Pb^z;w@2Lr95pFY~Ny(1EcHrIcE|A z`sBfcZX-`ls~}E&fU8M$-UR8upSK9b62(CrJ);@8Re^!wv`!@_7zQt(=aH5J;U&7 z4)#N4KuVH4ADh3-bkCO3pmvPBdL3A4Vw@D;3^t`i3C?=X(*u!>{QNI&n z!|cx>K2yjt$hb$if!2x!DN*d#opI6_!efwMR{57KBrcHr-FD4f$Rja< z`$pa_=qxzKB*=)iGJgl*BEiX3`rq(Zi)Jgq(I)2?GNdAJn?e|IY0AEGa&qb>F(;>Z zI0T`YKTY9Zd5EA=z>D1IxV~A*5=2Ebh}<;kH5YDb0{aB&++xD;semsna7kSnL+2k^ zF=Jy!fCc1RSpIF(5ieF&_28>mw{!HQ+dD zTSORSrLFyh$P$?fiP@VbcYXe~LeRH3X6LkD$p>c$rniN6jnSJ!bQ-u<^L-YfrqDxn zhiHzdkzh5XpG)DQG~Xok?1~2UGqkjSU-T-f4YFb_ut#1R1=InjHkZja8a7ly1sW)P zl(wPr4&?w&kX(lL$X{xi*t1?XpD!J#u;qTk9)i%NuQ~7^RaB~lyp%CVQWPLIZ;CCr$9uib zM;1aN%(1o6N7fA9>(b-Z^N|t99)Cq2nQD|*tq_qR@;$d9TJw>a&q^V5vKpbP3k3Gx zjHm2nPOQZc8i-|MI!!>A>lio@Utyd2M(-{xihorrD(2lq1wd9H8*OA85^)^TZShp0 zM1QQHthEL&==axFQH3=Lsl}IjgV(_-zp(t45a~Kt|FjYh213$tCon=h7O(A`i~KKW z1CGKAPuuRC(@b#Kozos1*N%42T$PnlR8Iao??U2jwk4O(Ny>el%#!@ypXau}WIF8% ziSq~IZ*efO#5fMaZ1CG+kCRWWyPX#H5%zbslUb(o&~d4=Jiw*KM2AZid!9=L zdp`MQJP}O!{Fhz+8}Fe-PpITe^i*0AwSn;dn4b2sdI6GxEyF_Wo@B4AeEGD7Laz5~0p88l%wWs&$X%nl-JULAhk=QbO|EcRm^O6pY6r0ZfH$5%aDuMt zY%G?EbO465EeBwLhTp>sFkB}e6S8r{S+b}~BWH8@1oKKP&4{Fm+!+XzQy3zUCRv3W z=s+qK#T%9Y%_wQI1W1mi766Crh9yCEduYvH7T|+wR4a9~8)rinsxJVWc3?-wiloh| zFyJzc&a%H$tZM*nU|beolpk z6z;v&33Z`fh9JXMwHA&*{H8)F{z5w-M@EVc$iYY<=4l_qI!Jmd#|$fE#Rt1~zMJ0eN8fM0*?+ z8q;PVBW$vVMPUDv+>n!5>n2`y^314bkdp;Km|VI+R7xa<(Xmw*Hd@kY897e-1b!Es z*ert|j2ZIlr=R|%AB%&5IEL6^o?(JI#DSk;8Z4L;2`s*G#uD6)U?^AFl-kxJuW4r4 zD+HYKZgY!{fC4xv0zb&ohbR|TN}+K&kSM1pnrw_3J90E)@I12-#JYUkV1*Z!O*)f| z6=jP#qUYh&D1S|ex6*ix(#tX&*tSOfit6S(9oWc~LBHh-8=MUHMTk8|+QtG&F;Rth zB?ppP0!IM+Dl>UH`p=!G)`-;z=CwtrK537}>D$O(wywzHAOS%misE64C_2NA?BR}a z6$xpW;iTCAFQLFLh6i%m$vr|R&Dcpb+HWH`G%cjYFH)mTol4^7&>(@MjYy7-Na=Px zP$>T{u|-4WsK7r$o9R~eO|Bo@W{XXOWPeloVkPcdQ{0fSWuu%085rGZdV=LlOd`A- ziTWTO+2V{~yYfa+f#t}5UuwGQ%cHTdYzR!&nHqS>2{|ScLJ$J<-vO$S$wHNr+N(+B ze!ofR zs1@hK@&#voPibHFV57egCmf(y$7*@e#v%VH*)aoQ1FXr6enLxr(8}UH${!1Nl{A0h zF{|%V7HE<*|D*6U#1oYNtUbXh`7eZY+`9-mI$iY-aol3BwY3fGc`-+k0abufq{x6u z?RRK90mQNJy0A+9Q$+6HZA|oq#8q zinRLH^02#+9sym)8-;awSCwqsxPCHk(!kv1yf1s>3<;NU2!rX_Bro1pDR<;q`Zu;O|> zyh{8QOT-ozUj&w&Zc;2fvEZXWCq-)Fu^g*iR z_#$GZ68}TmFc^nuZZ97IRMClzo(dENoPr&tvBNbu>ITcw`jJ zBPq`uCBdp<33_`#FcV`(JxPBpwRq)$cd!Uyhuc%hC!g~8iIA`1>a>b zJm}Rqbd1#VjkeaETk$xHI+TYPT8=^r2#&SRVPV%r?DW9>R84rAV0-OGvDj(MBDpb;Y9V%-R^VgNmIVL~daD!nz@L znpNw=*p{qSXU**tR6G(lNO}Vcn2{L@M=lnu<;xBP)b`mRi(R3Q6o;yyrsC^c)_NRkSZ-|uBD&)(l*UTgOOYf-lMH_AW7 zQ@wl=^D$#ETlGm@>EMs(iirAXI6e9v4 z8TC%0-Zpr*fCl40{Jic61TX+6$6`sOuBb|!3>g&%N+yyEci^Ew+~&Wn9=}Gmm1FNQ zIzSmm^^;}MTefG({fLrSYdq9s{_ce1G6>=U)BaT$XVF2xi>}|E?w2~i(*~VyI9G4w zJsZx|+k|KN&)&U?u3;!4$qUZa+rdnjnt#WM0A=mlrdOasQCnPiBgLFcjyuI{$uc-PJ&S7Mzw_roZ6Q2OUL&i7P)R&0XM)iY$gK+7Lq)ZHyt~ zQE_8-A|V-dZzmE`756%kkV@9#)if3uvR@Fdn_X=7?z=@(@24w(%^gb~u!#Wv4=(+S z!rzTI6Yag;;^jOT5YN~yh@IFl7;DJISxjdtoUbC0Exy#0g^GEzLrZWV5<66mfU0Q{ zo;S-N`@%aRgmy6%p@8)A`ne4lV$!0iCw3`T!Y`8t`eM8_G+?&alBivbw9om2ree`6 zNKeca^TYKH9snM*r!wlRhM7r)nMoFN>HyhAXz6>_9MLuT-{f43%BcT_rs1quYYw)4 zxd4`B(Uv7pdZ-^e6AFaT%Ey5?s}t(4^`oF9L#RK`+D7ng7UPfFSs&wH19V`S{|Z}K zKWiwtfC**qA=qDm1r-Co#$(3i`jHkYSS7MX!sYMr@uThR202{(%$g)91h@2YQ)}Q#BdI zKr1Gr+|gSzufY%C*JsOYq$cK{u$YVNSSc>o&mbJopMdaN{!Y3>NWP)vgL!~;(>#hz6 zVh8N|&`bh4#K*{D^Ps@iIw4SbO}cx`bWKcygHLW0G(}WQ)oGjSZoSRml=jLjv!$7 z6S8Kw5$TXpu@P0nfy8Vn|8N`;4kw-jW(`GAf4fq|rsEA^?DJ|DTP!XbegkKJ5ukzX zhpw~M6*{igWmQ`1ngC1cthLU4N`TFJ;x#F3%c7$A@jfg}(RS&}gr zvaWznh<#RvkU$NYyCTvKg6L+QP0A9vq79A`$f<`!4=3!QVw15=TC;jSIw^^f#7YaPy1yIj;F7qQ7- zw?RdsQmxMWVbsh$h`*Q+6rM!awYDQnMmpG@+u&{n1mt5(^#BVft1Yb%fkXli_yM2X zK$aR3z-koo!rGxF{Mrh+f(B=_qlEm#3=m*xq*T!bg*eNARt|9w&78EzHXZ9Fy{v~&^-Opp&PIm!k=Hbw} z>zc{BEH2Rk2NL~CbB&WiQ;=}3czJ*K-L7KA~W?(<(j4! z5-s9ML9iK0%!$MWA;@Z@2z6L&9_L>o3o-t&QoyA%VFHbXPBb_6@NcO5>O6p>1_HTg zU}}Nw5=E}D0pO&OI1!EP?t-F$*67%BimC;FN!dyE*QRWW1j_Eg00*-U3`W+~MhoH; zKn0`NRN!4mtixdiu5qQTA+b^*v9b<{40f-j9&`LvL)_~nR^ivAmq^k8zM-})9;Rj& zdYi4u0vbcUi+UumO#h_;`%#86qz=g%{pE1k);kxGIDqOQ{| zLm&3p=@!T<5ZWm0EGNx_Rc{KY)riM{i7ZT`WckQILaBN5tB5{Vt+<@I&}>i>c%e*h zkA_;R!!TY@pS6_5hsdKfjf-nRz_xQx*B{jtKER+8b6?FI%2(63 zt~b78Adt~2xz8xtYF@5e4wZ)HY{8XlInRBknOwc2b}#2d+`I}l%_F`BxA(AUkO4CCuo>Zry%7_YEM*F)RI zu_}L8iPis6V)bd)J00436OVyYKKEhV7R;uLW12TYJ=9d(v4O6{zASpCg2dwl8Wh`X z_`nM`PFNPlrzo2Es|MpDowi=33{)1Vw47J|FZZ&e-I?)~p;mZNUSWr;;GvcfN%e=i zGjt#9@vKoEg66MN&zk3e1zEvZZ!r*Bnk;GW|D#uIt&@NC(fNM?*a*9O3t{$D`VGRm z$s={kPTnm<)qC+9mhVhfrB{_s)Y6@y=nxIN+#*bE8sTJqjzli1|0+rtKEN;$HBp18I z(K3PT9zt*jS@J15ktOUR$?-01XXQ7Xx@^u{k>>4is!lRTu9Yh7`$CvNpkKVbucc06 zaO9Hqmoj{%Lt5V>LVzSJ+NHOnmMEYt{%GzbrauS+X>;IjBQ$ie6MG6XBJ_vxH}gy; zF0&ryQG`UZZm7WMWPj;EichCET)>tD+3E;6h#niyjGs-Fz3 z^fAbkI<_DCu2E3P$P1eWYE*#k5v(t`j&`IZIG}=N%Qpr`@s`#vDuD~tJp>-LEJ3YT zpnu^W8^iD6vom}Pgs}P#JOa^Qs)JO4j<(R!vCd4DFOSEq+tSzCR~k_E>%Y$Mkrj#! zdXoiwm*L6?Yyh%?*RVd=@n#!O!p=un5?4ea5}6s%*^BSnx5!ugQ{liqZY-bxP*h%# zXZVgUdOAh(tJw6P_b4kEY4Ue7kmoRrG<>Q-22%@^>1KWN1x|~zVUZi9vC=CI#`vlS zgc-_Dxs1#6Sldw;X02#oNn=5%PYAjaq&n zq|kTp0;lb0$J$;l#TC4FVW&IU^815l}p_)8M2 z0$%J*5i6|2H*(`*>#+8WF*qRoNw~Qn+;5K7v57$Y3XEbjbrD|a(F>bI1#-(lV(P#; zVk?^bru9vJCC-EZ6%rukWVsK(nNF_pZ?eX}Wv-7pzBS0_$~3CXJ{WCoG;_Ad0)4Kg zEiZkgn-T7u5Y0u(on*sP$~wD&D<_eaAJq~{FQVCDuJhbG%n30Y^o;Z&RL9;*Bns8Z zlW(i`npm>i8=V5^);{e7m0y*vPv0lQKBlo`Ociu-!MG(R6!J<*>uS?JBYhJR8~-k~ zSbPLcaBIg%aC?|Q2RwoyADuZj#k{Mi|w1WjIOZNusrY$iMG8!;kM zR<&^f1w^({d|HpJ!!mHJ5t&s?Pzxkz@z0{X&Em40IFxi~H{gZye=vpgRFK6@@R3-C z!*3<7nB%Aobpqnnvz-jUv-YXuFBM^dAEPe_u1)vIg^eP5NsC7=bi)6LG>ItRZbAy2 zv|jEQ*9Wae%Tf-gbvmZ{(DPzU%AtEX(}Al={XJHx{IE8*rGbrn;fo{`rjmek>k2g% z=++_?u(I1XY_0tAP=W+Pf2AKyix0JDcTY^ub*3)z{nzP*6Q{aacX2VBTU_8<&!;Em zrl&G~Pj&dPw0(>B$VBgByhr%hZSghUBMbVz_}!-#NLgISrWQNP*}`Hso0y#Joakoy z^mTS3d@BB)C92LAPR-xdS;`jg&L+yQ#a}ydVq$W-dtdls`-fSv9*Cl7dSRI_!%t66 z^FjG+vdBXEr+B}Gt2KONa)K}P@-f@+@!BKH#rJx9>GS#?`{ClFw;R6%USK4A$@s{` z!qkzw!{?2Qx+e6!V7_X+nDHg-`_{k>ud@@KrAdKy%s!61ly#3!ERgfw{qrZf_tEF2 ziTT^@i@I6o#Ny=ffR^cnY;kF-vsAn(>)^}FolwD5S6<1NkX7+A$TU zUd}D*Tf#>Swj*7AUHQoL)W)Y0fcxeJ-s#TdwG#^(68jc$cF%P8cy=YVQFM8HVk+Ea z(^I{U7X6!tTnu-o0R*V0@1Evc>%#w9<~0bq$2-|F-%QUYmb38bWA4`Hy=h{B zk3Uc4;T!VV#2iC3bzj!|pmAqvV~zmEy4MWB{Pgm&QFLcvx-%7e2gMfc1=#HC);31v z*PJ_3cY>ZQu+zl+;;DtMa9nUe=u9yjC7OFfABOg(PWSlY6!_)~^ctMSYhi|!I|IOL0`P**VfAitceCJ-iBfVU9a*i)xAL%SDEiN6I58uGn=e&;?3HCZT z6+XOuB!F-PD&(u(69HQR=;iLjQc-F{rnT{fkB>}sCa32o=9ZWA5$X~Ju-@F-H@IiKp9799x>8 zu89QzyN!(0Z(r_)YS%q7zkM$<+c`qKrT1mmjvu-9##?T?{muIe6s?z; z<^4?(rWd?l(;Umk7ni!HCzb^1axpANZ#f~ouy5a~g?pAJPK;iDl!418vZH)Ty>m1u zn7d$*iKV59`?9&t!m;l01mW)a*Wh1;f7Nx*HSP=EeM@H&KAY;?n=PWc&?gA_W1am6 zZ@f;zV9C@`(0Ti^d8ErV-=L@fLHDCXK-It5?MEqByIjSd8H z`w2dK-dXz${km6-8&XX^g~X8|Y@ diff --git a/locked-asset/simple-lock-whitelist/scenarios/old-farm.wasm b/locked-asset/simple-lock-whitelist/scenarios/old-farm.wasm deleted file mode 100644 index 0ffa046e31f275daf54dd6186bbf386d0b77d08d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 35969 zcmd6w51bv>Ro`dsytn&y-&^gKEZMTGz`Tb7t73rwM-q+`cGi~U5L;F(C2>Q_dbRr` zt)%_q{bO4cB*j)7IsOv^33VX}A{cCf^9M-41SbeEsasrXAb?v!YFf9r5NM#Gm^3B* z{?475_ufi&96q$4%HB6K_wTvqo`3h;b7!K7#hEyYqWJgX^k#SRWOQ>B-5hg?PsS&2 zj`$;y-{hq7^vgqq3r}{jQYTdW1Vv9oH&;)dJYl7HB9q6W@CoXuHA*Wdrf}T~TM;t* zsK`I^tRoscp@L2oD{3{mxnC9RF5wbjpdFI!A8jY0cUm|RxsMEdd(xi0b=BnI_TLX>3MB<-Zect zy?FSIvudL~6}g`3JLl&n4~OcjizfF^&$JhpCT8YC`cMvIHb38!SM@_EVK?WOD5vxk-rM@bi48snO-=j)e`1vm!-ocphtzBMEi_@c(Hg}Irr z<4f(u(C=k=zxx*^W*5Qen!_e{*RdysTBSU1X8laC{(nd{~za@4o-K0)8obOEs%+_P(c4<-uWvc==GlL8{D z1q6kuQ%ZXwz;sdG<_)*awikMaa!H<(k7d7rzGh-+B3i4qHg<9ioC^%Mn6VtR8)mP8 zwyvI=U25OH6s=PugCJ!0#Nu`BgG+(nhKr#?;x_gDDpnvQkYP_o7|^~h9x);>Y5;pV zZHC)R%lSEPT8+8-4jRh@qF&z_;|&Ybho<4f{kLB`v3NM3?vfnX{c~f+eMO657B4NR zQDl69{G9X!dQJv;g`KyA2G-`!SI^BK*O>Pmn}*#73?bzxR!~?j2lg!==w&DH(A~tp zaPM)kOOpO1sU+1(RB7;6;g8=at|Up+-ygZCkAHF0f3X#+UsA1Bs(m#Cd7n$1{xAL| ziLdqPA&RO|)QHw2>mwIetC4eYTyeA+B|h$FoC5<%?b4(^6h#{@i(-I?D|Ey^?({GG za+6T8QrXBv&>sk?Mz2T^sY*_0JMN=QB~BWu6t4o@zJ#Ajv?``}l=LOha9=dMx*mO< zTCeu?eSM?Wx2g&VNnbUp4cBT>tuLw8R!4o+WS|zgzJb{FSCcqe-FInnGR{t&Iv3SX zM%lA}+;#2$h5pO?X4*4z3&&klfmD{FZ?8?lPGb|3N2AxL+)geZn^Y}t&MqXG$^otZ3EgnF})zsvOw(>RsW3vy0;DYE*;<7UYL|} z{w;%uCj%uwmCY~_OVLwSJ|t0K-{A>V_P>oKyhGxR?Zx)Ot?lTyyV42-{JXeDxqVBJ zK=icrQOaplRXIh!8xPO47Y?;G605ox{a$?0jLk?}itkO|Hva9(jQ(p}ou61=0<1FUaWzN5e`)NuS4LCkx9=Q^)5P!CIpj$DPJd-9@~_@Gl%y`Tn~J}RCST)U zJN8`Uzsrx3{Vun&GMXjiXLUa|cJ6)8cyg{DJM|}jehD|%6h+dAhIiKeE*jqLucfoy z{&i`^#~X(0*`K@vkS_Ay9rfHk`!-VRmik2%SheDIUF7L^S7nqIenFX%8FF}PWa(}O9H%b(t9z;F{d82P#DGd%pT&#yMyUGJP7n1c z`+Xs8$otUz2c4Q%8AkJN5Nu`s)oIF9DKkuR_LcaSEZ${!q5hvMZcWs_m0yVK zYW_>gzL;!4j??HvV_%8y^va8}U%7*U3YQ6D%}4kLA0Lx9E=}y;8KM?TXba| zT+j5_&4=AEL(JZ-@m9Rg3qPg8JQ)yyFub9Gfq~2~RiUMCKsiK5ThS(geqF2LKj>QV zHn-P-L4W-asoB%f5x=JiN zAU^<2tU_7P-$=puXwx-7MH-E`9s0R~DNmy<(N+lW$#>DDddfbF{>q{&BPO!q_xWUl zje5T-M3A*501Tj5+K5Qq08d5oZ&bOxS-iVU<(Y!nGtrS&OcVZ17cOCWZ|=#XlTKw- zwd|3iaS%e!BkppDq;^F4)_GTc$c?hC-CgJT>aPhqQos4qgK{qha@U}`huvv;|5t6f zyIw$IXT$+ry(ob`0!}V~N-$iG=^vx#mpM_{AD)3=wu#D_=Fi>5!zzE1Jv&^+s#Niy1NwA?o5X&m}&=yGLL zBZEXZB!z>b`eFKjz5LNuBJN6I4F85^1wNougA1i<;tDXNp9Vcu{I9w+ApwFC%Rofg z`|kt5VFRBWYd)XH$>M&x!V@f17gy0}Gg!Nj*CO1eq z!6VrdSF@A$~_IDWJ z)Fg=#Wi*f^&{!5DXtud)1KI86Vtx2M2>Id`Y)fknRoqFE{1JbrYgGb#{z!JW;Oq0J z9hOEVixAgpo}rGowRrax?mV_*MQ=?>@L*u$NW27GX{3ULX1fN zPXBx?N&cO%z-~1br&WK(xs$@2Ukfn)&tuaSV^aFgUjn4hM@Iq?B`C4-7MYW$>QW4H zeJdV{>t5Ohq%?0B>JOs_G++1E??lx(n!eiw<-VKeKBZ)ji~S5=3!un>qF58*{5}Ehz|I+00#W4-HgNm5 zn_iaGX;jMGq@LYrQI0L~G z`Bz5uUvRD(S0(Bls=^&)poy>b$N*sS#_tJ$vme#V(1*f5gA7z1JiQNoLu|W)KbNk_6!YJPn zxltkTrlBZ%IB(MbEs`tB9w;8iRp1Bw-^assOjA9*WTUgL zP;#J@cvt=F?HStH3V@eq5t0^A{`LJ7-zvN2+hEk}$Hmx}h&9YCkWQ{-zo^8-?xB`& zBYyd<0k`I4zwCr_mBQjjbv06uBuj)2nFD`R(_LwT7t9dM6)xmS0Ux7)M=&t0v7e#k zS+NA74`qm!L9=X$;K5y&`8nMfCRM}FQ{r(-ph?xzV<;sRqJ5SabY!jiTWE1Xt5bV+ zev!d1G5G5CHGNm=lp#?e?QP{kax-*X$_<+ zdi8t85cRT*2K@;SwPc@-kJuodi6yQAZ2kloaI# z;$tMPQ7Z<~DYrd&5NxFvZBITbtes7cwE9x4CD|Z#e@d8r8W<{RU$(=4TISQ1=$QoA z`XG~#;h?qp5r6Rk+`r z95$SMROScE$Dx&lNP{0R&zfruVZ#?FfPK9=Ig>QkiE7@RG*<)3bNOUF+dElR6CgB- zMGb137xUcEbPQ1EGkKk-d+Q8>7YxzLis|(4h=ni_H2fK=0!ADNK)FD5bMulg$n`?% zm*ZyL4?q}Ex@wzyx0rEgn|nZ4zs%cbmsIC_?*~*6w&ggml_T-eVmuyd7NV0d`c}}j3GjR*m z;O~yp{1>PF>c7i$JW)%JM%5#{Cb8Ue8s6 zI=dsNY4FuqpC7VMebCx6BoTXi|u7i;9hN!%xWDSwHKqtC=mY)Jq6 zaSKLeJtrwvr7ApF@y5o91S?Aeqs6c~coLTbTG5}Ct)If<{^w#WXjX-??E4sySe+VL zxFkE0Q8K8*?~Wr@X-jkyYzUN;+MJ{&4J2dK8r_$IMzS21Dg=!*QIjPXzkT$FM3>^- zn<9T?#F~5&s;&(gDa|t~h&%0vFf}u!S#4{u=ad8wW)826a>XY>O2K8t?US9`bDdj6 zc2NNFP~1}c5gIjyP~-8H(dW4eOv!oVP*%0R#5&Ilec1e)A}kUig7po{CH?I8k7_ki zH=98q`m6l!&{$+HLoFoC;*IK;2<}J8#}^tPXZ(-E^$kk@80ps*>4H+mb^Ui^R|zI3 zOGsG{)baIym`{9&T3jGAqP@CGlj4MhFm=CPlme>>3k@Y9ksw9p zoh3MCHWR36$I=|JY0tC>!per~H_6Q1oUCtF>5k_Vl=Q&S>Ab3*o&O0ff$AAPCarGHukXgW9QtMraF->Tdctn_AB z1Ov<@D(@#^NfIR7J+AI201c0?=1I!}p><>4;`-7SBJZa}0GH!b4ZYzOEbOF$VzMjp zdaS34yeTA>LDyBj-BeSX^1^9Z*gC1#Kf=bNOdlq&74$r_2fc)HLbADT)GR_KXg=A3 zEKKmlAR9nM&+^0?8F5b*EFk{usq7?sP^l)fX~VOY5ifw5|0qx|WQ2);+xT7{itDeW zF_EGg%^<=ORzX8M55@jtG5#H`oCLbT(*a!z!X9wwGIS3p8wJ!_{}ssaxw!tCucZwQ zplD&e2hMe97#peR5x64XhevU*jP;7ig#^kl?$?G4{I{0{B;<_5%Hj-jeJu7r?JjF- z86O;kAp6P)OGri{hE=R$Zyww!o zue=sySB3ob6bJchc~(6Mej8phHe3r!6=3zBEf6IiumQv`xh0}BE3rQz&>{Rkw$3%f zv?$_hQa?=hVJgz&l=bN8@n-9(M7{qUMMvC&Vq5yMhqIDH8jdw3{YnWh_`k;1s5;`_ zTeSHfi)K?9k?)E9v#F(}LXX!n(oWGi-$Ip;e5 zwutt)}By7!LtzRA# z8EBWqWZJG3F=1c{bB>MMNR!2Mfu;JZDWJiE9uozad?cW7g|D3`Bgy45^B~Wd4k54p z!z&!IWIhD-C2lm=%(=;fk(sF*P#9X0GXXG+2cC3}bxbU_S*ee0mD**6 zyMVm!WhsE&t%A64Y?%`^kuLJS^^v?*$&46Gaf4mT?M805Var9u!qv9rSgZ#BGG0Vr zkgOq2gAt&bAw3}X3Pd27&)fDQzAArX{aeBi3qOIRkrrq28u~|64Qs1m0Sx9DxTt6^ z_CIO4H1XZtO}J5*&7w7!5&sFJQO8#6skGBDe)V_DOwEHh-pv}#F@8wtj(k(50EZ>c z$X#R9=HI!mM0fJMEuFq4S{Vt`|!qXSN{?60NtesJn7lxI!UiV+_zfUcW37{MX{MG`UK$K6o`fI_YaiaW0CS1&|!<`&MIC#ii%bjv%QlAGU@a65K+{)i={7L5^<;|U*;7(6)rzg168Smx# z!LE7_?gvUe!1!u~!?u7wIM(r~C;kU;yAR}5`c~A}G<-hS1jxM-=D^6CliSVBd)fug zkFrPTt6vk+WybeQKXjS--~rb-8l8#Gp5Yd6sct{RExd~p%hnblQC{}dK^j1@53rsx zmL}<(#`aP3qHA}U#YXN$e-;?fAG!UF!}s|FJYc@%De|bZ5sVa;7d?>|J;8xaYrr`u zqX+ag0{xiLW6E8`GbS+QVqq%+(lO+A``VT8VDPn{ab3Rl0_jcETY)pwH=2D9?)Mdx zMcR;xrFf`wxA>|Hlo?i;2NU`2QOQY@MW^;OjH18LJ5y)~hDN*nlJ5~de3OkQ$ zdrL>S{O`z0Io?UUhzl}Q{&x~(Q*)6`OP-`Ec@ncE=8ktsAUy6U4_yYi;Bn9W_PL8b z_rD87t&^GGKuvu?EI$1*z3$m3&M;aF=FB&ew`9?Gn?A)HAuIzl#dthi{X3A|8N$Mi zn%!YR0&+aEu0&!B6;0dJhG&IiF{$m17XDe;Pp*4+pIQ*y<8jJ=TcXC55vWkp%o23U zMmz;@z&n3GK*+3i{#R8Pl8IW$3Wb@N!c2M;X40!Lc`Ows1xtlVQ@O&Vk)SZw3-wY- zHU9uoU)?vPDSwD$QUlzr$99u)HWSDNgv&CyEy-uq&<-ZA?B1~kEM745l0U!uf1g7E)u4=lqk z0to6KFV_l%iKkr;nA~E8n}|jQddttBz)ltm029aAj$1x-=3%^wC*iWH!h{H-cpYnm zD!#bubqX0@l zQRrn%fru-6LCQ?5e!dBX5jRf>v}TI|sGW22U-d*3Q05lO$jq|M`p)uIi_Tb&K!S<(_AS6*g%gR{2FOX{*+4&w~{W?>S*7!oHM~^;wtDoJ zmjquY%{`6=!BxpG@ekS%v=+PJmZ28!C1i+Q8n`3t>~+#6D2fS)hzslOaIoIyNm=Ia zR{n0Im@I%A!4Rx^@VlVM?iIAM))au#)8&|;zgKpRJRdKrv&)CA9(}O9IT;E{DHzDviIiJP({{I zZrmW!3X2C*N7m4JrjCpo@~|OPQg#y-4@+}dJTjQ5phyKSd5l4@c%YyW7iQfBi|6c1 zSv)@-cSRPm_ROk^d6B577}d+si6Fb4Ei?!HOIRZ$bD7PA@js+0RzN^`3tV=R85_}3 z4o3w%_e)MB1XumC!-huOa{Ei>X0R!ObkcscYRVllL@s6VQZ=g*7ouos^D*^C#YMYq z%bVfvf%eUBR)1<0E8RYc=%(cDGfLyWE)$K|q$v+fqO#2*} zv&6rw`m0drePa*&HnxjG1I4Du?mq1n%k)E!8LCSsZ0x0^hXyVH7JP;h&7bLwFCUvpIRv zIQD7#{fyk1k`YoAa=o{zVlZ?9J+jgY3eK$mB<+{EZ>xK)7o;+DVYk9~R91QmmMS!q zqNpBlB4jt3u6`H~>nayx*=W_3m%$N`-@(ykJqcbM2Ouoy`wzzmTUBlQw0Xf<>NLLlt=c zIqT~&hnp!Ok#Is=S3J%YnLOfNkdN9R4>sEKHiMWguCDU@i=!)k=vn(zu=QF9V!Lcjn^b` zG)S~aGAg4k!i6T+aw~)ZY8?kuy2uSdIEc219A_%AmX9`*I;V5^O_QDV8bBb%eSHVb zYopBs5CkOR$0m@=0Fu=FHMk&fWru_~z_F8qawnHU{ErZxX!Cx*awI7ABHA-TnOB2$e4S@Jt~F@zy6dC`3!<&ij?xGWq;ps|@S zK%V1GgzMSSX@mvdA;dr>oTOGXZ0B?}^e2yx{{^52q55eQr{1s?Y-I5*Dq#{tL$F=UjZ9=X2DOxZ^uBX;Fc`p?xBFfF)A_vQ!_eGI zxoScxZdCuV-i~i+B@(S(J1Lb6W7!4)b+oESUr$V#<_D^W^0mbJxWpmdYfSvu0aB}A zm=(c`uxRcaTdjtCMd3kyzlLxsa*Pb~TmV1_cM#WoEIl8j!W26jy+6dU{7l~Y_Xw1H zWA}mb@~8Z>JJGrb?w)cx_L+ ztuE5_6mDu|ih9aYwh?SQpZk2N} zT+_`#EZxxAoe>u=Vi35WYPf;0^Y8_fDI$tSk@Oed9o7LB+v!B?3(S-rw0Mx4Q^vE+y_IK$0B>_QaV37p*kH$zX3XPN*y(OG zp#dFz<(HWJ+|_uyJdJUxQe<@pbwvtJ=B{ z4yu6YD-6*<9=1nl)uJ$S2=VJG3NwdL;c|wQ6%bks5Mh`!&E9w(hKa5K&0{%iMPky9osE-_)5E!*KtquViROj=+8Z>PCdF#ac7idHOkKg4 z!6KxT${D&=^kfJV?5+nTIkMQ54%0c}KF{W#8hOIHd@h#N?68{Ip(E;6#+B=iqRa>P zl3jMsL05-1JJz9g5y~zJv!cs{F1!0lUdGT~q93Z;T;~y+rldiHEWzuzF!R@Pf#a{? zf*gR@blEDkV#iEwDhY#zE*EXg2huo3$-wv!s~q_jy;+bWl$JBPI3|Q|S{|lJm&2Wf zFM6_LO^Sg}!4Hp_WDw-owm${xl|f?C8^0+7(Bd}}1x}ijI&AP#UNKOo@=81q zYw1CpK%v0i&^NbGwt_MT^4L(dZ9Rv!g(I4a{c}3sj%Azhr2te`- zWV$@Zz0Cq{Av2gGj3mMUwZzaSA__l*0){v@o{2Xt-?ifpXqSuatyp_vLDs1qx-2{V zfFOHNsl+{)`Sr8!I44c3^Jtx5&hA@6vGRbzMzQnx3Kn+dL)!g72t)k?aojIc6q845 zDNRZuWVi5Zz$66k^T%1ORzH6=%NgKq(0{#_S+9;)r7na1vQ?bHGDjU$$l@cI%wQLC zk`o`jq;*^EZ((hVewMoLR>I$uv?Bx4eT7^9EQ&qY|4*VU`}}XpcEsaj z+*H1$M2p4S$v|*J3mWr-axs~etQD*RCFLg6vexcpWRmWrar-hEVL!*yh+|ZG35NCp z9-}Butgvbpt9GrQkso=NSc@ZyjAFN;d?gE>PhQDFLjFn?p6!(^fW|JE_+GDf`FZPb zhdR8R%BA(QiQz{XIbt{k=gDJeENa6fA=vXetkappg&+VPL@cNmk*6 zW&mTWz_rUUT>drTH&t_Mc_mjESgPhWb>SD0 z_q9wHk!4T;CU$7f)`uIro4dlAV`28yUdUr;$A^$)8?!WT4yTynFSQUA+Tk;((GwCG zs4=XDsF5lg=?Kq|Y47tnD{&WImDb3%&eqTLyV}Xbw)lHkCK1bMb(K&P4+<_f;~y<0 zd*19L{(&1roW>0-7X@A5hyY$-FHy1B%eKZ?gkp5!dr{P_r4Z^=vW=FUfo*U{ms@Y@ z$=DztDa59p0xNX)8k@GA z;?N3WGLT+gJkU$0xHfXbuJNlENx(o*$6M;BsJ+nCCE+5~#e zqxy}S~&ZK$ql}sv$S%?6bw3Od@@eY#)-b?~>;r%UG zrr#KWgq#t0E*SyldYNnpbG-~3Lv#UIoX{4Zg zW3K<}94xC?G7eEE88;+0h$Zo`gB4?mY$X+h08oeW4!ibPIxoB~M7s$J#T+HMM%*z;T zOQkPxa1U8;v{e91uo2r(%xj?LB_nZgFktYjp^vrJDF^*x#xTy-d_@y*Syp(_nas-f z`?-Jy9S*Y9mh__nGs3%OIVlqpn{k+x+lmrwMcU2>g?HB3Gswf1x8{2`$YyQ0uul`S zm14V#ck3w$PZfJhi&odEZPc*3Vo|2eoJbp$3RU3lKD$#(x|4Mma&2 zM(tf9Ew&q3QxRY!Ps0cufbC5@v-nFBGNjG=8MlA0)8^57y?)8|k~aGHxkglvcw=6x zdHR=k}cq!-(cdOvAwP>o@1Ks1*%2UL42 z1eXpJFY&$G&av&}*cBTVF@7VFS9q@+6l@Dlc0q%eJ}g&37X;hq`oro}?_$JJtM|Xb z!=vnd0L)t;|NnId01nuj-^z!#YBgHqyp=7r*#Bv~!Hw!ayYKQDhx&!jA2UZN z>T>1{6?SyKSJ&{vg{pl z8bRy^NfAn9qoIFLZd;=WhU|&Aor~l!Lauc?j1brPworr3-f~X>hmp3HbsjRjQa>CV z%|1danECjG48E2fIR-SgR&(c3WKM{jQVLImsOU5D77dy^>2tcZcN%4X)=B+h=l1V) zJ8Wg|Q;+t3f$V*{U87VTwJ3M|m~=Z%2lDMWT|uS1QIAb%Vk#jVWW6E*^rq_iYW7iz z0|@s1@A{)v*9hAmdeISH5|M8C22OT>V_q(&*DT`Ug{E{7qZwgG~4pz0HWd#92A z4N&o>NTefsmUy5_3pf1$8)gl#r3EY~Z@*KI;e%hDsW0)bJrF8M!i5H+HDmt9|u#T?EM$A;K;12|W$6onueG zt*14Z`8>sX-zj37tzZ8aF?9YJrt7WUlm}=1wI+A9Cw37G)DR3@8cjHy7;S+4EDX#6 zTkg!N0GSF?u$}HendI0Dsn8hPL7LMMm1~)OLhm>S&thJ8sU%6_|B_w3RfV>W{I{Z- zwUs1|<-d{s>c7_qDVzIJR3nEU(8%iGvR-i=C{if{ff!62>7dDns@*zzF!(x~N=eaOi+ox5onThH~^FA zk$1unL&d?Q8&d+Bk#q_X>POMDr`JUGA;_!QC+}qf*Ln|L^bV27ap5*=l8U*fqNG^S zppiHDYVlSIO&0cR7uiAsIRT5M(^U@>im85Ao+T#D)z~5uL>6fv_4= zZ&lXYnDriAQq4pS#KMz^g^NeJaDis@CNA!-fqInAn`iR31&h%yP+NH96&^YmSb`Vk zMYuCcDuL~uln)4EcD~hrfVdk}O->j<$W%}!EJc{I>^$DNCzrpD%h?71T2JdA9NJp{ zfGtg3BznW-RD}i?Dj-3N%>hw6I5hUJe=3hS!M;Tfr?NQA-t*TPHIzs6)@mmrHV!f% zB=QnES}WJ4&c<0Jj{+sx>G-5bT2T_PjajNDXgBf9KvLL7WW`UgRN+c?czDEm74y=X zQ8V|9mVh1qSKtK53_Oez%Il}$H%2QoUhH2}KiAob!H5j{&_1w{y;suAV}T_ox+^l5 zJz6AGvm|?54;#qsLqYxlJDZH*-7yg&C`MSb8XlZI^o56xhR2k{(CvwJ65<7Pm>21u zR_s3s3Tc-pCkt?*iVcP+8wLpuO`Tg{B7J&7O88JjsvRg(>v8@<2hcN)2{O> z!*a+9P|#Ipx6lrFR?a`*S=B4_EcEw94|u|rKp_tR!wvTw z@HDk);BF-os7Jyj4Hs61O4J-0N!dls`~weo{*CBxC-v>!+(gwC;XL&}DbMP%nQ4fC zUBa8VV>hb*!dXr2^oA7-lv_mmVYDHxDH4`1dS4=FE24s+`kiG*yeM0-19@W@;~$Y} zyva=Cj=}7!9G&GfYRqZW^1aXS2Jfo9ip1A20x=B%Revt~^pcmb!tYo6O%>QmOsbu; z3_-q%@y#Nle2KRmavP97*{|M3*)<_R57qj?6@htD^)(K1^49nKAZH~UAqgPgqf z+l`)okh4$gQP@F_n%;w)eJc-g;vqR|?~+3!Ah2KVLCy^fu3KKL!(h9b8G0eEZ(Etw zipEa4w=nu&)_D86%y>VFk0k%L&E*%UM!cTt-JvD9eeTDk5_KoF8Nl_Oc|c_DMhcPGjGGelpqjx^FsxkE(L%O{-) zr@)^IA3<4Z6%^GEma95-l!%3;v>gJGC;I{i`)<~Y9jqlMUNq5wSS#ILFXn8-QVN>m z+rca_-z|Y@-*{L@taVt&F;^kEYmTA#`nL*n=_v_yd~|p)02&QRR1;UeL?kdf-yA5F z6JL<{eEc%r!TWj|G~zw~9lS`LB9gKAlF^5q=FNhc0n1;`qAl9Zka+RCK8j?Mdvm=n z@=t)(S4uP5n}1{|VsBV{Q+TObRqyqBfo)_jBnKM%stD2^4zEc>8xp) zr0zJ_%F)zu0-V{vT*5|7D`+M~!uAs5V=e^3LR67#Sk0yld6PsL{ry^?>^!ZY+xl=o zA0zbNtS{x|+#`&`J#zapap9#q4;$;bUIj9c&+vHRa};w>a(*S7`o zYzMhD>U9;@WNq4T-uG-!`UND|nmEZx$erXoo0B}SlyOrB^*5BPSB3R#dCDtQiaG6t zO{NmR2&lU(a@N1SWE61l5Repsqq7p`)}gk|B?EqP0vp z1sC3@Xu9wf6k6#BKiV_IZ7wGwCog8a@FXY>$s7q*@?%&a=;vSt5>DknHMGd=ydIZ8 zemaFU1w2tbO5+%fk6@|mHHNj8Td}R>Y+K9qY-?$X(W|z8@>yczABHhm9ng%a((@q@VDEju*gqyh?7bF(Rh)ypufQpk9;>XN zGD}$DD+?PkN+LDD`fI(gmRl3QqEW{y;Ert~=xazTUUulw7{p`gOyo3q80k(@(jL;%6idhU&jq&^ z0M!`h8v%yd=$u*L=q?tIxV`+I;IFv)n@f_6jk$D;t)g!v**YD04r@vMNm%3#tV(fS z;b(Motr%&950uue^KO5gw49xSlZZlP{S!TZvoO^oZwpZyj?IOZL1C zm_5a6TLuP*_?Y1@w>5i*n$yzxokJC%9xDFoc*@GogS`uqsaOJ#ONY?Cj2X$V9MidI z(Ay9S?YLJT1G;?$NdyzRl#{qikv!P2LG}cLM2v&1&bOYS5A`EzX>!S_wxiQ7Y*y4S z1u#3i34~0rUPYMm{>Nj7Es*Oe8)(q)Vz&!RM9qSQ00hCPu&qKOqPryQ15|E>?EA-* z+5ZT39)^gB=v-;vmWCVhAl&OsAZ6^KyR}q`cpdmE1K&e}9=Mn3@-2)zpL{U9lQ}Bb zb#O!dd%I)p3&FtW!zn_&07}9QnoQGi)%t7J73wbCW8n8G;c<8 z1{X$!UT?q(NjWK27%eewRCUK~g7M)5s|#K8M#rNx2c-R+A+)VG!o4=F$cGgnK$+Ul$Lbt>%mA zdGca9y_ilMTWC*A9Z&fZ_5m7+)db%$=fm;snfayT>7;$2{lLUj_Z=UdZ!akA7~f7$ z=jQb#cRkJrfELqZZF|nYx}Ep05=F|=+|l-IIz1J|QTS)y2T%F5{Nhpx)LS%!0DBln znNxr}W}Plf%(VG5`C=%fuX&Fz>dWbS=B&TeI?FTpWVt?|{$ii_wh!Ig*TMxUpAXN! zQ$HT?0DMc9J9lhqd}3*7VR3F@`p`HZG6x}($0nv{#&bwjz?zttnxfCe+4gN0e!gvb z>F~JlIG&fBoST{FWAIZ&OS62we5yS;Ju`8P5r(g@TaO1OCXa@m^&R$OOOuBuW)HQ; z7xYQ>vVg&02pC^no}WK<{Mf|e(s+AeVQyi32Dl~;wfUy`QahiR@lbRcm~Wd{m?|Gv zd@23HpH&y)57-_?};Ak^Ri~6GbL5j^S94|_SufR{w&Mz;ebNV}&^2zr@ z?djQDCyq@|rTi}QpzNi&IjDU0(81+dxMFTLotkSerh!W)+w)85&VASHF9_e=wm{L8 z89UHkP^%LQhnB^ni;$vWmfv)yy>JNHgwMLj6DAs;m{g17bTzf8-^oxYz|>xxT7qHr zLF;)_(^E8CaBJWMlLw145X1ET{3G^)Z_lp%JNcCT@=`mO71vB3JlI~4>D+Cz?FB)1-5lLrPr)42vE_x?GQD_U2v;Mi0I$6;%_Je-Qn+Gn z3RpzUS0dB`Z(QGAnoxCm-L=qee_xxMH&4&&vUg&6QP-=DQ*ICdJiT!qCa0~5*=%ZR z9|dXuMllhT)Abl-f6E40J&vR7o_o0YbnL$J6^;5}`?k)Yiy7|$E*;q{_-5vAZC^Ki z%kuQp^wRNcc4}<-_!vmGyM@{P5{ZkDDJ< zx*PVr@y4Aw8oLRgxW8VMu_8aRcbe4yz)3z&EG$eMm-s%kboly-SwNY3Q+qO?pQoLx3Gi|zcKdFKDJ?hF!9mS!ZM6}Y_YArgiEIHjq_7XUsjS?R~C4GSCbLy=%q)LpM6D<)R_y10D62o)-v6df=jlA7slbIZpd$aXs0 zJ~Sc4H$O2uJ((A*yO{go{P{AjkN5d#N57B0iNA~ai}?F1(w^n- IH~akm0nH;legFUf diff --git a/locked-asset/simple-lock-whitelist/scenarios/old-farm_locked_rewards.wasm b/locked-asset/simple-lock-whitelist/scenarios/old-farm_locked_rewards.wasm deleted file mode 100644 index 064e2a8871750cb787464e14ac4788d3be6cc663..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 37790 zcmd6w3!GfnUEl9xW?!?bJ(49$mKC@&h_Wsg2yi6fIIwqZ$#UX{VkvQ&rd^MAN772W zv+J2z+oHizY{gNC6DttF4G9s!U;{BRA#Y6B&_G-;#DFQLgw%lBrcEFrxUEUkq~G8F z+kH4!XOC3KMa$bqZ22Bn}guykV|+XJaKct zzxaeosmkuTlqjOiEue>7|l-rFVOQ!q~df6zF)+zo%DXKR6xS5ky}cesSDr-nwSyNMq*M z^^5!J#}^vSP7tbaWMOLg(4j`_`o?WRNd@DF8=dQy7t+?@WwmPi(n@>oaI-$YyVY83 z1%cX)(QayfQ5`mC8bL*6!w2UMU(@WQv$H{2&+Gm3p1I~+`^YPs>Z36mM18OCURsf7_(Hu|KirtTsWsPWT)TMKPs(L2uWod% zZ8Q&ejs$VfytKv(dY-Rap7-+{@$)=z)!ePV;DRnx_OuokrjB|Z|EPpE*hx67Z2-W`QeJQ&AuDIO>VrBVKs_{T3lVJVJ-!NDL3 z%KR4wgBMz}k&OcbrGfGglAs*Lk^Z0m7sqRd%6bTbfgl(SHX$s6C>$7w*9O5z5Jh2F zis(3q!$DR%JRA;P6l}gY2$@D$Vj%wGPXGB|Zerdkm9_*i!?EnZ4FoR=#zH1dMNIEu znO3DR9@T5%8YVm#^HW+AmO+7-Y4G0wn>sWYmxFQsziuS>7IjuGf9p^=UNaEHWjY=j z8Xqb{Y6C;-g7R<>m50M#t{Y9sJe7O9vJj3yZDe zQBVT!I>C#FW+1ew`pmIlU&8Io@_fD1xUq3ty*1n3v)H0b{`Kh0 ze0^>qs}2^&XBHQh7MGi|dC7g@1+eq!rPku?@=Rm8<@*VKHXKIoG+KM=t%cwh!lB0P za~->XZz$O`1&9}6#{2(~@fX2|{ZLygXHI0Ui-`SwWoA}aOjb#sSXbxn%8 zLvx3h{X_8aa81_0c)>NZ!EcA_dQ0{%FD=a<4;~FAnbgr-^Kjnu--lx4*Vfw|6N=Zt zjA4qw?}Qt(V!zBD5&65}x2Xz|*_ch+ZS^<<(H_6fvx%HnJr-U_v+IEP!tz2ks27sI zZwuO2pKFN=ws?EhtDm-s?rT8so#Xo&tr>~=$8APD*;M?j(gil66a0a-_eC_=f20lz z`NL2W!x!GzXg6B7HiAFuDa!%yL^wpd{T)ys_+uNRVEssuVvGJH9A9X(4mY$Cd$k=r z8D6kpJJJyEc-8kzf3GToFNEc#`f|Gwd?{SpY8;+xXGmag1%De3An?#hg8vy_Xux~U zz6Sp*T$k0@JK6UAy|oAK_4ykY=Ns)}Cc#(2jkG@}X#RJ&fvOvq+G%r^HMTN~^Gq+gT0Mkl!ec(s$jx5~N$)u4*Zb-S=1Hw3L434HRvls2olD|0SWjyfm3a z?(*GZVG_HS>>i6KyTZM+7PueSJr*ZXVmBrCgY-Y?(y6BdH|4IR`t8x~(qtM_e^tfp zo?3a=la87_Qz!r8^BcLjI&YE$biB9XuA$?XxtBB8%iOg|$zA8JPs;AP@k;s^Z)9E< zxEq4L+oxVnX~jyPQG+$BZZ`yu$?Yjk(!-Cc!9^|(DkA|C`n%A*C#qEaE%T_P$<-_~ zOrrE1Z=t1g&7hJ5l{K`O3fw47zJteMy>Me1wkxB);=_?1Dna_kg4~!J_uYRiQuk`Z zlKw3qw>F4tW(YHGU|?Y%k8ElhX9Fz+97+N4SIS}e#J2_MQ^B!XuvH6sMXlsM z7S+NX(Y|PsMmLU8nm!&Jb^EKVC%tG#RO0euKe7_+h*ULkv?e?|z=o)ht$QU6i-%WL zBNtZV7|dk)vAs|Y|kA12lLtI9dzo!u`v0x3Id` z_SG>+_hr3m)f0K=0ECezqDw)Yp`)s|!F%d`ZIEv79XhMmcvXmj_p8spsOWrC?pajt zvb#MWc)^}~-}6B1uGoXCA0*(1hsilW351I^{bP*$4Q^EW<(+`Q1M%=hI&JAx)!pb11?JBz~>%vftY(ulE@1)3ZuTqP4 zM2^nE&rw}24~D3q5DH14prCSuF(5B@tQL#95(vY+s#<~$Xf?`(Rzso+Af%sBMk=|p zQ4&)CLWyKRqV!W@b>lXDYOMRDbkw>?offk*k|(1(RGdwU*GG@m;1f3VgCG_x;}_`P zUVET&HH-0YMNAMvPKP?EmR}vbh1*S?mI`i7Pkt@7=UZDXTPjpLdX$c~ZsyL$H+~z6 z75y|Cu)5rStY%$`LBvzR&Y14gJi7$zRodKXr*B?zv#lz^)q?|t_(Iv6l8I>^~e4MxM^>>TijctYQ)H)hKOLxSGd0k#f`53jbEnDA}I#Z2`%4UKr8p<(AfQy zWOd{&WYRDQj|Z{jOn&=lajTMSaT{ylSXgm3%`mOrFgB0@45{XB+>NY?==k2q%j~Op z9#Bd8wCE>5R)%iVX7K}wl+m)_3AhE#=mdx+aM1}kA$sfrru1CEP*j0W)8;Du>^%oy zLI7i%9J*Hv6e8{Gior|VfxppJJ58X9U5v&>ZB)s&wnxixXW%Hz*t4&Dur7szlaNF30>N8HWTxcgA2m%O6) z{^p+Y{(E6tf+*UgpY>8F!fk;&pE?n_gF@LEHwz{-40WO##v*sf9j=yL2?Rdku6DC- zPEFj=YRMgQv#c;+Kg$pq;BoVywoqF8teV&@n7%z{Zyv3<0oIwof6#FK8gr3^`kMCW z$KBhC`U#}~A299KHu7g8_v;a?Xce~?iAeT{^#IEuYx{Fz97A1hUvc!?gwoXpQcD>?VBo0l1c6 zehG65O+K*dOalKBIQ)G&zz00g_}n1F{EhNz%Mj1uk$B1U?t) zB*Jc?frDlfM6zqqb6eO7^9j-~g({D?1(3&{i(N-I21&i)mTB<_Es#a(=_42`YDE7i z=?rAOx?Ab-Hkp3*9J$+B{Bagv+8N)>WpHPFgpwcP-@oDC>-hJ>H2nzuR@@yto#5Ze zke}D<=gzP?O7+R;Xl*!IHL%-11-q4cG2-qD-6>7sGvQHN$&;bjiJu^qRr-=1FsRB) z;_Xx6E0{UxQC*j;E(@v`(9tvDQN346)VDE%`|#pZM}+8N&m)RGH!#t#d6XXB%_fdsuH-E=gm zxHo8dk28l-GLY_ae?ACVrz4ogo?PliXe zwPkIet?hJd>hrUqdvmxN%-VoU;v)u?huNkOLu_nyBg!BJ6rJjN53%ucv_Mt8Bt9Ki zHwb;+9#_{gm8Y`}dur8&m5r6qE!ru-tx8Uh+LjFS))U!VkFR=b1lXX~l~!%4yC)RT zgxt`of0vnr9t~8>#BQ!`^b6f2z1O$!G+U$ z-n275sq4m_@w0Jy?_Dc$7rZ5`4MMMP4U@rS)ZMGg1?~(JcL?rBXr4Y&!bGlx$(Rg? zHMD(On5^gWqhT`6<;TLr`N9ppaIG&a`wNUxFI?#BhJE3Pzlc%19UaVH&?DTBhsj1R zbd7}5Wu3ohitGXS_7gzd{iJYqrR1f~onEraGjmq#a?E@%_o#GKw=aejN?gJ}O(8si z)(iK3?2Rm80-ZC;ty8qcE-D6y3dB& zrQx!{q?Yp*JxFERr=J7vgW+gU2`XMuqmN7C#2Ad94>RkTj>JUIbR^`e*hBmdG9iS8 zWct1Ymc~*AYY+Loz9QiXAVDh$*3emPbfHEE$>5IYX%#`$X>@tOt0^4WlwNM3+Whv> z?(ItV7HN<-faB!1faO6tHTqKL;pI4g{cLXM5!RNLZ7fmZ=VZxvMO9jdX5xO({RiIh zt~yx)rp^YHjjDey^|&fMX9mF@3@e*e{sGEgo|kJf(vvHH7)B+pPh!SN|F8~f;E7n< zgPCNkmZC{L4<#iw74M$x12|2vPgluee59bW?l%e3AW$uKR7GF{2+ZbV2BSl>S=xKl z$O-s1nxw24RA^{rt8~~);!SeJ>N#QMee>uJUe?Hw`z0AMl@vb@9hgO#M3swqC;cSL z{khQ1dN^oHY`q2wWWT#62Zgq%TlE-K=%oHF?P<3PRxP#FS835ly-hBcYbpO0V|ncGVlK415Hi)*(j5)v9ffN-uzJ z0ex+M3uTGAU)KI!ir>=L;d#pysT?8F%d+>dh4Q*N*qHUz)Bb2xU2V-8Cq-i$q*8ew zkw7%*l>MoJTHLWYpo4EG7@BuPHLwaV4y7z&RN(G_!Y3lvXIfY%6VanNhKtJjUXH{; zkh8|f>BC`%2-ShiUuml6QqY8-M?wGl!^*d7jv%4U74$3Ss@c%b{h|A4hzmtlkEU+( z=}sL&=${Tl`r(<%7ENlsyBl8ibXa-mH`9j}koU03Jrq_pAa-n}LO13WIAm32pS1as zk$nu28F4Ed0?qA%WWiR^3P~9-tvfdqm?(PzQs`2P@GC zh=+)JJUmt_$wS6iI9R?IR)-O=H)1K^9Yo`}Ox&wFh)BTuB412NoCGh3SobcT;9b=b zuA7b`<4WLV6+G4dVzrexLy0sVQ!-&D1FDqX2jXBkx_99_04M4Er%@2yXW9R&C4j_Y zdHzpSZwr>-OjgKSzA95oOQIDC=do$=l`Hs*b_(Pl&gKiL$Kme(g-Mho;c(DTB zyKL34An@uHcxWL?O|7!g?zi8^?Dvx)gnW(#t?t?H$n$q@3+nCs(GVK%?HrWRa{nQn z^Q!HphduqE8zo%W)JwUr@(C`mfUR8C?2I>Y83&F1HnCPCdBJO+-*n=gqG`}CJqt}o zJxB%uNlEaeC@jk;6t%C1ZXSd>d-On7hVg^(DOP54Wy6qAynBfX%kCqFHf{!Y>1<8A z{881G9Xb{-Bgnv61?(>40i7~-XRV`A@`fFP7gQx3*(6WXa>fM ziiz`#F6|jnjJpFjovBVS*=k_z+JM1?LbS zq9ExOz=tR(bOr+vy7}YST5?87>R??--TR=u zpQ)|zHmR*A8A{rl*V9kysXG(1Rw*dv8i*rPusxe=?G)$oc$g6|>DokWOP{e;{{cHik(Qa_bU>1uEQMZkfFn8kgv$76x z;Z+BCG%W_-Ye;-48FB=~Z=y%>XDnOd$q1EU_mh!T-jodHi%v@|YmiA+gG-F8UK7P3 zg2P6e-~#P$<$|P7xWEEXO}sS~PMv`E8J96cA$Wx3{QDxg0q8c|!3TCR6`22JJPUw3 zqV2E%KRY2tW+r6zC@VjJiw9Wl1uFD`t?1sNUWesAQ0G78qu*Ayl@SqzRf1$P2h%^h z2dJzURBSu)E+*VNiMy~f%mKoF-Zf2~(016mnB{iyhj%g7wqR1~0^4koT@1;p@zE7B zU2F@6Gw8WjZNyY^O=SB{%-)d)h`1QKZN(>^EzyH6hCAUS8Aj{EkQNMBC3htpDA~$B zt(A@Tu8d}z=!ej#U!4LJ9!kAk2u0ZGM(1Ut{#4k_0lgPC<-QY20k2foDV z7d3|p;W*2O$e#XM4$LU8!-M~xh;q;SeUde z*mS-?Mv(rkhS_s71z8 zfA2Kwxmcd^Y=XHPpQy!?tBi1wF;FwkD>~`3rau?ToR+o=uR6C$&BlBY!&v$zi{Dy{ zz?5zzPdhF??V%IN)uNmc#><#Ybcd<}3uN-D5rpe^bG35EyK=fxD+jM?E!3FZ zAxyZdd`B;6KsT~O@B=f_IF6Q{G57j*II^+~3~4Tk11Ru-WHn;s7h*1g2JS~~1BhWM z4iR~*RqV^Xhsg+I-V;{dF&eG)k*ddgBURvz#MdS+rY6vM$(8~VYQ5l`Er*{i7OcX( zBa(>-R)symD#e6Cv7_e(s}diqlGmdo-Jt8RkTTQMrs@V!dMiv!GpE4jLv1y2=E!zJAuWM1y>dNzd0?@+*t0XJ3z*Kr4&)PD) z1)?@zoE5~FgSal!kBPTis-`#?zJ0}mfL@uXAJM+y3=ZX0KpCUe7c$int`6kAH%m;4 zDP0oZuBc6VD#{p`U*L#GHlW$d97iBPrdJq8>@;g9&;z{EC%Gj?quVFA&7yjQ;BrBx z0ADwNcLtBmgG?YCFwqveQGq@JOQQt( zz&!=@EO1A_@2tcfin#^o2>4lGPmx)WT}bf})e~m0fF7oV1@s66enj=7mj|CzJvzvW zt|LA|r$FF}>Ol|-91`HOfFc3F)1~x3+_fSDgg_s0=h? zi*QyE=o_c)+rs1mE=UA&*dzqdE`0RQ3I}~5k!01O>#1%77hV|gg$O~_i9iYTL9@Ex z@>HPjLN2u2=r3#iMN?FuufU}N&-ow!27`TBZprtg!OKifkWwyV7362~c`~)vzDR-u z!Km2}FNr;VS1$BLl0zad(^BpUD-R6hi9Tm>n0oC=9B{z>p@i(S+**oCo&=~E7a0l? zNVp(azj-`SgXFh(Kf?h_p{4uP>|PoP<&mNa1F1F)T1QWr)X!DWv2%}#5pFuFt^*Zh zcdLeE$`fK8XtE>j#an+6;lc>TYa z$%JMyigoG%GNGAV+B=g=zbW`8>TW%G@V>i5-EHlGFG|igvt1x1Siq?X-`ys4x23nc z%d9(?-wWlt8rV^l;&e-zWZgmNQvUMYmvk6N9r~EZMra*G<&8wU0+FJiQ)%h4utl`p z_j4-EN7=rVxpPA4*4`DN7rciSK_WLZ?9_W`L$(*peG0eAQ=ycv?U{d8>Eh5R27)kg zmm5Vn$Q;-p?~drTqHwio^a^V6Dq4??*5f`}kNatz$AZ>rSkO9MWwcHwp4P!v2FCyxaz88f0!oa^ zF1g>J$HcY;>)mfL84v={Jgu`sgsCRU{!@CTyPy4aI}|Uj#tQNh9VH5kF|6ov)iM~R zCMc!^xM1e!tGQmaRf;{rSEXB|S9))OQmiv2j90c($z{S{5`U3VK_S2scF9f1Mct5u zu#3I@`4F!rGt+W}TUq+rUO7S|U%aWe_yMirK>+UKzzGNdm9Q`L^`|m<8WyW3AY|*!>2GD%NK|{%8`FGVe*x zR=UTZ4@cuC$_l8S?X^i!RD~(R8^%MbXEv!qZlKCgW}51Lz1gIudqN6%0;O;#eHNuT zJhw%Pk-JO_Y_l2*P(Le*&1LxKEmGRtN*h_NmXp|Z#w$%Pj3xn@@Ya}5H=AVBRA6VM z;AuXe1YA^%*GAbc_V_uVqUAj;=mf|y1&p7HV!D%&!Y^it+{Un+mDmSy8R(H%j7AzS z$)3u6vL1Wqt&Em%AF0bElz{wcH<^n*0g>!r8Q5kEAK`-8xI{_U7PfFiZHUZIBowM$ z4c+=4O;?7R^r*fur!@V0s400v^?cR=mcu3S5{61i7K)b_2qd#~EuJKtfQL#!vyfH9 zwr9`Y1kCI{nSfaer%XU#sTs%wM5ouSOhBS_+-k_e1f*z1tMF#A9J@n4fm8M$x^tiX zXTHF!1U7`hhy54I^b5V|ml7W?}vO0fBH&bS1|0WSsty*!GC5uNbon>kE&FtgpBy%~DyP={vJD%aW`w1tH%i``x^7a3wt{ z+Y*CGPCB!<>@wo(a2Tsl>6vC>St=#cR4=Ucmn@Z1<71s^PyEK?wr8*5TgJ`ObEZ@N ze3+X*-glgq!4#<%*O3$yK?2@Hi89U&+Z5*%da_rtWOUjo66e?g93si$ zlKWI7B!aU3eI&cyZa;;p1AS?WK%N9DXH0DzmKd+vO8 z81kxG(VID2nTGLTb_iW@ACVHuE$_tcCUhEzJ1N9|e!aZ#X3q=Jf_r$O_X|SAaKlwz zLFF!Io{lVc9T2Q4u!(K)W(J$AG$lXT4*&u}<BNO>E7oh_Uqgrry*SG4lB<@ zDhRm3ik{KSq!}-u)>Z4&zY~aIn7W+0g*hBP8jeS ziQ{xN5uLH$w<{6^&6pBvJ}FZ_$OlEFihsyEA@^nt?~zm(3_0>Df*Q^uJ)&+5h}^I> zf?DQGgfp>J<4_D0=|q6Y(%vA|T2EFfc)->_lufF(ZtBD^;MIBMifn> z9{STcf|I)9cKj+Z(m4b9)Fr^qs2ss{kFIdl)4Jk5G_*kQ$>%Ox=X0G2fCmzDna?ouQLd*DX(z8FnRcMUPlQO^p9G0@sx54?+fG~a>$Q2>R4D3WaqaatH@nO zf=}g@O0R*6VNzK7aYTotbHQE=TUA{*3{kIn2cPMDQ05nKuPqk_qN_yA~>k5%Ie zM_Ktz;@vV6#j@OoqRo|EjG)l4SgtH$8NtF5b{B<6$TG?W_9Ds3)??x-mm;XVCX8iq zBj}YEDz(ou7uB;HV)sVk1^oT)J?1shC$lfu`?6T?-Z8lgzYWMKpLdKVOY_bRj^ifmuept#=%-AYIopWsK_6OWFvNYG56Zm37z&dh1>o7zh%hTOliD@h^p zds1TUw#e@octZkC`sWgG`l`&Qb=bj=ou|!+8R=ZGJ`O|vLvF^Tq5HLrG`2tn@iic^ zpl(X#BR)CGxTjDG#wj=ZuL-+#^9#`f4sGT=VhciI{jAq#T_7}f-pnZFL1j24V-yU7 zWNi(|r$4xxC5$=Apgg}x_Ya2tOBT6@jTu&B7RYl5Pd;Ivq(K1TMoW<({tGoa;ne+V zjqwOJ;gifBfa+&7{}{oe=)vG<{x~kT8c20{03(px0nNZnWD5%%VzJ!dq)x+I)PhRC z1k0V-!bbXY>z(w;x2)I)SC|;U|FNj@+u6Qk%h2A-D%FORqDlP^#uMIBi^WPD7>cyQ z*04oLAe4{297{_3gTz9X!l~T9V?C*#nWkqS=CBtGvZ6d87Tx`x@ne9mqZgpx??Z%n zjiDhcQ7scduy+C1`?;UUz+h)ny6Hvtb1*zbvbhH|mF!zcKU;jt=_8R_ySYm%`A47J zr$YNwfqfLqe^7~b^ptfl(S7CqQy>Kg<3(Nt%{`_dIiC*BV3=7Gn*^n>1xQ8W0pEOgo1-7InXRfl+3)c zr#S|(XDm$APBHABe16=KH15ggXAH79^u-b;eXTzT!`)uAz$njAQu2{>Bw9|AYLmHB z$riyC%R!hjCcnDAQuxrTh25eA=o62@=DL^PY72V!JpoM_xx9SMTc&)URQ!H~W> z_kHTTC?z<}b75yIfd+d@01jI`YHo8^WG5w z2X$!&C9?Su%~AL=o1YF!oNIpC1f`p+?n$k#(>LxWVL0TIabB96(z=#WN zFN=liP!7%Q?3`Gg9v;u*kJh0O<{#c6Z%;&=j`7|8Ro=5S!=7_FCC=r5)Tj;^8oiKP zwE~0PbC&QF-SgFf>{JdTJpr|`UPD;z41wPsP%%UoR2KMMHOe;uC*{Mj>E4_FPXj5h zjx$X@i#5W8oK7!XxYgZUx($^%2j4B0yltVm7%q2utnQAu{p$uyjO zbctg9S}q{MtGPfr2e`mQq0@wX{z=JXJ9mAg7re(jfs?#=oqzvX| zOj5kYA9^w}N3rYb(K>#PmeEzTwXJ91Baa$W)ztAu{xYyv1%+|{sVC`?A60Fv(?-VQ zZ_i0qNst(rR>+&iw*`&Y*7RUpgsU+|Wepjt(MhJ^>_nCNwvm0`0+Q@i(leDfVCI(5 zn8zszh5bs7RF80{!Yiqv#Za=1_@D+yWeSM*=?Dxl3i7>a!FQSHH1ZkhJabH|_%bAk z>bAzuhYG&hOl=ViS`3MIk56K%_mh!#*Zk5OSEQ-v%MRT$P`$S#P-hwLe3aNn(7zRD zOYutiiwf#j|47pa1!VeC=whYNN$HNsBzjE2AD>TWzJuNm>D^8Rcpm53aaa*r2Gf_x{-{)W zs2cXE6%!6bohPV-ZGs*`P)SDstVD;n@-#YGBHq2VdZb-O*FN(pOcM>VOFviijub%z zntNJO{!|IQofg~mbD1@pU^?134Z*}B6hNA1S#G${)DlOOlt9g2=OU2|-R6m!XQ^me zbDPQ5ZgYX#FFW&^WvOP_WXz1*(wz)DUo5J^S2Q=zP?jo|HMa$f zsySY&(uuTeh{Ym83ZMYtJQN@l8TD=q<>kC^Y8rGT$P&TGlh_D>kitkomcq!hr7)@` z89pekc}vowX-PrWlINl&;D>wXEs3Gfl7g%y&qYfhUs;t1Rk1{i~hN2KB!Mx?k}&PAjY z_7Z84iV7Z`i%6lmqB*Ei}wNL@JJ% zvjB*+$mh(OcZn26WBka7i;z@K2!lol6l8?Jb3q6Y*EdLp5Encu@AG^)$HIFcHo6M$ zM-A^s`|y6WAMbfA@ScVR-qTfv_jHouy%E&NMlb5S5(@M{gy;a3H$>jUm}xKt zdqG|4$rSM`>avzd^JV6}`61F+=rvn|c})jA1^1!#7E^8@0umKyo=r7t8Hj>ys$91q zkEOyDi#{Ks;)9d7Qafo=C|)?P*xB#PR1 z)}Y~+$$WR0Dw+p~y=tZ6hvcc3mG^)&_cOR~S9gtKYMyjn-&=Wak%PVcSZ$EBS#(*< z2!gZlcEvUTodO%6gMZTTWgIc6b_tPb0$}^AgzgB*@fP7$#T~dKxXPV+(w)-8eXTUf z{0>FY$8ZC8Q#6?jfEqPIqO6OY9vNQ~48S&RMJOimsWYi*2;_e&pfGHofGr;CiU;O3bt$X)!(WG+qe=a* zx2VT6>3ho^l=|2zYmjXH$lK-S>xNYuru+`^8_9E(9o&7SV~2I zrNMlu`pPVEn7;`vGl^Zvf-)Q{t`XOcacrt%XNgTnT9y>;X^)l7(@9uXAN^7Ogw$Of zAfxT2m}Iyu2Ghq*F_b*hFSP`DswTkR>`Y|g{(flCU#6<*=b z7t3XU9rJ1~Ao~F>9B|&t1v_Sv3swyv5FyOk%S=TNNBm`;j?g$zcFl81rCh1}n)S^| zbXniZKhOb4Y+>SPRW-8eT{5pB0zZ|)x@J^-s0McXj0e0X{p9Oc0-4sZ%3jkN36KRK zIHcESS_=nt<~!t2@=9hAr|+W|4zcLVLLLn<)it?OAwYhQ=4Gc3h!JF{^x3=ZU7^ww z>Sn|&@6YPiKBSob_ipJk-P^C}cHG*&MMK)hjM8`McAZMMW14%D+r*f{Gvflaofl3* zX2kb=W2|6`%mB8CAb)=%w;fBjR@UOV&r|>Hk9<@fDo3OKoQXaglBE(9AL5SHIJPe_ z{~ddf>TAPQk>vW?C}*cno^-EahxASFu_%44095(~f#BO6+&29$Lh;euk_9N*ciFyR zuTm%?ur+;s^pX(ilD_`VQwV*@p3xtOHnCdeHxNq`5=m7i>Rzhh;2c&a#l6m-*j70mQPSIEcWZgQBcKRP49U#nDC(}eXn?&h~QU5J1}USs*PP2k}w6U zb;&;DaV=2hJD1YZ#oH!)Mh5r9A9U`F9#np*%4G-F#H|yJ1CO+Sv_;84 z<}^1Y1Hqp=(XDHnMx)XIj**7*Qs>2K+2 zkT1R3(_?zl7g6l#2|cZW%iGgm>S+X_Wlvww(>hEDoCRgj{0&<4`SVjtQG&?21< z*~|7*z!!IL6zDDyQ;FUGAds{MA`mhFkMBk7OO^wR!2L76T2N^fik^=zBM*B(Zm`s- z8Pqi=TSPaJqe#)vaz7L%fkZ6AoAPM=PE$=StH5Sz3fjlB5HJb?XsWI90@J;Mu3_Mx z2%$`!#gS`^JL={B(X_xO{Z#@sSBG{iw607W47qnh#}>9^BTUpI`TQ4YfLsDB1bTkJ zUqrnCFMWqD4f^yZH@xl{Xj`zwJ)4JHnI3Fh`YS)9ZcDI=A%t$SveI?!S%!c(KuH`R zeW&)?A*_f7yPYZ2loyoKIDJG9o2ea$CW%qiw1$5h60(JFu#IK^U~V)})@r(Z5J4xW zdvEfA%mHS}!V%_xM;?NENaWHqt`}yX zl<$7joFVsCev`lWCeA7bSS(rLP5WB~fHw1hg9!S7=|(Ph4ZS4556U{teV%UcAws_0 z$CSiL$_2~$nvt7lIXY>sE!NJ194L~c_%fOA_{w2zQ=(?Wm)LH4dr_RdyMyVx$ z%DZJ=;MJ$j&`y|z>@Jq;?_r6?P;9!}spQQGe@XlWwOWPRKSL+GsGEP_sk5&N2lw*6 zeSEZnr~eHrfqnM=FNy<%c*YG7kc$3V*Y{V$Xj1?4hstDrctsBs=xTXGsO&WHTAu%4 zMe*r+Fn(__5PxPsv8b#w^p*EXdDv>oLszA6`nb&llG=QxFHbgrF1{Y}7rvl%R-kQ1 zbNReP_r~YZQ{JlntC<>dhn)`dS)5AZOasz5NvIr)l)0S##@)1C=d)#CM8CKyOGc7) zh~sCZbY#cRO8)p6xSkz98#wpzvjM5?kc0h6mcHX>1FMgpVV54WuX#${h+rPf@f$dP zwwd(QUS6>tQMQL2;-j%UR#(-6sgu!bSp7$}-hmzs$6bkKn*CX?OV9Bd$uoNIPT4W` zm(E=3$EdDujINbuNB9;u6)j*;(PSS&fKzs25sj?Gyq~l2S_XUF-O3)UF`mgbVor}C zNo!CCi1JtBvqU}v_Y$!|UhWd{)n3?w=Tb*uEHE}1JW^%=wm41cXqvcBAPB^y&0`|2 z{C*UAvTQxa;STo9DDRGpIeGf@Oo{10;gx^gHxR6ofsF6tQN>23U#QzgM!Hp@C(y_~ zCIxe&1G#Aw_sK>itimMH_r4j}uhpN1`(7Z*T;C){IpFx?H|xnw_Npy=v$^y31L3^B9-58Ny5z_Ub-1OC!0EJCLISQ9}& z?yk^)ib*%bTd+)1h`hg!Pv`_M@F63ePPVir_2d!nrvLO44RvpyexfVx_30-% z@m|lNXcEA}qmjvMgT9$-DmrHfh%zdjk79+nP0unXSP~uMlTA5VXNOrYVS!#An?7pT zm}|yD$?m7K)_YK}0}pk-owe(^ugl?NI4$g867+J84{@!@^luKY=^I?xw>&rw7gXL_ z91BkJ&u`>0fyfv$IKU>;JMI=8FarxBNlj_5<~58JXHXVItT+Q9Qf?@TIm*V?B_$ud zf($%{Af$yh7T6@}ptEMZ2hBtpxku`Equf%BZq*-VVLpL)xRtZ&(;=987(Q-+?!K1{2; zsbE7W`q88?I4$W9NSSiZ*uYH@=32xcI{3sj&l-Hc4kdIK`fXB5J^u?TcV+HrkLS^( zy2g5itb21TOUIIkW7r-K<@qV0XerCGpSM05`6NrA5m=_Xc%?wG)y@?4q*q#5j<1y) zi^XM_%3oIl6PxR8()L*|Sm%{-&_?_$9MzQVpYuh-9{;9l1<@;qMtG%%IwZjE*U55pBn+EzQ3Z^J2}hV z!yEsdhzeLj$WlOtl!5Gy!fT3EnN_s>lJ)%D8p-nY4z<)T9$3lA0u#g^fl}Qgek@ToW zQ)DVg0Q0#qaX!Ki4C`ktj~w$HH@}6T!k?S_Kv-EUsLx>b!aHCvmHq)klgSBTnZo5V zZHrN5>1SI^bc&%&HSyCxBk#o+Y`}j)fCvi0I?IVgnh>C7wpbpk=L-GVH;N1m#mQ}> zcK zS-wc5DnzN&bK+V&;7)-3p7SruW}M}pF)P;8%{J%Qsxo%8(46Tb&cyT!ji>URT1p?+ z$+_V#A<*(V&kpw$JLFwiNPDAOy)HMT1ehl4HDB(;iV+VcvHT>_)-z_S?)CAo8mtlgs|@3q|3vjKSE#djFWvs;Qcp@d8s#i~aYUiFGn|`pms>S{0Tx6JL!7c5P zJ~5gpynJ*93E3N^$aKo{(!Zpx*@m8F`B|Ae2S=+u>*7KGPs*YG5wst~v#9C!3R}nP z+-xkmp16QE8D;iY!kqAiH}@E}p|~7MAHdh48_v3ziUDj0E`gt7HJ^r6Y4g}&W2mF( zbm!(#nI7@tpohAI;m<=~hR3pAE5F{A4HBz%tb;&{Y#t3yQYXid@`Ft%q-FK|ay(F) zr@7?1$DBMfDeG|4fJCuoE+VzO1dMi0TFYS^lt`5W`IJgPbJOu@&JBuHh>n4SJyNey1}Uaznq|F)S-;k-@<W~_6EqlXL2QzNdEmeIaBRr-%4wKjdr8oe1Kx^Z1l;l?8X60nW3u`{9 z(BV%x`vudG6ey*fV1pi!@#quwY~%z--4mYw?-I}MglJ(Yd+;|q;uCplD~n{UisS#LHMJIPXOadvs8k^E4j zwV1RTx7Ay-Nqu2)x!KugHFM3wS#dj=YbW*jR--<9JZUuR2k9hK7xkIW+^vnq!cymW zGPBq`GT$_WsGZC=?DK(Q5lf(@Txkbo)rX)wq7q z#!GCltg_W;H(IwgI<0!MeTasQ+Z!{}hwJU>`MHI;P5?M5)GYOHdSUKxtFF~edpIz^ zj@2&C&ra7nomP9XHFtP=#sD%iU!Pl;&St6x)OW?Cp)I1t&QoG&Imd$h)TgUU3e!6qbrR7etsDFnN z@ZoS{u6b*Her`75cbNxOcNQ1H^5)?~%T1_av6;*+Hrk1&l9|R*C)vIKsslOVN4K?T zny_OB8!h!(ZyjD1iMBySgDk(vLZfvU+=R}0&=Vq>uFt5)X@;6@>vzUC@^fmmXFCwg zesDeOYHpTpb87XJVEmxH05Z%S$S_>=q-keE< zP97AAsI@&mHv>`#(dQ2GcDuP~O@w(#0TE$v(m7J^Buz~&qv5%xIEHPIV7O3k9`Ax< zcXM`WagO0<>dj=aIe$Dk*sz`(v&q5Z$>MEI@C?S(X{62BJ&P^jVz!Vec3HRAE;8Bt zfdyV^%^~hNwh-o*Kr@T8Oh>4GIV{gp&UKAWU9U6no>rsrLk(_jnp@IkUwyf)>y<`F zH`pBN%~vkL0_dyWOlN2J(~$me6p4XXJ&!^9<8Ov3hhdQZf^PmGjK2PLE&Nd9w(h!f zeCV58GI5FKx3G9?YI>%Y|)bjBu;B0rT<^l1?Hb@M?_Pu?%U!gA(v(@U7 z?v`Di?7sTitFD}yzVg}|_P_GR-5D5r(IdaVPI$Ab-q6DHm%u(gQu*UZs8MgV>c_?B z4|k4SS8p<_*;h4YlDXz=7-gr$YY>l{Ua@*qaJlNStnhhud0l8Ff&dnr?Gc(JrR%6!0*jj$`e;0B;o;_d8_2~f@ Z+&t)l8~FDF{F~t4Mf@A$-(L^7{|hq&h) { - let mut whitelist = self.token_whitelist(); - for token_id in token_whitelist { - self.require_valid_token_id(&token_id); - - let _ = whitelist.insert(token_id); - } - - self.transfer_roles_not_set().set(true); - } - - #[upgrade] - fn upgrade(&self) {} - - /// Sets the transfer role for the given address. Defaults to own address. - #[only_owner] - #[endpoint(setTransferRoleLockedToken)] - fn set_transfer_role(&self, opt_address: OptionalValue) { - let address = match opt_address { - OptionalValue::Some(addr) => addr, - OptionalValue::None => self.blockchain().get_sc_address(), - }; - - self.locked_token() - .set_local_roles_for_address(&address, &[EsdtLocalRole::Transfer], None); - } - - #[only_owner] - #[endpoint(setTransferRolesStatus)] - fn set_transfer_roles_status(&self, roles_status: bool) { - self.locked_token().require_issued_or_set(); - - self.transfer_roles_not_set().set(roles_status); - } - - #[only_owner] - #[endpoint(setTransferRoleProxyLpToken)] - fn set_transfer_role_proxy_lp(&self, opt_address: OptionalValue) { - let address = match opt_address { - OptionalValue::Some(addr) => addr, - OptionalValue::None => self.blockchain().get_sc_address(), - }; - - self.lp_proxy_token().set_local_roles_for_address( - &address, - &[EsdtLocalRole::Transfer], - None, - ); - } - - #[only_owner] - #[endpoint(setTransferRoleProxyFarmToken)] - fn set_transfer_role_proxy_farm(&self, opt_address: OptionalValue) { - let address = match opt_address { - OptionalValue::Some(addr) => addr, - OptionalValue::None => self.blockchain().get_sc_address(), - }; - - self.farm_proxy_token().set_local_roles_for_address( - &address, - &[EsdtLocalRole::Transfer], - None, - ); - } - - /// Locks a whitelisted token until `unlock_epoch` and receive meta ESDT LOCKED tokens. - /// on a 1:1 ratio. If unlock epoch has already passed, the original tokens are sent instead. - /// - /// Expected payment: A whitelisted token - /// - /// Arguments: - /// - unlock epoch - the epoch from which the LOCKED token holder may call the unlock endpoint - /// - opt_destination - OPTIONAL: destination address for the LOCKED tokens. Default is caller. - /// - /// Output payments: LOCKED tokens (or original payment if current_epoch >= unlock_epoch) - #[payable("*")] - #[endpoint(lockTokens)] - fn lock_tokens_endpoint( - &self, - unlock_epoch: u64, - opt_destination: OptionalValue, - ) -> EgldOrEsdtTokenPayment { - self.require_transfer_roles_ready(); - let payment = self.call_value().single_esdt(); - self.require_token_in_whitelist(&payment.token_identifier); - - let dest_address = self.dest_from_optional(opt_destination); - self.lock_and_send( - &dest_address, - EgldOrEsdtTokenPayment::from(payment), - unlock_epoch, - ) - } - - /// Unlock tokens, previously locked with the `lockTokens` endpoint - /// - /// Expected payment: LOCKED tokens - /// - /// Arguments: - /// - opt_destination - OPTIONAL: destination address for the unlocked tokens - /// - /// Output payments: the originally locked tokens - #[payable("*")] - #[endpoint(unlockTokens)] - fn unlock_tokens_endpoint( - &self, - opt_destination: OptionalValue, - ) -> EgldOrEsdtTokenPayment { - self.require_transfer_roles_ready(); - let payment = self.call_value().single_esdt(); - let dest_address = self.dest_from_optional(opt_destination); - self.unlock_and_send(&dest_address, payment) - } - - fn require_token_in_whitelist(&self, token_id: &TokenIdentifier) { - require!( - self.token_whitelist().contains(token_id), - INVALID_PAYMENTS_ERR_MSG - ); - } - - fn require_transfer_roles_ready(&self) { - require!( - !self.transfer_roles_not_set().get(), - "Transfer roles not ready" - ); - } - - #[view(getTokenWhitelist)] - #[storage_mapper("tokenWhitelist")] - fn token_whitelist(&self) -> UnorderedSetMapper; - - #[view(getTransferRolesNotSet)] - #[storage_mapper("transferRolesNotSet")] - fn transfer_roles_not_set(&self) -> SingleValueMapper; -} diff --git a/locked-asset/simple-lock-whitelist/testnet.toml b/locked-asset/simple-lock-whitelist/testnet.toml deleted file mode 100644 index e69de29bb..000000000 diff --git a/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs b/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs deleted file mode 100644 index 193c633cf..000000000 --- a/locked-asset/simple-lock-whitelist/tests/whitelist_test.rs +++ /dev/null @@ -1,99 +0,0 @@ -#![allow(deprecated)] - -use multiversx_sc::codec::multi_types::OptionalValue; -use multiversx_sc::types::{EsdtLocalRole, MultiValueEncoded}; -use multiversx_sc_scenario::{managed_token_id, rust_biguint, DebugApi}; -use multiversx_sc_scenario::{managed_token_id_wrapped, whitebox_legacy::*}; - -use multiversx_sc::storage::mappers::StorageTokenWrapper; -use simple_lock::locked_token::*; -use simple_lock_whitelist::SimpleLockWhitelist; - -static FREE_TOKEN_ID: &[u8] = b"FREEEEE-123456"; -static OTHER_TOKEN_ID: &[u8] = b"ILLEGAL-123456"; -static LOCKED_TOKEN_ID: &[u8] = b"NOOO0-123456"; - -#[test] -fn lock_whitelist_test() { - let rust_zero = rust_biguint!(0); - let mut b_mock = BlockchainStateWrapper::new(); - - let user_addr = b_mock.create_user_account(&rust_zero); - let owner_addr = b_mock.create_user_account(&rust_zero); - let sc_wrapper = b_mock.create_sc_account( - &rust_zero, - Some(&owner_addr), - simple_lock_whitelist::contract_obj, - "Some path", - ); - - b_mock.set_block_epoch(5); - - b_mock - .execute_tx(&owner_addr, &sc_wrapper, &rust_zero, |sc| { - let mut whitelist = MultiValueEncoded::new(); - whitelist.push(managed_token_id!(FREE_TOKEN_ID)); - - sc.init(whitelist); - sc.locked_token() - .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); - - sc.set_transfer_roles_status(false); - }) - .assert_ok(); - - b_mock.set_esdt_local_roles( - sc_wrapper.address_ref(), - LOCKED_TOKEN_ID, - &[ - EsdtLocalRole::NftCreate, - EsdtLocalRole::NftAddQuantity, - EsdtLocalRole::NftBurn, - ], - ); - - let lock_amount = rust_biguint!(1_000); - b_mock.set_esdt_balance(&user_addr, FREE_TOKEN_ID, &lock_amount); - b_mock.set_esdt_balance(&user_addr, OTHER_TOKEN_ID, &lock_amount); - - // lock wrong token - b_mock - .execute_esdt_transfer( - &user_addr, - &sc_wrapper, - OTHER_TOKEN_ID, - 0, - &lock_amount, - |sc| { - let _ = sc.lock_tokens_endpoint(10, OptionalValue::None); - }, - ) - .assert_user_error("Invalid payments"); - - // lock ok - b_mock - .execute_esdt_transfer( - &user_addr, - &sc_wrapper, - FREE_TOKEN_ID, - 0, - &lock_amount, - |sc| { - let _ = sc.lock_tokens_endpoint(10, OptionalValue::None); - }, - ) - .assert_ok(); - - DebugApi::dummy(); - b_mock.check_nft_balance( - &user_addr, - LOCKED_TOKEN_ID, - 1, - &lock_amount, - Some(&LockedTokenAttributes:: { - original_token_id: managed_token_id_wrapped!(FREE_TOKEN_ID), - original_token_nonce: 0, - unlock_epoch: 10, - }), - ); -} diff --git a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs b/locked-asset/simple-lock-whitelist/wasm/src/lib.rs deleted file mode 100644 index aa78142e1..000000000 --- a/locked-asset/simple-lock-whitelist/wasm/src/lib.rs +++ /dev/null @@ -1,52 +0,0 @@ -// Code generated by the multiversx-sc build system. DO NOT EDIT. - -//////////////////////////////////////////////////// -////////////////// AUTO-GENERATED ////////////////// -//////////////////////////////////////////////////// - -// Init: 1 -// Endpoints: 26 -// Async Callback: 1 -// Total number of exported functions: 28 - -#![no_std] -#![allow(internal_features)] -#![feature(lang_items)] - -multiversx_sc_wasm_adapter::allocator!(); -multiversx_sc_wasm_adapter::panic_handler!(); - -multiversx_sc_wasm_adapter::endpoints! { - simple_lock_whitelist - ( - init => init - upgrade => upgrade - setTransferRoleLockedToken => set_transfer_role - setTransferRolesStatus => set_transfer_roles_status - setTransferRoleProxyLpToken => set_transfer_role_proxy_lp - setTransferRoleProxyFarmToken => set_transfer_role_proxy_farm - lockTokens => lock_tokens_endpoint - unlockTokens => unlock_tokens_endpoint - getTokenWhitelist => token_whitelist - getTransferRolesNotSet => transfer_roles_not_set - issueLockedToken => issue_locked_token - getLockedTokenId => locked_token - issueLpProxyToken => issue_lp_proxy_token - addLpToWhitelist => add_lp_to_whitelist - removeLpFromWhitelist => remove_lp_from_whitelist - addLiquidityLockedToken => add_liquidity_locked_token - removeLiquidityLockedToken => remove_liquidity_locked_token - getKnownLiquidityPools => known_liquidity_pools - getLpProxyTokenId => lp_proxy_token - issueFarmProxyToken => issue_farm_proxy_token - addFarmToWhitelist => add_farm_to_whitelist - removeFarmFromWhitelist => remove_farm_from_whitelist - enterFarmLockedToken => enter_farm_locked_token - exitFarmLockedToken => exit_farm_locked_token - farmClaimRewardsLockedToken => farm_claim_rewards_locked_token - getKnownFarms => known_farms - getFarmProxyTokenId => farm_proxy_token - ) -} - -multiversx_sc_wasm_adapter::async_callback! { simple_lock_whitelist } From 981866bf5d44bfd7866e1314144332ffe6a49902 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 22 May 2024 18:02:57 +0300 Subject: [PATCH 053/103] simple lock legacy tests & fixes --- .../simple-lock-legacy/src/lib.rs | 2 +- .../simple-lock-legacy/src/proxy_farm.rs | 6 - .../simple-lock-legacy/src/proxy_lp.rs | 3 +- .../simple-lock-legacy/tests/rust_test.rs | 575 ++++++++++++++++++ 4 files changed, 577 insertions(+), 9 deletions(-) create mode 100644 legacy-contracts/simple-lock-legacy/tests/rust_test.rs diff --git a/legacy-contracts/simple-lock-legacy/src/lib.rs b/legacy-contracts/simple-lock-legacy/src/lib.rs index 14bf6f447..4f0abbe0c 100644 --- a/legacy-contracts/simple-lock-legacy/src/lib.rs +++ b/legacy-contracts/simple-lock-legacy/src/lib.rs @@ -9,7 +9,7 @@ pub mod proxy_farm; pub mod proxy_lp; #[multiversx_sc::contract] -pub trait SimpleLock: +pub trait SimpleLockLegacy: basic_lock_unlock::BasicLockUnlock + locked_token::LockedTokenModule + proxy_lp::ProxyLpModule diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs b/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs index c17cdfd7f..e2dc5931a 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs @@ -45,12 +45,6 @@ pub trait ProxyFarmModule: &payment.amount, ); - self.send().esdt_local_burn( - &payment.token_identifier, - payment.token_nonce, - &payment.amount, - ); - let output_token_payment = EsdtTokenPayment::new( farm_proxy_token_attributes.farm_token_id, farm_proxy_token_attributes.farm_token_nonce, diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs index 4f5f120eb..902683567 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs @@ -30,7 +30,6 @@ pub trait ProxyLpModule: crate::locked_token::LockedTokenModule { ); let output_token_payment = EsdtTokenPayment::new(unlocked_lp_token_id, 0, payment.amount); - self.send().direct_esdt( &caller, &output_token_payment.token_identifier, @@ -59,7 +58,7 @@ pub trait ProxyLpModule: crate::locked_token::LockedTokenModule { .get_token_attributes(lp_proxy_token_attributes.first_token_locked_nonce); require!( - token_attributes.unlock_epoch >= current_epoch, + current_epoch >= token_attributes.unlock_epoch, CANNOT_UNLOCK_YET_ERR_MSG ); } diff --git a/legacy-contracts/simple-lock-legacy/tests/rust_test.rs b/legacy-contracts/simple-lock-legacy/tests/rust_test.rs new file mode 100644 index 000000000..4d6089744 --- /dev/null +++ b/legacy-contracts/simple-lock-legacy/tests/rust_test.rs @@ -0,0 +1,575 @@ +#![allow(deprecated)] + +use common_structs::FarmTokenAttributes; +use multiversx_sc::codec::multi_types::OptionalValue; +use multiversx_sc::imports::ContractBase; +use multiversx_sc::types::EsdtLocalRole; +use multiversx_sc_scenario::{ + managed_address, managed_biguint, managed_token_id, rust_biguint, DebugApi, +}; +use multiversx_sc_scenario::{managed_token_id_wrapped, whitebox_legacy::*}; + +use multiversx_sc::storage::mappers::StorageTokenWrapper; +use simple_lock_legacy::proxy_farm::{FarmProxyTokenAttributes, FarmType, ProxyFarmModule}; +use simple_lock_legacy::proxy_lp::{LpProxyTokenAttributes, ProxyLpModule}; +use simple_lock_legacy::{locked_token::*, SimpleLockLegacy}; + +const FREE_TOKEN_ID: &[u8] = b"FREEEEE-123456"; +const WEGLD_TOKEN_ID: &[u8] = b"WEGLD-123456"; +const LOCKED_TOKEN_ID: &[u8] = b"NOOO0-123456"; +const LP_TOKEN_ID: &[u8] = b"LPTOK-123456"; +const LP_PROXY_TOKEN_ID: &[u8] = b"LPPROXY-123456"; +const FARM_TOKEN_ID: &[u8] = b"FARMTOK-123456"; +const FARM_PROXY_TOKEN_ID: &[u8] = b"FARMPROXY-123456"; + +#[test] +fn unlock_token_test() { + let rust_zero = rust_biguint!(0); + let mut b_mock = BlockchainStateWrapper::new(); + + let user_addr = b_mock.create_user_account(&rust_zero); + let owner_addr = b_mock.create_user_account(&rust_zero); + let sc_wrapper = b_mock.create_sc_account( + &rust_zero, + Some(&owner_addr), + simple_lock_legacy::contract_obj, + "Some path", + ); + + b_mock.set_block_epoch(5); + + b_mock + .execute_tx(&owner_addr, &sc_wrapper, &rust_zero, |sc| { + sc.init(); + sc.locked_token() + .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); + sc.lp_proxy_token() + .set_token_id(managed_token_id!(LP_PROXY_TOKEN_ID)); + sc.farm_proxy_token() + .set_token_id(managed_token_id!(FARM_PROXY_TOKEN_ID)); + }) + .assert_ok(); + + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + LOCKED_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + LP_PROXY_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + FARM_PROXY_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + + let lock_token_nonce = 1u64; + let lock_amount = rust_biguint!(1_000); + + DebugApi::dummy(); + b_mock.set_esdt_balance(sc_wrapper.address_ref(), FREE_TOKEN_ID, &lock_amount); + let locked_token_attributes: LockedTokenAttributes = LockedTokenAttributes { + original_token_id: managed_token_id_wrapped!(FREE_TOKEN_ID), + original_token_nonce: 0, + unlock_epoch: 10u64, + }; + b_mock.set_nft_balance( + &user_addr, + LOCKED_TOKEN_ID, + lock_token_nonce, + &lock_amount, + &locked_token_attributes, + ); + + b_mock.check_nft_balance( + &user_addr, + LOCKED_TOKEN_ID, + lock_token_nonce, + &lock_amount, + Some(&locked_token_attributes), + ); + b_mock.check_esdt_balance(sc_wrapper.address_ref(), FREE_TOKEN_ID, &lock_amount); + b_mock.check_esdt_balance(&user_addr, FREE_TOKEN_ID, &rust_zero); + + // try unlock too early + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + LOCKED_TOKEN_ID, + lock_token_nonce, + &lock_amount, + |sc| { + sc.unlock_tokens_endpoint(OptionalValue::None); + }, + ) + .assert_user_error("Cannot unlock yet"); + + // unlock ok + b_mock.set_block_epoch(10); + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + LOCKED_TOKEN_ID, + lock_token_nonce, + &lock_amount, + |sc| { + sc.unlock_tokens_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + b_mock.check_esdt_balance(&user_addr, FREE_TOKEN_ID, &lock_amount); + b_mock.check_nft_balance( + &user_addr, + LOCKED_TOKEN_ID, + lock_token_nonce, + &rust_zero, + Some(&locked_token_attributes), + ); + b_mock.check_esdt_balance(sc_wrapper.address_ref(), FREE_TOKEN_ID, &rust_zero); + b_mock.check_nft_balance( + sc_wrapper.address_ref(), + LOCKED_TOKEN_ID, + lock_token_nonce, + &rust_zero, + Some(&locked_token_attributes), + ); +} + +#[test] +fn exit_lp_test() { + let rust_zero = rust_biguint!(0); + let mut b_mock = BlockchainStateWrapper::new(); + + let user_addr = b_mock.create_user_account(&rust_zero); + let owner_addr = b_mock.create_user_account(&rust_zero); + let sc_wrapper = b_mock.create_sc_account( + &rust_zero, + Some(&owner_addr), + simple_lock_legacy::contract_obj, + "Some path", + ); + + b_mock.set_block_epoch(5); + + b_mock + .execute_tx(&owner_addr, &sc_wrapper, &rust_zero, |sc| { + sc.init(); + sc.locked_token() + .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); + sc.lp_proxy_token() + .set_token_id(managed_token_id!(LP_PROXY_TOKEN_ID)); + sc.farm_proxy_token() + .set_token_id(managed_token_id!(FARM_PROXY_TOKEN_ID)); + }) + .assert_ok(); + + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + LOCKED_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + LP_PROXY_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + FARM_PROXY_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + + let lock_token_nonce = 1u64; + let lock_amount = rust_biguint!(1_000); + + DebugApi::dummy(); + // Simulate the user add liquidity step by setting the SC balance manually + b_mock.set_esdt_balance(sc_wrapper.address_ref(), LP_TOKEN_ID, &lock_amount); + + b_mock + .execute_tx(&owner_addr, &sc_wrapper, &rust_zero, |sc| { + let lp_proxy_token_amount = managed_biguint!(1_000u64); + // Needed to be able to read the token attributes + sc.send().esdt_nft_create_compact( + &managed_token_id!(LOCKED_TOKEN_ID), + &managed_biguint!(1u64), + &LockedTokenAttributes:: { + original_token_id: managed_token_id_wrapped!(FREE_TOKEN_ID), + original_token_nonce: 0, + unlock_epoch: 10, + }, + ); + let lp_proxy_token_nonce = sc.send().esdt_nft_create_compact( + &managed_token_id!(LP_PROXY_TOKEN_ID), + &lp_proxy_token_amount, + &LpProxyTokenAttributes:: { + lp_token_id: managed_token_id!(LP_TOKEN_ID), + first_token_id: managed_token_id!(FREE_TOKEN_ID), + first_token_locked_nonce: 1, + second_token_id: managed_token_id!(WEGLD_TOKEN_ID), + second_token_locked_nonce: 0, + }, + ); + + sc.send().direct_esdt( + &managed_address!(&user_addr), + &managed_token_id!(LP_PROXY_TOKEN_ID), + lp_proxy_token_nonce, + &lp_proxy_token_amount, + ); + }) + .assert_ok(); + + let locked_lp_token_attributes: LpProxyTokenAttributes = LpProxyTokenAttributes { + lp_token_id: managed_token_id!(LP_TOKEN_ID), + first_token_id: managed_token_id!(FREE_TOKEN_ID), + first_token_locked_nonce: 1, + second_token_id: managed_token_id!(WEGLD_TOKEN_ID), + second_token_locked_nonce: 0, + }; + b_mock.check_nft_balance( + &user_addr, + LP_PROXY_TOKEN_ID, + lock_token_nonce, + &lock_amount, + Some(&locked_lp_token_attributes), + ); + + // try unlock too early + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + LP_PROXY_TOKEN_ID, + lock_token_nonce, + &lock_amount, + |sc| { + sc.remove_liquidity_locked_token(); + }, + ) + .assert_user_error("Cannot unlock yet"); + + // unlock ok + b_mock.set_block_epoch(10); + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + LP_PROXY_TOKEN_ID, + lock_token_nonce, + &lock_amount, + |sc| { + sc.remove_liquidity_locked_token(); + }, + ) + .assert_ok(); + b_mock.check_esdt_balance(&user_addr, LP_TOKEN_ID, &lock_amount); + b_mock.check_esdt_balance(sc_wrapper.address_ref(), LP_TOKEN_ID, &rust_zero); + b_mock.check_nft_balance( + &user_addr, + LP_PROXY_TOKEN_ID, + lock_token_nonce, + &rust_zero, + Some(&locked_lp_token_attributes), + ); + b_mock.check_nft_balance( + sc_wrapper.address_ref(), + LP_PROXY_TOKEN_ID, + lock_token_nonce, + &rust_zero, + Some(&locked_lp_token_attributes), + ); +} + +#[test] +fn exit_farm_test() { + let rust_zero = rust_biguint!(0); + let mut b_mock = BlockchainStateWrapper::new(); + + let user_addr = b_mock.create_user_account(&rust_zero); + let owner_addr = b_mock.create_user_account(&rust_zero); + let sc_wrapper = b_mock.create_sc_account( + &rust_zero, + Some(&owner_addr), + simple_lock_legacy::contract_obj, + "Some path", + ); + + b_mock.set_block_epoch(5); + + b_mock + .execute_tx(&owner_addr, &sc_wrapper, &rust_zero, |sc| { + sc.init(); + sc.locked_token() + .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); + sc.lp_proxy_token() + .set_token_id(managed_token_id!(LP_PROXY_TOKEN_ID)); + sc.farm_proxy_token() + .set_token_id(managed_token_id!(FARM_PROXY_TOKEN_ID)); + }) + .assert_ok(); + + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + LOCKED_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + LP_PROXY_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + b_mock.set_esdt_local_roles( + sc_wrapper.address_ref(), + FARM_PROXY_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ], + ); + + let lock_token_nonce = 1u64; + let lock_amount = rust_biguint!(2_000u64); + + DebugApi::dummy(); + b_mock + .execute_tx(&owner_addr, &sc_wrapper, &rust_zero, |sc| { + let farm_proxy_token_amount = managed_biguint!(2_000u64); + // Needed to be able to read the token attributes + sc.send().esdt_nft_create_compact( + &managed_token_id!(LOCKED_TOKEN_ID), + &managed_biguint!(1u64), + &LockedTokenAttributes:: { + original_token_id: managed_token_id_wrapped!(FREE_TOKEN_ID), + original_token_nonce: 0, + unlock_epoch: 10, + }, + ); + sc.send().esdt_nft_create_compact( + &managed_token_id!(LP_PROXY_TOKEN_ID), + &farm_proxy_token_amount, + &LpProxyTokenAttributes:: { + lp_token_id: managed_token_id!(LP_TOKEN_ID), + first_token_id: managed_token_id!(FREE_TOKEN_ID), + first_token_locked_nonce: 1, + second_token_id: managed_token_id!(WEGLD_TOKEN_ID), + second_token_locked_nonce: 0, + }, + ); + let farm_proxy_token_nonce = sc.send().esdt_nft_create_compact( + &managed_token_id!(FARM_PROXY_TOKEN_ID), + &farm_proxy_token_amount, + &FarmProxyTokenAttributes:: { + farm_type: FarmType::FarmWithLockedRewards, + farm_token_id: managed_token_id!(FARM_TOKEN_ID), + farm_token_nonce: 1, + farming_token_id: managed_token_id!(LP_TOKEN_ID), + farming_token_locked_nonce: 1, + }, + ); + + sc.send().direct_esdt( + &managed_address!(&user_addr), + &managed_token_id!(FARM_PROXY_TOKEN_ID), + farm_proxy_token_nonce, + &farm_proxy_token_amount, + ); + }) + .assert_ok(); + + let locked_farm_token_attributes: FarmProxyTokenAttributes = + FarmProxyTokenAttributes { + farm_type: FarmType::FarmWithLockedRewards, + farm_token_id: managed_token_id!(FARM_TOKEN_ID), + farm_token_nonce: 1, + farming_token_id: managed_token_id!(LP_TOKEN_ID), + farming_token_locked_nonce: 1, + }; + b_mock.check_nft_balance( + &user_addr, + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &lock_amount, + Some(&locked_farm_token_attributes), + ); + + let farm_attributes: FarmTokenAttributes = FarmTokenAttributes { + reward_per_share: managed_biguint!(0u64), + entering_epoch: 5u64, + compounded_reward: managed_biguint!(0u64), + current_farm_amount: managed_biguint!(2_000u64), + original_owner: managed_address!(&user_addr), + }; + b_mock.set_nft_balance( + sc_wrapper.address_ref(), + FARM_TOKEN_ID, + 1, + &lock_amount, + &farm_attributes, + ); + b_mock.check_nft_balance::>( + &user_addr, + FARM_TOKEN_ID, + 1, + &rust_zero, + None, + ); + b_mock.check_nft_balance( + sc_wrapper.address_ref(), + FARM_TOKEN_ID, + 1, + &lock_amount, + Some(&farm_attributes), + ); + + // try unlock too early + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &lock_amount, + |sc| { + sc.farm_claim_rewards_locked_token(); + }, + ) + .assert_user_error("Cannot unlock yet"); + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &lock_amount, + |sc| { + sc.exit_farm_locked_token(); + }, + ) + .assert_user_error("Cannot unlock yet"); + + // unlock ok + let half_lock_amount = rust_biguint!(1_000u64); + b_mock.set_block_epoch(10); + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &half_lock_amount, + |sc| { + sc.farm_claim_rewards_locked_token(); + }, + ) + .assert_ok(); + + b_mock.check_nft_balance::>( + sc_wrapper.address_ref(), + FARM_TOKEN_ID, + lock_token_nonce, + &half_lock_amount, + Some(&farm_attributes), + ); + b_mock.check_nft_balance( + &user_addr, + FARM_TOKEN_ID, + lock_token_nonce, + &half_lock_amount, + Some(&farm_attributes), + ); + b_mock.check_nft_balance::>( + sc_wrapper.address_ref(), + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &rust_zero, + None, + ); + b_mock.check_nft_balance::>( + &user_addr, + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &half_lock_amount, + Some(&locked_farm_token_attributes), + ); + + b_mock + .execute_esdt_transfer( + &user_addr, + &sc_wrapper, + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &half_lock_amount, + |sc| { + sc.exit_farm_locked_token(); + }, + ) + .assert_ok(); + + b_mock.check_nft_balance::>( + sc_wrapper.address_ref(), + FARM_TOKEN_ID, + lock_token_nonce, + &rust_zero, + None, + ); + b_mock.check_nft_balance( + &user_addr, + FARM_TOKEN_ID, + lock_token_nonce, + &lock_amount, + Some(&farm_attributes), + ); + b_mock.check_nft_balance::>( + sc_wrapper.address_ref(), + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &rust_zero, + None, + ); + b_mock.check_nft_balance::>( + &user_addr, + FARM_PROXY_TOKEN_ID, + lock_token_nonce, + &rust_zero, + None, + ); +} From efbd326e701149ebf6a15629719ddbeeab15f903 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 22 May 2024 18:14:29 +0300 Subject: [PATCH 054/103] add initial endpoints parameters --- legacy-contracts/simple-lock-legacy/src/proxy_lp.rs | 6 +++++- legacy-contracts/simple-lock-legacy/tests/rust_test.rs | 4 ++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs index 902683567..5617219d5 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs @@ -16,7 +16,11 @@ pub struct LpProxyTokenAttributes { pub trait ProxyLpModule: crate::locked_token::LockedTokenModule { #[payable("*")] #[endpoint(removeLiquidityLockedToken)] - fn remove_liquidity_locked_token(&self) -> EsdtTokenPayment { + fn remove_liquidity_locked_token( + &self, + _first_token_amount_min: BigUint, + _second_token_amount_min: BigUint, + ) -> EsdtTokenPayment { let payment = self.call_value().single_esdt(); let caller = self.blockchain().get_caller(); diff --git a/legacy-contracts/simple-lock-legacy/tests/rust_test.rs b/legacy-contracts/simple-lock-legacy/tests/rust_test.rs index 4d6089744..31fe17235 100644 --- a/legacy-contracts/simple-lock-legacy/tests/rust_test.rs +++ b/legacy-contracts/simple-lock-legacy/tests/rust_test.rs @@ -273,7 +273,7 @@ fn exit_lp_test() { lock_token_nonce, &lock_amount, |sc| { - sc.remove_liquidity_locked_token(); + sc.remove_liquidity_locked_token(managed_biguint!(0u64), managed_biguint!(0u64)); }, ) .assert_user_error("Cannot unlock yet"); @@ -288,7 +288,7 @@ fn exit_lp_test() { lock_token_nonce, &lock_amount, |sc| { - sc.remove_liquidity_locked_token(); + sc.remove_liquidity_locked_token(managed_biguint!(0u64), managed_biguint!(0u64)); }, ) .assert_ok(); From d11cdc27c70cce25608938d3e295f79039ac2a6b Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 28 May 2024 22:27:18 +0300 Subject: [PATCH 055/103] simple lock legacy check fix --- legacy-contracts/simple-lock-legacy/src/proxy_lp.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs index 5617219d5..2d384a1f3 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs @@ -72,7 +72,7 @@ pub trait ProxyLpModule: crate::locked_token::LockedTokenModule { .get_token_attributes(lp_proxy_token_attributes.second_token_locked_nonce); require!( - token_attributes.unlock_epoch >= current_epoch, + current_epoch >= token_attributes.unlock_epoch, CANNOT_UNLOCK_YET_ERR_MSG ); } From 7b75780ea242c63b5d351d02048b1dc755b59e33 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 29 May 2024 00:40:20 +0300 Subject: [PATCH 056/103] build fix --- .github/workflows/actions.yml | 4 ++-- .github/workflows/release.yml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml index eb7e44644..6becbecc0 100644 --- a/.github/workflows/actions.yml +++ b/.github/workflows/actions.yml @@ -20,9 +20,9 @@ permissions: jobs: contracts: name: Contracts - uses: multiversx/mx-sc-actions/.github/workflows/contracts.yml@v3.1.0 + uses: multiversx/mx-sc-actions/.github/workflows/contracts.yml@v3.2.0 with: - rust-toolchain: nightly-2023-12-11 + rust-toolchain: nightly-2024-05-22 coverage-args: --ignore-filename-regex='/.cargo/git' --output ./coverage.md secrets: token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a19b5ed98..352ab4397 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,7 +9,7 @@ permissions: jobs: build: - uses: multiversx/mx-sc-actions/.github/workflows/reproducible-build.yml@v2.3.5 + uses: multiversx/mx-sc-actions/.github/workflows/reproducible-build.yml@v3.2.0 with: - image_tag: v6.0.0 + image_tag: v7.0.0 attach_to_existing_release: true From 04eff5af2579972d2ae50953ff69e13f273b72ea Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 29 May 2024 00:47:15 +0300 Subject: [PATCH 057/103] build fix --- .../workflows/on_pull_request_build_contracts.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 .github/workflows/on_pull_request_build_contracts.yml diff --git a/.github/workflows/on_pull_request_build_contracts.yml b/.github/workflows/on_pull_request_build_contracts.yml new file mode 100644 index 000000000..dd4b3713c --- /dev/null +++ b/.github/workflows/on_pull_request_build_contracts.yml @@ -0,0 +1,14 @@ +name: On pull request, build contracts + +on: + pull_request: + +permissions: + contents: write + +jobs: + build: + uses: multiversx/mx-sc-actions/.github/workflows/reproducible-build.yml@v3.2.0 + with: + image_tag: v7.0.0 + package_whole_project_src: true \ No newline at end of file From 5c3b990d382c8017e66e6993fadd34f3136b258c Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 5 Jun 2024 12:43:59 +0300 Subject: [PATCH 058/103] Remove checks in simple lock legacy SC --- .../simple-lock-legacy/src/proxy_lp.rs | 22 ------------------- 1 file changed, 22 deletions(-) diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs index 2d384a1f3..2d972c274 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs @@ -55,28 +55,6 @@ pub trait ProxyLpModule: crate::locked_token::LockedTokenModule { let lp_proxy_token_attributes: LpProxyTokenAttributes = lp_proxy_token_mapper.get_token_attributes(token_nonce); - let current_epoch = self.blockchain().get_block_epoch(); - if lp_proxy_token_attributes.first_token_locked_nonce > 0 { - let token_attributes: LockedTokenAttributes = self - .locked_token() - .get_token_attributes(lp_proxy_token_attributes.first_token_locked_nonce); - - require!( - current_epoch >= token_attributes.unlock_epoch, - CANNOT_UNLOCK_YET_ERR_MSG - ); - } - if lp_proxy_token_attributes.second_token_locked_nonce > 0 { - let token_attributes: LockedTokenAttributes = self - .locked_token() - .get_token_attributes(lp_proxy_token_attributes.second_token_locked_nonce); - - require!( - current_epoch >= token_attributes.unlock_epoch, - CANNOT_UNLOCK_YET_ERR_MSG - ); - } - lp_proxy_token_attributes.lp_token_id } From d56ca3244c1f9cfb163c93acb7326ceb59864169 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 5 Jun 2024 12:53:16 +0300 Subject: [PATCH 059/103] updated tests --- .../simple-lock-legacy/src/proxy_lp.rs | 2 +- .../simple-lock-legacy/tests/rust_test.rs | 54 ------------------- 2 files changed, 1 insertion(+), 55 deletions(-) diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs index 2d972c274..550bd5d1c 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs @@ -1,7 +1,7 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); -use crate::{error_messages::CANNOT_UNLOCK_YET_ERR_MSG, locked_token::LockedTokenAttributes}; +use crate::locked_token::LockedTokenAttributes; #[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq, Debug)] pub struct LpProxyTokenAttributes { diff --git a/legacy-contracts/simple-lock-legacy/tests/rust_test.rs b/legacy-contracts/simple-lock-legacy/tests/rust_test.rs index 31fe17235..568605b0b 100644 --- a/legacy-contracts/simple-lock-legacy/tests/rust_test.rs +++ b/legacy-contracts/simple-lock-legacy/tests/rust_test.rs @@ -106,20 +106,6 @@ fn unlock_token_test() { b_mock.check_esdt_balance(sc_wrapper.address_ref(), FREE_TOKEN_ID, &lock_amount); b_mock.check_esdt_balance(&user_addr, FREE_TOKEN_ID, &rust_zero); - // try unlock too early - b_mock - .execute_esdt_transfer( - &user_addr, - &sc_wrapper, - LOCKED_TOKEN_ID, - lock_token_nonce, - &lock_amount, - |sc| { - sc.unlock_tokens_endpoint(OptionalValue::None); - }, - ) - .assert_user_error("Cannot unlock yet"); - // unlock ok b_mock.set_block_epoch(10); b_mock @@ -264,20 +250,6 @@ fn exit_lp_test() { Some(&locked_lp_token_attributes), ); - // try unlock too early - b_mock - .execute_esdt_transfer( - &user_addr, - &sc_wrapper, - LP_PROXY_TOKEN_ID, - lock_token_nonce, - &lock_amount, - |sc| { - sc.remove_liquidity_locked_token(managed_biguint!(0u64), managed_biguint!(0u64)); - }, - ) - .assert_user_error("Cannot unlock yet"); - // unlock ok b_mock.set_block_epoch(10); b_mock @@ -460,32 +432,6 @@ fn exit_farm_test() { Some(&farm_attributes), ); - // try unlock too early - b_mock - .execute_esdt_transfer( - &user_addr, - &sc_wrapper, - FARM_PROXY_TOKEN_ID, - lock_token_nonce, - &lock_amount, - |sc| { - sc.farm_claim_rewards_locked_token(); - }, - ) - .assert_user_error("Cannot unlock yet"); - b_mock - .execute_esdt_transfer( - &user_addr, - &sc_wrapper, - FARM_PROXY_TOKEN_ID, - lock_token_nonce, - &lock_amount, - |sc| { - sc.exit_farm_locked_token(); - }, - ) - .assert_user_error("Cannot unlock yet"); - // unlock ok let half_lock_amount = rust_biguint!(1_000u64); b_mock.set_block_epoch(10); From 5dc34ef48c7721c6782799d2c4161a0f00fa8888 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 5 Jun 2024 13:06:12 +0300 Subject: [PATCH 060/103] clippy fix --- legacy-contracts/simple-lock-legacy/src/proxy_lp.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs index 550bd5d1c..60145ad5e 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_lp.rs @@ -1,8 +1,6 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); -use crate::locked_token::LockedTokenAttributes; - #[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq, Debug)] pub struct LpProxyTokenAttributes { pub lp_token_id: TokenIdentifier, From c3d54f0d83d81fe3b8a879d406e68eb7c2dfc22d Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 11 Jun 2024 02:48:15 +0300 Subject: [PATCH 061/103] Framework upgrade 0.50.4. No syntax change. --- Cargo.lock | 429 +++++++++++++----- common/common_errors/Cargo.toml | 2 +- common/common_structs/Cargo.toml | 2 +- common/modules/farm/config/Cargo.toml | 2 +- common/modules/farm/contexts/Cargo.toml | 4 +- common/modules/farm/events/Cargo.toml | 2 +- common/modules/farm/farm_base_impl/Cargo.toml | 6 +- common/modules/farm/farm_token/Cargo.toml | 4 +- .../modules/farm/farm_token_merge/Cargo.toml | 4 +- common/modules/farm/rewards/Cargo.toml | 4 +- .../legacy_token_decode_module/Cargo.toml | 2 +- common/modules/locking_module/Cargo.toml | 2 +- .../src/lock_with_energy_module.rs | 2 +- .../locking_module/src/locking_module.rs | 4 +- common/modules/math/Cargo.toml | 2 +- common/modules/pausable/Cargo.toml | 2 +- common/modules/permissions_module/Cargo.toml | 2 +- .../permissions_module/src/permissions.rs | 20 +- .../src/permissions_module.rs | 2 +- common/modules/sc_whitelist_module/Cargo.toml | 2 +- common/modules/token_merge_helper/Cargo.toml | 2 +- common/modules/token_send/Cargo.toml | 2 +- common/modules/utils/Cargo.toml | 2 +- common/traits/fixed-supply-token/Cargo.toml | 2 +- common/traits/mergeable/Cargo.toml | 2 +- common/traits/unwrappable/Cargo.toml | 2 +- dex/Cargo.toml | 6 +- dex/farm-with-locked-rewards/Cargo.toml | 6 +- dex/farm-with-locked-rewards/meta/Cargo.toml | 2 +- dex/farm-with-locked-rewards/wasm/Cargo.lock | 52 ++- dex/farm-with-locked-rewards/wasm/Cargo.toml | 5 +- dex/farm-with-locked-rewards/wasm/src/lib.rs | 5 +- dex/farm/Cargo.toml | 6 +- dex/farm/meta/Cargo.toml | 2 +- dex/farm/wasm/Cargo.lock | 52 ++- dex/farm/wasm/Cargo.toml | 5 +- dex/farm/wasm/src/lib.rs | 5 +- dex/fuzz/Cargo.toml | 4 +- dex/governance/Cargo.toml | 4 +- dex/governance/meta/Cargo.toml | 2 +- dex/governance/wasm/Cargo.lock | 48 +- dex/governance/wasm/Cargo.toml | 5 +- dex/governance/wasm/src/lib.rs | 5 +- dex/pair-mock/Cargo.toml | 4 +- dex/pair-mock/meta/Cargo.toml | 2 +- dex/pair-mock/wasm/Cargo.lock | 48 +- dex/pair-mock/wasm/Cargo.toml | 5 +- dex/pair-mock/wasm/src/lib.rs | 2 - dex/pair/Cargo.toml | 4 +- dex/pair/meta/Cargo.toml | 2 +- dex/pair/src/locking_wrapper.rs | 2 +- dex/pair/wasm-pair-full/Cargo.lock | 52 ++- dex/pair/wasm-pair-full/Cargo.toml | 5 +- dex/pair/wasm-pair-full/src/lib.rs | 5 +- dex/pair/wasm-safe-price-view/Cargo.lock | 52 ++- dex/pair/wasm-safe-price-view/Cargo.toml | 5 +- dex/pair/wasm-safe-price-view/src/lib.rs | 2 - dex/pair/wasm/Cargo.lock | 52 ++- dex/pair/wasm/Cargo.toml | 5 +- dex/pair/wasm/src/lib.rs | 5 +- dex/price-discovery/Cargo.toml | 6 +- dex/price-discovery/elrond.json | 3 - dex/price-discovery/meta/Cargo.toml | 2 +- dex/price-discovery/wasm/Cargo.lock | 52 ++- dex/price-discovery/wasm/Cargo.toml | 5 +- dex/price-discovery/wasm/src/lib.rs | 5 +- dex/proxy-deployer/Cargo.toml | 4 +- dex/proxy-deployer/meta/Cargo.toml | 2 +- dex/proxy-deployer/wasm/Cargo.lock | 52 ++- dex/proxy-deployer/wasm/Cargo.toml | 5 +- dex/proxy-deployer/wasm/src/lib.rs | 5 +- dex/router/Cargo.toml | 4 +- dex/router/meta/Cargo.toml | 2 +- dex/router/src/contract.rs | 1 + dex/router/wasm/Cargo.lock | 52 ++- dex/router/wasm/Cargo.toml | 5 +- dex/router/wasm/src/lib.rs | 5 +- .../common-modules/energy-query/Cargo.toml | 2 +- .../week-timekeeping/Cargo.toml | 2 +- .../weekly-rewards-splitting/Cargo.toml | 2 +- energy-integration/common-types/Cargo.toml | 2 +- .../energy-factory-mock/Cargo.toml | 4 +- .../energy-factory-mock/meta/Cargo.toml | 2 +- .../energy-factory-mock/wasm/Cargo.lock | 52 ++- .../energy-factory-mock/wasm/Cargo.toml | 5 +- .../energy-factory-mock/wasm/src/lib.rs | 2 - energy-integration/energy-update/Cargo.toml | 6 +- energy-integration/energy-update/elrond.json | 3 - .../energy-update/meta/Cargo.toml | 2 +- .../energy-update/wasm/Cargo.lock | 52 ++- .../energy-update/wasm/Cargo.toml | 5 +- .../energy-update/wasm/src/lib.rs | 5 +- .../farm-boosted-yields/Cargo.toml | 2 +- energy-integration/fees-collector/Cargo.toml | 6 +- .../fees-collector/meta/Cargo.toml | 2 +- .../fees-collector/wasm/Cargo.lock | 52 ++- .../fees-collector/wasm/Cargo.toml | 5 +- .../fees-collector/wasm/src/lib.rs | 5 +- energy-integration/governance-v2/Cargo.toml | 4 +- .../governance-v2/meta/Cargo.toml | 2 +- .../governance-v2/wasm/Cargo.lock | 52 ++- .../governance-v2/wasm/Cargo.toml | 5 +- .../governance-v2/wasm/src/lib.rs | 5 +- farm-staking/farm-staking-proxy/Cargo.toml | 6 +- .../farm-staking-proxy/meta/Cargo.toml | 2 +- .../src/external_contracts_interactions.rs | 6 +- .../farm-staking-proxy/wasm/Cargo.lock | 52 ++- .../farm-staking-proxy/wasm/Cargo.toml | 5 +- .../farm-staking-proxy/wasm/src/lib.rs | 5 +- farm-staking/farm-staking/Cargo.toml | 6 +- farm-staking/farm-staking/meta/Cargo.toml | 2 +- farm-staking/farm-staking/wasm/Cargo.lock | 52 ++- farm-staking/farm-staking/wasm/Cargo.toml | 5 +- farm-staking/farm-staking/wasm/src/lib.rs | 5 +- farm-staking/metabonding-staking/Cargo.toml | 6 +- .../metabonding-staking/meta/Cargo.toml | 2 +- .../metabonding-staking/wasm/Cargo.lock | 52 ++- .../metabonding-staking/wasm/Cargo.toml | 5 +- .../metabonding-staking/wasm/src/lib.rs | 5 +- .../simple-lock-legacy/Cargo.toml | 6 +- .../simple-lock-legacy/meta/Cargo.toml | 2 +- .../simple-lock-legacy/wasm/Cargo.lock | 52 ++- .../simple-lock-legacy/wasm/Cargo.toml | 5 +- .../simple-lock-legacy/wasm/src/lib.rs | 5 +- locked-asset/Cargo.toml | 6 +- locked-asset/distribution/Cargo.toml | 4 +- locked-asset/distribution/meta/Cargo.toml | 2 +- locked-asset/distribution/wasm/Cargo.lock | 52 ++- locked-asset/distribution/wasm/Cargo.toml | 5 +- locked-asset/distribution/wasm/src/lib.rs | 5 +- locked-asset/energy-factory/Cargo.toml | 6 +- locked-asset/energy-factory/meta/Cargo.toml | 2 +- locked-asset/energy-factory/wasm/Cargo.lock | 52 ++- locked-asset/energy-factory/wasm/Cargo.toml | 5 +- locked-asset/energy-factory/wasm/src/lib.rs | 5 +- locked-asset/factory/Cargo.toml | 6 +- locked-asset/factory/meta/Cargo.toml | 2 +- locked-asset/factory/wasm/Cargo.lock | 52 ++- locked-asset/factory/wasm/Cargo.toml | 5 +- locked-asset/factory/wasm/src/lib.rs | 5 +- locked-asset/lkmex-transfer/Cargo.toml | 6 +- locked-asset/lkmex-transfer/meta/Cargo.toml | 2 +- locked-asset/lkmex-transfer/wasm/Cargo.lock | 52 ++- locked-asset/lkmex-transfer/wasm/Cargo.toml | 5 +- locked-asset/lkmex-transfer/wasm/src/lib.rs | 5 +- locked-asset/locked-token-wrapper/Cargo.toml | 6 +- .../locked-token-wrapper/meta/Cargo.toml | 2 +- .../locked-token-wrapper/wasm/Cargo.lock | 52 ++- .../locked-token-wrapper/wasm/Cargo.toml | 5 +- .../locked-token-wrapper/wasm/src/lib.rs | 5 +- locked-asset/proxy_dex/Cargo.toml | 6 +- locked-asset/proxy_dex/meta/Cargo.toml | 2 +- .../proxy_dex/src/external_merging.rs | 2 + .../proxy_dex/src/farm_interactions.rs | 6 +- locked-asset/proxy_dex/wasm/Cargo.lock | 52 ++- locked-asset/proxy_dex/wasm/Cargo.toml | 5 +- locked-asset/proxy_dex/wasm/src/lib.rs | 5 +- locked-asset/simple-lock/Cargo.toml | 6 +- locked-asset/simple-lock/meta/Cargo.toml | 2 +- .../simple-lock/src/farm_interactions.rs | 6 +- locked-asset/simple-lock/wasm/Cargo.lock | 52 ++- locked-asset/simple-lock/wasm/Cargo.toml | 5 +- locked-asset/simple-lock/wasm/src/lib.rs | 5 +- locked-asset/token-unstake/Cargo.toml | 6 +- locked-asset/token-unstake/meta/Cargo.toml | 2 +- locked-asset/token-unstake/wasm/Cargo.lock | 52 ++- locked-asset/token-unstake/wasm/Cargo.toml | 5 +- locked-asset/token-unstake/wasm/src/lib.rs | 5 +- pause-all/Cargo.toml | 6 +- pause-all/meta/Cargo.toml | 2 +- pause-all/wasm/Cargo.lock | 52 ++- pause-all/wasm/Cargo.toml | 5 +- pause-all/wasm/src/lib.rs | 5 +- 173 files changed, 1452 insertions(+), 955 deletions(-) delete mode 100644 dex/price-discovery/elrond.json delete mode 100644 energy-integration/energy-update/elrond.json diff --git a/Cargo.lock b/Cargo.lock index 515bb376b..f4091b679 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -27,6 +27,18 @@ version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if 1.0.0", + "once_cell", + "version_check", + "zerocopy", +] + [[package]] name = "aho-corasick" version = "1.1.2" @@ -90,12 +102,27 @@ version = "1.0.79" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "080e9890a082662b09c1ad45f567faeeb47f22b5fb23895fbe1e651e718e25ca" +[[package]] +name = "arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" +dependencies = [ + "derive_arbitrary", +] + [[package]] name = "arrayvec" version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + [[package]] name = "autocfg" version = "1.1.0" @@ -123,6 +150,12 @@ version = "0.21.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + [[package]] name = "bech32" version = "0.9.1" @@ -156,9 +189,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "block-buffer" @@ -190,9 +223,9 @@ dependencies = [ [[package]] name = "bumpalo" -version = "3.14.0" +version = "3.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f30e7476521f6f8af1a1c4c0b8cc94f0bee37d91763d0ca2665f299b6cd8aec" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" [[package]] name = "byteorder" @@ -388,9 +421,9 @@ dependencies = [ [[package]] name = "crc32fast" -version = "1.3.2" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" dependencies = [ "cfg-if 1.0.0", ] @@ -416,9 +449,9 @@ dependencies = [ [[package]] name = "crossbeam-utils" -version = "0.8.19" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" [[package]] name = "crypto-common" @@ -443,6 +476,17 @@ dependencies = [ "zeroize", ] +[[package]] +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "dex-tests" version = "0.0.0" @@ -489,6 +533,17 @@ dependencies = [ "subtle", ] +[[package]] +name = "displaydoc" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "distribution" version = "0.0.0" @@ -958,9 +1013,9 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.28" +version = "1.0.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46303f565772937ffe1d394a4fac6f411c6013172fadde9dcdb1e147a086940e" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" dependencies = [ "crc32fast", "miniz_oxide", @@ -1003,6 +1058,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" dependencies = [ "futures-core", + "futures-sink", ] [[package]] @@ -1037,6 +1093,7 @@ checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" dependencies = [ "futures-core", "futures-io", + "futures-sink", "futures-task", "memchr", "pin-project-lite", @@ -1160,15 +1217,15 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.24" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb2c4422095b67ee78da96fbb51a4cc413b3b25883c7717ff7ca1ab31022c9c9" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" dependencies = [ + "atomic-waker", "bytes", "fnv", "futures-core", "futures-sink", - "futures-util", "http", "indexmap", "slab", @@ -1182,6 +1239,10 @@ name = "hashbrown" version = "0.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" +dependencies = [ + "ahash", + "serde", +] [[package]] name = "heck" @@ -1224,9 +1285,9 @@ dependencies = [ [[package]] name = "http" -version = "0.2.11" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8947b1a6fad4393052c7ba1f4cd97bed3e953a95c79c92ad9b051a04611d9fbb" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" dependencies = [ "bytes", "fnv", @@ -1235,12 +1296,24 @@ dependencies = [ [[package]] name = "http-body" -version = "0.4.6" +version = "1.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ceab25649e9960c0311ea418d17bee82c0dcec1bd053b5f9a66e265a693bed2" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" dependencies = [ "bytes", "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", "pin-project-lite", ] @@ -1250,47 +1323,60 @@ version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" -[[package]] -name = "httpdate" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" - [[package]] name = "hyper" -version = "0.14.28" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf96e135eb83a2a8ddf766e426a841d8ddd7449d5f00d34ea02b41d2f19eef80" +checksum = "fe575dd17d0862a9a33781c8c4696a55c320909004a67a00fb286ba8b1bc496d" dependencies = [ "bytes", "futures-channel", - "futures-core", "futures-util", "h2", "http", "http-body", "httparse", - "httpdate", "itoa", "pin-project-lite", - "socket2", + "smallvec", "tokio", - "tower-service", - "tracing", "want", ] [[package]] name = "hyper-tls" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" dependencies = [ "bytes", + "http-body-util", "hyper", + "hyper-util", "native-tls", "tokio", "tokio-native-tls", + "tower-service", +] + +[[package]] +name = "hyper-util" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b875924a60b96e5d7b9ae7b066540b1dd1cbd90d1828f54c92e02a283351c56" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", ] [[package]] @@ -1327,6 +1413,7 @@ checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" dependencies = [ "equivalent", "hashbrown", + "serde", ] [[package]] @@ -1467,6 +1554,12 @@ dependencies = [ "multiversx-sc-meta", ] +[[package]] +name = "lockfree-object-pool" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" + [[package]] name = "locking_module" version = "0.0.0" @@ -1478,9 +1571,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.20" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" [[package]] name = "math" @@ -1491,9 +1584,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.7.1" +version = "2.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "523dc4f511e55ab87b694dc30d0f820d60906ef06413f93d4d7a1385599cc149" +checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" [[package]] name = "memory_units" @@ -1571,11 +1664,11 @@ dependencies = [ [[package]] name = "multiversx-chain-vm" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a363734a77774f4095fad6f49c6772b82edd833ed47a7c1ca87db18f68ccfffd" +checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" dependencies = [ - "bitflags 2.4.2", + "bitflags 2.5.0", "colored", "ed25519-dalek", "hex", @@ -1598,33 +1691,35 @@ checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ - "bitflags 2.4.2", + "bitflags 2.5.0", "hex-literal 0.4.1", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", "num-bigint", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -1634,9 +1729,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -1647,9 +1742,9 @@ dependencies = [ [[package]] name = "multiversx-sc-meta" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ce1f4557894ea3b556d3376d4a12c0494b8085a69c7f02def42bed0702ade58" +checksum = "93aba82492783759620d72f21059749177e66438d0c021597c567eae8e888307" dependencies = [ "clap", "colored", @@ -1667,27 +1762,27 @@ dependencies = [ "serde", "serde_json", "toml", - "wasmparser 0.121.2", + "wasmparser", "wasmprinter", "zip", ] [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-scenario" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa109d85d90599c232c2c4ac19a0f6c12a558ad72aa04f4b40ff9e23365b1897" +checksum = "d2992739c2ef6bc8e448434b9c3ab848f2ce17264192a9918734cbb3884d0435" dependencies = [ - "base64", + "base64 0.22.1", "bech32", "clap", "colored", @@ -1707,16 +1802,17 @@ dependencies = [ "serde_json", "sha2 0.10.8", "tokio", + "unwrap-infallible", ] [[package]] name = "multiversx-sdk" -version = "0.3.2" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46d709ddf46c50a407ce4b90ff487e854926d47f80de6abfe4a4adca3eaa7964" +checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" dependencies = [ "anyhow", - "base64", + "base64 0.22.1", "bech32", "bip39", "hex", @@ -1764,30 +1860,28 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.4" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608e7659b5c3d7cba262d894801b9ec9d00de989e8a82bd4bef91d08da45cdc0" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" dependencies = [ - "autocfg", "num-integer", "num-traits", ] [[package]] name = "num-integer" -version = "0.1.45" +version = "0.1.46" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" dependencies = [ - "autocfg", "num-traits", ] [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -1829,7 +1923,7 @@ version = "0.10.62" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8cde4d2d9200ad5909f8dac647e29482e07c3a35de8a13fce7c9c7747ad9f671" dependencies = [ - "bitflags 2.4.2", + "bitflags 2.5.0", "cfg-if 1.0.0", "foreign-types", "libc", @@ -1983,7 +2077,7 @@ version = "3.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1b8fcc794035347fb64beda2d3b462595dd2753e3f268d89c5aae77e8cf2c310" dependencies = [ - "base64", + "base64 0.21.7", "serde", ] @@ -1997,11 +2091,31 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" name = "permissions_module" version = "0.0.0" dependencies = [ - "bitflags 2.4.2", + "bitflags 2.5.0", "common_errors", "multiversx-sc", ] +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "pin-project-lite" version = "0.2.13" @@ -2051,9 +2165,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] @@ -2123,9 +2237,9 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -2260,20 +2374,23 @@ checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" [[package]] name = "reqwest" -version = "0.11.23" +version = "0.12.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37b1ae8d9ac08420c66222fb9096fc5de435c3c48542bc5336c51892cffafb41" +checksum = "566cafdd92868e0939d3fb961bd0dc25fcfaaed179291093b3d43e6b3150ea10" dependencies = [ - "base64", + "base64 0.22.1", "bytes", "encoding_rs", + "futures-channel", "futures-core", "futures-util", "h2", "http", "http-body", + "http-body-util", "hyper", "hyper-tls", + "hyper-util", "ipnet", "js-sys", "log", @@ -2282,9 +2399,11 @@ dependencies = [ "once_cell", "percent-encoding", "pin-project-lite", + "rustls-pemfile", "serde", "serde_json", "serde_urlencoded", + "sync_wrapper", "system-configuration", "tokio", "tokio-native-tls", @@ -2367,13 +2486,29 @@ version = "0.38.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "322394588aaf33c24007e8bb3238ee3e4c5c09c084ab32bc73890b99ff326bca" dependencies = [ - "bitflags 2.4.2", + "bitflags 2.5.0", "errno", "libc", "linux-raw-sys", "windows-sys 0.52.0", ] +[[package]] +name = "rustls-pemfile" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +dependencies = [ + "base64 0.22.1", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + [[package]] name = "ryu" version = "1.0.16" @@ -2554,6 +2689,12 @@ version = "1.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + [[package]] name = "simple-lock" version = "0.0.0" @@ -2635,15 +2776,21 @@ checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", "unicode-ident", ] +[[package]] +name = "sync_wrapper" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" + [[package]] name = "system-configuration" version = "0.5.1" @@ -2678,6 +2825,26 @@ dependencies = [ "windows-sys 0.52.0", ] +[[package]] +name = "thiserror" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "tinyvec" version = "1.6.0" @@ -2826,6 +2993,27 @@ dependencies = [ "winnow", ] +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + [[package]] name = "tower-service" version = "0.3.2" @@ -2890,6 +3078,12 @@ version = "1.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" @@ -3035,34 +3229,26 @@ checksum = "4d91413b1c31d7539ba5ef2451af3f0b833a005eb27a631cec32bc0635a8602b" [[package]] name = "wasmparser" -version = "0.119.0" +version = "0.208.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c35daf77afb4f9b14016625144a391085ec2ca99ca9cc53ed291bb53ab5278d" +checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" dependencies = [ - "bitflags 2.4.2", - "indexmap", - "semver", -] - -[[package]] -name = "wasmparser" -version = "0.121.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9dbe55c8f9d0dbd25d9447a5a889ff90c0cc3feaa7395310d3d826b2c703eaab" -dependencies = [ - "bitflags 2.4.2", + "ahash", + "bitflags 2.5.0", + "hashbrown", "indexmap", "semver", + "serde", ] [[package]] name = "wasmprinter" -version = "0.2.76" +version = "0.208.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cac2a7745372074e5573e365e17100f5a26058740576313784ef03fb900ea8d2" +checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" dependencies = [ "anyhow", - "wasmparser 0.119.0", + "wasmparser", ] [[package]] @@ -3281,14 +3467,34 @@ dependencies = [ [[package]] name = "winreg" -version = "0.50.0" +version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" dependencies = [ "cfg-if 1.0.0", "windows-sys 0.48.0", ] +[[package]] +name = "zerocopy" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "zeroize" version = "1.7.0" @@ -3311,12 +3517,31 @@ dependencies = [ [[package]] name = "zip" -version = "0.6.6" +version = "2.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "760394e246e4c28189f19d488c058bf16f564016aefac5d32bb1f3b51d5e9261" +checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" dependencies = [ - "byteorder", + "arbitrary", "crc32fast", "crossbeam-utils", + "displaydoc", "flate2", + "indexmap", + "memchr", + "thiserror", + "zopfli", +] + +[[package]] +name = "zopfli" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" +dependencies = [ + "bumpalo", + "crc32fast", + "lockfree-object-pool", + "log", + "once_cell", + "simd-adler32", ] diff --git a/common/common_errors/Cargo.toml b/common/common_errors/Cargo.toml index 64926a87a..3c09666f5 100644 --- a/common/common_errors/Cargo.toml +++ b/common/common_errors/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/common_structs/Cargo.toml b/common/common_structs/Cargo.toml index 7379b6b97..4c968a4ea 100644 --- a/common/common_structs/Cargo.toml +++ b/common/common_structs/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] diff --git a/common/modules/farm/config/Cargo.toml b/common/modules/farm/config/Cargo.toml index 89f943416..67129dfb3 100644 --- a/common/modules/farm/config/Cargo.toml +++ b/common/modules/farm/config/Cargo.toml @@ -23,5 +23,5 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/contexts/Cargo.toml b/common/modules/farm/contexts/Cargo.toml index fc43fa5e1..b13802a54 100644 --- a/common/modules/farm/contexts/Cargo.toml +++ b/common/modules/farm/contexts/Cargo.toml @@ -35,8 +35,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" diff --git a/common/modules/farm/events/Cargo.toml b/common/modules/farm/events/Cargo.toml index 96af56178..bb5b0be65 100644 --- a/common/modules/farm/events/Cargo.toml +++ b/common/modules/farm/events/Cargo.toml @@ -14,5 +14,5 @@ path = "../../../common_structs" path = "../contexts" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/farm_base_impl/Cargo.toml b/common/modules/farm/farm_base_impl/Cargo.toml index ff33b5860..7fc90ef69 100644 --- a/common/modules/farm/farm_base_impl/Cargo.toml +++ b/common/modules/farm/farm_base_impl/Cargo.toml @@ -50,11 +50,11 @@ path = "../../../traits/mergeable" path = "../../../traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/common/modules/farm/farm_token/Cargo.toml b/common/modules/farm/farm_token/Cargo.toml index eaf015a78..5de06a44e 100644 --- a/common/modules/farm/farm_token/Cargo.toml +++ b/common/modules/farm/farm_token/Cargo.toml @@ -26,8 +26,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" diff --git a/common/modules/farm/farm_token_merge/Cargo.toml b/common/modules/farm/farm_token_merge/Cargo.toml index 1b8ec9ee2..52fbad221 100644 --- a/common/modules/farm/farm_token_merge/Cargo.toml +++ b/common/modules/farm/farm_token_merge/Cargo.toml @@ -23,11 +23,11 @@ path = "../../token_merge_helper" path = "../farm_token" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/common/modules/farm/rewards/Cargo.toml b/common/modules/farm/rewards/Cargo.toml index 115cd04b3..815bc8a5d 100644 --- a/common/modules/farm/rewards/Cargo.toml +++ b/common/modules/farm/rewards/Cargo.toml @@ -29,8 +29,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" diff --git a/common/modules/legacy_token_decode_module/Cargo.toml b/common/modules/legacy_token_decode_module/Cargo.toml index 5c12ba15d..1be8769aa 100644 --- a/common/modules/legacy_token_decode_module/Cargo.toml +++ b/common/modules/legacy_token_decode_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/modules/locking_module/Cargo.toml b/common/modules/locking_module/Cargo.toml index 07b8719b7..3c88f3cb8 100644 --- a/common/modules/locking_module/Cargo.toml +++ b/common/modules/locking_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.simple-lock] diff --git a/common/modules/locking_module/src/lock_with_energy_module.rs b/common/modules/locking_module/src/lock_with_energy_module.rs index cb7b02911..7569c4f61 100644 --- a/common/modules/locking_module/src/lock_with_energy_module.rs +++ b/common/modules/locking_module/src/lock_with_energy_module.rs @@ -36,7 +36,7 @@ pub trait LockWithEnergyModule { .execute_on_dest_context() } - fn get_locking_sc_proxy_instance(&self) -> energy_factory::Proxy { + fn get_locking_sc_proxy_instance(&self) -> energy_factory::ProxyTo { let locking_sc_address = self.locking_sc_address().get(); self.locking_sc_proxy_obj(locking_sc_address) } diff --git a/common/modules/locking_module/src/locking_module.rs b/common/modules/locking_module/src/locking_module.rs index 4b79a57af..05596a2f5 100644 --- a/common/modules/locking_module/src/locking_module.rs +++ b/common/modules/locking_module/src/locking_module.rs @@ -53,13 +53,13 @@ pub trait LockingModule { .execute_on_dest_context() } - fn get_locking_sc_proxy_instance(&self) -> simple_lock::Proxy { + fn get_locking_sc_proxy_instance(&self) -> simple_lock::ProxyTo { let locking_sc_address = self.locking_sc_address().get(); self.locking_sc_proxy_obj(locking_sc_address) } #[proxy] - fn locking_sc_proxy_obj(&self, sc_address: ManagedAddress) -> simple_lock::Proxy; + fn locking_sc_proxy_obj(&self, sc_address: ManagedAddress) -> simple_lock::ProxyTo; #[view(getLockingScAddress)] #[storage_mapper("lockingScAddress")] diff --git a/common/modules/math/Cargo.toml b/common/modules/math/Cargo.toml index 830764e08..8a9df07f0 100644 --- a/common/modules/math/Cargo.toml +++ b/common/modules/math/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/pausable/Cargo.toml b/common/modules/pausable/Cargo.toml index 3668c2822..3d825a9f1 100644 --- a/common/modules/pausable/Cargo.toml +++ b/common/modules/pausable/Cargo.toml @@ -11,5 +11,5 @@ path = "src/pausable.rs" path = "../permissions_module" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/permissions_module/Cargo.toml b/common/modules/permissions_module/Cargo.toml index af71e2aef..53ea3eea0 100644 --- a/common/modules/permissions_module/Cargo.toml +++ b/common/modules/permissions_module/Cargo.toml @@ -17,5 +17,5 @@ bitflags = "2.4.1" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/permissions_module/src/permissions.rs b/common/modules/permissions_module/src/permissions.rs index 623c72718..245ccda6a 100644 --- a/common/modules/permissions_module/src/permissions.rs +++ b/common/modules/permissions_module/src/permissions.rs @@ -1,6 +1,6 @@ use bitflags::bitflags; use multiversx_sc::{ - abi::TypeAbi, + abi::{TypeAbi, TypeAbiFrom}, codec::{DecodeError, TopDecode, TopEncode}, }; bitflags! { @@ -32,8 +32,16 @@ impl TopDecode for Permissions { } } -impl TypeAbi for Permissions { - fn type_name() -> multiversx_sc::abi::TypeName { - core::any::type_name::().into() - } -} +impl TypeAbiFrom for Permissions {} + + impl TypeAbi for Permissions { + type Unmanaged = Self; + + fn type_name() -> multiversx_sc::abi::TypeName { + core::any::type_name::().into() + } + + fn type_name_rust() -> multiversx_sc::abi::TypeName { + core::any::type_name::().into() + } + } \ No newline at end of file diff --git a/common/modules/permissions_module/src/permissions_module.rs b/common/modules/permissions_module/src/permissions_module.rs index 5853ca0da..38eab7fdd 100644 --- a/common/modules/permissions_module/src/permissions_module.rs +++ b/common/modules/permissions_module/src/permissions_module.rs @@ -1,6 +1,6 @@ #![no_std] -mod permissions; +pub mod permissions; use common_errors::ERROR_PERMISSION_DENIED; diff --git a/common/modules/sc_whitelist_module/Cargo.toml b/common/modules/sc_whitelist_module/Cargo.toml index 82e3e103a..37be4210c 100644 --- a/common/modules/sc_whitelist_module/Cargo.toml +++ b/common/modules/sc_whitelist_module/Cargo.toml @@ -11,5 +11,5 @@ path = "src/sc_whitelist_module.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_merge_helper/Cargo.toml b/common/modules/token_merge_helper/Cargo.toml index 46795b0fc..8f8d34845 100644 --- a/common/modules/token_merge_helper/Cargo.toml +++ b/common/modules/token_merge_helper/Cargo.toml @@ -11,5 +11,5 @@ path = "src/lib.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_send/Cargo.toml b/common/modules/token_send/Cargo.toml index 714272dea..afe83527d 100644 --- a/common/modules/token_send/Cargo.toml +++ b/common/modules/token_send/Cargo.toml @@ -14,5 +14,5 @@ path = "../../common_structs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/utils/Cargo.toml b/common/modules/utils/Cargo.toml index cc25d8fb1..0e748a5d4 100644 --- a/common/modules/utils/Cargo.toml +++ b/common/modules/utils/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/traits/fixed-supply-token/Cargo.toml b/common/traits/fixed-supply-token/Cargo.toml index 951361da3..0d8c17fdd 100644 --- a/common/traits/fixed-supply-token/Cargo.toml +++ b/common/traits/fixed-supply-token/Cargo.toml @@ -8,4 +8,4 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" diff --git a/common/traits/mergeable/Cargo.toml b/common/traits/mergeable/Cargo.toml index 5d21bb032..a68b46bb9 100644 --- a/common/traits/mergeable/Cargo.toml +++ b/common/traits/mergeable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/traits/unwrappable/Cargo.toml b/common/traits/unwrappable/Cargo.toml index abfe07baa..c938ec365 100644 --- a/common/traits/unwrappable/Cargo.toml +++ b/common/traits/unwrappable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/dex/Cargo.toml b/dex/Cargo.toml index 15911dec5..a247791a9 100644 --- a/dex/Cargo.toml +++ b/dex/Cargo.toml @@ -5,17 +5,17 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.config] path = "../common/modules/farm/config" diff --git a/dex/farm-with-locked-rewards/Cargo.toml b/dex/farm-with-locked-rewards/Cargo.toml index 2f7981506..8871b9679 100644 --- a/dex/farm-with-locked-rewards/Cargo.toml +++ b/dex/farm-with-locked-rewards/Cargo.toml @@ -75,17 +75,17 @@ path = "../../locked-asset/energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.simple-lock] path = "../../locked-asset/simple-lock" diff --git a/dex/farm-with-locked-rewards/meta/Cargo.toml b/dex/farm-with-locked-rewards/meta/Cargo.toml index 804328648..de17ee22d 100644 --- a/dex/farm-with-locked-rewards/meta/Cargo.toml +++ b/dex/farm-with-locked-rewards/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.lock b/dex/farm-with-locked-rewards/wasm/Cargo.lock index 8cdfe8576..f4ea9e617 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.lock +++ b/dex/farm-with-locked-rewards/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -315,32 +315,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -350,9 +352,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -363,18 +365,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -390,9 +392,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -432,18 +434,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -498,9 +500,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -530,6 +532,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.toml b/dex/farm-with-locked-rewards/wasm/Cargo.toml index 6a907bd28..b43cd7487 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.toml +++ b/dex/farm-with-locked-rewards/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.farm-with-locked-rewards] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/farm-with-locked-rewards/wasm/src/lib.rs b/dex/farm-with-locked-rewards/wasm/src/lib.rs index c3aaf7509..37561d256 100644 --- a/dex/farm-with-locked-rewards/wasm/src/lib.rs +++ b/dex/farm-with-locked-rewards/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 68 +// Upgrade: 1 +// Endpoints: 67 // Async Callback: 1 // Total number of exported functions: 70 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/farm/Cargo.toml b/dex/farm/Cargo.toml index 411855d62..639c8b0d5 100644 --- a/dex/farm/Cargo.toml +++ b/dex/farm/Cargo.toml @@ -69,11 +69,11 @@ path = "../../energy-integration/common-modules/weekly-rewards-splitting" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies] num-bigint = "0.4.2" @@ -82,7 +82,7 @@ num-bigint = "0.4.2" path = "../../energy-integration/energy-update" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.energy-factory-mock] path = "../../energy-integration/energy-factory-mock" diff --git a/dex/farm/meta/Cargo.toml b/dex/farm/meta/Cargo.toml index 396e12099..ede4d6be2 100644 --- a/dex/farm/meta/Cargo.toml +++ b/dex/farm/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/farm/wasm/Cargo.lock b/dex/farm/wasm/Cargo.lock index 98035925c..320954ab7 100644 --- a/dex/farm/wasm/Cargo.lock +++ b/dex/farm/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -285,32 +285,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -320,9 +322,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -333,18 +335,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -360,9 +362,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -402,18 +404,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -468,9 +470,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -500,6 +502,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/farm/wasm/Cargo.toml b/dex/farm/wasm/Cargo.toml index f2c3e3d7b..503e8c78f 100644 --- a/dex/farm/wasm/Cargo.toml +++ b/dex/farm/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.farm] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/farm/wasm/src/lib.rs b/dex/farm/wasm/src/lib.rs index c129590b3..60fe520f8 100644 --- a/dex/farm/wasm/src/lib.rs +++ b/dex/farm/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 65 +// Upgrade: 1 +// Endpoints: 64 // Async Callback: 1 // Total number of exported functions: 67 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/fuzz/Cargo.toml b/dex/fuzz/Cargo.toml index c88fdb5fe..ea1861c9f 100644 --- a/dex/fuzz/Cargo.toml +++ b/dex/fuzz/Cargo.toml @@ -12,11 +12,11 @@ num-bigint = "0.4.2" rand = "0.8.4" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dependencies.pausable] path = "../../common/modules/pausable" diff --git a/dex/governance/Cargo.toml b/dex/governance/Cargo.toml index 8488415a5..4680872a4 100644 --- a/dex/governance/Cargo.toml +++ b/dex/governance/Cargo.toml @@ -9,14 +9,14 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.pair-mock] path = "../pair-mock" diff --git a/dex/governance/meta/Cargo.toml b/dex/governance/meta/Cargo.toml index 89991cea1..8960adb4d 100644 --- a/dex/governance/meta/Cargo.toml +++ b/dex/governance/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/governance/wasm/Cargo.lock b/dex/governance/wasm/Cargo.lock index 9fff7d29b..f0431c399 100644 --- a/dex/governance/wasm/Cargo.lock +++ b/dex/governance/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "endian-type" @@ -55,32 +55,34 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -90,9 +92,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -103,9 +105,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -121,27 +123,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -164,9 +166,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -178,3 +180,9 @@ name = "unicode-ident" version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/dex/governance/wasm/Cargo.toml b/dex/governance/wasm/Cargo.toml index 773f97944..7a40f5eab 100644 --- a/dex/governance/wasm/Cargo.toml +++ b/dex/governance/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.governance] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/governance/wasm/src/lib.rs b/dex/governance/wasm/src/lib.rs index 913c84bba..8e699c12c 100644 --- a/dex/governance/wasm/src/lib.rs +++ b/dex/governance/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 22 +// Upgrade: 1 +// Endpoints: 21 // Async Callback (empty): 1 // Total number of exported functions: 24 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/pair-mock/Cargo.toml b/dex/pair-mock/Cargo.toml index e723b6cb2..471866c8d 100644 --- a/dex/pair-mock/Cargo.toml +++ b/dex/pair-mock/Cargo.toml @@ -12,7 +12,7 @@ path = "src/pair.rs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.itertools] @@ -20,4 +20,4 @@ version = "0.10.1" default-features = false [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/dex/pair-mock/meta/Cargo.toml b/dex/pair-mock/meta/Cargo.toml index 6be30bffe..783641ecd 100644 --- a/dex/pair-mock/meta/Cargo.toml +++ b/dex/pair-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/pair-mock/wasm/Cargo.lock b/dex/pair-mock/wasm/Cargo.lock index e792a0986..a7914463c 100644 --- a/dex/pair-mock/wasm/Cargo.lock +++ b/dex/pair-mock/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_errors" @@ -62,32 +62,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -97,9 +99,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -110,9 +112,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -128,9 +130,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -154,18 +156,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -188,9 +190,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -202,3 +204,9 @@ name = "unicode-ident" version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/dex/pair-mock/wasm/Cargo.toml b/dex/pair-mock/wasm/Cargo.toml index 76349235f..e0dc17d07 100644 --- a/dex/pair-mock/wasm/Cargo.toml +++ b/dex/pair-mock/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.pair-mock] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/pair-mock/wasm/src/lib.rs b/dex/pair-mock/wasm/src/lib.rs index e3462d773..4501da7a5 100644 --- a/dex/pair-mock/wasm/src/lib.rs +++ b/dex/pair-mock/wasm/src/lib.rs @@ -10,8 +10,6 @@ // Total number of exported functions: 4 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/pair/Cargo.toml b/dex/pair/Cargo.toml index 145fc58af..60d42ebb5 100644 --- a/dex/pair/Cargo.toml +++ b/dex/pair/Cargo.toml @@ -37,11 +37,11 @@ version = "0.10.1" default-features = false [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/dex/pair/meta/Cargo.toml b/dex/pair/meta/Cargo.toml index cb381e44d..ba136bd9a 100644 --- a/dex/pair/meta/Cargo.toml +++ b/dex/pair/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/pair/src/locking_wrapper.rs b/dex/pair/src/locking_wrapper.rs index 14fb910b8..88d056044 100644 --- a/dex/pair/src/locking_wrapper.rs +++ b/dex/pair/src/locking_wrapper.rs @@ -74,7 +74,7 @@ pub trait LockingWrapperModule: current_epoch < locking_deadline_epoch } - fn get_locking_sc_proxy_instance(&self) -> simple_lock::Proxy { + fn get_locking_sc_proxy_instance(&self) -> simple_lock::ProxyTo { let locking_sc_address = self.locking_sc_address().get(); self.locking_sc_proxy_obj(locking_sc_address) } diff --git a/dex/pair/wasm-pair-full/Cargo.lock b/dex/pair/wasm-pair-full/Cargo.lock index 31a1865f1..911587c1d 100644 --- a/dex/pair/wasm-pair-full/Cargo.lock +++ b/dex/pair/wasm-pair-full/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -161,32 +161,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -196,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -209,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -236,9 +238,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -286,18 +288,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -337,9 +339,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -361,6 +363,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/pair/wasm-pair-full/Cargo.toml b/dex/pair/wasm-pair-full/Cargo.toml index 96ee5d5db..dd36c1284 100644 --- a/dex/pair/wasm-pair-full/Cargo.toml +++ b/dex/pair/wasm-pair-full/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.pair] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/pair/wasm-pair-full/src/lib.rs b/dex/pair/wasm-pair-full/src/lib.rs index 149c4a91b..5f39165a9 100644 --- a/dex/pair/wasm-pair-full/src/lib.rs +++ b/dex/pair/wasm-pair-full/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 64 +// Upgrade: 1 +// Endpoints: 63 // Async Callback (empty): 1 // Total number of exported functions: 66 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/pair/wasm-safe-price-view/Cargo.lock b/dex/pair/wasm-safe-price-view/Cargo.lock index 4357069de..d12ba17f0 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.lock +++ b/dex/pair/wasm-safe-price-view/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -161,32 +161,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -196,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -209,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -236,9 +238,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -278,18 +280,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -337,9 +339,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -361,6 +363,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/pair/wasm-safe-price-view/Cargo.toml b/dex/pair/wasm-safe-price-view/Cargo.toml index 2ded396fe..d4de815c0 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.toml +++ b/dex/pair/wasm-safe-price-view/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.pair] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/pair/wasm-safe-price-view/src/lib.rs b/dex/pair/wasm-safe-price-view/src/lib.rs index cc5f99d90..de0966c65 100644 --- a/dex/pair/wasm-safe-price-view/src/lib.rs +++ b/dex/pair/wasm-safe-price-view/src/lib.rs @@ -10,8 +10,6 @@ // Total number of exported functions: 11 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/pair/wasm/Cargo.lock b/dex/pair/wasm/Cargo.lock index 42713d696..bcaa3d0bc 100644 --- a/dex/pair/wasm/Cargo.lock +++ b/dex/pair/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -161,32 +161,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -196,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -209,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -236,9 +238,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -286,18 +288,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -337,9 +339,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -361,6 +363,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/pair/wasm/Cargo.toml b/dex/pair/wasm/Cargo.toml index 7ab7c8901..3484c1e89 100644 --- a/dex/pair/wasm/Cargo.toml +++ b/dex/pair/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.pair] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/pair/wasm/src/lib.rs b/dex/pair/wasm/src/lib.rs index 82a357b8a..7279213ee 100644 --- a/dex/pair/wasm/src/lib.rs +++ b/dex/pair/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 55 +// Upgrade: 1 +// Endpoints: 54 // Async Callback (empty): 1 // Total number of exported functions: 57 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/price-discovery/Cargo.toml b/dex/price-discovery/Cargo.toml index 74efd78a8..bdf95bc25 100644 --- a/dex/price-discovery/Cargo.toml +++ b/dex/price-discovery/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.locking_module] path = "../../common/modules/locking_module" @@ -30,4 +30,4 @@ hex = "0.4" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/dex/price-discovery/elrond.json b/dex/price-discovery/elrond.json deleted file mode 100644 index 736553962..000000000 --- a/dex/price-discovery/elrond.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "language": "rust" -} \ No newline at end of file diff --git a/dex/price-discovery/meta/Cargo.toml b/dex/price-discovery/meta/Cargo.toml index c6a8b19d7..e66c3061b 100644 --- a/dex/price-discovery/meta/Cargo.toml +++ b/dex/price-discovery/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/price-discovery/wasm/Cargo.lock b/dex/price-discovery/wasm/Cargo.lock index ae8611c4d..dfb83b4ec 100644 --- a/dex/price-discovery/wasm/Cargo.lock +++ b/dex/price-discovery/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_errors" @@ -119,32 +119,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal 0.4.1", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -154,9 +156,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -167,18 +169,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -194,9 +196,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -221,18 +223,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -272,9 +274,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -287,6 +289,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/price-discovery/wasm/Cargo.toml b/dex/price-discovery/wasm/Cargo.toml index 0969e1b66..f85524500 100644 --- a/dex/price-discovery/wasm/Cargo.toml +++ b/dex/price-discovery/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.price-discovery] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/price-discovery/wasm/src/lib.rs b/dex/price-discovery/wasm/src/lib.rs index c29196d8a..5e55db7a5 100644 --- a/dex/price-discovery/wasm/src/lib.rs +++ b/dex/price-discovery/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 28 +// Upgrade: 1 +// Endpoints: 27 // Async Callback: 1 // Total number of exported functions: 30 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/proxy-deployer/Cargo.toml b/dex/proxy-deployer/Cargo.toml index f50a038ff..4b99fc099 100644 --- a/dex/proxy-deployer/Cargo.toml +++ b/dex/proxy-deployer/Cargo.toml @@ -21,11 +21,11 @@ path = "../../common/modules/farm/config" path = "../../common/modules/farm/farm_token" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/dex/proxy-deployer/meta/Cargo.toml b/dex/proxy-deployer/meta/Cargo.toml index ddae9ccb9..a56b481ae 100644 --- a/dex/proxy-deployer/meta/Cargo.toml +++ b/dex/proxy-deployer/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/proxy-deployer/wasm/Cargo.lock b/dex/proxy-deployer/wasm/Cargo.lock index e3585e359..af17a3fca 100644 --- a/dex/proxy-deployer/wasm/Cargo.lock +++ b/dex/proxy-deployer/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -277,32 +277,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -312,9 +314,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -325,18 +327,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -352,9 +354,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -394,9 +396,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] @@ -422,9 +424,9 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -479,9 +481,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -511,6 +513,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/proxy-deployer/wasm/Cargo.toml b/dex/proxy-deployer/wasm/Cargo.toml index 33d489855..d5629cb8d 100644 --- a/dex/proxy-deployer/wasm/Cargo.toml +++ b/dex/proxy-deployer/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.proxy-deployer] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/proxy-deployer/wasm/src/lib.rs b/dex/proxy-deployer/wasm/src/lib.rs index b8f3493f8..620fcb058 100644 --- a/dex/proxy-deployer/wasm/src/lib.rs +++ b/dex/proxy-deployer/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 5 +// Upgrade: 1 +// Endpoints: 4 // Async Callback (empty): 1 // Total number of exported functions: 7 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/dex/router/Cargo.toml b/dex/router/Cargo.toml index a70a9ba1d..ade4ab150 100644 --- a/dex/router/Cargo.toml +++ b/dex/router/Cargo.toml @@ -15,7 +15,7 @@ path = "../../common/modules/token_send" path = "../../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.pair] @@ -28,4 +28,4 @@ path = "../../common/modules/locking_module" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/dex/router/meta/Cargo.toml b/dex/router/meta/Cargo.toml index 744ea5d49..9d8831aa3 100644 --- a/dex/router/meta/Cargo.toml +++ b/dex/router/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/dex/router/src/contract.rs b/dex/router/src/contract.rs index e23d0f12f..cfe2d6936 100644 --- a/dex/router/src/contract.rs +++ b/dex/router/src/contract.rs @@ -1,4 +1,5 @@ #![no_std] +#![allow(deprecated)] multiversx_sc::imports!(); multiversx_sc::derive_imports!(); diff --git a/dex/router/wasm/Cargo.lock b/dex/router/wasm/Cargo.lock index 4b5559753..da5457672 100644 --- a/dex/router/wasm/Cargo.lock +++ b/dex/router/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -161,32 +161,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -196,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -209,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -236,9 +238,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -278,18 +280,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -349,9 +351,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -373,6 +375,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/dex/router/wasm/Cargo.toml b/dex/router/wasm/Cargo.toml index 32fa69d41..947c3c8bf 100644 --- a/dex/router/wasm/Cargo.toml +++ b/dex/router/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.router] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/dex/router/wasm/src/lib.rs b/dex/router/wasm/src/lib.rs index ee424764b..eb0bb84d5 100644 --- a/dex/router/wasm/src/lib.rs +++ b/dex/router/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 30 +// Upgrade: 1 +// Endpoints: 29 // Async Callback: 1 // Total number of exported functions: 32 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/energy-integration/common-modules/energy-query/Cargo.toml b/energy-integration/common-modules/energy-query/Cargo.toml index 71d7eae02..40ee230ca 100644 --- a/energy-integration/common-modules/energy-query/Cargo.toml +++ b/energy-integration/common-modules/energy-query/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-factory] diff --git a/energy-integration/common-modules/week-timekeeping/Cargo.toml b/energy-integration/common-modules/week-timekeeping/Cargo.toml index 9fd1da07a..5dae717d3 100644 --- a/energy-integration/common-modules/week-timekeeping/Cargo.toml +++ b/energy-integration/common-modules/week-timekeeping/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.common-types] diff --git a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml index 5492ba8cb..b2f7fa142 100644 --- a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml +++ b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-query] diff --git a/energy-integration/common-types/Cargo.toml b/energy-integration/common-types/Cargo.toml index 1f8d53b0a..0a8187567 100644 --- a/energy-integration/common-types/Cargo.toml +++ b/energy-integration/common-types/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] diff --git a/energy-integration/energy-factory-mock/Cargo.toml b/energy-integration/energy-factory-mock/Cargo.toml index d7f9bcec9..d9545f430 100644 --- a/energy-integration/energy-factory-mock/Cargo.toml +++ b/energy-integration/energy-factory-mock/Cargo.toml @@ -12,8 +12,8 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/energy-integration/energy-factory-mock/meta/Cargo.toml b/energy-integration/energy-factory-mock/meta/Cargo.toml index 0806b3834..bbfca05d0 100644 --- a/energy-integration/energy-factory-mock/meta/Cargo.toml +++ b/energy-integration/energy-factory-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.lock b/energy-integration/energy-factory-mock/wasm/Cargo.lock index a0351871d..8bd373b84 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.lock +++ b/energy-integration/energy-factory-mock/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_errors" @@ -128,32 +128,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -163,9 +165,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -176,18 +178,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -203,27 +205,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -263,9 +265,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -278,6 +280,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.toml b/energy-integration/energy-factory-mock/wasm/Cargo.toml index eb5ced1a1..c7c143695 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.toml +++ b/energy-integration/energy-factory-mock/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.energy-factory-mock] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/energy-integration/energy-factory-mock/wasm/src/lib.rs b/energy-integration/energy-factory-mock/wasm/src/lib.rs index c52b88848..400849b5a 100644 --- a/energy-integration/energy-factory-mock/wasm/src/lib.rs +++ b/energy-integration/energy-factory-mock/wasm/src/lib.rs @@ -10,8 +10,6 @@ // Total number of exported functions: 6 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/energy-integration/energy-update/Cargo.toml b/energy-integration/energy-update/Cargo.toml index e090da980..578fa3dec 100644 --- a/energy-integration/energy-update/Cargo.toml +++ b/energy-integration/energy-update/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.farm] path = "../../dex/farm" @@ -25,4 +25,4 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/energy-integration/energy-update/elrond.json b/energy-integration/energy-update/elrond.json deleted file mode 100644 index 736553962..000000000 --- a/energy-integration/energy-update/elrond.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "language": "rust" -} \ No newline at end of file diff --git a/energy-integration/energy-update/meta/Cargo.toml b/energy-integration/energy-update/meta/Cargo.toml index cb055bb36..ee1661cc5 100644 --- a/energy-integration/energy-update/meta/Cargo.toml +++ b/energy-integration/energy-update/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/energy-integration/energy-update/wasm/Cargo.lock b/energy-integration/energy-update/wasm/Cargo.lock index e167135ea..74f6a59a6 100644 --- a/energy-integration/energy-update/wasm/Cargo.lock +++ b/energy-integration/energy-update/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -295,32 +295,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -330,9 +332,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -343,18 +345,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -370,9 +372,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -412,18 +414,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -478,9 +480,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -510,6 +512,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/energy-integration/energy-update/wasm/Cargo.toml b/energy-integration/energy-update/wasm/Cargo.toml index 7b47001ca..7289149fa 100644 --- a/energy-integration/energy-update/wasm/Cargo.toml +++ b/energy-integration/energy-update/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.energy-update] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/energy-integration/energy-update/wasm/src/lib.rs b/energy-integration/energy-update/wasm/src/lib.rs index b4de939ec..7d5e5998a 100644 --- a/energy-integration/energy-update/wasm/src/lib.rs +++ b/energy-integration/energy-update/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 2 +// Upgrade: 1 +// Endpoints: 1 // Async Callback (empty): 1 // Total number of exported functions: 4 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/energy-integration/farm-boosted-yields/Cargo.toml b/energy-integration/farm-boosted-yields/Cargo.toml index 2cd9dd558..69a6fe39d 100644 --- a/energy-integration/farm-boosted-yields/Cargo.toml +++ b/energy-integration/farm-boosted-yields/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.config] diff --git a/energy-integration/fees-collector/Cargo.toml b/energy-integration/fees-collector/Cargo.toml index 0a978dfb8..59455e4fd 100644 --- a/energy-integration/fees-collector/Cargo.toml +++ b/energy-integration/fees-collector/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.energy-query] path = "../common-modules/energy-query" @@ -49,7 +49,7 @@ path = "../../common/common_errors" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.sc_whitelist_module] path = "../../common/modules/sc_whitelist_module" diff --git a/energy-integration/fees-collector/meta/Cargo.toml b/energy-integration/fees-collector/meta/Cargo.toml index 319511b83..0434fe3fa 100644 --- a/energy-integration/fees-collector/meta/Cargo.toml +++ b/energy-integration/fees-collector/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/energy-integration/fees-collector/wasm/Cargo.lock b/energy-integration/fees-collector/wasm/Cargo.lock index 695f4de4b..92c1abe1e 100644 --- a/energy-integration/fees-collector/wasm/Cargo.lock +++ b/energy-integration/fees-collector/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -154,32 +154,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -189,9 +191,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -202,18 +204,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -229,27 +231,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -289,9 +291,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -304,6 +306,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/energy-integration/fees-collector/wasm/Cargo.toml b/energy-integration/fees-collector/wasm/Cargo.toml index 0d9804acf..ca74577c5 100644 --- a/energy-integration/fees-collector/wasm/Cargo.toml +++ b/energy-integration/fees-collector/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.fees-collector] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/energy-integration/fees-collector/wasm/src/lib.rs b/energy-integration/fees-collector/wasm/src/lib.rs index 75812bfb1..283f21a67 100644 --- a/energy-integration/fees-collector/wasm/src/lib.rs +++ b/energy-integration/fees-collector/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 39 +// Upgrade: 1 +// Endpoints: 38 // Async Callback (empty): 1 // Total number of exported functions: 41 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/energy-integration/governance-v2/Cargo.toml b/energy-integration/governance-v2/Cargo.toml index aec8974fb..516e466c5 100644 --- a/energy-integration/governance-v2/Cargo.toml +++ b/energy-integration/governance-v2/Cargo.toml @@ -12,7 +12,7 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.permissions_module] @@ -28,7 +28,7 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.energy-factory-mock] path = "../energy-factory-mock" diff --git a/energy-integration/governance-v2/meta/Cargo.toml b/energy-integration/governance-v2/meta/Cargo.toml index cb33b5197..4474de48c 100644 --- a/energy-integration/governance-v2/meta/Cargo.toml +++ b/energy-integration/governance-v2/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/energy-integration/governance-v2/wasm/Cargo.lock b/energy-integration/governance-v2/wasm/Cargo.lock index cfe51a0c6..9be4c4915 100644 --- a/energy-integration/governance-v2/wasm/Cargo.lock +++ b/energy-integration/governance-v2/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -165,32 +165,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -200,9 +202,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -213,18 +215,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -240,9 +242,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -258,18 +260,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -309,9 +311,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -324,6 +326,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/energy-integration/governance-v2/wasm/Cargo.toml b/energy-integration/governance-v2/wasm/Cargo.toml index 090b2e76b..b99743471 100644 --- a/energy-integration/governance-v2/wasm/Cargo.toml +++ b/energy-integration/governance-v2/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.governance-v2] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/energy-integration/governance-v2/wasm/src/lib.rs b/energy-integration/governance-v2/wasm/src/lib.rs index bb977bc97..0211fca5a 100644 --- a/energy-integration/governance-v2/wasm/src/lib.rs +++ b/energy-integration/governance-v2/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 30 +// Upgrade: 1 +// Endpoints: 29 // Async Callback (empty): 1 // Total number of exported functions: 32 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/farm-staking/farm-staking-proxy/Cargo.toml b/farm-staking/farm-staking-proxy/Cargo.toml index a4fa7e84b..d4320ae73 100644 --- a/farm-staking/farm-staking-proxy/Cargo.toml +++ b/farm-staking/farm-staking-proxy/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.farm] path = "../../dex/farm" @@ -67,7 +67,7 @@ path = "../../energy-integration/common-modules/energy-query" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.farm_token] path = "../../common/modules/farm/farm_token" diff --git a/farm-staking/farm-staking-proxy/meta/Cargo.toml b/farm-staking/farm-staking-proxy/meta/Cargo.toml index 62566f32c..e2fbbe1c7 100644 --- a/farm-staking/farm-staking-proxy/meta/Cargo.toml +++ b/farm-staking/farm-staking-proxy/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/farm-staking/farm-staking-proxy/src/external_contracts_interactions.rs b/farm-staking/farm-staking-proxy/src/external_contracts_interactions.rs index f8048d66b..00df4c3ce 100644 --- a/farm-staking/farm-staking-proxy/src/external_contracts_interactions.rs +++ b/farm-staking/farm-staking-proxy/src/external_contracts_interactions.rs @@ -34,7 +34,7 @@ pub trait ExternalContractsInteractionsModule: let lp_farm_address = self.lp_farm_address().get(); let lp_farm_result: ClaimRewardsResultType = self .lp_farm_proxy_obj(lp_farm_address) - .claim_rewards_endpoint(orig_caller) + .claim_rewards_endpoint(OptionalValue::Some(orig_caller)) .with_esdt_transfer((lp_farm_token_id, lp_farm_token_nonce, lp_farm_token_amount)) .execute_on_dest_context(); let (new_lp_farm_tokens, lp_farm_rewards) = lp_farm_result.into_tuple(); @@ -55,7 +55,7 @@ pub trait ExternalContractsInteractionsModule: let lp_farm_address = self.lp_farm_address().get(); let exit_farm_result: ExitFarmWithPartialPosResultType = self .lp_farm_proxy_obj(lp_farm_address) - .exit_farm_endpoint(orig_caller) + .exit_farm_endpoint(OptionalValue::Some(orig_caller)) .with_esdt_transfer((lp_farm_token_id, lp_farm_token_nonce, lp_farm_token_amount)) .execute_on_dest_context(); let (lp_tokens, lp_farm_rewards) = exit_farm_result.into_tuple(); @@ -82,7 +82,7 @@ pub trait ExternalContractsInteractionsModule: let lp_farm_address = self.lp_farm_address().get(); self.lp_farm_proxy_obj(lp_farm_address) - .merge_farm_tokens_endpoint(orig_caller) + .merge_farm_tokens_endpoint(OptionalValue::Some(orig_caller)) .with_multi_token_transfer(additional_lp_farm_tokens) .execute_on_dest_context() } diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.lock b/farm-staking/farm-staking-proxy/wasm/Cargo.lock index eed21c778..d1d81fddb 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.lock +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -376,32 +376,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal 0.4.1", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -411,9 +413,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -424,18 +426,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -451,9 +453,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -493,18 +495,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -559,9 +561,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -591,6 +593,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.toml b/farm-staking/farm-staking-proxy/wasm/Cargo.toml index 7656441fa..a27f85570 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.toml +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.farm-staking-proxy] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/farm-staking/farm-staking-proxy/wasm/src/lib.rs b/farm-staking/farm-staking-proxy/wasm/src/lib.rs index ee8a50b10..3f9abd0a4 100644 --- a/farm-staking/farm-staking-proxy/wasm/src/lib.rs +++ b/farm-staking/farm-staking-proxy/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 18 +// Upgrade: 1 +// Endpoints: 17 // Async Callback: 1 // Total number of exported functions: 20 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/farm-staking/farm-staking/Cargo.toml b/farm-staking/farm-staking/Cargo.toml index 988da5f65..7ee4d43a8 100644 --- a/farm-staking/farm-staking/Cargo.toml +++ b/farm-staking/farm-staking/Cargo.toml @@ -78,14 +78,14 @@ path = "../../common/common_structs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/farm-staking/farm-staking/meta/Cargo.toml b/farm-staking/farm-staking/meta/Cargo.toml index ec34dd897..e2f328513 100644 --- a/farm-staking/farm-staking/meta/Cargo.toml +++ b/farm-staking/farm-staking/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/farm-staking/farm-staking/wasm/Cargo.lock b/farm-staking/farm-staking/wasm/Cargo.lock index 61f912ed6..15454fe7f 100644 --- a/farm-staking/farm-staking/wasm/Cargo.lock +++ b/farm-staking/farm-staking/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -316,32 +316,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -351,9 +353,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -364,18 +366,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -391,9 +393,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -433,18 +435,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -499,9 +501,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -531,6 +533,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/farm-staking/farm-staking/wasm/Cargo.toml b/farm-staking/farm-staking/wasm/Cargo.toml index 3c20c8125..d8f7b729c 100644 --- a/farm-staking/farm-staking/wasm/Cargo.toml +++ b/farm-staking/farm-staking/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.farm-staking] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/farm-staking/farm-staking/wasm/src/lib.rs b/farm-staking/farm-staking/wasm/src/lib.rs index 4bc7e0bbb..4842309c2 100644 --- a/farm-staking/farm-staking/wasm/src/lib.rs +++ b/farm-staking/farm-staking/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 71 +// Upgrade: 1 +// Endpoints: 70 // Async Callback: 1 // Total number of exported functions: 73 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/farm-staking/metabonding-staking/Cargo.toml b/farm-staking/metabonding-staking/Cargo.toml index b0cfbd186..20448ffcb 100644 --- a/farm-staking/metabonding-staking/Cargo.toml +++ b/farm-staking/metabonding-staking/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.factory] path = "../../locked-asset/factory" @@ -22,7 +22,7 @@ path = "../../locked-asset/factory" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.common_structs] path = "../../common/common_structs" diff --git a/farm-staking/metabonding-staking/meta/Cargo.toml b/farm-staking/metabonding-staking/meta/Cargo.toml index ed0656799..a7d645707 100644 --- a/farm-staking/metabonding-staking/meta/Cargo.toml +++ b/farm-staking/metabonding-staking/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/farm-staking/metabonding-staking/wasm/Cargo.lock b/farm-staking/metabonding-staking/wasm/Cargo.lock index 80567369d..1b00d9efc 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.lock +++ b/farm-staking/metabonding-staking/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "cfg-if" @@ -170,32 +170,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -205,9 +207,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -218,18 +220,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -245,27 +247,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -305,9 +307,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -337,6 +339,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/farm-staking/metabonding-staking/wasm/Cargo.toml b/farm-staking/metabonding-staking/wasm/Cargo.toml index 35311134a..44fbc121d 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.toml +++ b/farm-staking/metabonding-staking/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.metabonding-staking] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/farm-staking/metabonding-staking/wasm/src/lib.rs b/farm-staking/metabonding-staking/wasm/src/lib.rs index b8e948d22..22b6f6de2 100644 --- a/farm-staking/metabonding-staking/wasm/src/lib.rs +++ b/farm-staking/metabonding-staking/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 11 +// Upgrade: 1 +// Endpoints: 10 // Async Callback (empty): 1 // Total number of exported functions: 13 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/legacy-contracts/simple-lock-legacy/Cargo.toml b/legacy-contracts/simple-lock-legacy/Cargo.toml index fb660121e..273f1ea46 100644 --- a/legacy-contracts/simple-lock-legacy/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/legacy-contracts/simple-lock-legacy/meta/Cargo.toml b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml index d9ce41012..d8265bb27 100644 --- a/legacy-contracts/simple-lock-legacy/meta/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock index 0a3d09bf3..9a0ea9eb9 100644 --- a/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_structs" @@ -72,32 +72,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -107,9 +109,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -120,18 +122,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -147,27 +149,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -207,9 +209,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -222,6 +224,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml index 258af6806..e85db946d 100644 --- a/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.simple-lock-legacy] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/legacy-contracts/simple-lock-legacy/wasm/src/lib.rs b/legacy-contracts/simple-lock-legacy/wasm/src/lib.rs index 59effebc7..996a3fd22 100644 --- a/legacy-contracts/simple-lock-legacy/wasm/src/lib.rs +++ b/legacy-contracts/simple-lock-legacy/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 8 +// Upgrade: 1 +// Endpoints: 7 // Async Callback (empty): 1 // Total number of exported functions: 10 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/Cargo.toml b/locked-asset/Cargo.toml index ad5a5986f..ccfa78c14 100644 --- a/locked-asset/Cargo.toml +++ b/locked-asset/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.farm] @@ -50,7 +50,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/distribution/Cargo.toml b/locked-asset/distribution/Cargo.toml index f17a090c9..c0cb6b3e0 100644 --- a/locked-asset/distribution/Cargo.toml +++ b/locked-asset/distribution/Cargo.toml @@ -14,8 +14,8 @@ path = "../../common/common_structs" path = "../factory" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/distribution/meta/Cargo.toml b/locked-asset/distribution/meta/Cargo.toml index 596ee0e76..d67ac96db 100644 --- a/locked-asset/distribution/meta/Cargo.toml +++ b/locked-asset/distribution/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/distribution/wasm/Cargo.lock b/locked-asset/distribution/wasm/Cargo.lock index f942da7bf..68c738b3e 100644 --- a/locked-asset/distribution/wasm/Cargo.lock +++ b/locked-asset/distribution/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "cfg-if" @@ -170,32 +170,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -205,9 +207,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -218,18 +220,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -245,27 +247,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -305,9 +307,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -337,6 +339,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/distribution/wasm/Cargo.toml b/locked-asset/distribution/wasm/Cargo.toml index b878ac51b..320796e85 100644 --- a/locked-asset/distribution/wasm/Cargo.toml +++ b/locked-asset/distribution/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.distribution] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/distribution/wasm/src/lib.rs b/locked-asset/distribution/wasm/src/lib.rs index 87c728bb7..4f919ac08 100644 --- a/locked-asset/distribution/wasm/src/lib.rs +++ b/locked-asset/distribution/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 16 +// Upgrade: 1 +// Endpoints: 15 // Async Callback (empty): 1 // Total number of exported functions: 18 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/energy-factory/Cargo.toml b/locked-asset/energy-factory/Cargo.toml index 8b88fa231..a040473c0 100644 --- a/locked-asset/energy-factory/Cargo.toml +++ b/locked-asset/energy-factory/Cargo.toml @@ -33,11 +33,11 @@ path = "../../common/traits/unwrappable" path = "../../common/modules/legacy_token_decode_module" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies] num-bigint = "0.4.2" @@ -45,4 +45,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/energy-factory/meta/Cargo.toml b/locked-asset/energy-factory/meta/Cargo.toml index 2329f08ed..a92e84898 100644 --- a/locked-asset/energy-factory/meta/Cargo.toml +++ b/locked-asset/energy-factory/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/energy-factory/wasm/Cargo.lock b/locked-asset/energy-factory/wasm/Cargo.lock index ea350f025..bf1aebf96 100644 --- a/locked-asset/energy-factory/wasm/Cargo.lock +++ b/locked-asset/energy-factory/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_errors" @@ -112,32 +112,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -147,9 +149,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -160,18 +162,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -187,27 +189,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -247,9 +249,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -262,6 +264,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/energy-factory/wasm/Cargo.toml b/locked-asset/energy-factory/wasm/Cargo.toml index 195fec384..f12dae00b 100644 --- a/locked-asset/energy-factory/wasm/Cargo.toml +++ b/locked-asset/energy-factory/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.energy-factory] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/energy-factory/wasm/src/lib.rs b/locked-asset/energy-factory/wasm/src/lib.rs index 7393a9e97..fafdc534e 100644 --- a/locked-asset/energy-factory/wasm/src/lib.rs +++ b/locked-asset/energy-factory/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 34 +// Upgrade: 1 +// Endpoints: 33 // Async Callback: 1 // Total number of exported functions: 36 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/factory/Cargo.toml b/locked-asset/factory/Cargo.toml index bebae0fe8..4b290a2b1 100644 --- a/locked-asset/factory/Cargo.toml +++ b/locked-asset/factory/Cargo.toml @@ -26,11 +26,11 @@ path = "../../common/modules/token_merge_helper" path = "../energy-factory" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.arrayvec] version = "0.7.1" @@ -49,4 +49,4 @@ hex = "0.4" path = "../simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/factory/meta/Cargo.toml b/locked-asset/factory/meta/Cargo.toml index a18aa81f1..5d2be2857 100644 --- a/locked-asset/factory/meta/Cargo.toml +++ b/locked-asset/factory/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/factory/wasm/Cargo.lock b/locked-asset/factory/wasm/Cargo.lock index 499ad138f..95f5fb37b 100644 --- a/locked-asset/factory/wasm/Cargo.lock +++ b/locked-asset/factory/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "cfg-if" @@ -161,32 +161,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -196,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -209,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -236,27 +238,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -296,9 +298,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -328,6 +330,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/factory/wasm/Cargo.toml b/locked-asset/factory/wasm/Cargo.toml index 5b7a5a327..3adf3713b 100644 --- a/locked-asset/factory/wasm/Cargo.toml +++ b/locked-asset/factory/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.factory] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/factory/wasm/src/lib.rs b/locked-asset/factory/wasm/src/lib.rs index 7ad9e4ac0..8b83df95b 100644 --- a/locked-asset/factory/wasm/src/lib.rs +++ b/locked-asset/factory/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 25 +// Upgrade: 1 +// Endpoints: 24 // Async Callback: 1 // Total number of exported functions: 27 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/lkmex-transfer/Cargo.toml b/locked-asset/lkmex-transfer/Cargo.toml index dbfa97c2b..d0e85105e 100644 --- a/locked-asset/lkmex-transfer/Cargo.toml +++ b/locked-asset/lkmex-transfer/Cargo.toml @@ -30,14 +30,14 @@ path = "../energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/lkmex-transfer/meta/Cargo.toml b/locked-asset/lkmex-transfer/meta/Cargo.toml index 9ed81bd18..7a1529dbb 100644 --- a/locked-asset/lkmex-transfer/meta/Cargo.toml +++ b/locked-asset/lkmex-transfer/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.lock b/locked-asset/lkmex-transfer/wasm/Cargo.lock index 68f71358d..6aed1f456 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.lock +++ b/locked-asset/lkmex-transfer/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_errors" @@ -134,32 +134,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -169,9 +171,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -182,18 +184,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -209,9 +211,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -227,18 +229,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -278,9 +280,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -293,6 +295,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.toml b/locked-asset/lkmex-transfer/wasm/Cargo.toml index 53407e6a3..39ba55989 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.toml +++ b/locked-asset/lkmex-transfer/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.lkmex-transfer] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/lkmex-transfer/wasm/src/lib.rs b/locked-asset/lkmex-transfer/wasm/src/lib.rs index 6df953b3e..24d976e2b 100644 --- a/locked-asset/lkmex-transfer/wasm/src/lib.rs +++ b/locked-asset/lkmex-transfer/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 12 +// Upgrade: 1 +// Endpoints: 11 // Async Callback (empty): 1 // Total number of exported functions: 14 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/locked-token-wrapper/Cargo.toml b/locked-asset/locked-token-wrapper/Cargo.toml index 47ae7ce44..a4cbc2d73 100644 --- a/locked-asset/locked-token-wrapper/Cargo.toml +++ b/locked-asset/locked-token-wrapper/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.utils] path = "../../common/modules/utils" @@ -44,4 +44,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/locked-token-wrapper/meta/Cargo.toml b/locked-asset/locked-token-wrapper/meta/Cargo.toml index 9f28fba35..647b2023b 100644 --- a/locked-asset/locked-token-wrapper/meta/Cargo.toml +++ b/locked-asset/locked-token-wrapper/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.lock b/locked-asset/locked-token-wrapper/wasm/Cargo.lock index b4acc31d9..038df0afe 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.lock +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_errors" @@ -158,32 +158,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -193,9 +195,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -206,18 +208,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -233,9 +235,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -251,18 +253,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -302,9 +304,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -317,6 +319,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.toml b/locked-asset/locked-token-wrapper/wasm/Cargo.toml index ed6d0c360..3ce5d92cb 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.toml +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.locked-token-wrapper] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/locked-token-wrapper/wasm/src/lib.rs b/locked-asset/locked-token-wrapper/wasm/src/lib.rs index 6c59af09c..97c8b9704 100644 --- a/locked-asset/locked-token-wrapper/wasm/src/lib.rs +++ b/locked-asset/locked-token-wrapper/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 9 +// Upgrade: 1 +// Endpoints: 8 // Async Callback: 1 // Total number of exported functions: 11 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/proxy_dex/Cargo.toml b/locked-asset/proxy_dex/Cargo.toml index a36ca0338..90765cf13 100644 --- a/locked-asset/proxy_dex/Cargo.toml +++ b/locked-asset/proxy_dex/Cargo.toml @@ -45,11 +45,11 @@ path = "../../common/traits/mergeable" path = "../../common/traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.energy-factory] path = "../energy-factory" @@ -69,7 +69,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.pausable] path = "../../common/modules/pausable" diff --git a/locked-asset/proxy_dex/meta/Cargo.toml b/locked-asset/proxy_dex/meta/Cargo.toml index 3cec85ec8..c1706c5da 100644 --- a/locked-asset/proxy_dex/meta/Cargo.toml +++ b/locked-asset/proxy_dex/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/proxy_dex/src/external_merging.rs b/locked-asset/proxy_dex/src/external_merging.rs index 30ef3eb88..6d1428411 100644 --- a/locked-asset/proxy_dex/src/external_merging.rs +++ b/locked-asset/proxy_dex/src/external_merging.rs @@ -1,3 +1,5 @@ +#![allow(deprecated)] + multiversx_sc::imports!(); use common_structs::PaymentsVec; diff --git a/locked-asset/proxy_dex/src/farm_interactions.rs b/locked-asset/proxy_dex/src/farm_interactions.rs index dab9a7825..cabd55f8d 100644 --- a/locked-asset/proxy_dex/src/farm_interactions.rs +++ b/locked-asset/proxy_dex/src/farm_interactions.rs @@ -27,7 +27,7 @@ pub trait FarmInteractionsModule { ) -> EnterFarmResultWrapper { let enter_farm_result: EnterFarmResultType = self .farm_contract_proxy(farm_address) - .enter_farm_endpoint(user) + .enter_farm_endpoint(OptionalValue::Some(user)) .with_esdt_transfer((farming_token_id, 0, farming_token_amount)) .execute_on_dest_context(); @@ -47,7 +47,7 @@ pub trait FarmInteractionsModule { ) -> ExitFarmResultWrapper { let raw_result: ExitFarmWithPartialPosResultType = self .farm_contract_proxy(farm_address) - .exit_farm_endpoint(user) + .exit_farm_endpoint(OptionalValue::Some(user)) .with_esdt_transfer(farm_token) .execute_on_dest_context(); let (farming_tokens, reward_tokens) = raw_result.into_tuple(); @@ -66,7 +66,7 @@ pub trait FarmInteractionsModule { ) -> ClaimRewardsResultWrapper { let raw_result: ClaimRewardsResultType = self .farm_contract_proxy(farm_address) - .claim_rewards_endpoint(user) + .claim_rewards_endpoint(OptionalValue::Some(user)) .with_esdt_transfer(farm_token) .execute_on_dest_context(); let (new_farm_token, rewards) = raw_result.into_tuple(); diff --git a/locked-asset/proxy_dex/wasm/Cargo.lock b/locked-asset/proxy_dex/wasm/Cargo.lock index 6194e8070..5872c386f 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.lock +++ b/locked-asset/proxy_dex/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -307,32 +307,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -342,9 +344,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -355,18 +357,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -382,9 +384,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -424,9 +426,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] @@ -465,9 +467,9 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -522,9 +524,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -554,6 +556,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/proxy_dex/wasm/Cargo.toml b/locked-asset/proxy_dex/wasm/Cargo.toml index 294ba0f8a..0a906dc13 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.toml +++ b/locked-asset/proxy_dex/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.proxy_dex] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/proxy_dex/wasm/src/lib.rs b/locked-asset/proxy_dex/wasm/src/lib.rs index 29b3ab709..c04d97990 100644 --- a/locked-asset/proxy_dex/wasm/src/lib.rs +++ b/locked-asset/proxy_dex/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 31 +// Upgrade: 1 +// Endpoints: 30 // Async Callback: 1 // Total number of exported functions: 33 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/simple-lock/Cargo.toml b/locked-asset/simple-lock/Cargo.toml index 5a2205d17..b765985c3 100644 --- a/locked-asset/simple-lock/Cargo.toml +++ b/locked-asset/simple-lock/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/simple-lock/meta/Cargo.toml b/locked-asset/simple-lock/meta/Cargo.toml index e8398e175..69d47ab9d 100644 --- a/locked-asset/simple-lock/meta/Cargo.toml +++ b/locked-asset/simple-lock/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/simple-lock/src/farm_interactions.rs b/locked-asset/simple-lock/src/farm_interactions.rs index 2579a7531..58ea1ae0d 100644 --- a/locked-asset/simple-lock/src/farm_interactions.rs +++ b/locked-asset/simple-lock/src/farm_interactions.rs @@ -74,7 +74,7 @@ pub trait FarmInteractionsModule { ) -> EnterFarmResultWrapper { let mut contract_call = self .farm_proxy(farm_address) - .enter_farm(caller) + .enter_farm(OptionalValue::Some(caller)) .with_esdt_transfer(EsdtTokenPayment::new( farming_token, 0, @@ -108,7 +108,7 @@ pub trait FarmInteractionsModule { ) -> ExitFarmResultWrapper { let raw_results: RawResultsType = self .farm_proxy(farm_address) - .exit_farm(caller) + .exit_farm(OptionalValue::Some(caller)) .with_esdt_transfer(EsdtTokenPayment::new( farm_token, farm_token_nonce, @@ -138,7 +138,7 @@ pub trait FarmInteractionsModule { ) -> FarmClaimRewardsResultWrapper { let raw_results: RawResultsType = self .farm_proxy(farm_address) - .claim_rewards(caller) + .claim_rewards(OptionalValue::Some(caller)) .with_esdt_transfer(EsdtTokenPayment::new( farm_token, farm_token_nonce, diff --git a/locked-asset/simple-lock/wasm/Cargo.lock b/locked-asset/simple-lock/wasm/Cargo.lock index b09697870..8d74083b5 100644 --- a/locked-asset/simple-lock/wasm/Cargo.lock +++ b/locked-asset/simple-lock/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_structs" @@ -72,32 +72,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -107,9 +109,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -120,18 +122,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -147,27 +149,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -207,9 +209,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -222,6 +224,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/simple-lock/wasm/Cargo.toml b/locked-asset/simple-lock/wasm/Cargo.toml index df38efee7..f3c01319d 100644 --- a/locked-asset/simple-lock/wasm/Cargo.toml +++ b/locked-asset/simple-lock/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.simple-lock] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/simple-lock/wasm/src/lib.rs b/locked-asset/simple-lock/wasm/src/lib.rs index 4e1b87c7d..eeafb6cb1 100644 --- a/locked-asset/simple-lock/wasm/src/lib.rs +++ b/locked-asset/simple-lock/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 20 +// Upgrade: 1 +// Endpoints: 19 // Async Callback: 1 // Total number of exported functions: 22 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/locked-asset/token-unstake/Cargo.toml b/locked-asset/token-unstake/Cargo.toml index e98adb1a8..46e3a4e66 100644 --- a/locked-asset/token-unstake/Cargo.toml +++ b/locked-asset/token-unstake/Cargo.toml @@ -9,7 +9,7 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] @@ -39,7 +39,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" diff --git a/locked-asset/token-unstake/meta/Cargo.toml b/locked-asset/token-unstake/meta/Cargo.toml index 217e2f67f..46081ddf1 100644 --- a/locked-asset/token-unstake/meta/Cargo.toml +++ b/locked-asset/token-unstake/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/locked-asset/token-unstake/wasm/Cargo.lock b/locked-asset/token-unstake/wasm/Cargo.lock index 87bea6198..c0dbbdef3 100644 --- a/locked-asset/token-unstake/wasm/Cargo.lock +++ b/locked-asset/token-unstake/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common-types" @@ -119,32 +119,34 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -154,9 +156,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -167,18 +169,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -194,27 +196,27 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -254,9 +256,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -291,6 +293,12 @@ version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + [[package]] name = "unwrappable" version = "0.0.0" diff --git a/locked-asset/token-unstake/wasm/Cargo.toml b/locked-asset/token-unstake/wasm/Cargo.toml index cba43e2e5..13cb91277 100644 --- a/locked-asset/token-unstake/wasm/Cargo.toml +++ b/locked-asset/token-unstake/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.token-unstake] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/locked-asset/token-unstake/wasm/src/lib.rs b/locked-asset/token-unstake/wasm/src/lib.rs index 396d02ba0..ea93ce423 100644 --- a/locked-asset/token-unstake/wasm/src/lib.rs +++ b/locked-asset/token-unstake/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 11 +// Upgrade: 1 +// Endpoints: 10 // Async Callback (empty): 1 // Total number of exported functions: 13 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); diff --git a/pause-all/Cargo.toml b/pause-all/Cargo.toml index 4428bd4ea..8856a1b7a 100644 --- a/pause-all/Cargo.toml +++ b/pause-all/Cargo.toml @@ -12,14 +12,14 @@ path = "src/lib.rs" path = "../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.48.1" +version = "=0.50.4" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.48.1" +version = "=0.50.4" [dev-dependencies.farm] path = "../dex/farm" diff --git a/pause-all/meta/Cargo.toml b/pause-all/meta/Cargo.toml index 204a54967..9f1d2bdd5 100644 --- a/pause-all/meta/Cargo.toml +++ b/pause-all/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.48.1" +version = "0.50.4" default-features = false diff --git a/pause-all/wasm/Cargo.lock b/pause-all/wasm/Cargo.lock index 1f61fcf8f..d942f7370 100644 --- a/pause-all/wasm/Cargo.lock +++ b/pause-all/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "bitflags" -version = "2.4.2" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed570934406eb16438a4e976b1b4500774099c13b8cb96eec99f620f05090ddf" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "common_errors" @@ -47,32 +47,34 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23f5fa49bfb4505465784dc6b8b1d5e52ffcdafedfc2c6f5e9ba54b4bcf5cee8" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" dependencies = [ "bitflags", "hex-literal", "multiversx-sc-codec", "multiversx-sc-derive", "num-traits", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f7711088da6b140257f35a25d90dc4f78bc4e2be324d1096f7f5842dd397cda" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", + "unwrap-infallible", ] [[package]] name = "multiversx-sc-codec-derive" -version = "0.18.7" +version = "0.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc92c79e975de4b4f956d54d2c31aaca5e18310e1c36d37593fe856a07b8130" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" dependencies = [ "hex", "proc-macro2", @@ -82,9 +84,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f114e0cd72950ae1f0dc1bca2da7d2a02f6ce51bcbee7721980340436bfe63a" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" dependencies = [ "hex", "proc-macro2", @@ -95,18 +97,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17c9e2000b81f241706a080291f6a7791e221a6ba292cec93687feae53592c9c" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.48.1" +version = "0.50.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c50d29ab99fab424227c181b6a918ca4ee234c4f18ea5fbbf2853b2ccb0ebc" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" dependencies = [ "multiversx-sc", ] @@ -122,9 +124,9 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.17" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", ] @@ -165,18 +167,18 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.78" +version = "1.0.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" dependencies = [ "unicode-ident", ] [[package]] name = "quote" -version = "1.0.35" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -199,9 +201,9 @@ checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" [[package]] name = "syn" -version = "2.0.48" +version = "2.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" dependencies = [ "proc-macro2", "quote", @@ -213,3 +215,9 @@ name = "unicode-ident" version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/pause-all/wasm/Cargo.toml b/pause-all/wasm/Cargo.toml index 6bbe809bc..5c679c0f7 100644 --- a/pause-all/wasm/Cargo.toml +++ b/pause-all/wasm/Cargo.toml @@ -21,11 +21,14 @@ debug = false panic = "abort" overflow-checks = false +[profile.dev] +panic = "abort" + [dependencies.pause-all] path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.48.1" +version = "=0.50.4" [workspace] members = ["."] diff --git a/pause-all/wasm/src/lib.rs b/pause-all/wasm/src/lib.rs index 2302b1e6a..88f01cb87 100644 --- a/pause-all/wasm/src/lib.rs +++ b/pause-all/wasm/src/lib.rs @@ -5,13 +5,12 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 8 +// Upgrade: 1 +// Endpoints: 7 // Async Callback (empty): 1 // Total number of exported functions: 10 #![no_std] -#![allow(internal_features)] -#![feature(lang_items)] multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); From a235b6d6ef286e1f16766db0d387bdb8b4b094c1 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 11 Jun 2024 11:59:37 +0300 Subject: [PATCH 062/103] router upgrade pair endpoint fix --- dex/router/src/contract.rs | 19 +---------------- dex/router/src/factory.rs | 36 +++++++++------------------------ dex/router/tests/router_test.rs | 8 +------- 3 files changed, 12 insertions(+), 51 deletions(-) diff --git a/dex/router/src/contract.rs b/dex/router/src/contract.rs index cfe2d6936..ad30b7f9e 100644 --- a/dex/router/src/contract.rs +++ b/dex/router/src/contract.rs @@ -157,9 +157,6 @@ pub trait Router: &self, first_token_id: TokenIdentifier, second_token_id: TokenIdentifier, - initial_liquidity_adder: ManagedAddress, - total_fee_percent_requested: u64, - special_fee_percent_requested: u64, ) { require!(self.is_active(), "Not active"); @@ -175,21 +172,7 @@ pub trait Router: let pair_address = self.get_pair(first_token_id.clone(), second_token_id.clone()); require!(!pair_address.is_zero(), "Pair does not exists"); - require!( - total_fee_percent_requested >= special_fee_percent_requested - && total_fee_percent_requested < MAX_TOTAL_FEE_PERCENT, - "Bad percents" - ); - - self.upgrade_pair( - pair_address, - &first_token_id, - &second_token_id, - &self.owner().get(), - &initial_liquidity_adder, - total_fee_percent_requested, - special_fee_percent_requested, - ); + self.upgrade_pair(pair_address); } #[payable("EGLD")] diff --git a/dex/router/src/factory.rs b/dex/router/src/factory.rs index fea434703..ff7633a15 100644 --- a/dex/router/src/factory.rs +++ b/dex/router/src/factory.rs @@ -82,32 +82,16 @@ pub trait FactoryModule: config::ConfigModule + read_pair_storage::ReadPairStora new_address } - fn upgrade_pair( - &self, - pair_address: ManagedAddress, - first_token_id: &TokenIdentifier, - second_token_id: &TokenIdentifier, - owner: &ManagedAddress, - _initial_liquidity_adder: &ManagedAddress, - total_fee_percent: u64, - special_fee_percent: u64, - ) { - self.pair_contract_deploy_proxy() - .contract(pair_address) - .init( - first_token_id, - second_token_id, - self.blockchain().get_sc_address(), - owner, - total_fee_percent, - special_fee_percent, - ManagedAddress::zero(), - MultiValueEncoded::new(), - ) - .upgrade_from_source( - &self.pair_template_address().get(), - CodeMetadata::UPGRADEABLE | CodeMetadata::READABLE | CodeMetadata::PAYABLE_BY_SC, - ); + fn upgrade_pair(&self, pair_address: ManagedAddress) { + let pair_template_address = self.pair_template_address().get(); + let code_metadata = + CodeMetadata::UPGRADEABLE | CodeMetadata::READABLE | CodeMetadata::PAYABLE_BY_SC; + self.tx() + .to(pair_address) + .raw_upgrade() + .from_source(pair_template_address) + .code_metadata(code_metadata) + .upgrade_async_call_and_exit(); } #[view(getAllPairsManagedAddresses)] diff --git a/dex/router/tests/router_test.rs b/dex/router/tests/router_test.rs index 54765f2c4..6564a508e 100644 --- a/dex/router/tests/router_test.rs +++ b/dex/router/tests/router_test.rs @@ -113,13 +113,7 @@ fn test_router_upgrade_pair() { .execute_tx(&owner, &router_wrapper, &rust_zero, |sc| { let first_token_id = managed_token_id!(CUSTOM_TOKEN_ID); let second_token_id = managed_token_id!(USDC_TOKEN_ID); - sc.upgrade_pair_endpoint( - first_token_id, - second_token_id, - managed_address!(&user), - 300, - 50, - ); + sc.upgrade_pair_endpoint(first_token_id, second_token_id); }) .assert_ok(); From 78fa9a103af05da6092ce9e814a3437dc3e00ab0 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 11 Jun 2024 12:51:13 +0300 Subject: [PATCH 063/103] Simple lock exit farm with penalty fix --- locked-asset/simple-lock/src/proxy_farm.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/locked-asset/simple-lock/src/proxy_farm.rs b/locked-asset/simple-lock/src/proxy_farm.rs index 1d1a918d2..9defead0c 100644 --- a/locked-asset/simple-lock/src/proxy_farm.rs +++ b/locked-asset/simple-lock/src/proxy_farm.rs @@ -214,7 +214,7 @@ pub trait ProxyFarmModule: farm_address, farm_proxy_token_attributes.farm_token_id, farm_proxy_token_attributes.farm_token_nonce, - payment.amount, + payment.amount.clone(), caller.clone(), ); require!( @@ -236,6 +236,15 @@ pub trait ProxyFarmModule: &lp_proxy_token_payment.amount, ); + if payment.amount > lp_proxy_token_payment.amount { + let penalty_amount = &payment.amount - &lp_proxy_token_payment.amount; + + self.lp_proxy_token().nft_burn( + farm_proxy_token_attributes.farming_token_locked_nonce, + &penalty_amount, + ); + } + if exit_farm_result.reward_tokens.amount > 0 { self.send().direct_esdt( &caller, From 0485c8384bb74454362252e984844d2814a92512 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 11 Jun 2024 13:25:07 +0300 Subject: [PATCH 064/103] scenario test fix --- dex/scenarios/upgrade_contract.scen.json | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/dex/scenarios/upgrade_contract.scen.json b/dex/scenarios/upgrade_contract.scen.json index cdadc752b..9a9c88fe2 100644 --- a/dex/scenarios/upgrade_contract.scen.json +++ b/dex/scenarios/upgrade_contract.scen.json @@ -14,10 +14,7 @@ "function": "upgradePair", "arguments": [ "str:ALC-abcdef", - "str:WEGLD-abcdef", - "0x0000000000000000000000000000000000000000000000000000000000000000", - "300", - "100" + "str:WEGLD-abcdef" ], "gasLimit": "1,000,000,000", "gasPrice": "0" From c874ed6c0c4d72eb7f513a966f0087c043911710 Mon Sep 17 00:00:00 2001 From: Claudiu Lataretu Date: Tue, 11 Jun 2024 20:10:26 +0300 Subject: [PATCH 065/103] simple-lock-legacy: add missing FarmType Signed-off-by: Claudiu Lataretu --- legacy-contracts/simple-lock-legacy/src/proxy_farm.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs b/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs index e2dc5931a..6cdcac9f5 100644 --- a/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs +++ b/legacy-contracts/simple-lock-legacy/src/proxy_farm.rs @@ -9,6 +9,7 @@ use crate::error_messages::*; pub enum FarmType { SimpleFarm, FarmWithLockedRewards, + FarmWithBoostedRewards } #[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq, Debug)] From c2a140af9a430a9d7fd63faf5818f7c123b65508 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 24 Jun 2024 02:33:10 +0300 Subject: [PATCH 066/103] Farm Staking Proxy Legacy SC --- Cargo.lock | 22 ++ Cargo.toml | 2 + .../farm-staking-proxy-legacy/.gitignore | 7 + .../farm-staking-proxy-legacy/Cargo.toml | 30 +++ .../farm-staking-proxy-legacy/meta/Cargo.toml | 13 + .../meta/src/main.rs | 3 + .../farm-staking-proxy-legacy/multiversx.json | 3 + .../src/dual_yield_token.rs | 108 ++++++++ .../src/external_contracts_interactions.rs | 236 ++++++++++++++++ .../farm-staking-proxy-legacy/src/lib.rs | 91 +++++++ .../src/lp_farm_token.rs | 50 ++++ .../src/result_types.rs | 38 +++ .../farm-staking-proxy-legacy/wasm/Cargo.lock | 254 ++++++++++++++++++ .../farm-staking-proxy-legacy/wasm/Cargo.toml | 34 +++ .../farm-staking-proxy-legacy/wasm/src/lib.rs | 33 +++ 15 files changed, 924 insertions(+) create mode 100644 legacy-contracts/farm-staking-proxy-legacy/.gitignore create mode 100644 legacy-contracts/farm-staking-proxy-legacy/Cargo.toml create mode 100644 legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml create mode 100644 legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/multiversx.json create mode 100644 legacy-contracts/farm-staking-proxy-legacy/src/dual_yield_token.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/src/lib.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/src/lp_farm_token.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/src/result_types.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock create mode 100644 legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml create mode 100644 legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index f4091b679..ad010ebcc 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -884,6 +884,28 @@ dependencies = [ "utils", ] +[[package]] +name = "farm-staking-proxy-legacy" +version = "0.0.0" +dependencies = [ + "common_structs", + "hex", + "multiversx-sc", + "multiversx-sc-modules", + "multiversx-sc-scenario", + "num-bigint", + "num-traits", + "token_merge_helper", +] + +[[package]] +name = "farm-staking-proxy-legacy-meta" +version = "0.0.0" +dependencies = [ + "farm-staking-proxy-legacy", + "multiversx-sc-meta", +] + [[package]] name = "farm-staking-proxy-meta" version = "0.0.0" diff --git a/Cargo.toml b/Cargo.toml index 0944e273b..1b7132c07 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -39,6 +39,8 @@ members = [ "legacy-contracts/simple-lock-legacy", "legacy-contracts/simple-lock-legacy/meta", + "legacy-contracts/farm-staking-proxy-legacy", + "legacy-contracts/farm-staking-proxy-legacy/meta", "locked-asset/", "locked-asset/distribution", diff --git a/legacy-contracts/farm-staking-proxy-legacy/.gitignore b/legacy-contracts/farm-staking-proxy-legacy/.gitignore new file mode 100644 index 000000000..eaf5915bd --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/.gitignore @@ -0,0 +1,7 @@ +# Generated by Cargo +# will have compiled files and executables +/target/ +*/target/ + +# The erdpy output +output diff --git a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml new file mode 100644 index 000000000..8804de4a4 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml @@ -0,0 +1,30 @@ +[package] +name = "farm-staking-proxy-legacy" +version = "0.0.0" +authors = ["MultiversX "] +edition = "2021" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "=0.50.4" +features = ["esdt-token-payment-legacy-decode"] + +[dependencies.multiversx-sc-modules] +version = "=0.50.4" + +[dependencies.token_merge_helper] +path = "../../common/modules/token_merge_helper" + +[dependencies.common_structs] +path = "../../common/common_structs" + +[dev-dependencies] +num-bigint = "0.4.2" +num-traits = "0.2" +hex = "0.4" + +[dev-dependencies.multiversx-sc-scenario] +version = "=0.50.4" diff --git a/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml new file mode 100644 index 000000000..4f7087bb4 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml @@ -0,0 +1,13 @@ +[package] +name = "farm-staking-proxy-legacy-meta" +version = "0.0.0" +edition = "2021" +publish = false +authors = ["MultiversX "] + +[dependencies.farm-staking-proxy-legacy] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.4" +default-features = false diff --git a/legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs b/legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs new file mode 100644 index 000000000..98ff6943a --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/multiversx.json b/legacy-contracts/farm-staking-proxy-legacy/multiversx.json new file mode 100644 index 000000000..736553962 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/multiversx.json @@ -0,0 +1,3 @@ +{ + "language": "rust" +} \ No newline at end of file diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/dual_yield_token.rs b/legacy-contracts/farm-staking-proxy-legacy/src/dual_yield_token.rs new file mode 100644 index 000000000..0c57f52ca --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/src/dual_yield_token.rs @@ -0,0 +1,108 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +#[derive(TypeAbi, TopEncode, TopDecode, PartialEq, Debug)] +pub struct DualYieldTokenAttributes { + pub lp_farm_token_nonce: u64, + pub lp_farm_token_amount: BigUint, + pub staking_farm_token_nonce: u64, + pub staking_farm_token_amount: BigUint, +} + +impl DualYieldTokenAttributes { + /// dual yield tokens are always created with an amount equal to staking_farm_token_amount, + /// so we just return this field instead of duplicating + #[inline] + pub fn get_total_dual_yield_tokens_for_position(&self) -> &BigUint { + &self.staking_farm_token_amount + } +} + +#[multiversx_sc::module] +pub trait DualYieldTokenModule: token_merge_helper::TokenMergeHelperModule { + #[only_owner] + #[endpoint(setTransferRoleDualYieldToken)] + fn set_transfer_role_dual_yield_token(&self, opt_address: OptionalValue) { + let address = self.resolve_address(opt_address); + let token_id = self.dual_yield_token_id().get(); + let roles = [EsdtLocalRole::Transfer]; + + self.send() + .esdt_system_sc_proxy() + .set_special_roles(&address, &token_id, roles.iter().cloned()) + .async_call_and_exit() + } + + fn resolve_address(&self, opt_address: OptionalValue) -> ManagedAddress { + match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + } + } + + fn require_dual_yield_token(&self, token_id: &TokenIdentifier) { + let dual_yield_token_id = self.dual_yield_token_id().get(); + require!(token_id == &dual_yield_token_id, "Invalid payment token"); + } + + fn require_all_payments_dual_yield_tokens( + &self, + payments: &ManagedVec>, + ) { + if payments.is_empty() { + return; + } + + let dual_yield_token_id = self.dual_yield_token_id().get(); + for p in payments { + require!( + p.token_identifier == dual_yield_token_id, + "Invalid payment token" + ); + } + } + + fn burn_dual_yield_tokens(&self, sft_nonce: u64, amount: &BigUint) { + let dual_yield_token_id = self.dual_yield_token_id().get(); + self.send() + .esdt_local_burn(&dual_yield_token_id, sft_nonce, amount); + } + + fn get_dual_yield_token_attributes( + &self, + dual_yield_token_nonce: u64, + ) -> DualYieldTokenAttributes { + let own_sc_address = self.blockchain().get_sc_address(); + let dual_yield_token_id = self.dual_yield_token_id().get(); + let token_info = self.blockchain().get_esdt_token_data( + &own_sc_address, + &dual_yield_token_id, + dual_yield_token_nonce, + ); + + token_info.decode_attributes() + } + + fn get_lp_farm_token_amount_equivalent( + &self, + attributes: &DualYieldTokenAttributes, + amount: &BigUint, + ) -> BigUint { + self.rule_of_three_non_zero_result( + amount, + attributes.get_total_dual_yield_tokens_for_position(), + &attributes.lp_farm_token_amount, + ) + } + + #[inline] + fn get_staking_farm_token_amount_equivalent(&self, amount: &BigUint) -> BigUint { + // since staking_farm_token_amount is equal to the total dual yield tokens, + // we simply return the amount + amount.clone() + } + + #[view(getDualYieldTokenId)] + #[storage_mapper("dualYieldTokenId")] + fn dual_yield_token_id(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs b/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs new file mode 100644 index 000000000..a6826771b --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs @@ -0,0 +1,236 @@ +multiversx_sc::imports!(); + +use common_structs::{RawResultWrapper, RawResultsType}; + +use crate::result_types::*; + +mod farm_proxy { + multiversx_sc::imports!(); + + #[multiversx_sc::proxy] + pub trait FarmProxy { + #[payable("*")] + #[endpoint(exitFarm)] + fn exit_farm(&self) -> MultiValue2; + + #[view(getFarmingTokenId)] + fn farming_token_id(&self) -> TokenIdentifier; + } +} + +mod farm_staking_proxy { + multiversx_sc::imports!(); + + #[multiversx_sc::proxy] + pub trait FarmStakingProxy { + #[payable("*")] + #[endpoint(unstakeFarmThroughProxy)] + fn unstake_farm_through_proxy( + &self, + original_caller: ManagedAddress, + ) -> MultiValue2; + } +} + +mod pair_proxy { + multiversx_sc::imports!(); + + #[multiversx_sc::proxy] + pub trait PairProxy { + #[payable("*")] + #[endpoint(removeLiquidity)] + fn remove_liquidity( + &self, + first_token_amount_min: BigUint, + second_token_amount_min: BigUint, + ) -> MultiValue2; + + #[endpoint(updateAndGetTokensForGivenPositionWithSafePrice)] + fn update_and_get_tokens_for_given_position_with_safe_price( + &self, + liquidity: BigUint, + ) -> MultiValue2; + } +} + +#[multiversx_sc::module] +pub trait ExternalContractsInteractionsModule: + crate::lp_farm_token::LpFarmTokenModule + token_merge_helper::TokenMergeHelperModule +{ + // lp farm + + fn lp_farm_exit( + &self, + lp_farm_token_nonce: u64, + lp_farm_token_amount: BigUint, + ) -> LpFarmExitResult { + let lp_farm_token_id = self.lp_farm_token_id().get(); + let lp_farm_address = self.lp_farm_address().get(); + let raw_results: RawResultsType = self + .lp_farm_proxy_obj(lp_farm_address) + .exit_farm() + .with_esdt_transfer((lp_farm_token_id, lp_farm_token_nonce, lp_farm_token_amount)) + .execute_on_dest_context(); + + let mut results_wrapper = RawResultWrapper::new(raw_results); + results_wrapper.trim_results_front(2); + + let mut lp_tokens: EsdtTokenPayment = results_wrapper.decode_next_result(); + let mut lp_farm_rewards: EsdtTokenPayment = results_wrapper.decode_next_result(); + + let received_lp_token_identifier = lp_tokens.token_identifier.clone(); + let lp_token_identifier = self.get_lp_farming_token_identifier(); + + if lp_token_identifier != received_lp_token_identifier { + core::mem::swap(&mut lp_tokens, &mut lp_farm_rewards); + } + + LpFarmExitResult { + lp_tokens, + lp_farm_rewards, + } + } + + fn get_lp_farming_token_identifier(&self) -> TokenIdentifier { + let lp_farm_address = self.lp_farm_address().get(); + self.lp_farm_proxy_obj(lp_farm_address) + .farming_token_id() + .execute_on_dest_context() + } + + // staking farm + + fn staking_farm_unstake( + &self, + orig_caller: ManagedAddress, + staking_tokens: EsdtTokenPayment, + farm_token_nonce: u64, + farm_token_amount: BigUint, + ) -> StakingFarmExitResult { + let staking_farm_token_id = self.staking_farm_token_id().get(); + let mut payments = ManagedVec::from_single_item(staking_tokens); + payments.push(EsdtTokenPayment::new( + staking_farm_token_id, + farm_token_nonce, + farm_token_amount, + )); + + let staking_farm_address = self.staking_farm_address().get(); + let raw_results: RawResultsType = self + .staking_farm_proxy_obj(staking_farm_address) + .unstake_farm_through_proxy(orig_caller) + .with_multi_token_transfer(payments) + .execute_on_dest_context(); + + let mut results_wrapper = RawResultWrapper::new(raw_results); + results_wrapper.trim_results_front(2); + + let unbond_staking_farm_token = results_wrapper.decode_next_result(); + let staking_rewards = results_wrapper.decode_next_result(); + + StakingFarmExitResult { + unbond_staking_farm_token, + staking_rewards, + } + } + + // pair + + fn pair_remove_liquidity( + &self, + lp_tokens: EsdtTokenPayment, + pair_first_token_min_amount: BigUint, + pair_second_token_min_amount: BigUint, + ) -> PairRemoveLiquidityResult { + let pair_address = self.pair_address().get(); + let raw_results: RawResultsType = self + .pair_proxy_obj(pair_address) + .remove_liquidity(pair_first_token_min_amount, pair_second_token_min_amount) + .with_esdt_transfer(( + lp_tokens.token_identifier, + lp_tokens.token_nonce, + lp_tokens.amount, + )) + .execute_on_dest_context(); + + let mut results_wrapper = RawResultWrapper::new(raw_results); + results_wrapper.trim_results_front(2); + + let pair_first_token_payment: EsdtTokenPayment = results_wrapper.decode_next_result(); + let pair_second_token_payment: EsdtTokenPayment = results_wrapper.decode_next_result(); + + let staking_token_id = self.staking_token_id().get(); + let (staking_token_payment, other_token_payment) = + if pair_first_token_payment.token_identifier == staking_token_id { + (pair_first_token_payment, pair_second_token_payment) + } else if pair_second_token_payment.token_identifier == staking_token_id { + (pair_second_token_payment, pair_first_token_payment) + } else { + sc_panic!("Invalid payments received from Pair"); + }; + + PairRemoveLiquidityResult { + staking_token_payment, + other_token_payment, + } + } + + fn get_lp_tokens_safe_price(&self, lp_tokens_amount: BigUint) -> BigUint { + let pair_address = self.pair_address().get(); + let raw_results: RawResultsType = self + .pair_proxy_obj(pair_address) + .update_and_get_tokens_for_given_position_with_safe_price(lp_tokens_amount) + .execute_on_dest_context(); + + let mut results_wrapper = RawResultWrapper::new(raw_results); + results_wrapper.trim_results_front(2); + + let first_token_info: EsdtTokenPayment = results_wrapper.decode_next_result(); + let second_token_info: EsdtTokenPayment = results_wrapper.decode_next_result(); + + let staking_token_id = self.staking_token_id().get(); + if first_token_info.token_identifier == staking_token_id { + first_token_info.amount + } else if second_token_info.token_identifier == staking_token_id { + second_token_info.amount + } else { + sc_panic!("Invalid Pair contract called"); + } + } + + // proxies + + #[proxy] + fn staking_farm_proxy_obj( + &self, + sc_address: ManagedAddress, + ) -> farm_staking_proxy::Proxy; + + #[proxy] + fn lp_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_proxy::Proxy; + + #[proxy] + fn pair_proxy_obj(&self, sc_address: ManagedAddress) -> pair_proxy::Proxy; + + // storage + + #[view(getLpFarmAddress)] + #[storage_mapper("lpFarmAddress")] + fn lp_farm_address(&self) -> SingleValueMapper; + + #[view(getStakingFarmAddress)] + #[storage_mapper("stakingFarmAddress")] + fn staking_farm_address(&self) -> SingleValueMapper; + + #[view(getPairAddress)] + #[storage_mapper("pairAddress")] + fn pair_address(&self) -> SingleValueMapper; + + #[view(getStakingTokenId)] + #[storage_mapper("stakingTokenId")] + fn staking_token_id(&self) -> SingleValueMapper; + + #[view(getFarmTokenId)] + #[storage_mapper("farmTokenId")] + fn staking_farm_token_id(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs b/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs new file mode 100644 index 000000000..957285429 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs @@ -0,0 +1,91 @@ +#![no_std] + +multiversx_sc::imports!(); + +pub mod dual_yield_token; +pub mod external_contracts_interactions; +pub mod lp_farm_token; +pub mod result_types; + +pub type UnstakeResult = MultiValueEncoded>; + +#[multiversx_sc::contract] +pub trait FarmStakingProxy: + dual_yield_token::DualYieldTokenModule + + external_contracts_interactions::ExternalContractsInteractionsModule + + lp_farm_token::LpFarmTokenModule + + token_merge_helper::TokenMergeHelperModule +{ + #[init] + fn init(&self) {} + + #[payable("*")] + #[endpoint(unstakeFarmTokens)] + fn unstake_farm_tokens( + &self, + pair_first_token_min_amount: BigUint, + pair_second_token_min_amount: BigUint, + ) -> UnstakeResult { + let caller = self.blockchain().get_caller(); + let (payment_token, payment_nonce, payment_amount) = + self.call_value().single_esdt().into_tuple(); + self.require_dual_yield_token(&payment_token); + + let attributes = self.get_dual_yield_token_attributes(payment_nonce); + let lp_farm_token_amount = + self.get_lp_farm_token_amount_equivalent(&attributes, &payment_amount); + let lp_farm_exit_result = + self.lp_farm_exit(attributes.lp_farm_token_nonce, lp_farm_token_amount); + + let remove_liq_result = self.pair_remove_liquidity( + lp_farm_exit_result.lp_tokens, + pair_first_token_min_amount, + pair_second_token_min_amount, + ); + + let staking_farm_token_amount = + self.get_staking_farm_token_amount_equivalent(&payment_amount); + let staking_farm_exit_result = self.staking_farm_unstake( + caller.clone(), + remove_liq_result.staking_token_payment, + attributes.staking_farm_token_nonce, + staking_farm_token_amount, + ); + let unstake_result = self.send_unstake_payments( + &caller, + remove_liq_result.other_token_payment, + lp_farm_exit_result.lp_farm_rewards, + staking_farm_exit_result.staking_rewards, + staking_farm_exit_result.unbond_staking_farm_token, + ); + + self.burn_dual_yield_tokens(payment_nonce, &payment_amount); + + unstake_result + } + + fn send_unstake_payments( + &self, + caller: &ManagedAddress, + other_token_payment: EsdtTokenPayment, + lp_farm_rewards: EsdtTokenPayment, + staking_rewards: EsdtTokenPayment, + unbond_staking_farm_token: EsdtTokenPayment, + ) -> UnstakeResult { + let mut user_payments = ManagedVec::new(); + if other_token_payment.amount > 0 { + user_payments.push(other_token_payment); + } + if lp_farm_rewards.amount > 0 { + user_payments.push(lp_farm_rewards); + } + if staking_rewards.amount > 0 { + user_payments.push(staking_rewards); + } + user_payments.push(unbond_staking_farm_token); + + self.send().direct_multi(caller, &user_payments); + + user_payments.into() + } +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/lp_farm_token.rs b/legacy-contracts/farm-staking-proxy-legacy/src/lp_farm_token.rs new file mode 100644 index 000000000..d917a0f99 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/src/lp_farm_token.rs @@ -0,0 +1,50 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +#[derive( + ManagedVecItem, + TopEncode, + TopDecode, + NestedEncode, + NestedDecode, + TypeAbi, + Clone, + PartialEq, + Debug, +)] +pub struct FarmTokenAttributes { + pub reward_per_share: BigUint, + pub original_entering_epoch: u64, + pub entering_epoch: u64, + pub initial_farming_amount: BigUint, + pub compounded_reward: BigUint, + pub current_farm_amount: BigUint, +} + +#[multiversx_sc::module] +pub trait LpFarmTokenModule: token_merge_helper::TokenMergeHelperModule { + fn get_lp_tokens_in_farm_position( + &self, + farm_token_nonce: u64, + farm_token_amount: &BigUint, + ) -> BigUint { + let own_sc_address = self.blockchain().get_sc_address(); + let lp_farm_token_id = self.lp_farm_token_id().get(); + let token_data = self.blockchain().get_esdt_token_data( + &own_sc_address, + &lp_farm_token_id, + farm_token_nonce, + ); + let attributes = token_data.decode_attributes::>(); + + self.rule_of_three_non_zero_result( + farm_token_amount, + &attributes.current_farm_amount, + &attributes.initial_farming_amount, + ) + } + + #[view(getLpFarmTokenId)] + #[storage_mapper("lpFarmTokenId")] + fn lp_farm_token_id(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/result_types.rs b/legacy-contracts/farm-staking-proxy-legacy/src/result_types.rs new file mode 100644 index 000000000..a27c2e1f2 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/src/result_types.rs @@ -0,0 +1,38 @@ +multiversx_sc::imports!(); + +pub type PaymentsVec = ManagedVec>; + +// lp farm + +pub struct LpFarmClaimRewardsResult { + pub new_lp_farm_tokens: EsdtTokenPayment, + pub lp_farm_rewards: EsdtTokenPayment, +} + +pub struct LpFarmExitResult { + pub lp_tokens: EsdtTokenPayment, + pub lp_farm_rewards: EsdtTokenPayment, +} + +// staking farm + +pub struct StakingFarmEnterResult { + pub received_staking_farm_token: EsdtTokenPayment, +} + +pub struct StakingFarmClaimRewardsResult { + pub new_staking_farm_tokens: EsdtTokenPayment, + pub staking_farm_rewards: EsdtTokenPayment, +} + +pub struct StakingFarmExitResult { + pub unbond_staking_farm_token: EsdtTokenPayment, + pub staking_rewards: EsdtTokenPayment, +} + +// pair + +pub struct PairRemoveLiquidityResult { + pub staking_token_payment: EsdtTokenPayment, + pub other_token_payment: EsdtTokenPayment, +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock new file mode 100644 index 000000000..1c15ac5fa --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock @@ -0,0 +1,254 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "common_errors" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "common_structs" +version = "0.0.0" +dependencies = [ + "fixed-supply-token", + "math", + "mergeable", + "multiversx-sc", + "unwrappable", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "farm-staking-proxy-legacy" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "multiversx-sc-modules", + "token_merge_helper", +] + +[[package]] +name = "farm-staking-proxy-legacy-wasm" +version = "0.0.0" +dependencies = [ + "farm-staking-proxy-legacy", + "multiversx-sc-wasm-adapter", +] + +[[package]] +name = "fixed-supply-token" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "math" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "mergeable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "multiversx-sc" +version = "0.50.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-modules" +version = "0.50.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.11.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "token_merge_helper" +version = "0.0.0" +dependencies = [ + "common_errors", + "multiversx-sc", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "unwrappable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml new file mode 100644 index 000000000..0990dd0b6 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "farm-staking-proxy-legacy-wasm" +version = "0.0.0" +edition = "2021" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.farm-staking-proxy-legacy] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "=0.50.4" + +[workspace] +members = ["."] diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs b/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs new file mode 100644 index 000000000..2ed024e96 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs @@ -0,0 +1,33 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 9 +// Async Callback (empty): 1 +// Total number of exported functions: 11 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + farm_staking_proxy_legacy + ( + init => init + unstakeFarmTokens => unstake_farm_tokens + setTransferRoleDualYieldToken => set_transfer_role_dual_yield_token + getDualYieldTokenId => dual_yield_token_id + getLpFarmAddress => lp_farm_address + getStakingFarmAddress => staking_farm_address + getPairAddress => pair_address + getStakingTokenId => staking_token_id + getFarmTokenId => staking_farm_token_id + getLpFarmTokenId => lp_farm_token_id + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} From 8a7325bbd4ee477c7f524e5ca96a9ad51f15574f Mon Sep 17 00:00:00 2001 From: Dorin Marian Iancu Date: Thu, 27 Jun 2024 10:21:59 +0300 Subject: [PATCH 067/103] upgrade --- Cargo.lock | 20 ++++++++--------- common/common_errors/Cargo.toml | 2 +- common/common_structs/Cargo.toml | 2 +- common/modules/farm/config/Cargo.toml | 2 +- common/modules/farm/contexts/Cargo.toml | 4 ++-- common/modules/farm/contexts/src/mod.rs | 1 - .../farm/contexts/src/storage_cache.rs | 11 ++++++++-- common/modules/farm/events/Cargo.toml | 2 +- common/modules/farm/farm_base_impl/Cargo.toml | 6 ++--- .../farm_base_impl/src/base_traits_impl.rs | 21 ++++++++++++++---- common/modules/farm/farm_base_impl/src/lib.rs | 4 ---- common/modules/farm/farm_token/Cargo.toml | 4 ++-- .../modules/farm/farm_token_merge/Cargo.toml | 4 ++-- common/modules/farm/rewards/Cargo.toml | 4 ++-- .../legacy_token_decode_module/Cargo.toml | 2 +- common/modules/locking_module/Cargo.toml | 2 +- common/modules/math/Cargo.toml | 2 +- common/modules/pausable/Cargo.toml | 2 +- common/modules/permissions_module/Cargo.toml | 2 +- common/modules/sc_whitelist_module/Cargo.toml | 2 +- common/modules/token_merge_helper/Cargo.toml | 2 +- common/modules/token_send/Cargo.toml | 2 +- common/modules/utils/Cargo.toml | 2 +- common/traits/fixed-supply-token/Cargo.toml | 2 +- common/traits/mergeable/Cargo.toml | 2 +- common/traits/unwrappable/Cargo.toml | 2 +- dex/Cargo.toml | 6 ++--- dex/farm-with-locked-rewards/Cargo.toml | 6 ++--- dex/farm-with-locked-rewards/meta/Cargo.toml | 2 +- dex/farm-with-locked-rewards/src/lib.rs | 2 -- dex/farm-with-locked-rewards/wasm/Cargo.lock | 16 +++++++------- dex/farm-with-locked-rewards/wasm/Cargo.toml | 2 +- dex/farm/Cargo.toml | 6 ++--- dex/farm/meta/Cargo.toml | 2 +- dex/farm/src/lib.rs | 2 -- dex/farm/wasm/Cargo.lock | 16 +++++++------- dex/farm/wasm/Cargo.toml | 2 +- dex/fuzz/Cargo.toml | 4 ++-- dex/fuzz/src/fuzz_data.rs | 8 +------ dex/governance/Cargo.toml | 4 ++-- dex/governance/meta/Cargo.toml | 2 +- dex/governance/wasm/Cargo.lock | 12 +++++----- dex/governance/wasm/Cargo.toml | 2 +- dex/pair-mock/Cargo.toml | 4 ++-- dex/pair-mock/meta/Cargo.toml | 2 +- dex/pair-mock/wasm/Cargo.lock | 12 +++++----- dex/pair-mock/wasm/Cargo.toml | 2 +- dex/pair/Cargo.toml | 4 ++-- dex/pair/meta/Cargo.toml | 2 +- dex/pair/wasm-pair-full/Cargo.lock | 16 +++++++------- dex/pair/wasm-pair-full/Cargo.toml | 2 +- dex/pair/wasm-safe-price-view/Cargo.lock | 16 +++++++------- dex/pair/wasm-safe-price-view/Cargo.toml | 2 +- dex/pair/wasm/Cargo.lock | 16 +++++++------- dex/pair/wasm/Cargo.toml | 2 +- dex/price-discovery/Cargo.toml | 6 ++--- dex/price-discovery/meta/Cargo.toml | 2 +- dex/price-discovery/wasm/Cargo.lock | 16 +++++++------- dex/price-discovery/wasm/Cargo.toml | 2 +- dex/proxy-deployer/Cargo.toml | 4 ++-- dex/proxy-deployer/meta/Cargo.toml | 2 +- dex/proxy-deployer/wasm/Cargo.lock | 16 +++++++------- dex/proxy-deployer/wasm/Cargo.toml | 2 +- dex/router/Cargo.toml | 4 ++-- dex/router/meta/Cargo.toml | 2 +- dex/router/wasm/Cargo.lock | 16 +++++++------- dex/router/wasm/Cargo.toml | 2 +- dex/tests/dex_scenario_rs_test.rs | 1 - .../common-modules/energy-query/Cargo.toml | 2 +- .../week-timekeeping/Cargo.toml | 2 +- .../weekly-rewards-splitting/Cargo.toml | 2 +- .../weekly-rewards-splitting/src/base_impl.rs | 22 ++++++++++++++++--- .../weekly-rewards-splitting/src/lib.rs | 2 -- energy-integration/common-types/Cargo.toml | 2 +- .../energy-factory-mock/Cargo.toml | 4 ++-- .../energy-factory-mock/meta/Cargo.toml | 2 +- .../energy-factory-mock/wasm/Cargo.lock | 16 +++++++------- .../energy-factory-mock/wasm/Cargo.toml | 2 +- energy-integration/energy-update/Cargo.toml | 6 ++--- .../energy-update/meta/Cargo.toml | 2 +- .../energy-update/wasm/Cargo.lock | 16 +++++++------- .../energy-update/wasm/Cargo.toml | 2 +- .../farm-boosted-yields/Cargo.toml | 2 +- energy-integration/fees-collector/Cargo.toml | 6 ++--- .../fees-collector/meta/Cargo.toml | 2 +- .../fees-collector/wasm/Cargo.lock | 16 +++++++------- .../fees-collector/wasm/Cargo.toml | 2 +- energy-integration/governance-v2/Cargo.toml | 4 ++-- .../governance-v2/meta/Cargo.toml | 2 +- .../governance-v2/tests/gov_test_setup/mod.rs | 7 ------ .../governance-v2/wasm/Cargo.lock | 16 +++++++------- .../governance-v2/wasm/Cargo.toml | 2 +- farm-staking/farm-staking-proxy/Cargo.toml | 6 ++--- .../farm-staking-proxy/meta/Cargo.toml | 2 +- .../farm-staking-proxy/wasm/Cargo.lock | 16 +++++++------- .../farm-staking-proxy/wasm/Cargo.toml | 2 +- farm-staking/farm-staking/Cargo.toml | 6 ++--- farm-staking/farm-staking/meta/Cargo.toml | 2 +- .../farm-staking/src/base_impl_wrapper.rs | 18 +++++++++++++-- farm-staking/farm-staking/src/lib.rs | 1 - farm-staking/farm-staking/wasm/Cargo.lock | 16 +++++++------- farm-staking/farm-staking/wasm/Cargo.toml | 2 +- farm-staking/metabonding-staking/Cargo.toml | 6 ++--- .../metabonding-staking/meta/Cargo.toml | 2 +- .../metabonding-staking/wasm/Cargo.lock | 16 +++++++------- .../metabonding-staking/wasm/Cargo.toml | 2 +- .../farm-staking-proxy-legacy/Cargo.toml | 6 ++--- .../farm-staking-proxy-legacy/meta/Cargo.toml | 2 +- .../farm-staking-proxy-legacy/wasm/Cargo.lock | 16 +++++++------- .../farm-staking-proxy-legacy/wasm/Cargo.toml | 2 +- .../simple-lock-legacy/Cargo.toml | 6 ++--- .../simple-lock-legacy/meta/Cargo.toml | 2 +- .../simple-lock-legacy/wasm/Cargo.lock | 16 +++++++------- .../simple-lock-legacy/wasm/Cargo.toml | 2 +- locked-asset/Cargo.toml | 6 ++--- locked-asset/distribution/Cargo.toml | 4 ++-- locked-asset/distribution/meta/Cargo.toml | 2 +- locked-asset/distribution/wasm/Cargo.lock | 16 +++++++------- locked-asset/distribution/wasm/Cargo.toml | 2 +- locked-asset/energy-factory/Cargo.toml | 6 ++--- locked-asset/energy-factory/meta/Cargo.toml | 2 +- locked-asset/energy-factory/wasm/Cargo.lock | 16 +++++++------- locked-asset/energy-factory/wasm/Cargo.toml | 2 +- locked-asset/factory/Cargo.toml | 6 ++--- locked-asset/factory/meta/Cargo.toml | 2 +- locked-asset/factory/src/lib.rs | 1 - .../factory/src/locked_asset_token_merge.rs | 4 ++-- locked-asset/factory/wasm/Cargo.lock | 16 +++++++------- locked-asset/factory/wasm/Cargo.toml | 2 +- locked-asset/lkmex-transfer/Cargo.toml | 6 ++--- locked-asset/lkmex-transfer/meta/Cargo.toml | 2 +- locked-asset/lkmex-transfer/wasm/Cargo.lock | 16 +++++++------- locked-asset/lkmex-transfer/wasm/Cargo.toml | 2 +- locked-asset/locked-token-wrapper/Cargo.toml | 6 ++--- .../locked-token-wrapper/meta/Cargo.toml | 2 +- locked-asset/locked-token-wrapper/src/lib.rs | 1 + .../locked-token-wrapper/wasm/Cargo.lock | 16 +++++++------- .../locked-token-wrapper/wasm/Cargo.toml | 2 +- locked-asset/proxy_dex/Cargo.toml | 6 ++--- locked-asset/proxy_dex/meta/Cargo.toml | 2 +- locked-asset/proxy_dex/src/lib.rs | 2 -- locked-asset/proxy_dex/wasm/Cargo.lock | 16 +++++++------- locked-asset/proxy_dex/wasm/Cargo.toml | 2 +- locked-asset/simple-lock/Cargo.toml | 6 ++--- locked-asset/simple-lock/meta/Cargo.toml | 2 +- locked-asset/simple-lock/wasm/Cargo.lock | 16 +++++++------- locked-asset/simple-lock/wasm/Cargo.toml | 2 +- locked-asset/token-unstake/Cargo.toml | 6 ++--- locked-asset/token-unstake/meta/Cargo.toml | 2 +- locked-asset/token-unstake/wasm/Cargo.lock | 16 +++++++------- locked-asset/token-unstake/wasm/Cargo.toml | 2 +- pause-all/Cargo.toml | 6 ++--- pause-all/meta/Cargo.toml | 2 +- pause-all/wasm/Cargo.lock | 16 +++++++------- pause-all/wasm/Cargo.toml | 2 +- 155 files changed, 459 insertions(+), 437 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index ad010ebcc..afe5fbff4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1713,9 +1713,9 @@ checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags 2.5.0", "hex-literal 0.4.1", @@ -1751,9 +1751,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -1764,9 +1764,9 @@ dependencies = [ [[package]] name = "multiversx-sc-meta" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93aba82492783759620d72f21059749177e66438d0c021597c567eae8e888307" +checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" dependencies = [ "clap", "colored", @@ -1791,18 +1791,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-scenario" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2992739c2ef6bc8e448434b9c3ab848f2ce17264192a9918734cbb3884d0435" +checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" dependencies = [ "base64 0.22.1", "bech32", diff --git a/common/common_errors/Cargo.toml b/common/common_errors/Cargo.toml index 3c09666f5..cd386f750 100644 --- a/common/common_errors/Cargo.toml +++ b/common/common_errors/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/common_structs/Cargo.toml b/common/common_structs/Cargo.toml index 4c968a4ea..983e946a4 100644 --- a/common/common_structs/Cargo.toml +++ b/common/common_structs/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] diff --git a/common/modules/farm/config/Cargo.toml b/common/modules/farm/config/Cargo.toml index 67129dfb3..18e114c64 100644 --- a/common/modules/farm/config/Cargo.toml +++ b/common/modules/farm/config/Cargo.toml @@ -23,5 +23,5 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/contexts/Cargo.toml b/common/modules/farm/contexts/Cargo.toml index b13802a54..97de2f04f 100644 --- a/common/modules/farm/contexts/Cargo.toml +++ b/common/modules/farm/contexts/Cargo.toml @@ -35,8 +35,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" diff --git a/common/modules/farm/contexts/src/mod.rs b/common/modules/farm/contexts/src/mod.rs index e8f133eb6..a1ceed191 100644 --- a/common/modules/farm/contexts/src/mod.rs +++ b/common/modules/farm/contexts/src/mod.rs @@ -1,5 +1,4 @@ #![no_std] -#![feature(trait_alias)] pub mod claim_rewards_context; pub mod enter_farm_context; diff --git a/common/modules/farm/contexts/src/storage_cache.rs b/common/modules/farm/contexts/src/storage_cache.rs index 4e14ea2ec..76f4cfc1d 100644 --- a/common/modules/farm/contexts/src/storage_cache.rs +++ b/common/modules/farm/contexts/src/storage_cache.rs @@ -3,8 +3,15 @@ multiversx_sc::derive_imports!(); use pausable::State; -pub trait FarmContracTraitBounds = - config::ConfigModule + rewards::RewardsModule + farm_token::FarmTokenModule; +pub trait FarmContracTraitBounds: + config::ConfigModule + rewards::RewardsModule + farm_token::FarmTokenModule +{ +} + +impl FarmContracTraitBounds for T where + T: config::ConfigModule + rewards::RewardsModule + farm_token::FarmTokenModule +{ +} pub struct StorageCache<'a, C: FarmContracTraitBounds> { sc_ref: &'a C, diff --git a/common/modules/farm/events/Cargo.toml b/common/modules/farm/events/Cargo.toml index bb5b0be65..5bd8b9e4a 100644 --- a/common/modules/farm/events/Cargo.toml +++ b/common/modules/farm/events/Cargo.toml @@ -14,5 +14,5 @@ path = "../../../common_structs" path = "../contexts" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/farm_base_impl/Cargo.toml b/common/modules/farm/farm_base_impl/Cargo.toml index 7fc90ef69..43d755b75 100644 --- a/common/modules/farm/farm_base_impl/Cargo.toml +++ b/common/modules/farm/farm_base_impl/Cargo.toml @@ -50,11 +50,11 @@ path = "../../../traits/mergeable" path = "../../../traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs index f2ccc293c..f26b15099 100644 --- a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs +++ b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs @@ -4,18 +4,31 @@ use common_structs::{FarmToken, FarmTokenAttributes, Nonce}; use config::ConfigModule; use contexts::storage_cache::StorageCache; use core::marker::PhantomData; +use farm_token::FarmTokenModule; use fixed_supply_token::FixedSupplyToken; use mergeable::Mergeable; use multiversx_sc_modules::transfer_role_proxy::PaymentsVec; use rewards::RewardsModule; -pub trait AllBaseFarmImplTraits = +pub trait AllBaseFarmImplTraits: rewards::RewardsModule + + config::ConfigModule + + farm_token::FarmTokenModule + + permissions_module::PermissionsModule + + pausable::PausableModule + + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule +{ +} + +impl AllBaseFarmImplTraits for T where + T: rewards::RewardsModule + config::ConfigModule + farm_token::FarmTokenModule + permissions_module::PermissionsModule + pausable::PausableModule - + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule; + + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule +{ +} pub trait FarmContract { type FarmSc: AllBaseFarmImplTraits; @@ -30,8 +43,7 @@ pub trait FarmContract { + FixedSupplyToken<::Api> + FarmToken<::Api> + From::Api>> - + Into::Api>> = - FarmTokenAttributes<::Api>; + + Into::Api>>; #[inline] fn mint_rewards( @@ -259,4 +271,5 @@ where T: AllBaseFarmImplTraits, { type FarmSc = T; + type AttributesType = FarmTokenAttributes<::Api>; } diff --git a/common/modules/farm/farm_base_impl/src/lib.rs b/common/modules/farm/farm_base_impl/src/lib.rs index f63df2820..24e156d2a 100644 --- a/common/modules/farm/farm_base_impl/src/lib.rs +++ b/common/modules/farm/farm_base_impl/src/lib.rs @@ -1,8 +1,4 @@ #![no_std] -#![allow(clippy::too_many_arguments)] -#![feature(exact_size_is_empty)] -#![feature(trait_alias)] -#![feature(associated_type_defaults)] multiversx_sc::imports!(); multiversx_sc::derive_imports!(); diff --git a/common/modules/farm/farm_token/Cargo.toml b/common/modules/farm/farm_token/Cargo.toml index 5de06a44e..ede42b094 100644 --- a/common/modules/farm/farm_token/Cargo.toml +++ b/common/modules/farm/farm_token/Cargo.toml @@ -26,8 +26,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" diff --git a/common/modules/farm/farm_token_merge/Cargo.toml b/common/modules/farm/farm_token_merge/Cargo.toml index 52fbad221..58df12194 100644 --- a/common/modules/farm/farm_token_merge/Cargo.toml +++ b/common/modules/farm/farm_token_merge/Cargo.toml @@ -23,11 +23,11 @@ path = "../../token_merge_helper" path = "../farm_token" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/common/modules/farm/rewards/Cargo.toml b/common/modules/farm/rewards/Cargo.toml index 815bc8a5d..77d5391c6 100644 --- a/common/modules/farm/rewards/Cargo.toml +++ b/common/modules/farm/rewards/Cargo.toml @@ -29,8 +29,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" diff --git a/common/modules/legacy_token_decode_module/Cargo.toml b/common/modules/legacy_token_decode_module/Cargo.toml index 1be8769aa..1eb14224a 100644 --- a/common/modules/legacy_token_decode_module/Cargo.toml +++ b/common/modules/legacy_token_decode_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/modules/locking_module/Cargo.toml b/common/modules/locking_module/Cargo.toml index 3c88f3cb8..afa7961a2 100644 --- a/common/modules/locking_module/Cargo.toml +++ b/common/modules/locking_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.simple-lock] diff --git a/common/modules/math/Cargo.toml b/common/modules/math/Cargo.toml index 8a9df07f0..b78acbbc4 100644 --- a/common/modules/math/Cargo.toml +++ b/common/modules/math/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/pausable/Cargo.toml b/common/modules/pausable/Cargo.toml index 3d825a9f1..fa9fe8d01 100644 --- a/common/modules/pausable/Cargo.toml +++ b/common/modules/pausable/Cargo.toml @@ -11,5 +11,5 @@ path = "src/pausable.rs" path = "../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/permissions_module/Cargo.toml b/common/modules/permissions_module/Cargo.toml index 53ea3eea0..b16125e14 100644 --- a/common/modules/permissions_module/Cargo.toml +++ b/common/modules/permissions_module/Cargo.toml @@ -17,5 +17,5 @@ bitflags = "2.4.1" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/sc_whitelist_module/Cargo.toml b/common/modules/sc_whitelist_module/Cargo.toml index 37be4210c..d1394b2b6 100644 --- a/common/modules/sc_whitelist_module/Cargo.toml +++ b/common/modules/sc_whitelist_module/Cargo.toml @@ -11,5 +11,5 @@ path = "src/sc_whitelist_module.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_merge_helper/Cargo.toml b/common/modules/token_merge_helper/Cargo.toml index 8f8d34845..775755d2b 100644 --- a/common/modules/token_merge_helper/Cargo.toml +++ b/common/modules/token_merge_helper/Cargo.toml @@ -11,5 +11,5 @@ path = "src/lib.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_send/Cargo.toml b/common/modules/token_send/Cargo.toml index afe83527d..ffd8c110e 100644 --- a/common/modules/token_send/Cargo.toml +++ b/common/modules/token_send/Cargo.toml @@ -14,5 +14,5 @@ path = "../../common_structs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/utils/Cargo.toml b/common/modules/utils/Cargo.toml index 0e748a5d4..97c4d8469 100644 --- a/common/modules/utils/Cargo.toml +++ b/common/modules/utils/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/traits/fixed-supply-token/Cargo.toml b/common/traits/fixed-supply-token/Cargo.toml index 0d8c17fdd..f77040cb7 100644 --- a/common/traits/fixed-supply-token/Cargo.toml +++ b/common/traits/fixed-supply-token/Cargo.toml @@ -8,4 +8,4 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" diff --git a/common/traits/mergeable/Cargo.toml b/common/traits/mergeable/Cargo.toml index a68b46bb9..ffcd7d4aa 100644 --- a/common/traits/mergeable/Cargo.toml +++ b/common/traits/mergeable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/traits/unwrappable/Cargo.toml b/common/traits/unwrappable/Cargo.toml index c938ec365..61f703d49 100644 --- a/common/traits/unwrappable/Cargo.toml +++ b/common/traits/unwrappable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/dex/Cargo.toml b/dex/Cargo.toml index a247791a9..f7092b937 100644 --- a/dex/Cargo.toml +++ b/dex/Cargo.toml @@ -5,17 +5,17 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.config] path = "../common/modules/farm/config" diff --git a/dex/farm-with-locked-rewards/Cargo.toml b/dex/farm-with-locked-rewards/Cargo.toml index 8871b9679..2c82821ac 100644 --- a/dex/farm-with-locked-rewards/Cargo.toml +++ b/dex/farm-with-locked-rewards/Cargo.toml @@ -75,17 +75,17 @@ path = "../../locked-asset/energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.simple-lock] path = "../../locked-asset/simple-lock" diff --git a/dex/farm-with-locked-rewards/meta/Cargo.toml b/dex/farm-with-locked-rewards/meta/Cargo.toml index de17ee22d..759756a2d 100644 --- a/dex/farm-with-locked-rewards/meta/Cargo.toml +++ b/dex/farm-with-locked-rewards/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index d704a80df..ab57eb826 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -1,6 +1,4 @@ #![no_std] -#![allow(clippy::too_many_arguments)] -#![feature(exact_size_is_empty)] multiversx_sc::imports!(); multiversx_sc::derive_imports!(); diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.lock b/dex/farm-with-locked-rewards/wasm/Cargo.lock index f4ea9e617..d1031c945 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.lock +++ b/dex/farm-with-locked-rewards/wasm/Cargo.lock @@ -315,9 +315,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -352,9 +352,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -365,18 +365,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.toml b/dex/farm-with-locked-rewards/wasm/Cargo.toml index b43cd7487..2ef56b51f 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.toml +++ b/dex/farm-with-locked-rewards/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/farm/Cargo.toml b/dex/farm/Cargo.toml index 639c8b0d5..ba4b12b2c 100644 --- a/dex/farm/Cargo.toml +++ b/dex/farm/Cargo.toml @@ -69,11 +69,11 @@ path = "../../energy-integration/common-modules/weekly-rewards-splitting" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies] num-bigint = "0.4.2" @@ -82,7 +82,7 @@ num-bigint = "0.4.2" path = "../../energy-integration/energy-update" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.energy-factory-mock] path = "../../energy-integration/energy-factory-mock" diff --git a/dex/farm/meta/Cargo.toml b/dex/farm/meta/Cargo.toml index ede4d6be2..47b03082d 100644 --- a/dex/farm/meta/Cargo.toml +++ b/dex/farm/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 1a35c1631..d51b9989c 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -1,6 +1,4 @@ #![no_std] -#![allow(clippy::too_many_arguments)] -#![feature(exact_size_is_empty)] multiversx_sc::imports!(); multiversx_sc::derive_imports!(); diff --git a/dex/farm/wasm/Cargo.lock b/dex/farm/wasm/Cargo.lock index 320954ab7..8ea1ffb97 100644 --- a/dex/farm/wasm/Cargo.lock +++ b/dex/farm/wasm/Cargo.lock @@ -285,9 +285,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -322,9 +322,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -335,18 +335,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/farm/wasm/Cargo.toml b/dex/farm/wasm/Cargo.toml index 503e8c78f..4ece2ffba 100644 --- a/dex/farm/wasm/Cargo.toml +++ b/dex/farm/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/fuzz/Cargo.toml b/dex/fuzz/Cargo.toml index ea1861c9f..31b25d4f2 100644 --- a/dex/fuzz/Cargo.toml +++ b/dex/fuzz/Cargo.toml @@ -12,11 +12,11 @@ num-bigint = "0.4.2" rand = "0.8.4" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dependencies.pausable] path = "../../common/modules/pausable" diff --git a/dex/fuzz/src/fuzz_data.rs b/dex/fuzz/src/fuzz_data.rs index 14de4e7c3..d7c78c494 100644 --- a/dex/fuzz/src/fuzz_data.rs +++ b/dex/fuzz/src/fuzz_data.rs @@ -151,7 +151,6 @@ pub mod fuzz_data_tests { PriceDiscObjBuilder: 'static + Copy + Fn() -> price_discovery::ContractObj, { pub rng: StdRng, - pub owner_address: Address, pub fuzz_args: FuzzDexExecutorInitArgs, pub statistics: EventsStatistics, pub blockchain_wrapper: BlockchainStateWrapper, @@ -297,7 +296,6 @@ pub mod fuzz_data_tests { FuzzerData { rng, - owner_address: owner_addr, fuzz_args, statistics, blockchain_wrapper, @@ -590,7 +588,6 @@ pub mod fuzz_data_tests { { pub pd_wrapper: ContractObjWrapper, PriceDiscObjBuilder>, - pub locking_sc_address: Address, } pub fn setup_price_disc( @@ -705,10 +702,7 @@ pub mod fuzz_data_tests { ) .assert_ok(); - PriceDiscSetup { - pd_wrapper, - locking_sc_address: locking_sc_wrapper.address_ref().clone(), - } + PriceDiscSetup { pd_wrapper } } #[derive(Clone, PartialEq)] diff --git a/dex/governance/Cargo.toml b/dex/governance/Cargo.toml index 4680872a4..559dcd8b0 100644 --- a/dex/governance/Cargo.toml +++ b/dex/governance/Cargo.toml @@ -9,14 +9,14 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.pair-mock] path = "../pair-mock" diff --git a/dex/governance/meta/Cargo.toml b/dex/governance/meta/Cargo.toml index 8960adb4d..0edbcfa91 100644 --- a/dex/governance/meta/Cargo.toml +++ b/dex/governance/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/governance/wasm/Cargo.lock b/dex/governance/wasm/Cargo.lock index f0431c399..2c838bb95 100644 --- a/dex/governance/wasm/Cargo.lock +++ b/dex/governance/wasm/Cargo.lock @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -92,9 +92,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -105,9 +105,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/governance/wasm/Cargo.toml b/dex/governance/wasm/Cargo.toml index 7a40f5eab..3fa482747 100644 --- a/dex/governance/wasm/Cargo.toml +++ b/dex/governance/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/pair-mock/Cargo.toml b/dex/pair-mock/Cargo.toml index 471866c8d..c5b9546ea 100644 --- a/dex/pair-mock/Cargo.toml +++ b/dex/pair-mock/Cargo.toml @@ -12,7 +12,7 @@ path = "src/pair.rs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.itertools] @@ -20,4 +20,4 @@ version = "0.10.1" default-features = false [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/dex/pair-mock/meta/Cargo.toml b/dex/pair-mock/meta/Cargo.toml index 783641ecd..e9b89883e 100644 --- a/dex/pair-mock/meta/Cargo.toml +++ b/dex/pair-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/pair-mock/wasm/Cargo.lock b/dex/pair-mock/wasm/Cargo.lock index a7914463c..178e0ae80 100644 --- a/dex/pair-mock/wasm/Cargo.lock +++ b/dex/pair-mock/wasm/Cargo.lock @@ -62,9 +62,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -99,9 +99,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -112,9 +112,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair-mock/wasm/Cargo.toml b/dex/pair-mock/wasm/Cargo.toml index e0dc17d07..2b0db710c 100644 --- a/dex/pair-mock/wasm/Cargo.toml +++ b/dex/pair-mock/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/pair/Cargo.toml b/dex/pair/Cargo.toml index 60d42ebb5..ee9c89796 100644 --- a/dex/pair/Cargo.toml +++ b/dex/pair/Cargo.toml @@ -37,11 +37,11 @@ version = "0.10.1" default-features = false [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/dex/pair/meta/Cargo.toml b/dex/pair/meta/Cargo.toml index ba136bd9a..4047753d0 100644 --- a/dex/pair/meta/Cargo.toml +++ b/dex/pair/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/pair/wasm-pair-full/Cargo.lock b/dex/pair/wasm-pair-full/Cargo.lock index 911587c1d..14e0fcb89 100644 --- a/dex/pair/wasm-pair-full/Cargo.lock +++ b/dex/pair/wasm-pair-full/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair/wasm-pair-full/Cargo.toml b/dex/pair/wasm-pair-full/Cargo.toml index dd36c1284..cb7e86119 100644 --- a/dex/pair/wasm-pair-full/Cargo.toml +++ b/dex/pair/wasm-pair-full/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/pair/wasm-safe-price-view/Cargo.lock b/dex/pair/wasm-safe-price-view/Cargo.lock index d12ba17f0..d3d33acec 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.lock +++ b/dex/pair/wasm-safe-price-view/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair/wasm-safe-price-view/Cargo.toml b/dex/pair/wasm-safe-price-view/Cargo.toml index d4de815c0..017e0d8e7 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.toml +++ b/dex/pair/wasm-safe-price-view/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/pair/wasm/Cargo.lock b/dex/pair/wasm/Cargo.lock index bcaa3d0bc..1ed40bfb6 100644 --- a/dex/pair/wasm/Cargo.lock +++ b/dex/pair/wasm/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/pair/wasm/Cargo.toml b/dex/pair/wasm/Cargo.toml index 3484c1e89..763f76956 100644 --- a/dex/pair/wasm/Cargo.toml +++ b/dex/pair/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/price-discovery/Cargo.toml b/dex/price-discovery/Cargo.toml index bdf95bc25..c8ef79f7b 100644 --- a/dex/price-discovery/Cargo.toml +++ b/dex/price-discovery/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.locking_module] path = "../../common/modules/locking_module" @@ -30,4 +30,4 @@ hex = "0.4" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/dex/price-discovery/meta/Cargo.toml b/dex/price-discovery/meta/Cargo.toml index e66c3061b..db083f12c 100644 --- a/dex/price-discovery/meta/Cargo.toml +++ b/dex/price-discovery/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/price-discovery/wasm/Cargo.lock b/dex/price-discovery/wasm/Cargo.lock index dfb83b4ec..04a98edc4 100644 --- a/dex/price-discovery/wasm/Cargo.lock +++ b/dex/price-discovery/wasm/Cargo.lock @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -156,9 +156,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -169,18 +169,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/price-discovery/wasm/Cargo.toml b/dex/price-discovery/wasm/Cargo.toml index f85524500..74978fb3e 100644 --- a/dex/price-discovery/wasm/Cargo.toml +++ b/dex/price-discovery/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/proxy-deployer/Cargo.toml b/dex/proxy-deployer/Cargo.toml index 4b99fc099..488949062 100644 --- a/dex/proxy-deployer/Cargo.toml +++ b/dex/proxy-deployer/Cargo.toml @@ -21,11 +21,11 @@ path = "../../common/modules/farm/config" path = "../../common/modules/farm/farm_token" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/dex/proxy-deployer/meta/Cargo.toml b/dex/proxy-deployer/meta/Cargo.toml index a56b481ae..8f99d0558 100644 --- a/dex/proxy-deployer/meta/Cargo.toml +++ b/dex/proxy-deployer/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/proxy-deployer/wasm/Cargo.lock b/dex/proxy-deployer/wasm/Cargo.lock index af17a3fca..bef49309c 100644 --- a/dex/proxy-deployer/wasm/Cargo.lock +++ b/dex/proxy-deployer/wasm/Cargo.lock @@ -277,9 +277,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -314,9 +314,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -327,18 +327,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/proxy-deployer/wasm/Cargo.toml b/dex/proxy-deployer/wasm/Cargo.toml index d5629cb8d..26a1eca02 100644 --- a/dex/proxy-deployer/wasm/Cargo.toml +++ b/dex/proxy-deployer/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/router/Cargo.toml b/dex/router/Cargo.toml index ade4ab150..b653e13d0 100644 --- a/dex/router/Cargo.toml +++ b/dex/router/Cargo.toml @@ -15,7 +15,7 @@ path = "../../common/modules/token_send" path = "../../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.pair] @@ -28,4 +28,4 @@ path = "../../common/modules/locking_module" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/dex/router/meta/Cargo.toml b/dex/router/meta/Cargo.toml index 9d8831aa3..6333e29d5 100644 --- a/dex/router/meta/Cargo.toml +++ b/dex/router/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/dex/router/wasm/Cargo.lock b/dex/router/wasm/Cargo.lock index da5457672..44918dd26 100644 --- a/dex/router/wasm/Cargo.lock +++ b/dex/router/wasm/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/dex/router/wasm/Cargo.toml b/dex/router/wasm/Cargo.toml index 947c3c8bf..25449bdd1 100644 --- a/dex/router/wasm/Cargo.toml +++ b/dex/router/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/dex/tests/dex_scenario_rs_test.rs b/dex/tests/dex_scenario_rs_test.rs index 623f63667..3a0b16a81 100644 --- a/dex/tests/dex_scenario_rs_test.rs +++ b/dex/tests/dex_scenario_rs_test.rs @@ -2,7 +2,6 @@ use multiversx_sc_scenario::ScenarioWorld; fn world() -> ScenarioWorld { let mut blockchain = ScenarioWorld::new(); - blockchain.set_current_dir_from_workspace("dex"); blockchain.register_contract("file:router/output/router.wasm", router::ContractBuilder); blockchain.register_contract("file:pair/output/pair.wasm", pair::ContractBuilder); diff --git a/energy-integration/common-modules/energy-query/Cargo.toml b/energy-integration/common-modules/energy-query/Cargo.toml index 40ee230ca..ad8bd57cf 100644 --- a/energy-integration/common-modules/energy-query/Cargo.toml +++ b/energy-integration/common-modules/energy-query/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-factory] diff --git a/energy-integration/common-modules/week-timekeeping/Cargo.toml b/energy-integration/common-modules/week-timekeeping/Cargo.toml index 5dae717d3..06c500490 100644 --- a/energy-integration/common-modules/week-timekeeping/Cargo.toml +++ b/energy-integration/common-modules/week-timekeeping/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.common-types] diff --git a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml index b2f7fa142..4b83416ac 100644 --- a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml +++ b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-query] diff --git a/energy-integration/common-modules/weekly-rewards-splitting/src/base_impl.rs b/energy-integration/common-modules/weekly-rewards-splitting/src/base_impl.rs index c8579672d..de8783686 100644 --- a/energy-integration/common-modules/weekly-rewards-splitting/src/base_impl.rs +++ b/energy-integration/common-modules/weekly-rewards-splitting/src/base_impl.rs @@ -3,16 +3,32 @@ multiversx_sc::imports!(); use common_types::PaymentsVec; use week_timekeeping::Week; -use crate::{events, ClaimProgress}; +use crate::{ + events, global_info::WeeklyRewardsGlobalInfo, + update_claim_progress_energy::UpdateClaimProgressEnergyModule, ClaimProgress, +}; -pub trait AllBaseWeeklyRewardsSplittingImplTraits = +pub trait AllBaseWeeklyRewardsSplittingImplTraits: crate::WeeklyRewardsSplittingModule + + energy_query::EnergyQueryModule + + week_timekeeping::WeekTimekeepingModule + + crate::global_info::WeeklyRewardsGlobalInfo + + crate::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + + events::WeeklyRewardsSplittingEventsModule + + crate::update_claim_progress_energy::UpdateClaimProgressEnergyModule +{ +} + +impl AllBaseWeeklyRewardsSplittingImplTraits for T where + T: crate::WeeklyRewardsSplittingModule + energy_query::EnergyQueryModule + week_timekeeping::WeekTimekeepingModule + crate::global_info::WeeklyRewardsGlobalInfo + crate::locked_token_buckets::WeeklyRewardsLockedTokenBucketsModule + events::WeeklyRewardsSplittingEventsModule - + crate::update_claim_progress_energy::UpdateClaimProgressEnergyModule; + + crate::update_claim_progress_energy::UpdateClaimProgressEnergyModule +{ +} pub trait WeeklyRewardsSplittingTraitsModule { type WeeklyRewardsSplittingMod: AllBaseWeeklyRewardsSplittingImplTraits; diff --git a/energy-integration/common-modules/weekly-rewards-splitting/src/lib.rs b/energy-integration/common-modules/weekly-rewards-splitting/src/lib.rs index 9268023bd..456bf60d2 100644 --- a/energy-integration/common-modules/weekly-rewards-splitting/src/lib.rs +++ b/energy-integration/common-modules/weekly-rewards-splitting/src/lib.rs @@ -1,6 +1,4 @@ #![no_std] -#![feature(trait_alias)] -#![feature(int_roundings)] multiversx_sc::imports!(); multiversx_sc::derive_imports!(); diff --git a/energy-integration/common-types/Cargo.toml b/energy-integration/common-types/Cargo.toml index 0a8187567..394f09b1b 100644 --- a/energy-integration/common-types/Cargo.toml +++ b/energy-integration/common-types/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] diff --git a/energy-integration/energy-factory-mock/Cargo.toml b/energy-integration/energy-factory-mock/Cargo.toml index d9545f430..4a494ca9c 100644 --- a/energy-integration/energy-factory-mock/Cargo.toml +++ b/energy-integration/energy-factory-mock/Cargo.toml @@ -12,8 +12,8 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/energy-integration/energy-factory-mock/meta/Cargo.toml b/energy-integration/energy-factory-mock/meta/Cargo.toml index bbfca05d0..68abe9e93 100644 --- a/energy-integration/energy-factory-mock/meta/Cargo.toml +++ b/energy-integration/energy-factory-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.lock b/energy-integration/energy-factory-mock/wasm/Cargo.lock index 8bd373b84..30564520b 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.lock +++ b/energy-integration/energy-factory-mock/wasm/Cargo.lock @@ -128,9 +128,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -178,18 +178,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.toml b/energy-integration/energy-factory-mock/wasm/Cargo.toml index c7c143695..40d83dc16 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.toml +++ b/energy-integration/energy-factory-mock/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/energy-integration/energy-update/Cargo.toml b/energy-integration/energy-update/Cargo.toml index 578fa3dec..bd8ced5d5 100644 --- a/energy-integration/energy-update/Cargo.toml +++ b/energy-integration/energy-update/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.farm] path = "../../dex/farm" @@ -25,4 +25,4 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/energy-integration/energy-update/meta/Cargo.toml b/energy-integration/energy-update/meta/Cargo.toml index ee1661cc5..306816956 100644 --- a/energy-integration/energy-update/meta/Cargo.toml +++ b/energy-integration/energy-update/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/energy-integration/energy-update/wasm/Cargo.lock b/energy-integration/energy-update/wasm/Cargo.lock index 74f6a59a6..6741f94e8 100644 --- a/energy-integration/energy-update/wasm/Cargo.lock +++ b/energy-integration/energy-update/wasm/Cargo.lock @@ -295,9 +295,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -332,9 +332,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -345,18 +345,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/energy-update/wasm/Cargo.toml b/energy-integration/energy-update/wasm/Cargo.toml index 7289149fa..39a04fe5a 100644 --- a/energy-integration/energy-update/wasm/Cargo.toml +++ b/energy-integration/energy-update/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/energy-integration/farm-boosted-yields/Cargo.toml b/energy-integration/farm-boosted-yields/Cargo.toml index 69a6fe39d..1ec5d2a22 100644 --- a/energy-integration/farm-boosted-yields/Cargo.toml +++ b/energy-integration/farm-boosted-yields/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.config] diff --git a/energy-integration/fees-collector/Cargo.toml b/energy-integration/fees-collector/Cargo.toml index 59455e4fd..d357714f3 100644 --- a/energy-integration/fees-collector/Cargo.toml +++ b/energy-integration/fees-collector/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.energy-query] path = "../common-modules/energy-query" @@ -49,7 +49,7 @@ path = "../../common/common_errors" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.sc_whitelist_module] path = "../../common/modules/sc_whitelist_module" diff --git a/energy-integration/fees-collector/meta/Cargo.toml b/energy-integration/fees-collector/meta/Cargo.toml index 0434fe3fa..24f69c8f0 100644 --- a/energy-integration/fees-collector/meta/Cargo.toml +++ b/energy-integration/fees-collector/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/energy-integration/fees-collector/wasm/Cargo.lock b/energy-integration/fees-collector/wasm/Cargo.lock index 92c1abe1e..8ac282906 100644 --- a/energy-integration/fees-collector/wasm/Cargo.lock +++ b/energy-integration/fees-collector/wasm/Cargo.lock @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -191,9 +191,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -204,18 +204,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/fees-collector/wasm/Cargo.toml b/energy-integration/fees-collector/wasm/Cargo.toml index ca74577c5..c631daf5b 100644 --- a/energy-integration/fees-collector/wasm/Cargo.toml +++ b/energy-integration/fees-collector/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/energy-integration/governance-v2/Cargo.toml b/energy-integration/governance-v2/Cargo.toml index 516e466c5..ee51183a3 100644 --- a/energy-integration/governance-v2/Cargo.toml +++ b/energy-integration/governance-v2/Cargo.toml @@ -12,7 +12,7 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.permissions_module] @@ -28,7 +28,7 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.energy-factory-mock] path = "../energy-factory-mock" diff --git a/energy-integration/governance-v2/meta/Cargo.toml b/energy-integration/governance-v2/meta/Cargo.toml index 4474de48c..54f7de3d2 100644 --- a/energy-integration/governance-v2/meta/Cargo.toml +++ b/energy-integration/governance-v2/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/energy-integration/governance-v2/tests/gov_test_setup/mod.rs b/energy-integration/governance-v2/tests/gov_test_setup/mod.rs index 489fec3b3..c1d448442 100644 --- a/energy-integration/governance-v2/tests/gov_test_setup/mod.rs +++ b/energy-integration/governance-v2/tests/gov_test_setup/mod.rs @@ -34,13 +34,6 @@ pub const FULL_PERCENTAGE: u64 = 10_000; pub const USER_ENERGY: u64 = 1_000_000; pub const GAS_LIMIT: u64 = 1_000_000; -#[derive(Clone)] -pub struct Payment { - pub token: Vec, - pub nonce: u64, - pub amount: u64, -} - pub struct GovSetup where GovBuilder: 'static + Copy + Fn() -> governance_v2::ContractObj, diff --git a/energy-integration/governance-v2/wasm/Cargo.lock b/energy-integration/governance-v2/wasm/Cargo.lock index 9be4c4915..872bda3b7 100644 --- a/energy-integration/governance-v2/wasm/Cargo.lock +++ b/energy-integration/governance-v2/wasm/Cargo.lock @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -202,9 +202,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -215,18 +215,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/energy-integration/governance-v2/wasm/Cargo.toml b/energy-integration/governance-v2/wasm/Cargo.toml index b99743471..c57b86b9b 100644 --- a/energy-integration/governance-v2/wasm/Cargo.toml +++ b/energy-integration/governance-v2/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/farm-staking/farm-staking-proxy/Cargo.toml b/farm-staking/farm-staking-proxy/Cargo.toml index d4320ae73..4e6aeea05 100644 --- a/farm-staking/farm-staking-proxy/Cargo.toml +++ b/farm-staking/farm-staking-proxy/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.farm] path = "../../dex/farm" @@ -67,7 +67,7 @@ path = "../../energy-integration/common-modules/energy-query" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.farm_token] path = "../../common/modules/farm/farm_token" diff --git a/farm-staking/farm-staking-proxy/meta/Cargo.toml b/farm-staking/farm-staking-proxy/meta/Cargo.toml index e2fbbe1c7..95fefa3c4 100644 --- a/farm-staking/farm-staking-proxy/meta/Cargo.toml +++ b/farm-staking/farm-staking-proxy/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.lock b/farm-staking/farm-staking-proxy/wasm/Cargo.lock index d1d81fddb..54852f7e5 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.lock +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.lock @@ -376,9 +376,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -413,9 +413,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -426,18 +426,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.toml b/farm-staking/farm-staking-proxy/wasm/Cargo.toml index a27f85570..bd620ca6b 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.toml +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/farm-staking/farm-staking/Cargo.toml b/farm-staking/farm-staking/Cargo.toml index 7ee4d43a8..bbe389e85 100644 --- a/farm-staking/farm-staking/Cargo.toml +++ b/farm-staking/farm-staking/Cargo.toml @@ -78,14 +78,14 @@ path = "../../common/common_structs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/farm-staking/farm-staking/meta/Cargo.toml b/farm-staking/farm-staking/meta/Cargo.toml index e2f328513..f36d834e2 100644 --- a/farm-staking/farm-staking/meta/Cargo.toml +++ b/farm-staking/farm-staking/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/farm-staking/farm-staking/src/base_impl_wrapper.rs b/farm-staking/farm-staking/src/base_impl_wrapper.rs index 2b671677f..357d2f048 100644 --- a/farm-staking/farm-staking/src/base_impl_wrapper.rs +++ b/farm-staking/farm-staking/src/base_impl_wrapper.rs @@ -9,15 +9,29 @@ use multiversx_sc_modules::transfer_role_proxy::PaymentsVec; use crate::token_attributes::StakingFarmTokenAttributes; -pub trait FarmStakingTraits = +pub trait FarmStakingTraits: crate::custom_rewards::CustomRewardsModule + + rewards::RewardsModule + + config::ConfigModule + + farm_token::FarmTokenModule + + pausable::PausableModule + + permissions_module::PermissionsModule + + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule + + farm_boosted_yields::FarmBoostedYieldsModule +{ +} + +impl FarmStakingTraits for T where + T: crate::custom_rewards::CustomRewardsModule + rewards::RewardsModule + config::ConfigModule + farm_token::FarmTokenModule + pausable::PausableModule + permissions_module::PermissionsModule + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule - + farm_boosted_yields::FarmBoostedYieldsModule; + + farm_boosted_yields::FarmBoostedYieldsModule +{ +} pub struct FarmStakingWrapper where diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index 5fd2b28d6..f783c7831 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -1,6 +1,5 @@ #![no_std] #![allow(clippy::from_over_into)] -#![feature(trait_alias)] multiversx_sc::imports!(); multiversx_sc::derive_imports!(); diff --git a/farm-staking/farm-staking/wasm/Cargo.lock b/farm-staking/farm-staking/wasm/Cargo.lock index 15454fe7f..a0b69f4ee 100644 --- a/farm-staking/farm-staking/wasm/Cargo.lock +++ b/farm-staking/farm-staking/wasm/Cargo.lock @@ -316,9 +316,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -353,9 +353,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -366,18 +366,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/farm-staking/farm-staking/wasm/Cargo.toml b/farm-staking/farm-staking/wasm/Cargo.toml index d8f7b729c..3f5313c18 100644 --- a/farm-staking/farm-staking/wasm/Cargo.toml +++ b/farm-staking/farm-staking/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/farm-staking/metabonding-staking/Cargo.toml b/farm-staking/metabonding-staking/Cargo.toml index 20448ffcb..05cf87564 100644 --- a/farm-staking/metabonding-staking/Cargo.toml +++ b/farm-staking/metabonding-staking/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.factory] path = "../../locked-asset/factory" @@ -22,7 +22,7 @@ path = "../../locked-asset/factory" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.common_structs] path = "../../common/common_structs" diff --git a/farm-staking/metabonding-staking/meta/Cargo.toml b/farm-staking/metabonding-staking/meta/Cargo.toml index a7d645707..7872ee659 100644 --- a/farm-staking/metabonding-staking/meta/Cargo.toml +++ b/farm-staking/metabonding-staking/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/farm-staking/metabonding-staking/wasm/Cargo.lock b/farm-staking/metabonding-staking/wasm/Cargo.lock index 1b00d9efc..e4b8627cd 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.lock +++ b/farm-staking/metabonding-staking/wasm/Cargo.lock @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -207,9 +207,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -220,18 +220,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/farm-staking/metabonding-staking/wasm/Cargo.toml b/farm-staking/metabonding-staking/wasm/Cargo.toml index 44fbc121d..a8a2a7a7c 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.toml +++ b/farm-staking/metabonding-staking/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml index 8804de4a4..2a75332c5 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.token_merge_helper] path = "../../common/modules/token_merge_helper" @@ -27,4 +27,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml index 4f7087bb4..8e33ff17a 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock index 1c15ac5fa..f5b4cc341 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock @@ -97,9 +97,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -134,9 +134,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -147,18 +147,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml index 0990dd0b6..8851e6be6 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/legacy-contracts/simple-lock-legacy/Cargo.toml b/legacy-contracts/simple-lock-legacy/Cargo.toml index 273f1ea46..d3e866d66 100644 --- a/legacy-contracts/simple-lock-legacy/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/legacy-contracts/simple-lock-legacy/meta/Cargo.toml b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml index d8265bb27..e00582e08 100644 --- a/legacy-contracts/simple-lock-legacy/meta/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock index 9a0ea9eb9..c6dc70fac 100644 --- a/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -109,9 +109,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -122,18 +122,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml index e85db946d..0c6712178 100644 --- a/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/Cargo.toml b/locked-asset/Cargo.toml index ccfa78c14..02b69159a 100644 --- a/locked-asset/Cargo.toml +++ b/locked-asset/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.farm] @@ -50,7 +50,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/distribution/Cargo.toml b/locked-asset/distribution/Cargo.toml index c0cb6b3e0..11d2ba1c3 100644 --- a/locked-asset/distribution/Cargo.toml +++ b/locked-asset/distribution/Cargo.toml @@ -14,8 +14,8 @@ path = "../../common/common_structs" path = "../factory" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/distribution/meta/Cargo.toml b/locked-asset/distribution/meta/Cargo.toml index d67ac96db..4c62fffbf 100644 --- a/locked-asset/distribution/meta/Cargo.toml +++ b/locked-asset/distribution/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/distribution/wasm/Cargo.lock b/locked-asset/distribution/wasm/Cargo.lock index 68c738b3e..30b240495 100644 --- a/locked-asset/distribution/wasm/Cargo.lock +++ b/locked-asset/distribution/wasm/Cargo.lock @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -207,9 +207,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -220,18 +220,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/distribution/wasm/Cargo.toml b/locked-asset/distribution/wasm/Cargo.toml index 320796e85..9c8780552 100644 --- a/locked-asset/distribution/wasm/Cargo.toml +++ b/locked-asset/distribution/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/energy-factory/Cargo.toml b/locked-asset/energy-factory/Cargo.toml index a040473c0..bd4e5c0b6 100644 --- a/locked-asset/energy-factory/Cargo.toml +++ b/locked-asset/energy-factory/Cargo.toml @@ -33,11 +33,11 @@ path = "../../common/traits/unwrappable" path = "../../common/modules/legacy_token_decode_module" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies] num-bigint = "0.4.2" @@ -45,4 +45,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/energy-factory/meta/Cargo.toml b/locked-asset/energy-factory/meta/Cargo.toml index a92e84898..e3773e413 100644 --- a/locked-asset/energy-factory/meta/Cargo.toml +++ b/locked-asset/energy-factory/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/energy-factory/wasm/Cargo.lock b/locked-asset/energy-factory/wasm/Cargo.lock index bf1aebf96..692139886 100644 --- a/locked-asset/energy-factory/wasm/Cargo.lock +++ b/locked-asset/energy-factory/wasm/Cargo.lock @@ -112,9 +112,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -149,9 +149,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -162,18 +162,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/energy-factory/wasm/Cargo.toml b/locked-asset/energy-factory/wasm/Cargo.toml index f12dae00b..f03bc747f 100644 --- a/locked-asset/energy-factory/wasm/Cargo.toml +++ b/locked-asset/energy-factory/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/factory/Cargo.toml b/locked-asset/factory/Cargo.toml index 4b290a2b1..fdf9e4909 100644 --- a/locked-asset/factory/Cargo.toml +++ b/locked-asset/factory/Cargo.toml @@ -26,11 +26,11 @@ path = "../../common/modules/token_merge_helper" path = "../energy-factory" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.arrayvec] version = "0.7.1" @@ -49,4 +49,4 @@ hex = "0.4" path = "../simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/factory/meta/Cargo.toml b/locked-asset/factory/meta/Cargo.toml index 5d2be2857..cb31d100a 100644 --- a/locked-asset/factory/meta/Cargo.toml +++ b/locked-asset/factory/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/factory/src/lib.rs b/locked-asset/factory/src/lib.rs index b826bb14b..bd27c4752 100644 --- a/locked-asset/factory/src/lib.rs +++ b/locked-asset/factory/src/lib.rs @@ -1,5 +1,4 @@ #![no_std] -#![feature(exact_size_is_empty)] mod attr_ex_helper; mod cache; diff --git a/locked-asset/factory/src/locked_asset_token_merge.rs b/locked-asset/factory/src/locked_asset_token_merge.rs index 995d13528..f2c76f235 100644 --- a/locked-asset/factory/src/locked_asset_token_merge.rs +++ b/locked-asset/factory/src/locked_asset_token_merge.rs @@ -49,8 +49,6 @@ pub trait LockedAssetTokenMergeModule: &self, payments: ManagedVecRefIterator>, ) -> (BigUint, LockedAssetTokenAttributesEx) { - require!(!payments.is_empty(), "Cannot merge with 0 tokens"); - let mut tokens = ManagedVec::new(); let mut sum_amount = BigUint::zero(); let locked_asset_token_id = self.locked_asset_token().get_token_id(); @@ -70,6 +68,8 @@ pub trait LockedAssetTokenMergeModule: }); } + require!(!tokens.is_empty(), "Cannot merge with 0 tokens"); + if tokens.len() == 1 { let token_0 = tokens.get(0); return (token_0.token_amount.amount, token_0.attributes); diff --git a/locked-asset/factory/wasm/Cargo.lock b/locked-asset/factory/wasm/Cargo.lock index 95f5fb37b..809943091 100644 --- a/locked-asset/factory/wasm/Cargo.lock +++ b/locked-asset/factory/wasm/Cargo.lock @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/factory/wasm/Cargo.toml b/locked-asset/factory/wasm/Cargo.toml index 3adf3713b..f42916ed8 100644 --- a/locked-asset/factory/wasm/Cargo.toml +++ b/locked-asset/factory/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/lkmex-transfer/Cargo.toml b/locked-asset/lkmex-transfer/Cargo.toml index d0e85105e..8f3a10373 100644 --- a/locked-asset/lkmex-transfer/Cargo.toml +++ b/locked-asset/lkmex-transfer/Cargo.toml @@ -30,14 +30,14 @@ path = "../energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/lkmex-transfer/meta/Cargo.toml b/locked-asset/lkmex-transfer/meta/Cargo.toml index 7a1529dbb..e355d4140 100644 --- a/locked-asset/lkmex-transfer/meta/Cargo.toml +++ b/locked-asset/lkmex-transfer/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.lock b/locked-asset/lkmex-transfer/wasm/Cargo.lock index 6aed1f456..5ec5b0139 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.lock +++ b/locked-asset/lkmex-transfer/wasm/Cargo.lock @@ -134,9 +134,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -171,9 +171,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -184,18 +184,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.toml b/locked-asset/lkmex-transfer/wasm/Cargo.toml index 39ba55989..c91df3b30 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.toml +++ b/locked-asset/lkmex-transfer/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/locked-token-wrapper/Cargo.toml b/locked-asset/locked-token-wrapper/Cargo.toml index a4cbc2d73..79ca7517d 100644 --- a/locked-asset/locked-token-wrapper/Cargo.toml +++ b/locked-asset/locked-token-wrapper/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.utils] path = "../../common/modules/utils" @@ -44,4 +44,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/locked-token-wrapper/meta/Cargo.toml b/locked-asset/locked-token-wrapper/meta/Cargo.toml index 647b2023b..cbafdc722 100644 --- a/locked-asset/locked-token-wrapper/meta/Cargo.toml +++ b/locked-asset/locked-token-wrapper/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/locked-token-wrapper/src/lib.rs b/locked-asset/locked-token-wrapper/src/lib.rs index 5398cc42a..0724260e6 100644 --- a/locked-asset/locked-token-wrapper/src/lib.rs +++ b/locked-asset/locked-token-wrapper/src/lib.rs @@ -1,4 +1,5 @@ #![no_std] +#![allow(deprecated)] multiversx_sc::imports!(); diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.lock b/locked-asset/locked-token-wrapper/wasm/Cargo.lock index 038df0afe..45d646f00 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.lock +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.lock @@ -158,9 +158,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -195,9 +195,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -208,18 +208,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.toml b/locked-asset/locked-token-wrapper/wasm/Cargo.toml index 3ce5d92cb..88b2fcef5 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.toml +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/proxy_dex/Cargo.toml b/locked-asset/proxy_dex/Cargo.toml index 90765cf13..6cd60b67d 100644 --- a/locked-asset/proxy_dex/Cargo.toml +++ b/locked-asset/proxy_dex/Cargo.toml @@ -45,11 +45,11 @@ path = "../../common/traits/mergeable" path = "../../common/traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.energy-factory] path = "../energy-factory" @@ -69,7 +69,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.pausable] path = "../../common/modules/pausable" diff --git a/locked-asset/proxy_dex/meta/Cargo.toml b/locked-asset/proxy_dex/meta/Cargo.toml index c1706c5da..81d2922ca 100644 --- a/locked-asset/proxy_dex/meta/Cargo.toml +++ b/locked-asset/proxy_dex/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/proxy_dex/src/lib.rs b/locked-asset/proxy_dex/src/lib.rs index 3e03c2f06..047b087e8 100644 --- a/locked-asset/proxy_dex/src/lib.rs +++ b/locked-asset/proxy_dex/src/lib.rs @@ -1,6 +1,4 @@ #![no_std] -#![allow(clippy::too_many_arguments)] -#![feature(exact_size_is_empty)] multiversx_sc::imports!(); multiversx_sc::derive_imports!(); diff --git a/locked-asset/proxy_dex/wasm/Cargo.lock b/locked-asset/proxy_dex/wasm/Cargo.lock index 5872c386f..bad19c9c7 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.lock +++ b/locked-asset/proxy_dex/wasm/Cargo.lock @@ -307,9 +307,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -344,9 +344,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -357,18 +357,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/proxy_dex/wasm/Cargo.toml b/locked-asset/proxy_dex/wasm/Cargo.toml index 0a906dc13..dfccc666f 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.toml +++ b/locked-asset/proxy_dex/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/simple-lock/Cargo.toml b/locked-asset/simple-lock/Cargo.toml index b765985c3..51a984cef 100644 --- a/locked-asset/simple-lock/Cargo.toml +++ b/locked-asset/simple-lock/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/simple-lock/meta/Cargo.toml b/locked-asset/simple-lock/meta/Cargo.toml index 69d47ab9d..7e88ea4e3 100644 --- a/locked-asset/simple-lock/meta/Cargo.toml +++ b/locked-asset/simple-lock/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/simple-lock/wasm/Cargo.lock b/locked-asset/simple-lock/wasm/Cargo.lock index 8d74083b5..7251fe292 100644 --- a/locked-asset/simple-lock/wasm/Cargo.lock +++ b/locked-asset/simple-lock/wasm/Cargo.lock @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -109,9 +109,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -122,18 +122,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/simple-lock/wasm/Cargo.toml b/locked-asset/simple-lock/wasm/Cargo.toml index f3c01319d..fb6783b82 100644 --- a/locked-asset/simple-lock/wasm/Cargo.toml +++ b/locked-asset/simple-lock/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/locked-asset/token-unstake/Cargo.toml b/locked-asset/token-unstake/Cargo.toml index 46e3a4e66..18eb2701d 100644 --- a/locked-asset/token-unstake/Cargo.toml +++ b/locked-asset/token-unstake/Cargo.toml @@ -9,7 +9,7 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] @@ -39,7 +39,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" diff --git a/locked-asset/token-unstake/meta/Cargo.toml b/locked-asset/token-unstake/meta/Cargo.toml index 46081ddf1..3cd65b028 100644 --- a/locked-asset/token-unstake/meta/Cargo.toml +++ b/locked-asset/token-unstake/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/locked-asset/token-unstake/wasm/Cargo.lock b/locked-asset/token-unstake/wasm/Cargo.lock index c0dbbdef3..79e063007 100644 --- a/locked-asset/token-unstake/wasm/Cargo.lock +++ b/locked-asset/token-unstake/wasm/Cargo.lock @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -156,9 +156,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -169,18 +169,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/locked-asset/token-unstake/wasm/Cargo.toml b/locked-asset/token-unstake/wasm/Cargo.toml index 13cb91277..c06b0843f 100644 --- a/locked-asset/token-unstake/wasm/Cargo.toml +++ b/locked-asset/token-unstake/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] diff --git a/pause-all/Cargo.toml b/pause-all/Cargo.toml index 8856a1b7a..ba3f18d7a 100644 --- a/pause-all/Cargo.toml +++ b/pause-all/Cargo.toml @@ -12,14 +12,14 @@ path = "src/lib.rs" path = "../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.50.4" +version = "=0.50.5" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.4" +version = "=0.50.5" [dev-dependencies.farm] path = "../dex/farm" diff --git a/pause-all/meta/Cargo.toml b/pause-all/meta/Cargo.toml index 9f1d2bdd5..ed3c087ed 100644 --- a/pause-all/meta/Cargo.toml +++ b/pause-all/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.4" +version = "0.50.5" default-features = false diff --git a/pause-all/wasm/Cargo.lock b/pause-all/wasm/Cargo.lock index d942f7370..d23e605c4 100644 --- a/pause-all/wasm/Cargo.lock +++ b/pause-all/wasm/Cargo.lock @@ -47,9 +47,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "748a370a86e9a3c51e0609c4a6c0c9a5cceaeb742656ee3284c0620504a3d7a5" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" dependencies = [ "bitflags", "hex-literal", @@ -84,9 +84,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6ca88f27a90b0a1b17d5b645cc859e0480f4321c551525873a59a954bfbcb53" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" dependencies = [ "hex", "proc-macro2", @@ -97,18 +97,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e97c7153d996ef412f5fc687a6799fc9173cb221adef283c217d160eebebe7d4" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.4" +version = "0.50.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37f083d6844a0919a39d87c2552b8e9ea30e365775265d31b419d24f6aa93eee" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" dependencies = [ "multiversx-sc", ] diff --git a/pause-all/wasm/Cargo.toml b/pause-all/wasm/Cargo.toml index 5c679c0f7..02be3f8ff 100644 --- a/pause-all/wasm/Cargo.toml +++ b/pause-all/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.4" +version = "=0.50.5" [workspace] members = ["."] From abf386a0d58b4fae6c609fc6459cc1379fc6ea65 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 28 Jun 2024 00:25:25 +0300 Subject: [PATCH 068/103] added unit test for unstake endpoint --- Cargo.lock | 10 + .../farm-staking-proxy-legacy/Cargo.toml | 30 ++ .../src/external_contracts_interactions.rs | 77 +--- .../farm-staking-proxy-legacy/src/lib.rs | 7 +- .../tests/constants/mod.rs | 48 +++ .../tests/staking_farm_with_lp.rs | 149 +++++++ .../mod.rs | 253 ++++++++++++ .../mod.rs | 222 +++++++++++ .../mod.rs | 153 ++++++++ .../farm-staking-proxy-legacy/wasm/Cargo.lock | 366 ++++++++++++++++++ 10 files changed, 1255 insertions(+), 60 deletions(-) create mode 100644 legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs create mode 100644 legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs diff --git a/Cargo.lock b/Cargo.lock index ad010ebcc..5d3ca5085 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -889,12 +889,22 @@ name = "farm-staking-proxy-legacy" version = "0.0.0" dependencies = [ "common_structs", + "energy-factory", + "energy-query", + "farm-staking", + "farm-with-locked-rewards", + "farm_token", "hex", + "locking_module", "multiversx-sc", "multiversx-sc-modules", "multiversx-sc-scenario", "num-bigint", "num-traits", + "pair", + "pausable", + "sc_whitelist_module", + "simple-lock", "token_merge_helper", ] diff --git a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml index 8804de4a4..71a633eec 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml @@ -21,6 +21,36 @@ path = "../../common/modules/token_merge_helper" [dependencies.common_structs] path = "../../common/common_structs" +[dependencies.farm-staking] +path = "../../farm-staking/farm-staking" + +[dependencies.pair] +path = "../../dex/pair" + +[dependencies.farm-with-locked-rewards] +path = "../../dex/farm-with-locked-rewards" + +[dev-dependencies.energy-factory] +path = "../../locked-asset/energy-factory" + +[dev-dependencies.energy-query] +path = "../../energy-integration/common-modules/energy-query" + +[dev-dependencies.simple-lock] +path = "../../locked-asset/simple-lock" + +[dev-dependencies.farm_token] +path = "../../common/modules/farm/farm_token" + +[dev-dependencies.locking_module] +path = "../../common/modules/locking_module" + +[dev-dependencies.pausable] +path = "../../common/modules/pausable" + +[dev-dependencies.sc_whitelist_module] +path = "../../common/modules/sc_whitelist_module" + [dev-dependencies] num-bigint = "0.4.2" num-traits = "0.2" diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs b/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs index a6826771b..3c4c92000 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs @@ -1,57 +1,13 @@ multiversx_sc::imports!(); use common_structs::{RawResultWrapper, RawResultsType}; +use farm_staking::unstake_farm::ProxyTrait as _; +use multiversx_sc::storage::StorageKey; +use pair::{pair_actions::remove_liq::ProxyTrait as _, safe_price_view::ProxyTrait as _}; use crate::result_types::*; -mod farm_proxy { - multiversx_sc::imports!(); - - #[multiversx_sc::proxy] - pub trait FarmProxy { - #[payable("*")] - #[endpoint(exitFarm)] - fn exit_farm(&self) -> MultiValue2; - - #[view(getFarmingTokenId)] - fn farming_token_id(&self) -> TokenIdentifier; - } -} - -mod farm_staking_proxy { - multiversx_sc::imports!(); - - #[multiversx_sc::proxy] - pub trait FarmStakingProxy { - #[payable("*")] - #[endpoint(unstakeFarmThroughProxy)] - fn unstake_farm_through_proxy( - &self, - original_caller: ManagedAddress, - ) -> MultiValue2; - } -} - -mod pair_proxy { - multiversx_sc::imports!(); - - #[multiversx_sc::proxy] - pub trait PairProxy { - #[payable("*")] - #[endpoint(removeLiquidity)] - fn remove_liquidity( - &self, - first_token_amount_min: BigUint, - second_token_amount_min: BigUint, - ) -> MultiValue2; - - #[endpoint(updateAndGetTokensForGivenPositionWithSafePrice)] - fn update_and_get_tokens_for_given_position_with_safe_price( - &self, - liquidity: BigUint, - ) -> MultiValue2; - } -} +pub static FARMING_TOKEN_STORAGE_KEY: &[u8] = b"farming_token_id"; #[multiversx_sc::module] pub trait ExternalContractsInteractionsModule: @@ -61,6 +17,7 @@ pub trait ExternalContractsInteractionsModule: fn lp_farm_exit( &self, + orig_caller: ManagedAddress, lp_farm_token_nonce: u64, lp_farm_token_amount: BigUint, ) -> LpFarmExitResult { @@ -68,7 +25,7 @@ pub trait ExternalContractsInteractionsModule: let lp_farm_address = self.lp_farm_address().get(); let raw_results: RawResultsType = self .lp_farm_proxy_obj(lp_farm_address) - .exit_farm() + .exit_farm_endpoint(OptionalValue::Some(orig_caller)) .with_esdt_transfer((lp_farm_token_id, lp_farm_token_nonce, lp_farm_token_amount)) .execute_on_dest_context(); @@ -93,9 +50,13 @@ pub trait ExternalContractsInteractionsModule: fn get_lp_farming_token_identifier(&self) -> TokenIdentifier { let lp_farm_address = self.lp_farm_address().get(); - self.lp_farm_proxy_obj(lp_farm_address) - .farming_token_id() - .execute_on_dest_context() + + let farming_token_mapper = SingleValueMapper::<_, _, ManagedAddress>::new_from_address( + lp_farm_address, + StorageKey::new(FARMING_TOKEN_STORAGE_KEY), + ); + + farming_token_mapper.get() } // staking farm @@ -201,16 +162,16 @@ pub trait ExternalContractsInteractionsModule: // proxies #[proxy] - fn staking_farm_proxy_obj( - &self, - sc_address: ManagedAddress, - ) -> farm_staking_proxy::Proxy; + fn staking_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_staking::Proxy; #[proxy] - fn lp_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_proxy::Proxy; + fn lp_farm_proxy_obj( + &self, + sc_address: ManagedAddress, + ) -> farm_with_locked_rewards::Proxy; #[proxy] - fn pair_proxy_obj(&self, sc_address: ManagedAddress) -> pair_proxy::Proxy; + fn pair_proxy_obj(&self, sc_address: ManagedAddress) -> pair::Proxy; // storage diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs b/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs index 957285429..211e4ec0e 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs @@ -34,8 +34,11 @@ pub trait FarmStakingProxy: let attributes = self.get_dual_yield_token_attributes(payment_nonce); let lp_farm_token_amount = self.get_lp_farm_token_amount_equivalent(&attributes, &payment_amount); - let lp_farm_exit_result = - self.lp_farm_exit(attributes.lp_farm_token_nonce, lp_farm_token_amount); + let lp_farm_exit_result = self.lp_farm_exit( + caller.clone(), + attributes.lp_farm_token_nonce, + lp_farm_token_amount, + ); let remove_liq_result = self.pair_remove_liquidity( lp_farm_exit_result.lp_tokens, diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs new file mode 100644 index 000000000..b9eef5056 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs @@ -0,0 +1,48 @@ +// Pair constants + +pub const PAIR_WASM_PATH: &'static str = "pair/output/pair.wasm"; +pub const WEGLD_TOKEN_ID: &[u8] = b"WEGLD-abcdef"; +pub const RIDE_TOKEN_ID: &[u8] = b"RIDE-abcdef"; +pub const LP_TOKEN_ID: &[u8] = b"LPTOK-abcdef"; // also farming token ID for LP farm + +pub const USER_TOTAL_WEGLD_TOKENS: u64 = 2_000_000_000; +pub const USER_TOTAL_RIDE_TOKENS: u64 = 2_000_000_000; +pub const USER_TOTAL_LP_TOKENS: u64 = 1_001_000_000; + +pub const BLOCK_NONCE_FIRST_ADD_LIQ: u64 = 5; +pub const BLOCK_NONCE_SECOND_ADD_LIQ: u64 = 6; +pub const BLOCK_NONCE_AFTER_PAIR_SETUP: u64 = 100; + +// LP farm constants + +pub const FARM_WASM_PATH: &'static str = "farm/output/farm.wasm"; +pub const LP_FARM_TOKEN_ID: &[u8] = b"LPFARM-abcdef"; +pub const DIVISION_SAFETY_CONSTANT: u64 = 1_000_000_000_000; +pub const MIN_FARMING_EPOCHS: u8 = 2; +pub const PENALTY_PERCENT: u64 = 10; +pub const LP_FARM_PER_BLOCK_REWARD_AMOUNT: u64 = 5_000; + +// Energy factory constants + +pub const EPOCHS_IN_YEAR: u64 = 360; +pub static MEX_TOKEN_ID: &[u8] = b"MEX-123456"; +pub static LOCKED_TOKEN_ID: &[u8] = b"LOCKED-123456"; +pub static LEGACY_LOCKED_TOKEN_ID: &[u8] = b"LEGACY-123456"; +pub static LOCK_OPTIONS: &[u64] = &[EPOCHS_IN_YEAR, 5 * EPOCHS_IN_YEAR, 10 * EPOCHS_IN_YEAR]; // 1, 5 or 10 years +pub static PENALTY_PERCENTAGES: &[u64] = &[4_000, 6_000, 8_000]; + +// Staking farm constants + +pub const STAKING_FARM_WASM_PATH: &str = "farm-staking/output/farm-staking.wasm"; +pub const STAKING_REWARD_TOKEN_ID: &[u8] = RIDE_TOKEN_ID; +pub const STAKING_TOKEN_ID: &[u8] = RIDE_TOKEN_ID; +pub const STAKING_FARM_TOKEN_ID: &[u8] = b"STKFARM-abcdef"; +pub const MAX_APR: u64 = 5_000; // 50% +pub const UNBOND_EPOCHS: u64 = 10; +pub const STAKING_FARM_PER_BLOCK_REWARD_AMOUNT: u64 = 1_000; +pub const REWARD_CAPACITY: u64 = 1_000_000_000_000; + +// Proxy constants + +pub const PROXY_WASM_PATH: &str = "farm-staking-proxy/output/farm-staking-proxy"; +pub const DUAL_YIELD_TOKEN_ID: &[u8] = b"DYIELD-abcdef"; diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs new file mode 100644 index 000000000..c7f92adf0 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs @@ -0,0 +1,149 @@ +#![allow(deprecated)] + +pub mod constants; +pub mod staking_farm_with_lp_external_contracts; +pub mod staking_farm_with_lp_staking_contract_interactions; +pub mod staking_farm_with_lp_staking_contract_setup; + +multiversx_sc::imports!(); + +use common_structs::FarmTokenAttributes; +use constants::*; +use farm_staking_proxy_legacy::dual_yield_token::DualYieldTokenAttributes; + +use farm_staking::stake_farm::StakeFarmModule; +use farm_with_locked_rewards::Farm; +use multiversx_sc_scenario::{ + imports::TxTokenTransfer, managed_address, managed_biguint, rust_biguint, DebugApi, +}; +use pair::pair_actions::add_liq::AddLiquidityModule; +use staking_farm_with_lp_staking_contract_interactions::*; + +#[test] +fn test_all_setup() { + let _ = FarmStakingSetup::new( + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + farm_staking::contract_obj, + farm_staking_proxy_legacy::contract_obj, + ); +} + +#[test] +fn test_unstake_from_legacy_proxy() { + let mut setup = FarmStakingSetup::new( + pair::contract_obj, + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + farm_staking::contract_obj, + farm_staking_proxy_legacy::contract_obj, + ); + + DebugApi::dummy(); + setup + .b_mock + .set_block_nonce(BLOCK_NONCE_AFTER_PAIR_SETUP + 20); + setup.b_mock.set_block_epoch(20); + + let token_amount = 1_000_000_000u64; + + let payments = vec![ + TxTokenTransfer { + token_identifier: WEGLD_TOKEN_ID.to_vec(), + nonce: 0, + value: rust_biguint!(token_amount), + }, + TxTokenTransfer { + token_identifier: RIDE_TOKEN_ID.to_vec(), + nonce: 0, + value: rust_biguint!(token_amount), + }, + ]; + setup + .b_mock + .execute_esdt_multi_transfer(&setup.user_addr, &setup.pair_wrapper, &payments, |sc| { + sc.add_liquidity(managed_biguint!(1u64), managed_biguint!(1u64)); + }) + .assert_ok(); + + setup + .b_mock + .execute_esdt_transfer( + &setup.user_addr, + &setup.lp_farm_wrapper, + LP_TOKEN_ID, + 0, + &rust_biguint!(token_amount), + |sc| { + sc.enter_farm_endpoint(OptionalValue::None); + }, + ) + .assert_ok(); + + // Simulate enter proxy staking contract + let lp_farm_token_attributes: FarmTokenAttributes = FarmTokenAttributes { + reward_per_share: managed_biguint!(0), + entering_epoch: 20, + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(token_amount), + original_owner: managed_address!(&setup.user_addr), + }; + setup.b_mock.set_nft_balance( + setup.proxy_wrapper.address_ref(), + LP_FARM_TOKEN_ID, + 1, + &rust_biguint!(token_amount), + &lp_farm_token_attributes, + ); + setup.b_mock.set_esdt_balance( + setup.proxy_wrapper.address_ref(), + RIDE_TOKEN_ID, + &rust_biguint!(token_amount), + ); + + setup + .b_mock + .execute_tx( + setup.proxy_wrapper.address_ref(), + &setup.staking_farm_wrapper, + &rust_biguint!(0u64), + |sc| { + sc.stake_farm_through_proxy( + managed_biguint!(token_amount), + managed_address!(&setup.user_addr), + ); + }, + ) + .assert_ok(); + + let dual_yield_token_amount = token_amount; + let dual_yield_token_attributes: DualYieldTokenAttributes = + DualYieldTokenAttributes { + lp_farm_token_nonce: 1, + lp_farm_token_amount: managed_biguint!(dual_yield_token_amount), + staking_farm_token_nonce: 1, + staking_farm_token_amount: managed_biguint!(dual_yield_token_amount), + }; + setup.b_mock.set_nft_balance( + &setup.user_addr, + DUAL_YIELD_TOKEN_ID, + 1, + &rust_biguint!(dual_yield_token_amount), + &dual_yield_token_attributes, + ); + + let expected_token_amount = 990_000_000u64; + setup.unstake_proxy( + 1, + dual_yield_token_amount, + expected_token_amount, + 0, + 0, + expected_token_amount, + 30, + ); + + setup.b_mock.set_block_epoch(30); + setup.unbond_proxy(2, expected_token_amount, expected_token_amount); +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs new file mode 100644 index 000000000..94306f44e --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs @@ -0,0 +1,253 @@ +use energy_factory::token_whitelist::TokenWhitelistModule; +use energy_factory::SimpleLockEnergy; +use energy_query::EnergyQueryModule; +use farm_token::FarmTokenModule; +use farm_with_locked_rewards::Farm; +use multiversx_sc::imports::StorageTokenWrapper; +use multiversx_sc::types::{Address, EsdtLocalRole, MultiValueEncoded}; +use multiversx_sc_modules::pause::PauseModule; +use multiversx_sc_scenario::{ + managed_address, managed_biguint, managed_token_id, rust_biguint, testing_framework::*, + DebugApi, +}; + +use pair::config as pair_config; +use pair::*; +use pair_actions::add_liq::AddLiquidityModule; +use pair_actions::initial_liq::InitialLiquidityModule; +use pair_config::ConfigModule as _; + +use pausable::{PausableModule, State}; +use simple_lock::locked_token::LockedTokenModule as _; + +use crate::constants::*; + +pub fn setup_pair( + owner_addr: &Address, + user_addr: &Address, + b_mock: &mut BlockchainStateWrapper, + pair_builder: PairObjBuilder, +) -> ContractObjWrapper, PairObjBuilder> +where + PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, +{ + let rust_zero = rust_biguint!(0u64); + let pair_wrapper = + b_mock.create_sc_account(&rust_zero, Some(owner_addr), pair_builder, PAIR_WASM_PATH); + + b_mock + .execute_tx(&owner_addr, &pair_wrapper, &rust_zero, |sc| { + let first_token_id = managed_token_id!(WEGLD_TOKEN_ID); + let second_token_id = managed_token_id!(RIDE_TOKEN_ID); + let router_address = managed_address!(&owner_addr); + let router_owner_address = managed_address!(&owner_addr); + let initial_liquidity_adder = managed_address!(&owner_addr); + let total_fee_percent = 300u64; + let special_fee_percent = 50u64; + + sc.init( + first_token_id, + second_token_id, + router_address, + router_owner_address, + total_fee_percent, + special_fee_percent, + initial_liquidity_adder, + MultiValueEncoded::new(), + ); + + let lp_token_id = managed_token_id!(LP_TOKEN_ID); + sc.lp_token_identifier().set(&lp_token_id); + }) + .assert_ok(); + + let lp_token_roles = [EsdtLocalRole::Mint, EsdtLocalRole::Burn]; + b_mock.set_esdt_local_roles(pair_wrapper.address_ref(), LP_TOKEN_ID, &lp_token_roles[..]); + + // set user balance + b_mock.set_esdt_balance( + &user_addr, + WEGLD_TOKEN_ID, + &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), + ); + b_mock.set_esdt_balance( + &user_addr, + RIDE_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + b_mock.set_block_nonce(BLOCK_NONCE_FIRST_ADD_LIQ); + + b_mock.set_esdt_balance( + &owner_addr, + WEGLD_TOKEN_ID, + &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), + ); + b_mock.set_esdt_balance( + &owner_addr, + RIDE_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + let payments = vec![ + TxTokenTransfer { + token_identifier: WEGLD_TOKEN_ID.to_vec(), + nonce: 0, + value: rust_biguint!(1_000_000_000), + }, + TxTokenTransfer { + token_identifier: RIDE_TOKEN_ID.to_vec(), + nonce: 0, + value: rust_biguint!(1_000_000_000), + }, + ]; + b_mock + .execute_esdt_multi_transfer(&owner_addr, &pair_wrapper, &payments, |sc| { + sc.add_initial_liquidity(); + }) + .assert_ok(); + + b_mock.set_block_nonce(BLOCK_NONCE_SECOND_ADD_LIQ); + + b_mock + .execute_esdt_multi_transfer(&owner_addr, &pair_wrapper, &payments, |sc| { + sc.add_liquidity(managed_biguint!(1u64), managed_biguint!(1u64)); + }) + .assert_ok(); + + b_mock.set_block_nonce(BLOCK_NONCE_AFTER_PAIR_SETUP); + + pair_wrapper +} + +pub fn setup_lp_farm( + owner_addr: &Address, + energy_factory_address: &Address, + b_mock: &mut BlockchainStateWrapper, + farm_builder: FarmObjBuilder, +) -> ContractObjWrapper, FarmObjBuilder> +where + FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, +{ + let rust_zero = rust_biguint!(0u64); + let farm_wrapper = + b_mock.create_sc_account(&rust_zero, Some(&owner_addr), farm_builder, FARM_WASM_PATH); + + // init farm contract + + b_mock + .execute_tx(&owner_addr, &farm_wrapper, &rust_zero, |sc| { + let reward_token_id = managed_token_id!(RIDE_TOKEN_ID); + let farming_token_id = managed_token_id!(LP_TOKEN_ID); + let division_safety_constant = managed_biguint!(DIVISION_SAFETY_CONSTANT); + let pair_address = managed_address!(&Address::zero()); + + sc.init( + reward_token_id, + farming_token_id, + division_safety_constant, + pair_address, + managed_address!(owner_addr), + MultiValueEncoded::new(), + ); + + let farm_token_id = managed_token_id!(LP_FARM_TOKEN_ID); + sc.farm_token().set_token_id(farm_token_id); + + sc.energy_factory_address() + .set(managed_address!(energy_factory_address)); + + sc.state().set(State::Active); + }) + .assert_ok(); + + let farm_token_roles = [ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ]; + b_mock.set_esdt_local_roles( + farm_wrapper.address_ref(), + LP_FARM_TOKEN_ID, + &farm_token_roles[..], + ); + + let farming_token_roles = [EsdtLocalRole::Burn]; + b_mock.set_esdt_local_roles( + farm_wrapper.address_ref(), + LP_TOKEN_ID, + &farming_token_roles[..], + ); + + let reward_token_roles = [EsdtLocalRole::Mint]; + b_mock.set_esdt_local_roles( + farm_wrapper.address_ref(), + RIDE_TOKEN_ID, + &reward_token_roles[..], + ); + + farm_wrapper +} + +pub fn setup_energy_factory( + owner_addr: &Address, + b_mock: &mut BlockchainStateWrapper, + energy_factory_builder: EnergyFactoryObjBuilder, +) -> ContractObjWrapper, EnergyFactoryObjBuilder> +where + EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, +{ + let rust_zero = rust_biguint!(0u64); + let energy_factory_wrapper = b_mock.create_sc_account( + &rust_zero, + Some(owner_addr), + energy_factory_builder, + "energy factory", + ); + + b_mock + .execute_tx(owner_addr, &energy_factory_wrapper, &rust_zero, |sc| { + let mut lock_options = MultiValueEncoded::new(); + for (option, penalty) in LOCK_OPTIONS.iter().zip(PENALTY_PERCENTAGES.iter()) { + lock_options.push((*option, *penalty).into()); + } + + sc.init( + managed_token_id!(LOCKED_TOKEN_ID), + managed_token_id!(LEGACY_LOCKED_TOKEN_ID), + managed_address!(energy_factory_wrapper.address_ref()), + 0, + lock_options, + ); + + sc.base_asset_token_id() + .set(managed_token_id!(MEX_TOKEN_ID)); + sc.locked_token() + .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); + sc.set_paused(false); + }) + .assert_ok(); + + b_mock.set_esdt_local_roles( + energy_factory_wrapper.address_ref(), + MEX_TOKEN_ID, + &[EsdtLocalRole::Mint, EsdtLocalRole::Burn], + ); + b_mock.set_esdt_local_roles( + energy_factory_wrapper.address_ref(), + LOCKED_TOKEN_ID, + &[ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + EsdtLocalRole::Transfer, + ], + ); + b_mock.set_esdt_local_roles( + energy_factory_wrapper.address_ref(), + LEGACY_LOCKED_TOKEN_ID, + &[EsdtLocalRole::NftBurn], + ); + + energy_factory_wrapper +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs new file mode 100644 index 000000000..cc134820c --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs @@ -0,0 +1,222 @@ +use multiversx_sc::types::Address; +use multiversx_sc_scenario::{ + managed_biguint, rust_biguint, + testing_framework::{BlockchainStateWrapper, ContractObjWrapper}, + DebugApi, +}; + +use farm_staking::*; +use farm_staking_proxy_legacy::*; +use token_attributes::UnbondSftAttributes; +use unbond_farm::UnbondFarmModule; + +use crate::{ + constants::*, + staking_farm_with_lp_external_contracts::{setup_energy_factory, setup_lp_farm, setup_pair}, + staking_farm_with_lp_staking_contract_setup::{ + add_proxy_to_whitelist, setup_proxy, setup_staking_farm, + }, +}; + +pub struct NonceAmountPair { + pub nonce: u64, + pub amount: u64, +} + +pub struct FarmStakingSetup< + PairObjBuilder, + FarmObjBuilder, + EnergyFactoryObjBuilder, + StakingContractObjBuilder, + ProxyContractObjBuilder, +> where + PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, + FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, + EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, + StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, + ProxyContractObjBuilder: + 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, +{ + pub owner_addr: Address, + pub user_addr: Address, + pub b_mock: BlockchainStateWrapper, + pub pair_wrapper: ContractObjWrapper, PairObjBuilder>, + pub lp_farm_wrapper: + ContractObjWrapper, FarmObjBuilder>, + pub energy_factory_wrapper: + ContractObjWrapper, EnergyFactoryObjBuilder>, + pub staking_farm_wrapper: + ContractObjWrapper, StakingContractObjBuilder>, + pub proxy_wrapper: ContractObjWrapper< + farm_staking_proxy_legacy::ContractObj, + ProxyContractObjBuilder, + >, +} + +impl< + PairObjBuilder, + FarmObjBuilder, + EnergyFactoryObjBuilder, + StakingContractObjBuilder, + ProxyContractObjBuilder, + > + FarmStakingSetup< + PairObjBuilder, + FarmObjBuilder, + EnergyFactoryObjBuilder, + StakingContractObjBuilder, + ProxyContractObjBuilder, + > +where + PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, + FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, + EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, + StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, + ProxyContractObjBuilder: + 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, +{ + pub fn new( + pair_builder: PairObjBuilder, + lp_farm_builder: FarmObjBuilder, + energy_factory_builder: EnergyFactoryObjBuilder, + staking_farm_builder: StakingContractObjBuilder, + proxy_builder: ProxyContractObjBuilder, + ) -> Self { + let rust_zero = rust_biguint!(0u64); + let mut b_mock = BlockchainStateWrapper::new(); + let owner_addr = b_mock.create_user_account(&rust_zero); + let user_addr = b_mock.create_user_account(&rust_biguint!(100_000_000)); + + let pair_wrapper = setup_pair(&owner_addr, &user_addr, &mut b_mock, pair_builder); + let energy_factory_wrapper = + setup_energy_factory(&owner_addr, &mut b_mock, energy_factory_builder); + let lp_farm_wrapper = setup_lp_farm( + &owner_addr, + energy_factory_wrapper.address_ref(), + &mut b_mock, + lp_farm_builder, + ); + + let staking_farm_wrapper = + setup_staking_farm(&owner_addr, &mut b_mock, staking_farm_builder); + let proxy_wrapper = setup_proxy( + &owner_addr, + lp_farm_wrapper.address_ref(), + staking_farm_wrapper.address_ref(), + pair_wrapper.address_ref(), + &mut b_mock, + proxy_builder, + ); + + add_proxy_to_whitelist( + &owner_addr, + proxy_wrapper.address_ref(), + &mut b_mock, + &lp_farm_wrapper, + &staking_farm_wrapper, + ); + + FarmStakingSetup { + owner_addr, + user_addr, + b_mock, + pair_wrapper, + lp_farm_wrapper, + energy_factory_wrapper, + staking_farm_wrapper, + proxy_wrapper, + } + } + + pub fn unstake_proxy( + &mut self, + dual_yield_token_nonce: u64, + dual_yield_token_amount: u64, + expected_wegld_amount: u64, + expected_lp_farm_rewards: u64, + expected_staking_rewards: u64, + expected_unbond_token_amount: u64, + expected_unbond_token_unlock_epoch: u64, + ) -> u64 { + let mut unbond_token_nonce = 0; + + self.b_mock + .execute_esdt_transfer( + &self.user_addr, + &self.proxy_wrapper, + DUAL_YIELD_TOKEN_ID, + dual_yield_token_nonce, + &rust_biguint!(dual_yield_token_amount), + |sc| { + let received_tokens = sc + .unstake_farm_tokens(managed_biguint!(1), managed_biguint!(1)) + .to_vec(); + let mut vec_index = 0; + + if expected_wegld_amount > 0 { + let wegld_payment = received_tokens.get(vec_index); + assert_eq!(wegld_payment.amount, expected_wegld_amount); + + vec_index += 1; + } + + if expected_lp_farm_rewards > 0 { + let lp_farm_rewards = received_tokens.get(vec_index); + assert_eq!(lp_farm_rewards.amount, expected_lp_farm_rewards); + + vec_index += 1; + } + + if expected_staking_rewards > 0 { + let staking_rewards = received_tokens.get(vec_index); + assert_eq!(staking_rewards.amount, expected_staking_rewards); + + vec_index += 1; + } + + let unbond_tokens = received_tokens.get(vec_index); + assert_eq!(unbond_tokens.amount, expected_unbond_token_amount); + + unbond_token_nonce = unbond_tokens.token_nonce; + }, + ) + .assert_ok(); + + self.b_mock.execute_in_managed_environment(|| { + let expected_attributes = UnbondSftAttributes { + unlock_epoch: expected_unbond_token_unlock_epoch, + }; + + self.b_mock.check_nft_balance( + &self.user_addr, + STAKING_FARM_TOKEN_ID, + unbond_token_nonce, + &rust_biguint!(expected_unbond_token_amount), + Some(&expected_attributes), + ); + }); + + unbond_token_nonce + } + + pub fn unbond_proxy( + &mut self, + unbond_token_nonce: u64, + unbond_token_amount: u64, + expected_token_out_amount: u64, + ) { + self.b_mock + .execute_esdt_transfer( + &self.user_addr, + &self.staking_farm_wrapper, + STAKING_FARM_TOKEN_ID, + unbond_token_nonce, + &rust_biguint!(unbond_token_amount), + |sc| { + let received_tokens = sc.unbond_farm(); + assert_eq!(received_tokens.amount, expected_token_out_amount); + }, + ) + .assert_ok(); + } +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs new file mode 100644 index 000000000..0cca69853 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs @@ -0,0 +1,153 @@ +use external_contracts_interactions::ExternalContractsInteractionsModule; +use farm_token::FarmTokenModule; +use lp_farm_token::LpFarmTokenModule; +use multiversx_sc::{ + imports::StorageTokenWrapper, + types::{Address, EsdtLocalRole, MultiValueEncoded}, +}; +use multiversx_sc_scenario::{ + managed_address, managed_biguint, managed_token_id, rust_biguint, + testing_framework::{BlockchainStateWrapper, ContractObjWrapper}, + DebugApi, +}; + +use farm_staking::*; + +use farm_staking_proxy_legacy::dual_yield_token::DualYieldTokenModule; +use farm_staking_proxy_legacy::*; +use pausable::{PausableModule, State}; +use sc_whitelist_module::SCWhitelistModule; + +use crate::constants::*; + +pub fn setup_staking_farm( + owner_addr: &Address, + b_mock: &mut BlockchainStateWrapper, + builder: StakingContractObjBuilder, +) -> ContractObjWrapper, StakingContractObjBuilder> +where + StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, +{ + let rust_zero = rust_biguint!(0u64); + let farm_staking_wrapper = + b_mock.create_sc_account(&rust_zero, Some(owner_addr), builder, PROXY_WASM_PATH); + + b_mock + .execute_tx(owner_addr, &farm_staking_wrapper, &rust_zero, |sc| { + let farming_token_id = managed_token_id!(STAKING_TOKEN_ID); + let div_const = managed_biguint!(DIVISION_SAFETY_CONSTANT); + let max_apr = managed_biguint!(MAX_APR); + + sc.init( + farming_token_id, + div_const, + max_apr, + UNBOND_EPOCHS, + managed_address!(owner_addr), + MultiValueEncoded::new(), + ); + + sc.farm_token() + .set_token_id(managed_token_id!(STAKING_FARM_TOKEN_ID)); + + sc.state().set(State::Active); + }) + .assert_ok(); + + b_mock.set_esdt_balance( + farm_staking_wrapper.address_ref(), + STAKING_REWARD_TOKEN_ID, + &rust_biguint!(REWARD_CAPACITY), + ); + + let farm_token_roles = [ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ]; + b_mock.set_esdt_local_roles( + farm_staking_wrapper.address_ref(), + STAKING_FARM_TOKEN_ID, + &farm_token_roles[..], + ); + + farm_staking_wrapper +} + +pub fn add_proxy_to_whitelist( + owner_addr: &Address, + proxy_address: &Address, + b_mock: &mut BlockchainStateWrapper, + lp_farm_builder: &ContractObjWrapper< + farm_with_locked_rewards::ContractObj, + FarmObjBuilder, + >, + staking_farm_builder: &ContractObjWrapper< + farm_staking::ContractObj, + StakingContractObjBuilder, + >, +) where + FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, + StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, +{ + let rust_zero = rust_biguint!(0u64); + b_mock + .execute_tx(owner_addr, lp_farm_builder, &rust_zero, |sc| { + sc.add_sc_address_to_whitelist(managed_address!(proxy_address)); + }) + .assert_ok(); + b_mock + .execute_tx(owner_addr, staking_farm_builder, &rust_zero, |sc| { + sc.add_sc_address_to_whitelist(managed_address!(proxy_address)); + }) + .assert_ok(); +} + +pub fn setup_proxy( + owner_addr: &Address, + lp_farm_address: &Address, + staking_farm_address: &Address, + pair_address: &Address, + b_mock: &mut BlockchainStateWrapper, + builder: ProxyContractObjBuilder, +) -> ContractObjWrapper, ProxyContractObjBuilder> +where + ProxyContractObjBuilder: + 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, +{ + let rust_zero = rust_biguint!(0u64); + let proxy_wrapper = + b_mock.create_sc_account(&rust_zero, Some(owner_addr), builder, PROXY_WASM_PATH); + + b_mock + .execute_tx(&owner_addr, &proxy_wrapper, &rust_zero, |sc| { + sc.init(); + + sc.pair_address().set(managed_address!(pair_address)); + sc.lp_farm_address().set(managed_address!(lp_farm_address)); + sc.lp_farm_token_id() + .set(managed_token_id!(LP_FARM_TOKEN_ID)); + sc.staking_farm_address() + .set(managed_address!(staking_farm_address)); + sc.staking_token_id() + .set(managed_token_id!(STAKING_TOKEN_ID)); + sc.staking_farm_token_id() + .set(managed_token_id!(STAKING_FARM_TOKEN_ID)); + sc.dual_yield_token_id() + .set(&managed_token_id!(DUAL_YIELD_TOKEN_ID)); + }) + .assert_ok(); + + let dual_yield_token_roles = [ + EsdtLocalRole::NftCreate, + EsdtLocalRole::NftAddQuantity, + EsdtLocalRole::NftBurn, + ]; + b_mock.set_esdt_local_roles( + proxy_wrapper.address_ref(), + DUAL_YIELD_TOKEN_ID, + &dual_yield_token_roles[..], + ); + + proxy_wrapper +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock index 1c15ac5fa..cb02bd384 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock @@ -20,6 +20,13 @@ version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +[[package]] +name = "common-types" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + [[package]] name = "common_errors" version = "0.0.0" @@ -38,19 +45,163 @@ dependencies = [ "unwrappable", ] +[[package]] +name = "config" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "multiversx-sc", + "pausable", + "permissions_module", + "token_send", +] + +[[package]] +name = "contexts" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "config", + "farm_token", + "multiversx-sc", + "multiversx-sc-modules", + "pausable", + "permissions_module", + "rewards", + "token_merge_helper", + "token_send", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + [[package]] name = "endian-type" version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" +[[package]] +name = "energy-factory" +version = "0.0.0" +dependencies = [ + "common_structs", + "legacy_token_decode_module", + "math", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "sc_whitelist_module", + "simple-lock", + "unwrappable", + "utils", +] + +[[package]] +name = "energy-query" +version = "0.0.0" +dependencies = [ + "energy-factory", + "multiversx-sc", +] + +[[package]] +name = "events" +version = "0.0.0" +dependencies = [ + "common_structs", + "contexts", + "multiversx-sc", +] + +[[package]] +name = "farm" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "config", + "contexts", + "energy-query", + "events", + "farm-boosted-yields", + "farm_base_impl", + "farm_token", + "fixed-supply-token", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "pair", + "pausable", + "permissions_module", + "rewards", + "sc_whitelist_module", + "token_send", + "utils", + "week-timekeeping", + "weekly-rewards-splitting", +] + +[[package]] +name = "farm-boosted-yields" +version = "0.0.0" +dependencies = [ + "common-types", + "config", + "energy-query", + "multiversx-sc", + "pausable", + "permissions_module", + "week-timekeeping", + "weekly-rewards-splitting", +] + +[[package]] +name = "farm-staking" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "config", + "contexts", + "energy-factory", + "energy-query", + "events", + "farm", + "farm-boosted-yields", + "farm_base_impl", + "farm_token", + "fixed-supply-token", + "math", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "pair", + "pausable", + "permissions_module", + "rewards", + "sc_whitelist_module", + "token_send", + "utils", + "week-timekeeping", + "weekly-rewards-splitting", +] + [[package]] name = "farm-staking-proxy-legacy" version = "0.0.0" dependencies = [ "common_structs", + "farm-staking", + "farm-with-locked-rewards", "multiversx-sc", "multiversx-sc-modules", + "pair", "token_merge_helper", ] @@ -62,6 +213,90 @@ dependencies = [ "multiversx-sc-wasm-adapter", ] +[[package]] +name = "farm-with-locked-rewards" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "config", + "contexts", + "energy-factory", + "energy-query", + "events", + "farm", + "farm-boosted-yields", + "farm_base_impl", + "farm_token", + "fixed-supply-token", + "locking_module", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "pausable", + "permissions_module", + "rewards", + "sc_whitelist_module", + "token_send", + "utils", + "week-timekeeping", + "weekly-rewards-splitting", +] + +[[package]] +name = "farm_base_impl" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "config", + "contexts", + "events", + "farm_token", + "fixed-supply-token", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "pausable", + "permissions_module", + "rewards", + "token_merge_helper", + "token_send", + "utils", +] + +[[package]] +name = "farm_token" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "config", + "multiversx-sc", + "multiversx-sc-modules", + "pausable", + "permissions_module", + "token_send", +] + +[[package]] +name = "fees-collector" +version = "0.0.0" +dependencies = [ + "common-types", + "common_errors", + "energy-factory", + "energy-query", + "locking_module", + "multiversx-sc", + "multiversx-sc-modules", + "sc_whitelist_module", + "simple-lock", + "utils", + "week-timekeeping", + "weekly-rewards-splitting", +] + [[package]] name = "fixed-supply-token" version = "0.0.0" @@ -81,6 +316,33 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" +[[package]] +name = "itertools" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +dependencies = [ + "either", +] + +[[package]] +name = "legacy_token_decode_module" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "utils", +] + +[[package]] +name = "locking_module" +version = "0.0.0" +dependencies = [ + "energy-factory", + "multiversx-sc", + "simple-lock", +] + [[package]] name = "math" version = "0.0.0" @@ -181,6 +443,39 @@ dependencies = [ "autocfg", ] +[[package]] +name = "pair" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "fees-collector", + "itertools", + "multiversx-sc", + "pausable", + "permissions_module", + "simple-lock", + "token_send", + "utils", +] + +[[package]] +name = "pausable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "permissions_module", +] + +[[package]] +name = "permissions_module" +version = "0.0.0" +dependencies = [ + "bitflags", + "common_errors", + "multiversx-sc", +] + [[package]] name = "proc-macro2" version = "1.0.82" @@ -209,6 +504,38 @@ dependencies = [ "nibble_vec", ] +[[package]] +name = "rewards" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "config", + "farm_token", + "multiversx-sc", + "multiversx-sc-modules", + "pausable", + "permissions_module", + "token_send", +] + +[[package]] +name = "sc_whitelist_module" +version = "0.0.0" +dependencies = [ + "common_errors", + "multiversx-sc", +] + +[[package]] +name = "simple-lock" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "multiversx-sc-modules", +] + [[package]] name = "smallvec" version = "1.11.2" @@ -234,6 +561,15 @@ dependencies = [ "multiversx-sc", ] +[[package]] +name = "token_send" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "multiversx-sc", +] + [[package]] name = "unicode-ident" version = "1.0.12" @@ -252,3 +588,33 @@ version = "0.0.0" dependencies = [ "multiversx-sc", ] + +[[package]] +name = "utils" +version = "0.0.0" +dependencies = [ + "common_structs", + "fixed-supply-token", + "mergeable", + "multiversx-sc", +] + +[[package]] +name = "week-timekeeping" +version = "0.0.0" +dependencies = [ + "common-types", + "multiversx-sc", +] + +[[package]] +name = "weekly-rewards-splitting" +version = "0.0.0" +dependencies = [ + "common-types", + "energy-query", + "math", + "multiversx-sc", + "unwrappable", + "week-timekeeping", +] From 2231e505aac10591377a6731fcfefc0df77c8571 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 28 Jun 2024 00:37:05 +0300 Subject: [PATCH 069/103] clippy fixes --- .../tests/constants/mod.rs | 4 ++-- .../tests/staking_farm_with_lp.rs | 2 -- .../mod.rs | 24 +++++++++---------- .../mod.rs | 21 ---------------- .../mod.rs | 2 +- 5 files changed, 15 insertions(+), 38 deletions(-) diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs index b9eef5056..8be5d8cbd 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs @@ -1,6 +1,6 @@ // Pair constants -pub const PAIR_WASM_PATH: &'static str = "pair/output/pair.wasm"; +pub const PAIR_WASM_PATH: &str = "pair/output/pair.wasm"; pub const WEGLD_TOKEN_ID: &[u8] = b"WEGLD-abcdef"; pub const RIDE_TOKEN_ID: &[u8] = b"RIDE-abcdef"; pub const LP_TOKEN_ID: &[u8] = b"LPTOK-abcdef"; // also farming token ID for LP farm @@ -15,7 +15,7 @@ pub const BLOCK_NONCE_AFTER_PAIR_SETUP: u64 = 100; // LP farm constants -pub const FARM_WASM_PATH: &'static str = "farm/output/farm.wasm"; +pub const FARM_WASM_PATH: &str = "farm/output/farm.wasm"; pub const LP_FARM_TOKEN_ID: &[u8] = b"LPFARM-abcdef"; pub const DIVISION_SAFETY_CONSTANT: u64 = 1_000_000_000_000; pub const MIN_FARMING_EPOCHS: u8 = 2; diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs index c7f92adf0..6e3a01f00 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs @@ -138,8 +138,6 @@ fn test_unstake_from_legacy_proxy() { 1, dual_yield_token_amount, expected_token_amount, - 0, - 0, expected_token_amount, 30, ); diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs index 94306f44e..026fea631 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs @@ -36,12 +36,12 @@ where b_mock.create_sc_account(&rust_zero, Some(owner_addr), pair_builder, PAIR_WASM_PATH); b_mock - .execute_tx(&owner_addr, &pair_wrapper, &rust_zero, |sc| { + .execute_tx(owner_addr, &pair_wrapper, &rust_zero, |sc| { let first_token_id = managed_token_id!(WEGLD_TOKEN_ID); let second_token_id = managed_token_id!(RIDE_TOKEN_ID); - let router_address = managed_address!(&owner_addr); - let router_owner_address = managed_address!(&owner_addr); - let initial_liquidity_adder = managed_address!(&owner_addr); + let router_address = managed_address!(owner_addr); + let router_owner_address = managed_address!(owner_addr); + let initial_liquidity_adder = managed_address!(owner_addr); let total_fee_percent = 300u64; let special_fee_percent = 50u64; @@ -66,12 +66,12 @@ where // set user balance b_mock.set_esdt_balance( - &user_addr, + user_addr, WEGLD_TOKEN_ID, &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), ); b_mock.set_esdt_balance( - &user_addr, + user_addr, RIDE_TOKEN_ID, &rust_biguint!(USER_TOTAL_RIDE_TOKENS), ); @@ -79,12 +79,12 @@ where b_mock.set_block_nonce(BLOCK_NONCE_FIRST_ADD_LIQ); b_mock.set_esdt_balance( - &owner_addr, + owner_addr, WEGLD_TOKEN_ID, &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), ); b_mock.set_esdt_balance( - &owner_addr, + owner_addr, RIDE_TOKEN_ID, &rust_biguint!(USER_TOTAL_RIDE_TOKENS), ); @@ -102,7 +102,7 @@ where }, ]; b_mock - .execute_esdt_multi_transfer(&owner_addr, &pair_wrapper, &payments, |sc| { + .execute_esdt_multi_transfer(owner_addr, &pair_wrapper, &payments, |sc| { sc.add_initial_liquidity(); }) .assert_ok(); @@ -110,7 +110,7 @@ where b_mock.set_block_nonce(BLOCK_NONCE_SECOND_ADD_LIQ); b_mock - .execute_esdt_multi_transfer(&owner_addr, &pair_wrapper, &payments, |sc| { + .execute_esdt_multi_transfer(owner_addr, &pair_wrapper, &payments, |sc| { sc.add_liquidity(managed_biguint!(1u64), managed_biguint!(1u64)); }) .assert_ok(); @@ -131,12 +131,12 @@ where { let rust_zero = rust_biguint!(0u64); let farm_wrapper = - b_mock.create_sc_account(&rust_zero, Some(&owner_addr), farm_builder, FARM_WASM_PATH); + b_mock.create_sc_account(&rust_zero, Some(owner_addr), farm_builder, FARM_WASM_PATH); // init farm contract b_mock - .execute_tx(&owner_addr, &farm_wrapper, &rust_zero, |sc| { + .execute_tx(owner_addr, &farm_wrapper, &rust_zero, |sc| { let reward_token_id = managed_token_id!(RIDE_TOKEN_ID); let farming_token_id = managed_token_id!(LP_TOKEN_ID); let division_safety_constant = managed_biguint!(DIVISION_SAFETY_CONSTANT); diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs index cc134820c..6a2406a63 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs @@ -18,11 +18,6 @@ use crate::{ }, }; -pub struct NonceAmountPair { - pub nonce: u64, - pub amount: u64, -} - pub struct FarmStakingSetup< PairObjBuilder, FarmObjBuilder, @@ -133,8 +128,6 @@ where dual_yield_token_nonce: u64, dual_yield_token_amount: u64, expected_wegld_amount: u64, - expected_lp_farm_rewards: u64, - expected_staking_rewards: u64, expected_unbond_token_amount: u64, expected_unbond_token_unlock_epoch: u64, ) -> u64 { @@ -160,20 +153,6 @@ where vec_index += 1; } - if expected_lp_farm_rewards > 0 { - let lp_farm_rewards = received_tokens.get(vec_index); - assert_eq!(lp_farm_rewards.amount, expected_lp_farm_rewards); - - vec_index += 1; - } - - if expected_staking_rewards > 0 { - let staking_rewards = received_tokens.get(vec_index); - assert_eq!(staking_rewards.amount, expected_staking_rewards); - - vec_index += 1; - } - let unbond_tokens = received_tokens.get(vec_index); assert_eq!(unbond_tokens.amount, expected_unbond_token_amount); diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs index 0cca69853..e4ed2862f 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs @@ -120,7 +120,7 @@ where b_mock.create_sc_account(&rust_zero, Some(owner_addr), builder, PROXY_WASM_PATH); b_mock - .execute_tx(&owner_addr, &proxy_wrapper, &rust_zero, |sc| { + .execute_tx(owner_addr, &proxy_wrapper, &rust_zero, |sc| { sc.init(); sc.pair_address().set(managed_address!(pair_address)); From 72f8304138f905b9cc82983389d7980d3738a3dc Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 2 Jul 2024 02:06:04 +0300 Subject: [PATCH 070/103] added legacy farm v1.3 contract --- Cargo.lock | 19 +- Cargo.toml | 2 + .../farm-staking-proxy-legacy/Cargo.toml | 4 +- .../src/external_contracts_interactions.rs | 33 +- .../farm-staking-proxy-legacy/src/lib.rs | 10 +- .../tests/constants/mod.rs | 96 +- .../tests/staking_farm_with_lp.rs | 264 +- .../mod.rs | 506 ++-- .../mod.rs | 402 +-- .../mod.rs | 306 +- .../farm-staking-proxy-legacy/wasm/Cargo.lock | 27 +- .../farm-staking-proxy-legacy/wasm/src/lib.rs | 4 +- legacy-contracts/farm-v-13/Cargo.lock | 2593 +++++++++++++++++ legacy-contracts/farm-v-13/Cargo.toml | 18 + legacy-contracts/farm-v-13/meta/Cargo.toml | 12 + legacy-contracts/farm-v-13/meta/src/main.rs | 3 + legacy-contracts/farm-v-13/multiversx.json | 3 + legacy-contracts/farm-v-13/src/lib.rs | 58 + legacy-contracts/farm-v-13/wasm/Cargo.lock | 188 ++ legacy-contracts/farm-v-13/wasm/Cargo.toml | 34 + legacy-contracts/farm-v-13/wasm/src/lib.rs | 29 + 21 files changed, 3760 insertions(+), 851 deletions(-) create mode 100644 legacy-contracts/farm-v-13/Cargo.lock create mode 100644 legacy-contracts/farm-v-13/Cargo.toml create mode 100644 legacy-contracts/farm-v-13/meta/Cargo.toml create mode 100644 legacy-contracts/farm-v-13/meta/src/main.rs create mode 100644 legacy-contracts/farm-v-13/multiversx.json create mode 100644 legacy-contracts/farm-v-13/src/lib.rs create mode 100644 legacy-contracts/farm-v-13/wasm/Cargo.lock create mode 100644 legacy-contracts/farm-v-13/wasm/Cargo.toml create mode 100644 legacy-contracts/farm-v-13/wasm/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index 5d3ca5085..9b2bb784e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -892,7 +892,7 @@ dependencies = [ "energy-factory", "energy-query", "farm-staking", - "farm-with-locked-rewards", + "farm-v-13", "farm_token", "hex", "locking_module", @@ -924,6 +924,23 @@ dependencies = [ "multiversx-sc-meta", ] +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v-13-meta" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-meta", +] + [[package]] name = "farm-with-locked-rewards" version = "0.0.0" diff --git a/Cargo.toml b/Cargo.toml index 1b7132c07..537839c76 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -41,6 +41,8 @@ members = [ "legacy-contracts/simple-lock-legacy/meta", "legacy-contracts/farm-staking-proxy-legacy", "legacy-contracts/farm-staking-proxy-legacy/meta", + "legacy-contracts/farm-v-13", + "legacy-contracts/farm-v-13/meta", "locked-asset/", "locked-asset/distribution", diff --git a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml index 71a633eec..d85ae3897 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml @@ -27,8 +27,8 @@ path = "../../farm-staking/farm-staking" [dependencies.pair] path = "../../dex/pair" -[dependencies.farm-with-locked-rewards] -path = "../../dex/farm-with-locked-rewards" +[dependencies.farm-v-13] +path = "../farm-v-13" [dev-dependencies.energy-factory] path = "../../locked-asset/energy-factory" diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs b/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs index 3c4c92000..11c226cb8 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs @@ -3,7 +3,7 @@ multiversx_sc::imports!(); use common_structs::{RawResultWrapper, RawResultsType}; use farm_staking::unstake_farm::ProxyTrait as _; use multiversx_sc::storage::StorageKey; -use pair::{pair_actions::remove_liq::ProxyTrait as _, safe_price_view::ProxyTrait as _}; +use pair::pair_actions::remove_liq::ProxyTrait as _; use crate::result_types::*; @@ -17,7 +17,6 @@ pub trait ExternalContractsInteractionsModule: fn lp_farm_exit( &self, - orig_caller: ManagedAddress, lp_farm_token_nonce: u64, lp_farm_token_amount: BigUint, ) -> LpFarmExitResult { @@ -25,7 +24,7 @@ pub trait ExternalContractsInteractionsModule: let lp_farm_address = self.lp_farm_address().get(); let raw_results: RawResultsType = self .lp_farm_proxy_obj(lp_farm_address) - .exit_farm_endpoint(OptionalValue::Some(orig_caller)) + .exit_farm(OptionalValue::::None) .with_esdt_transfer((lp_farm_token_id, lp_farm_token_nonce, lp_farm_token_amount)) .execute_on_dest_context(); @@ -136,39 +135,13 @@ pub trait ExternalContractsInteractionsModule: } } - fn get_lp_tokens_safe_price(&self, lp_tokens_amount: BigUint) -> BigUint { - let pair_address = self.pair_address().get(); - let raw_results: RawResultsType = self - .pair_proxy_obj(pair_address) - .update_and_get_tokens_for_given_position_with_safe_price(lp_tokens_amount) - .execute_on_dest_context(); - - let mut results_wrapper = RawResultWrapper::new(raw_results); - results_wrapper.trim_results_front(2); - - let first_token_info: EsdtTokenPayment = results_wrapper.decode_next_result(); - let second_token_info: EsdtTokenPayment = results_wrapper.decode_next_result(); - - let staking_token_id = self.staking_token_id().get(); - if first_token_info.token_identifier == staking_token_id { - first_token_info.amount - } else if second_token_info.token_identifier == staking_token_id { - second_token_info.amount - } else { - sc_panic!("Invalid Pair contract called"); - } - } - // proxies #[proxy] fn staking_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_staking::Proxy; #[proxy] - fn lp_farm_proxy_obj( - &self, - sc_address: ManagedAddress, - ) -> farm_with_locked_rewards::Proxy; + fn lp_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_v_13::Proxy; #[proxy] fn pair_proxy_obj(&self, sc_address: ManagedAddress) -> pair::Proxy; diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs b/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs index 211e4ec0e..361338441 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs @@ -19,6 +19,9 @@ pub trait FarmStakingProxy: #[init] fn init(&self) {} + #[upgrade] + fn upgrade(&self) {} + #[payable("*")] #[endpoint(unstakeFarmTokens)] fn unstake_farm_tokens( @@ -34,11 +37,8 @@ pub trait FarmStakingProxy: let attributes = self.get_dual_yield_token_attributes(payment_nonce); let lp_farm_token_amount = self.get_lp_farm_token_amount_equivalent(&attributes, &payment_amount); - let lp_farm_exit_result = self.lp_farm_exit( - caller.clone(), - attributes.lp_farm_token_nonce, - lp_farm_token_amount, - ); + let lp_farm_exit_result = + self.lp_farm_exit(attributes.lp_farm_token_nonce, lp_farm_token_amount); let remove_liq_result = self.pair_remove_liquidity( lp_farm_exit_result.lp_tokens, diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs index 8be5d8cbd..f59a14a45 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs @@ -1,48 +1,48 @@ -// Pair constants - -pub const PAIR_WASM_PATH: &str = "pair/output/pair.wasm"; -pub const WEGLD_TOKEN_ID: &[u8] = b"WEGLD-abcdef"; -pub const RIDE_TOKEN_ID: &[u8] = b"RIDE-abcdef"; -pub const LP_TOKEN_ID: &[u8] = b"LPTOK-abcdef"; // also farming token ID for LP farm - -pub const USER_TOTAL_WEGLD_TOKENS: u64 = 2_000_000_000; -pub const USER_TOTAL_RIDE_TOKENS: u64 = 2_000_000_000; -pub const USER_TOTAL_LP_TOKENS: u64 = 1_001_000_000; - -pub const BLOCK_NONCE_FIRST_ADD_LIQ: u64 = 5; -pub const BLOCK_NONCE_SECOND_ADD_LIQ: u64 = 6; -pub const BLOCK_NONCE_AFTER_PAIR_SETUP: u64 = 100; - -// LP farm constants - -pub const FARM_WASM_PATH: &str = "farm/output/farm.wasm"; -pub const LP_FARM_TOKEN_ID: &[u8] = b"LPFARM-abcdef"; -pub const DIVISION_SAFETY_CONSTANT: u64 = 1_000_000_000_000; -pub const MIN_FARMING_EPOCHS: u8 = 2; -pub const PENALTY_PERCENT: u64 = 10; -pub const LP_FARM_PER_BLOCK_REWARD_AMOUNT: u64 = 5_000; - -// Energy factory constants - -pub const EPOCHS_IN_YEAR: u64 = 360; -pub static MEX_TOKEN_ID: &[u8] = b"MEX-123456"; -pub static LOCKED_TOKEN_ID: &[u8] = b"LOCKED-123456"; -pub static LEGACY_LOCKED_TOKEN_ID: &[u8] = b"LEGACY-123456"; -pub static LOCK_OPTIONS: &[u64] = &[EPOCHS_IN_YEAR, 5 * EPOCHS_IN_YEAR, 10 * EPOCHS_IN_YEAR]; // 1, 5 or 10 years -pub static PENALTY_PERCENTAGES: &[u64] = &[4_000, 6_000, 8_000]; - -// Staking farm constants - -pub const STAKING_FARM_WASM_PATH: &str = "farm-staking/output/farm-staking.wasm"; -pub const STAKING_REWARD_TOKEN_ID: &[u8] = RIDE_TOKEN_ID; -pub const STAKING_TOKEN_ID: &[u8] = RIDE_TOKEN_ID; -pub const STAKING_FARM_TOKEN_ID: &[u8] = b"STKFARM-abcdef"; -pub const MAX_APR: u64 = 5_000; // 50% -pub const UNBOND_EPOCHS: u64 = 10; -pub const STAKING_FARM_PER_BLOCK_REWARD_AMOUNT: u64 = 1_000; -pub const REWARD_CAPACITY: u64 = 1_000_000_000_000; - -// Proxy constants - -pub const PROXY_WASM_PATH: &str = "farm-staking-proxy/output/farm-staking-proxy"; -pub const DUAL_YIELD_TOKEN_ID: &[u8] = b"DYIELD-abcdef"; +// // Pair constants + +// pub const PAIR_WASM_PATH: &str = "pair/output/pair.wasm"; +// pub const WEGLD_TOKEN_ID: &[u8] = b"WEGLD-abcdef"; +// pub const RIDE_TOKEN_ID: &[u8] = b"RIDE-abcdef"; +// pub const LP_TOKEN_ID: &[u8] = b"LPTOK-abcdef"; // also farming token ID for LP farm + +// pub const USER_TOTAL_WEGLD_TOKENS: u64 = 2_000_000_000; +// pub const USER_TOTAL_RIDE_TOKENS: u64 = 2_000_000_000; +// pub const USER_TOTAL_LP_TOKENS: u64 = 1_001_000_000; + +// pub const BLOCK_NONCE_FIRST_ADD_LIQ: u64 = 5; +// pub const BLOCK_NONCE_SECOND_ADD_LIQ: u64 = 6; +// pub const BLOCK_NONCE_AFTER_PAIR_SETUP: u64 = 100; + +// // LP farm constants + +// pub const FARM_WASM_PATH: &str = "farm/output/farm.wasm"; +// pub const LP_FARM_TOKEN_ID: &[u8] = b"LPFARM-abcdef"; +// pub const DIVISION_SAFETY_CONSTANT: u64 = 1_000_000_000_000; +// pub const MIN_FARMING_EPOCHS: u8 = 2; +// pub const PENALTY_PERCENT: u64 = 10; +// pub const LP_FARM_PER_BLOCK_REWARD_AMOUNT: u64 = 5_000; + +// // Energy factory constants + +// pub const EPOCHS_IN_YEAR: u64 = 360; +// pub static MEX_TOKEN_ID: &[u8] = b"MEX-123456"; +// pub static LOCKED_TOKEN_ID: &[u8] = b"LOCKED-123456"; +// pub static LEGACY_LOCKED_TOKEN_ID: &[u8] = b"LEGACY-123456"; +// pub static LOCK_OPTIONS: &[u64] = &[EPOCHS_IN_YEAR, 5 * EPOCHS_IN_YEAR, 10 * EPOCHS_IN_YEAR]; // 1, 5 or 10 years +// pub static PENALTY_PERCENTAGES: &[u64] = &[4_000, 6_000, 8_000]; + +// // Staking farm constants + +// pub const STAKING_FARM_WASM_PATH: &str = "farm-staking/output/farm-staking.wasm"; +// pub const STAKING_REWARD_TOKEN_ID: &[u8] = RIDE_TOKEN_ID; +// pub const STAKING_TOKEN_ID: &[u8] = RIDE_TOKEN_ID; +// pub const STAKING_FARM_TOKEN_ID: &[u8] = b"STKFARM-abcdef"; +// pub const MAX_APR: u64 = 5_000; // 50% +// pub const UNBOND_EPOCHS: u64 = 10; +// pub const STAKING_FARM_PER_BLOCK_REWARD_AMOUNT: u64 = 1_000; +// pub const REWARD_CAPACITY: u64 = 1_000_000_000_000; + +// // Proxy constants + +// pub const PROXY_WASM_PATH: &str = "farm-staking-proxy/output/farm-staking-proxy"; +// pub const DUAL_YIELD_TOKEN_ID: &[u8] = b"DYIELD-abcdef"; diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs index 6e3a01f00..faad624a7 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs @@ -1,147 +1,147 @@ -#![allow(deprecated)] +// #![allow(deprecated)] -pub mod constants; -pub mod staking_farm_with_lp_external_contracts; -pub mod staking_farm_with_lp_staking_contract_interactions; -pub mod staking_farm_with_lp_staking_contract_setup; +// pub mod constants; +// pub mod staking_farm_with_lp_external_contracts; +// pub mod staking_farm_with_lp_staking_contract_interactions; +// pub mod staking_farm_with_lp_staking_contract_setup; -multiversx_sc::imports!(); +// multiversx_sc::imports!(); -use common_structs::FarmTokenAttributes; -use constants::*; -use farm_staking_proxy_legacy::dual_yield_token::DualYieldTokenAttributes; +// use common_structs::FarmTokenAttributes; +// use constants::*; +// use farm_staking_proxy_legacy::dual_yield_token::DualYieldTokenAttributes; -use farm_staking::stake_farm::StakeFarmModule; -use farm_with_locked_rewards::Farm; -use multiversx_sc_scenario::{ - imports::TxTokenTransfer, managed_address, managed_biguint, rust_biguint, DebugApi, -}; -use pair::pair_actions::add_liq::AddLiquidityModule; -use staking_farm_with_lp_staking_contract_interactions::*; +// use farm_staking::stake_farm::StakeFarmModule; +// use farm_with_locked_rewards::Farm; +// use multiversx_sc_scenario::{ +// imports::TxTokenTransfer, managed_address, managed_biguint, rust_biguint, DebugApi, +// }; +// use pair::pair_actions::add_liq::AddLiquidityModule; +// use staking_farm_with_lp_staking_contract_interactions::*; -#[test] -fn test_all_setup() { - let _ = FarmStakingSetup::new( - pair::contract_obj, - farm_with_locked_rewards::contract_obj, - energy_factory::contract_obj, - farm_staking::contract_obj, - farm_staking_proxy_legacy::contract_obj, - ); -} +// #[test] +// fn test_all_setup() { +// let _ = FarmStakingSetup::new( +// pair::contract_obj, +// farm_with_locked_rewards::contract_obj, +// energy_factory::contract_obj, +// farm_staking::contract_obj, +// farm_staking_proxy_legacy::contract_obj, +// ); +// } -#[test] -fn test_unstake_from_legacy_proxy() { - let mut setup = FarmStakingSetup::new( - pair::contract_obj, - farm_with_locked_rewards::contract_obj, - energy_factory::contract_obj, - farm_staking::contract_obj, - farm_staking_proxy_legacy::contract_obj, - ); +// #[test] +// fn test_unstake_from_legacy_proxy() { +// let mut setup = FarmStakingSetup::new( +// pair::contract_obj, +// farm_with_locked_rewards::contract_obj, +// energy_factory::contract_obj, +// farm_staking::contract_obj, +// farm_staking_proxy_legacy::contract_obj, +// ); - DebugApi::dummy(); - setup - .b_mock - .set_block_nonce(BLOCK_NONCE_AFTER_PAIR_SETUP + 20); - setup.b_mock.set_block_epoch(20); +// DebugApi::dummy(); +// setup +// .b_mock +// .set_block_nonce(BLOCK_NONCE_AFTER_PAIR_SETUP + 20); +// setup.b_mock.set_block_epoch(20); - let token_amount = 1_000_000_000u64; +// let token_amount = 1_000_000_000u64; - let payments = vec![ - TxTokenTransfer { - token_identifier: WEGLD_TOKEN_ID.to_vec(), - nonce: 0, - value: rust_biguint!(token_amount), - }, - TxTokenTransfer { - token_identifier: RIDE_TOKEN_ID.to_vec(), - nonce: 0, - value: rust_biguint!(token_amount), - }, - ]; - setup - .b_mock - .execute_esdt_multi_transfer(&setup.user_addr, &setup.pair_wrapper, &payments, |sc| { - sc.add_liquidity(managed_biguint!(1u64), managed_biguint!(1u64)); - }) - .assert_ok(); +// let payments = vec![ +// TxTokenTransfer { +// token_identifier: WEGLD_TOKEN_ID.to_vec(), +// nonce: 0, +// value: rust_biguint!(token_amount), +// }, +// TxTokenTransfer { +// token_identifier: RIDE_TOKEN_ID.to_vec(), +// nonce: 0, +// value: rust_biguint!(token_amount), +// }, +// ]; +// setup +// .b_mock +// .execute_esdt_multi_transfer(&setup.user_addr, &setup.pair_wrapper, &payments, |sc| { +// sc.add_liquidity(managed_biguint!(1u64), managed_biguint!(1u64)); +// }) +// .assert_ok(); - setup - .b_mock - .execute_esdt_transfer( - &setup.user_addr, - &setup.lp_farm_wrapper, - LP_TOKEN_ID, - 0, - &rust_biguint!(token_amount), - |sc| { - sc.enter_farm_endpoint(OptionalValue::None); - }, - ) - .assert_ok(); +// setup +// .b_mock +// .execute_esdt_transfer( +// &setup.user_addr, +// &setup.lp_farm_wrapper, +// LP_TOKEN_ID, +// 0, +// &rust_biguint!(token_amount), +// |sc| { +// sc.enter_farm_endpoint(OptionalValue::None); +// }, +// ) +// .assert_ok(); - // Simulate enter proxy staking contract - let lp_farm_token_attributes: FarmTokenAttributes = FarmTokenAttributes { - reward_per_share: managed_biguint!(0), - entering_epoch: 20, - compounded_reward: managed_biguint!(0), - current_farm_amount: managed_biguint!(token_amount), - original_owner: managed_address!(&setup.user_addr), - }; - setup.b_mock.set_nft_balance( - setup.proxy_wrapper.address_ref(), - LP_FARM_TOKEN_ID, - 1, - &rust_biguint!(token_amount), - &lp_farm_token_attributes, - ); - setup.b_mock.set_esdt_balance( - setup.proxy_wrapper.address_ref(), - RIDE_TOKEN_ID, - &rust_biguint!(token_amount), - ); +// // Simulate enter proxy staking contract +// let lp_farm_token_attributes: FarmTokenAttributes = FarmTokenAttributes { +// reward_per_share: managed_biguint!(0), +// entering_epoch: 20, +// compounded_reward: managed_biguint!(0), +// current_farm_amount: managed_biguint!(token_amount), +// original_owner: managed_address!(&setup.user_addr), +// }; +// setup.b_mock.set_nft_balance( +// setup.proxy_wrapper.address_ref(), +// LP_FARM_TOKEN_ID, +// 1, +// &rust_biguint!(token_amount), +// &lp_farm_token_attributes, +// ); +// setup.b_mock.set_esdt_balance( +// setup.proxy_wrapper.address_ref(), +// RIDE_TOKEN_ID, +// &rust_biguint!(token_amount), +// ); - setup - .b_mock - .execute_tx( - setup.proxy_wrapper.address_ref(), - &setup.staking_farm_wrapper, - &rust_biguint!(0u64), - |sc| { - sc.stake_farm_through_proxy( - managed_biguint!(token_amount), - managed_address!(&setup.user_addr), - ); - }, - ) - .assert_ok(); +// setup +// .b_mock +// .execute_tx( +// setup.proxy_wrapper.address_ref(), +// &setup.staking_farm_wrapper, +// &rust_biguint!(0u64), +// |sc| { +// sc.stake_farm_through_proxy( +// managed_biguint!(token_amount), +// managed_address!(&setup.user_addr), +// ); +// }, +// ) +// .assert_ok(); - let dual_yield_token_amount = token_amount; - let dual_yield_token_attributes: DualYieldTokenAttributes = - DualYieldTokenAttributes { - lp_farm_token_nonce: 1, - lp_farm_token_amount: managed_biguint!(dual_yield_token_amount), - staking_farm_token_nonce: 1, - staking_farm_token_amount: managed_biguint!(dual_yield_token_amount), - }; - setup.b_mock.set_nft_balance( - &setup.user_addr, - DUAL_YIELD_TOKEN_ID, - 1, - &rust_biguint!(dual_yield_token_amount), - &dual_yield_token_attributes, - ); +// let dual_yield_token_amount = token_amount; +// let dual_yield_token_attributes: DualYieldTokenAttributes = +// DualYieldTokenAttributes { +// lp_farm_token_nonce: 1, +// lp_farm_token_amount: managed_biguint!(dual_yield_token_amount), +// staking_farm_token_nonce: 1, +// staking_farm_token_amount: managed_biguint!(dual_yield_token_amount), +// }; +// setup.b_mock.set_nft_balance( +// &setup.user_addr, +// DUAL_YIELD_TOKEN_ID, +// 1, +// &rust_biguint!(dual_yield_token_amount), +// &dual_yield_token_attributes, +// ); - let expected_token_amount = 990_000_000u64; - setup.unstake_proxy( - 1, - dual_yield_token_amount, - expected_token_amount, - expected_token_amount, - 30, - ); +// let expected_token_amount = 990_000_000u64; +// setup.unstake_proxy( +// 1, +// dual_yield_token_amount, +// expected_token_amount, +// expected_token_amount, +// 30, +// ); - setup.b_mock.set_block_epoch(30); - setup.unbond_proxy(2, expected_token_amount, expected_token_amount); -} +// setup.b_mock.set_block_epoch(30); +// setup.unbond_proxy(2, expected_token_amount, expected_token_amount); +// } diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs index 026fea631..ffd3c9313 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs @@ -1,253 +1,253 @@ -use energy_factory::token_whitelist::TokenWhitelistModule; -use energy_factory::SimpleLockEnergy; -use energy_query::EnergyQueryModule; -use farm_token::FarmTokenModule; -use farm_with_locked_rewards::Farm; -use multiversx_sc::imports::StorageTokenWrapper; -use multiversx_sc::types::{Address, EsdtLocalRole, MultiValueEncoded}; -use multiversx_sc_modules::pause::PauseModule; -use multiversx_sc_scenario::{ - managed_address, managed_biguint, managed_token_id, rust_biguint, testing_framework::*, - DebugApi, -}; - -use pair::config as pair_config; -use pair::*; -use pair_actions::add_liq::AddLiquidityModule; -use pair_actions::initial_liq::InitialLiquidityModule; -use pair_config::ConfigModule as _; - -use pausable::{PausableModule, State}; -use simple_lock::locked_token::LockedTokenModule as _; - -use crate::constants::*; - -pub fn setup_pair( - owner_addr: &Address, - user_addr: &Address, - b_mock: &mut BlockchainStateWrapper, - pair_builder: PairObjBuilder, -) -> ContractObjWrapper, PairObjBuilder> -where - PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, -{ - let rust_zero = rust_biguint!(0u64); - let pair_wrapper = - b_mock.create_sc_account(&rust_zero, Some(owner_addr), pair_builder, PAIR_WASM_PATH); - - b_mock - .execute_tx(owner_addr, &pair_wrapper, &rust_zero, |sc| { - let first_token_id = managed_token_id!(WEGLD_TOKEN_ID); - let second_token_id = managed_token_id!(RIDE_TOKEN_ID); - let router_address = managed_address!(owner_addr); - let router_owner_address = managed_address!(owner_addr); - let initial_liquidity_adder = managed_address!(owner_addr); - let total_fee_percent = 300u64; - let special_fee_percent = 50u64; - - sc.init( - first_token_id, - second_token_id, - router_address, - router_owner_address, - total_fee_percent, - special_fee_percent, - initial_liquidity_adder, - MultiValueEncoded::new(), - ); - - let lp_token_id = managed_token_id!(LP_TOKEN_ID); - sc.lp_token_identifier().set(&lp_token_id); - }) - .assert_ok(); - - let lp_token_roles = [EsdtLocalRole::Mint, EsdtLocalRole::Burn]; - b_mock.set_esdt_local_roles(pair_wrapper.address_ref(), LP_TOKEN_ID, &lp_token_roles[..]); - - // set user balance - b_mock.set_esdt_balance( - user_addr, - WEGLD_TOKEN_ID, - &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), - ); - b_mock.set_esdt_balance( - user_addr, - RIDE_TOKEN_ID, - &rust_biguint!(USER_TOTAL_RIDE_TOKENS), - ); - - b_mock.set_block_nonce(BLOCK_NONCE_FIRST_ADD_LIQ); - - b_mock.set_esdt_balance( - owner_addr, - WEGLD_TOKEN_ID, - &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), - ); - b_mock.set_esdt_balance( - owner_addr, - RIDE_TOKEN_ID, - &rust_biguint!(USER_TOTAL_RIDE_TOKENS), - ); - - let payments = vec![ - TxTokenTransfer { - token_identifier: WEGLD_TOKEN_ID.to_vec(), - nonce: 0, - value: rust_biguint!(1_000_000_000), - }, - TxTokenTransfer { - token_identifier: RIDE_TOKEN_ID.to_vec(), - nonce: 0, - value: rust_biguint!(1_000_000_000), - }, - ]; - b_mock - .execute_esdt_multi_transfer(owner_addr, &pair_wrapper, &payments, |sc| { - sc.add_initial_liquidity(); - }) - .assert_ok(); - - b_mock.set_block_nonce(BLOCK_NONCE_SECOND_ADD_LIQ); - - b_mock - .execute_esdt_multi_transfer(owner_addr, &pair_wrapper, &payments, |sc| { - sc.add_liquidity(managed_biguint!(1u64), managed_biguint!(1u64)); - }) - .assert_ok(); - - b_mock.set_block_nonce(BLOCK_NONCE_AFTER_PAIR_SETUP); - - pair_wrapper -} - -pub fn setup_lp_farm( - owner_addr: &Address, - energy_factory_address: &Address, - b_mock: &mut BlockchainStateWrapper, - farm_builder: FarmObjBuilder, -) -> ContractObjWrapper, FarmObjBuilder> -where - FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, -{ - let rust_zero = rust_biguint!(0u64); - let farm_wrapper = - b_mock.create_sc_account(&rust_zero, Some(owner_addr), farm_builder, FARM_WASM_PATH); - - // init farm contract - - b_mock - .execute_tx(owner_addr, &farm_wrapper, &rust_zero, |sc| { - let reward_token_id = managed_token_id!(RIDE_TOKEN_ID); - let farming_token_id = managed_token_id!(LP_TOKEN_ID); - let division_safety_constant = managed_biguint!(DIVISION_SAFETY_CONSTANT); - let pair_address = managed_address!(&Address::zero()); - - sc.init( - reward_token_id, - farming_token_id, - division_safety_constant, - pair_address, - managed_address!(owner_addr), - MultiValueEncoded::new(), - ); - - let farm_token_id = managed_token_id!(LP_FARM_TOKEN_ID); - sc.farm_token().set_token_id(farm_token_id); - - sc.energy_factory_address() - .set(managed_address!(energy_factory_address)); - - sc.state().set(State::Active); - }) - .assert_ok(); - - let farm_token_roles = [ - EsdtLocalRole::NftCreate, - EsdtLocalRole::NftAddQuantity, - EsdtLocalRole::NftBurn, - ]; - b_mock.set_esdt_local_roles( - farm_wrapper.address_ref(), - LP_FARM_TOKEN_ID, - &farm_token_roles[..], - ); - - let farming_token_roles = [EsdtLocalRole::Burn]; - b_mock.set_esdt_local_roles( - farm_wrapper.address_ref(), - LP_TOKEN_ID, - &farming_token_roles[..], - ); - - let reward_token_roles = [EsdtLocalRole::Mint]; - b_mock.set_esdt_local_roles( - farm_wrapper.address_ref(), - RIDE_TOKEN_ID, - &reward_token_roles[..], - ); - - farm_wrapper -} - -pub fn setup_energy_factory( - owner_addr: &Address, - b_mock: &mut BlockchainStateWrapper, - energy_factory_builder: EnergyFactoryObjBuilder, -) -> ContractObjWrapper, EnergyFactoryObjBuilder> -where - EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, -{ - let rust_zero = rust_biguint!(0u64); - let energy_factory_wrapper = b_mock.create_sc_account( - &rust_zero, - Some(owner_addr), - energy_factory_builder, - "energy factory", - ); - - b_mock - .execute_tx(owner_addr, &energy_factory_wrapper, &rust_zero, |sc| { - let mut lock_options = MultiValueEncoded::new(); - for (option, penalty) in LOCK_OPTIONS.iter().zip(PENALTY_PERCENTAGES.iter()) { - lock_options.push((*option, *penalty).into()); - } - - sc.init( - managed_token_id!(LOCKED_TOKEN_ID), - managed_token_id!(LEGACY_LOCKED_TOKEN_ID), - managed_address!(energy_factory_wrapper.address_ref()), - 0, - lock_options, - ); - - sc.base_asset_token_id() - .set(managed_token_id!(MEX_TOKEN_ID)); - sc.locked_token() - .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); - sc.set_paused(false); - }) - .assert_ok(); - - b_mock.set_esdt_local_roles( - energy_factory_wrapper.address_ref(), - MEX_TOKEN_ID, - &[EsdtLocalRole::Mint, EsdtLocalRole::Burn], - ); - b_mock.set_esdt_local_roles( - energy_factory_wrapper.address_ref(), - LOCKED_TOKEN_ID, - &[ - EsdtLocalRole::NftCreate, - EsdtLocalRole::NftAddQuantity, - EsdtLocalRole::NftBurn, - EsdtLocalRole::Transfer, - ], - ); - b_mock.set_esdt_local_roles( - energy_factory_wrapper.address_ref(), - LEGACY_LOCKED_TOKEN_ID, - &[EsdtLocalRole::NftBurn], - ); - - energy_factory_wrapper -} +// use energy_factory::token_whitelist::TokenWhitelistModule; +// use energy_factory::SimpleLockEnergy; +// use energy_query::EnergyQueryModule; +// use farm_token::FarmTokenModule; +// use farm_with_locked_rewards::Farm; +// use multiversx_sc::imports::StorageTokenWrapper; +// use multiversx_sc::types::{Address, EsdtLocalRole, MultiValueEncoded}; +// use multiversx_sc_modules::pause::PauseModule; +// use multiversx_sc_scenario::{ +// managed_address, managed_biguint, managed_token_id, rust_biguint, testing_framework::*, +// DebugApi, +// }; + +// use pair::config as pair_config; +// use pair::*; +// use pair_actions::add_liq::AddLiquidityModule; +// use pair_actions::initial_liq::InitialLiquidityModule; +// use pair_config::ConfigModule as _; + +// use pausable::{PausableModule, State}; +// use simple_lock::locked_token::LockedTokenModule as _; + +// use crate::constants::*; + +// pub fn setup_pair( +// owner_addr: &Address, +// user_addr: &Address, +// b_mock: &mut BlockchainStateWrapper, +// pair_builder: PairObjBuilder, +// ) -> ContractObjWrapper, PairObjBuilder> +// where +// PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, +// { +// let rust_zero = rust_biguint!(0u64); +// let pair_wrapper = +// b_mock.create_sc_account(&rust_zero, Some(owner_addr), pair_builder, PAIR_WASM_PATH); + +// b_mock +// .execute_tx(owner_addr, &pair_wrapper, &rust_zero, |sc| { +// let first_token_id = managed_token_id!(WEGLD_TOKEN_ID); +// let second_token_id = managed_token_id!(RIDE_TOKEN_ID); +// let router_address = managed_address!(owner_addr); +// let router_owner_address = managed_address!(owner_addr); +// let initial_liquidity_adder = managed_address!(owner_addr); +// let total_fee_percent = 300u64; +// let special_fee_percent = 50u64; + +// sc.init( +// first_token_id, +// second_token_id, +// router_address, +// router_owner_address, +// total_fee_percent, +// special_fee_percent, +// initial_liquidity_adder, +// MultiValueEncoded::new(), +// ); + +// let lp_token_id = managed_token_id!(LP_TOKEN_ID); +// sc.lp_token_identifier().set(&lp_token_id); +// }) +// .assert_ok(); + +// let lp_token_roles = [EsdtLocalRole::Mint, EsdtLocalRole::Burn]; +// b_mock.set_esdt_local_roles(pair_wrapper.address_ref(), LP_TOKEN_ID, &lp_token_roles[..]); + +// // set user balance +// b_mock.set_esdt_balance( +// user_addr, +// WEGLD_TOKEN_ID, +// &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), +// ); +// b_mock.set_esdt_balance( +// user_addr, +// RIDE_TOKEN_ID, +// &rust_biguint!(USER_TOTAL_RIDE_TOKENS), +// ); + +// b_mock.set_block_nonce(BLOCK_NONCE_FIRST_ADD_LIQ); + +// b_mock.set_esdt_balance( +// owner_addr, +// WEGLD_TOKEN_ID, +// &rust_biguint!(USER_TOTAL_WEGLD_TOKENS), +// ); +// b_mock.set_esdt_balance( +// owner_addr, +// RIDE_TOKEN_ID, +// &rust_biguint!(USER_TOTAL_RIDE_TOKENS), +// ); + +// let payments = vec![ +// TxTokenTransfer { +// token_identifier: WEGLD_TOKEN_ID.to_vec(), +// nonce: 0, +// value: rust_biguint!(1_000_000_000), +// }, +// TxTokenTransfer { +// token_identifier: RIDE_TOKEN_ID.to_vec(), +// nonce: 0, +// value: rust_biguint!(1_000_000_000), +// }, +// ]; +// b_mock +// .execute_esdt_multi_transfer(owner_addr, &pair_wrapper, &payments, |sc| { +// sc.add_initial_liquidity(); +// }) +// .assert_ok(); + +// b_mock.set_block_nonce(BLOCK_NONCE_SECOND_ADD_LIQ); + +// b_mock +// .execute_esdt_multi_transfer(owner_addr, &pair_wrapper, &payments, |sc| { +// sc.add_liquidity(managed_biguint!(1u64), managed_biguint!(1u64)); +// }) +// .assert_ok(); + +// b_mock.set_block_nonce(BLOCK_NONCE_AFTER_PAIR_SETUP); + +// pair_wrapper +// } + +// pub fn setup_lp_farm( +// owner_addr: &Address, +// energy_factory_address: &Address, +// b_mock: &mut BlockchainStateWrapper, +// farm_builder: FarmObjBuilder, +// ) -> ContractObjWrapper, FarmObjBuilder> +// where +// FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, +// { +// let rust_zero = rust_biguint!(0u64); +// let farm_wrapper = +// b_mock.create_sc_account(&rust_zero, Some(owner_addr), farm_builder, FARM_WASM_PATH); + +// // init farm contract + +// b_mock +// .execute_tx(owner_addr, &farm_wrapper, &rust_zero, |sc| { +// let reward_token_id = managed_token_id!(RIDE_TOKEN_ID); +// let farming_token_id = managed_token_id!(LP_TOKEN_ID); +// let division_safety_constant = managed_biguint!(DIVISION_SAFETY_CONSTANT); +// let pair_address = managed_address!(&Address::zero()); + +// sc.init( +// reward_token_id, +// farming_token_id, +// division_safety_constant, +// pair_address, +// managed_address!(owner_addr), +// MultiValueEncoded::new(), +// ); + +// let farm_token_id = managed_token_id!(LP_FARM_TOKEN_ID); +// sc.farm_token().set_token_id(farm_token_id); + +// sc.energy_factory_address() +// .set(managed_address!(energy_factory_address)); + +// sc.state().set(State::Active); +// }) +// .assert_ok(); + +// let farm_token_roles = [ +// EsdtLocalRole::NftCreate, +// EsdtLocalRole::NftAddQuantity, +// EsdtLocalRole::NftBurn, +// ]; +// b_mock.set_esdt_local_roles( +// farm_wrapper.address_ref(), +// LP_FARM_TOKEN_ID, +// &farm_token_roles[..], +// ); + +// let farming_token_roles = [EsdtLocalRole::Burn]; +// b_mock.set_esdt_local_roles( +// farm_wrapper.address_ref(), +// LP_TOKEN_ID, +// &farming_token_roles[..], +// ); + +// let reward_token_roles = [EsdtLocalRole::Mint]; +// b_mock.set_esdt_local_roles( +// farm_wrapper.address_ref(), +// RIDE_TOKEN_ID, +// &reward_token_roles[..], +// ); + +// farm_wrapper +// } + +// pub fn setup_energy_factory( +// owner_addr: &Address, +// b_mock: &mut BlockchainStateWrapper, +// energy_factory_builder: EnergyFactoryObjBuilder, +// ) -> ContractObjWrapper, EnergyFactoryObjBuilder> +// where +// EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, +// { +// let rust_zero = rust_biguint!(0u64); +// let energy_factory_wrapper = b_mock.create_sc_account( +// &rust_zero, +// Some(owner_addr), +// energy_factory_builder, +// "energy factory", +// ); + +// b_mock +// .execute_tx(owner_addr, &energy_factory_wrapper, &rust_zero, |sc| { +// let mut lock_options = MultiValueEncoded::new(); +// for (option, penalty) in LOCK_OPTIONS.iter().zip(PENALTY_PERCENTAGES.iter()) { +// lock_options.push((*option, *penalty).into()); +// } + +// sc.init( +// managed_token_id!(LOCKED_TOKEN_ID), +// managed_token_id!(LEGACY_LOCKED_TOKEN_ID), +// managed_address!(energy_factory_wrapper.address_ref()), +// 0, +// lock_options, +// ); + +// sc.base_asset_token_id() +// .set(managed_token_id!(MEX_TOKEN_ID)); +// sc.locked_token() +// .set_token_id(managed_token_id!(LOCKED_TOKEN_ID)); +// sc.set_paused(false); +// }) +// .assert_ok(); + +// b_mock.set_esdt_local_roles( +// energy_factory_wrapper.address_ref(), +// MEX_TOKEN_ID, +// &[EsdtLocalRole::Mint, EsdtLocalRole::Burn], +// ); +// b_mock.set_esdt_local_roles( +// energy_factory_wrapper.address_ref(), +// LOCKED_TOKEN_ID, +// &[ +// EsdtLocalRole::NftCreate, +// EsdtLocalRole::NftAddQuantity, +// EsdtLocalRole::NftBurn, +// EsdtLocalRole::Transfer, +// ], +// ); +// b_mock.set_esdt_local_roles( +// energy_factory_wrapper.address_ref(), +// LEGACY_LOCKED_TOKEN_ID, +// &[EsdtLocalRole::NftBurn], +// ); + +// energy_factory_wrapper +// } diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs index 6a2406a63..7073690b5 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs @@ -1,201 +1,201 @@ -use multiversx_sc::types::Address; -use multiversx_sc_scenario::{ - managed_biguint, rust_biguint, - testing_framework::{BlockchainStateWrapper, ContractObjWrapper}, - DebugApi, -}; - -use farm_staking::*; -use farm_staking_proxy_legacy::*; -use token_attributes::UnbondSftAttributes; -use unbond_farm::UnbondFarmModule; - -use crate::{ - constants::*, - staking_farm_with_lp_external_contracts::{setup_energy_factory, setup_lp_farm, setup_pair}, - staking_farm_with_lp_staking_contract_setup::{ - add_proxy_to_whitelist, setup_proxy, setup_staking_farm, - }, -}; - -pub struct FarmStakingSetup< - PairObjBuilder, - FarmObjBuilder, - EnergyFactoryObjBuilder, - StakingContractObjBuilder, - ProxyContractObjBuilder, -> where - PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, - FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, - EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, - StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, - ProxyContractObjBuilder: - 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, -{ - pub owner_addr: Address, - pub user_addr: Address, - pub b_mock: BlockchainStateWrapper, - pub pair_wrapper: ContractObjWrapper, PairObjBuilder>, - pub lp_farm_wrapper: - ContractObjWrapper, FarmObjBuilder>, - pub energy_factory_wrapper: - ContractObjWrapper, EnergyFactoryObjBuilder>, - pub staking_farm_wrapper: - ContractObjWrapper, StakingContractObjBuilder>, - pub proxy_wrapper: ContractObjWrapper< - farm_staking_proxy_legacy::ContractObj, - ProxyContractObjBuilder, - >, -} - -impl< - PairObjBuilder, - FarmObjBuilder, - EnergyFactoryObjBuilder, - StakingContractObjBuilder, - ProxyContractObjBuilder, - > - FarmStakingSetup< - PairObjBuilder, - FarmObjBuilder, - EnergyFactoryObjBuilder, - StakingContractObjBuilder, - ProxyContractObjBuilder, - > -where - PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, - FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, - EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, - StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, - ProxyContractObjBuilder: - 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, -{ - pub fn new( - pair_builder: PairObjBuilder, - lp_farm_builder: FarmObjBuilder, - energy_factory_builder: EnergyFactoryObjBuilder, - staking_farm_builder: StakingContractObjBuilder, - proxy_builder: ProxyContractObjBuilder, - ) -> Self { - let rust_zero = rust_biguint!(0u64); - let mut b_mock = BlockchainStateWrapper::new(); - let owner_addr = b_mock.create_user_account(&rust_zero); - let user_addr = b_mock.create_user_account(&rust_biguint!(100_000_000)); - - let pair_wrapper = setup_pair(&owner_addr, &user_addr, &mut b_mock, pair_builder); - let energy_factory_wrapper = - setup_energy_factory(&owner_addr, &mut b_mock, energy_factory_builder); - let lp_farm_wrapper = setup_lp_farm( - &owner_addr, - energy_factory_wrapper.address_ref(), - &mut b_mock, - lp_farm_builder, - ); - - let staking_farm_wrapper = - setup_staking_farm(&owner_addr, &mut b_mock, staking_farm_builder); - let proxy_wrapper = setup_proxy( - &owner_addr, - lp_farm_wrapper.address_ref(), - staking_farm_wrapper.address_ref(), - pair_wrapper.address_ref(), - &mut b_mock, - proxy_builder, - ); - - add_proxy_to_whitelist( - &owner_addr, - proxy_wrapper.address_ref(), - &mut b_mock, - &lp_farm_wrapper, - &staking_farm_wrapper, - ); - - FarmStakingSetup { - owner_addr, - user_addr, - b_mock, - pair_wrapper, - lp_farm_wrapper, - energy_factory_wrapper, - staking_farm_wrapper, - proxy_wrapper, - } - } - - pub fn unstake_proxy( - &mut self, - dual_yield_token_nonce: u64, - dual_yield_token_amount: u64, - expected_wegld_amount: u64, - expected_unbond_token_amount: u64, - expected_unbond_token_unlock_epoch: u64, - ) -> u64 { - let mut unbond_token_nonce = 0; - - self.b_mock - .execute_esdt_transfer( - &self.user_addr, - &self.proxy_wrapper, - DUAL_YIELD_TOKEN_ID, - dual_yield_token_nonce, - &rust_biguint!(dual_yield_token_amount), - |sc| { - let received_tokens = sc - .unstake_farm_tokens(managed_biguint!(1), managed_biguint!(1)) - .to_vec(); - let mut vec_index = 0; - - if expected_wegld_amount > 0 { - let wegld_payment = received_tokens.get(vec_index); - assert_eq!(wegld_payment.amount, expected_wegld_amount); - - vec_index += 1; - } - - let unbond_tokens = received_tokens.get(vec_index); - assert_eq!(unbond_tokens.amount, expected_unbond_token_amount); - - unbond_token_nonce = unbond_tokens.token_nonce; - }, - ) - .assert_ok(); - - self.b_mock.execute_in_managed_environment(|| { - let expected_attributes = UnbondSftAttributes { - unlock_epoch: expected_unbond_token_unlock_epoch, - }; - - self.b_mock.check_nft_balance( - &self.user_addr, - STAKING_FARM_TOKEN_ID, - unbond_token_nonce, - &rust_biguint!(expected_unbond_token_amount), - Some(&expected_attributes), - ); - }); - - unbond_token_nonce - } - - pub fn unbond_proxy( - &mut self, - unbond_token_nonce: u64, - unbond_token_amount: u64, - expected_token_out_amount: u64, - ) { - self.b_mock - .execute_esdt_transfer( - &self.user_addr, - &self.staking_farm_wrapper, - STAKING_FARM_TOKEN_ID, - unbond_token_nonce, - &rust_biguint!(unbond_token_amount), - |sc| { - let received_tokens = sc.unbond_farm(); - assert_eq!(received_tokens.amount, expected_token_out_amount); - }, - ) - .assert_ok(); - } -} +// use multiversx_sc::types::Address; +// use multiversx_sc_scenario::{ +// managed_biguint, rust_biguint, +// testing_framework::{BlockchainStateWrapper, ContractObjWrapper}, +// DebugApi, +// }; + +// use farm_staking::*; +// use farm_staking_proxy_legacy::*; +// use token_attributes::UnbondSftAttributes; +// use unbond_farm::UnbondFarmModule; + +// use crate::{ +// constants::*, +// staking_farm_with_lp_external_contracts::{setup_energy_factory, setup_lp_farm, setup_pair}, +// staking_farm_with_lp_staking_contract_setup::{ +// add_proxy_to_whitelist, setup_proxy, setup_staking_farm, +// }, +// }; + +// pub struct FarmStakingSetup< +// PairObjBuilder, +// FarmObjBuilder, +// EnergyFactoryObjBuilder, +// StakingContractObjBuilder, +// ProxyContractObjBuilder, +// > where +// PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, +// FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, +// EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, +// StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, +// ProxyContractObjBuilder: +// 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, +// { +// pub owner_addr: Address, +// pub user_addr: Address, +// pub b_mock: BlockchainStateWrapper, +// pub pair_wrapper: ContractObjWrapper, PairObjBuilder>, +// pub lp_farm_wrapper: +// ContractObjWrapper, FarmObjBuilder>, +// pub energy_factory_wrapper: +// ContractObjWrapper, EnergyFactoryObjBuilder>, +// pub staking_farm_wrapper: +// ContractObjWrapper, StakingContractObjBuilder>, +// pub proxy_wrapper: ContractObjWrapper< +// farm_staking_proxy_legacy::ContractObj, +// ProxyContractObjBuilder, +// >, +// } + +// impl< +// PairObjBuilder, +// FarmObjBuilder, +// EnergyFactoryObjBuilder, +// StakingContractObjBuilder, +// ProxyContractObjBuilder, +// > +// FarmStakingSetup< +// PairObjBuilder, +// FarmObjBuilder, +// EnergyFactoryObjBuilder, +// StakingContractObjBuilder, +// ProxyContractObjBuilder, +// > +// where +// PairObjBuilder: 'static + Copy + Fn() -> pair::ContractObj, +// FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, +// EnergyFactoryObjBuilder: 'static + Copy + Fn() -> energy_factory::ContractObj, +// StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, +// ProxyContractObjBuilder: +// 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, +// { +// pub fn new( +// pair_builder: PairObjBuilder, +// lp_farm_builder: FarmObjBuilder, +// energy_factory_builder: EnergyFactoryObjBuilder, +// staking_farm_builder: StakingContractObjBuilder, +// proxy_builder: ProxyContractObjBuilder, +// ) -> Self { +// let rust_zero = rust_biguint!(0u64); +// let mut b_mock = BlockchainStateWrapper::new(); +// let owner_addr = b_mock.create_user_account(&rust_zero); +// let user_addr = b_mock.create_user_account(&rust_biguint!(100_000_000)); + +// let pair_wrapper = setup_pair(&owner_addr, &user_addr, &mut b_mock, pair_builder); +// let energy_factory_wrapper = +// setup_energy_factory(&owner_addr, &mut b_mock, energy_factory_builder); +// let lp_farm_wrapper = setup_lp_farm( +// &owner_addr, +// energy_factory_wrapper.address_ref(), +// &mut b_mock, +// lp_farm_builder, +// ); + +// let staking_farm_wrapper = +// setup_staking_farm(&owner_addr, &mut b_mock, staking_farm_builder); +// let proxy_wrapper = setup_proxy( +// &owner_addr, +// lp_farm_wrapper.address_ref(), +// staking_farm_wrapper.address_ref(), +// pair_wrapper.address_ref(), +// &mut b_mock, +// proxy_builder, +// ); + +// add_proxy_to_whitelist( +// &owner_addr, +// proxy_wrapper.address_ref(), +// &mut b_mock, +// &lp_farm_wrapper, +// &staking_farm_wrapper, +// ); + +// FarmStakingSetup { +// owner_addr, +// user_addr, +// b_mock, +// pair_wrapper, +// lp_farm_wrapper, +// energy_factory_wrapper, +// staking_farm_wrapper, +// proxy_wrapper, +// } +// } + +// pub fn unstake_proxy( +// &mut self, +// dual_yield_token_nonce: u64, +// dual_yield_token_amount: u64, +// expected_wegld_amount: u64, +// expected_unbond_token_amount: u64, +// expected_unbond_token_unlock_epoch: u64, +// ) -> u64 { +// let mut unbond_token_nonce = 0; + +// self.b_mock +// .execute_esdt_transfer( +// &self.user_addr, +// &self.proxy_wrapper, +// DUAL_YIELD_TOKEN_ID, +// dual_yield_token_nonce, +// &rust_biguint!(dual_yield_token_amount), +// |sc| { +// let received_tokens = sc +// .unstake_farm_tokens(managed_biguint!(1), managed_biguint!(1)) +// .to_vec(); +// let mut vec_index = 0; + +// if expected_wegld_amount > 0 { +// let wegld_payment = received_tokens.get(vec_index); +// assert_eq!(wegld_payment.amount, expected_wegld_amount); + +// vec_index += 1; +// } + +// let unbond_tokens = received_tokens.get(vec_index); +// assert_eq!(unbond_tokens.amount, expected_unbond_token_amount); + +// unbond_token_nonce = unbond_tokens.token_nonce; +// }, +// ) +// .assert_ok(); + +// self.b_mock.execute_in_managed_environment(|| { +// let expected_attributes = UnbondSftAttributes { +// unlock_epoch: expected_unbond_token_unlock_epoch, +// }; + +// self.b_mock.check_nft_balance( +// &self.user_addr, +// STAKING_FARM_TOKEN_ID, +// unbond_token_nonce, +// &rust_biguint!(expected_unbond_token_amount), +// Some(&expected_attributes), +// ); +// }); + +// unbond_token_nonce +// } + +// pub fn unbond_proxy( +// &mut self, +// unbond_token_nonce: u64, +// unbond_token_amount: u64, +// expected_token_out_amount: u64, +// ) { +// self.b_mock +// .execute_esdt_transfer( +// &self.user_addr, +// &self.staking_farm_wrapper, +// STAKING_FARM_TOKEN_ID, +// unbond_token_nonce, +// &rust_biguint!(unbond_token_amount), +// |sc| { +// let received_tokens = sc.unbond_farm(); +// assert_eq!(received_tokens.amount, expected_token_out_amount); +// }, +// ) +// .assert_ok(); +// } +// } diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs index e4ed2862f..2cb4d6e97 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs @@ -1,153 +1,153 @@ -use external_contracts_interactions::ExternalContractsInteractionsModule; -use farm_token::FarmTokenModule; -use lp_farm_token::LpFarmTokenModule; -use multiversx_sc::{ - imports::StorageTokenWrapper, - types::{Address, EsdtLocalRole, MultiValueEncoded}, -}; -use multiversx_sc_scenario::{ - managed_address, managed_biguint, managed_token_id, rust_biguint, - testing_framework::{BlockchainStateWrapper, ContractObjWrapper}, - DebugApi, -}; - -use farm_staking::*; - -use farm_staking_proxy_legacy::dual_yield_token::DualYieldTokenModule; -use farm_staking_proxy_legacy::*; -use pausable::{PausableModule, State}; -use sc_whitelist_module::SCWhitelistModule; - -use crate::constants::*; - -pub fn setup_staking_farm( - owner_addr: &Address, - b_mock: &mut BlockchainStateWrapper, - builder: StakingContractObjBuilder, -) -> ContractObjWrapper, StakingContractObjBuilder> -where - StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, -{ - let rust_zero = rust_biguint!(0u64); - let farm_staking_wrapper = - b_mock.create_sc_account(&rust_zero, Some(owner_addr), builder, PROXY_WASM_PATH); - - b_mock - .execute_tx(owner_addr, &farm_staking_wrapper, &rust_zero, |sc| { - let farming_token_id = managed_token_id!(STAKING_TOKEN_ID); - let div_const = managed_biguint!(DIVISION_SAFETY_CONSTANT); - let max_apr = managed_biguint!(MAX_APR); - - sc.init( - farming_token_id, - div_const, - max_apr, - UNBOND_EPOCHS, - managed_address!(owner_addr), - MultiValueEncoded::new(), - ); - - sc.farm_token() - .set_token_id(managed_token_id!(STAKING_FARM_TOKEN_ID)); - - sc.state().set(State::Active); - }) - .assert_ok(); - - b_mock.set_esdt_balance( - farm_staking_wrapper.address_ref(), - STAKING_REWARD_TOKEN_ID, - &rust_biguint!(REWARD_CAPACITY), - ); - - let farm_token_roles = [ - EsdtLocalRole::NftCreate, - EsdtLocalRole::NftAddQuantity, - EsdtLocalRole::NftBurn, - ]; - b_mock.set_esdt_local_roles( - farm_staking_wrapper.address_ref(), - STAKING_FARM_TOKEN_ID, - &farm_token_roles[..], - ); - - farm_staking_wrapper -} - -pub fn add_proxy_to_whitelist( - owner_addr: &Address, - proxy_address: &Address, - b_mock: &mut BlockchainStateWrapper, - lp_farm_builder: &ContractObjWrapper< - farm_with_locked_rewards::ContractObj, - FarmObjBuilder, - >, - staking_farm_builder: &ContractObjWrapper< - farm_staking::ContractObj, - StakingContractObjBuilder, - >, -) where - FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, - StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, -{ - let rust_zero = rust_biguint!(0u64); - b_mock - .execute_tx(owner_addr, lp_farm_builder, &rust_zero, |sc| { - sc.add_sc_address_to_whitelist(managed_address!(proxy_address)); - }) - .assert_ok(); - b_mock - .execute_tx(owner_addr, staking_farm_builder, &rust_zero, |sc| { - sc.add_sc_address_to_whitelist(managed_address!(proxy_address)); - }) - .assert_ok(); -} - -pub fn setup_proxy( - owner_addr: &Address, - lp_farm_address: &Address, - staking_farm_address: &Address, - pair_address: &Address, - b_mock: &mut BlockchainStateWrapper, - builder: ProxyContractObjBuilder, -) -> ContractObjWrapper, ProxyContractObjBuilder> -where - ProxyContractObjBuilder: - 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, -{ - let rust_zero = rust_biguint!(0u64); - let proxy_wrapper = - b_mock.create_sc_account(&rust_zero, Some(owner_addr), builder, PROXY_WASM_PATH); - - b_mock - .execute_tx(owner_addr, &proxy_wrapper, &rust_zero, |sc| { - sc.init(); - - sc.pair_address().set(managed_address!(pair_address)); - sc.lp_farm_address().set(managed_address!(lp_farm_address)); - sc.lp_farm_token_id() - .set(managed_token_id!(LP_FARM_TOKEN_ID)); - sc.staking_farm_address() - .set(managed_address!(staking_farm_address)); - sc.staking_token_id() - .set(managed_token_id!(STAKING_TOKEN_ID)); - sc.staking_farm_token_id() - .set(managed_token_id!(STAKING_FARM_TOKEN_ID)); - sc.dual_yield_token_id() - .set(&managed_token_id!(DUAL_YIELD_TOKEN_ID)); - }) - .assert_ok(); - - let dual_yield_token_roles = [ - EsdtLocalRole::NftCreate, - EsdtLocalRole::NftAddQuantity, - EsdtLocalRole::NftBurn, - ]; - b_mock.set_esdt_local_roles( - proxy_wrapper.address_ref(), - DUAL_YIELD_TOKEN_ID, - &dual_yield_token_roles[..], - ); - - proxy_wrapper -} +// use external_contracts_interactions::ExternalContractsInteractionsModule; +// use farm_token::FarmTokenModule; +// use lp_farm_token::LpFarmTokenModule; +// use multiversx_sc::{ +// imports::StorageTokenWrapper, +// types::{Address, EsdtLocalRole, MultiValueEncoded}, +// }; +// use multiversx_sc_scenario::{ +// managed_address, managed_biguint, managed_token_id, rust_biguint, +// testing_framework::{BlockchainStateWrapper, ContractObjWrapper}, +// DebugApi, +// }; + +// use farm_staking::*; + +// use farm_staking_proxy_legacy::dual_yield_token::DualYieldTokenModule; +// use farm_staking_proxy_legacy::*; +// use pausable::{PausableModule, State}; +// use sc_whitelist_module::SCWhitelistModule; + +// use crate::constants::*; + +// pub fn setup_staking_farm( +// owner_addr: &Address, +// b_mock: &mut BlockchainStateWrapper, +// builder: StakingContractObjBuilder, +// ) -> ContractObjWrapper, StakingContractObjBuilder> +// where +// StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, +// { +// let rust_zero = rust_biguint!(0u64); +// let farm_staking_wrapper = +// b_mock.create_sc_account(&rust_zero, Some(owner_addr), builder, PROXY_WASM_PATH); + +// b_mock +// .execute_tx(owner_addr, &farm_staking_wrapper, &rust_zero, |sc| { +// let farming_token_id = managed_token_id!(STAKING_TOKEN_ID); +// let div_const = managed_biguint!(DIVISION_SAFETY_CONSTANT); +// let max_apr = managed_biguint!(MAX_APR); + +// sc.init( +// farming_token_id, +// div_const, +// max_apr, +// UNBOND_EPOCHS, +// managed_address!(owner_addr), +// MultiValueEncoded::new(), +// ); + +// sc.farm_token() +// .set_token_id(managed_token_id!(STAKING_FARM_TOKEN_ID)); + +// sc.state().set(State::Active); +// }) +// .assert_ok(); + +// b_mock.set_esdt_balance( +// farm_staking_wrapper.address_ref(), +// STAKING_REWARD_TOKEN_ID, +// &rust_biguint!(REWARD_CAPACITY), +// ); + +// let farm_token_roles = [ +// EsdtLocalRole::NftCreate, +// EsdtLocalRole::NftAddQuantity, +// EsdtLocalRole::NftBurn, +// ]; +// b_mock.set_esdt_local_roles( +// farm_staking_wrapper.address_ref(), +// STAKING_FARM_TOKEN_ID, +// &farm_token_roles[..], +// ); + +// farm_staking_wrapper +// } + +// pub fn add_proxy_to_whitelist( +// owner_addr: &Address, +// proxy_address: &Address, +// b_mock: &mut BlockchainStateWrapper, +// lp_farm_builder: &ContractObjWrapper< +// farm_with_locked_rewards::ContractObj, +// FarmObjBuilder, +// >, +// staking_farm_builder: &ContractObjWrapper< +// farm_staking::ContractObj, +// StakingContractObjBuilder, +// >, +// ) where +// FarmObjBuilder: 'static + Copy + Fn() -> farm_with_locked_rewards::ContractObj, +// StakingContractObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, +// { +// let rust_zero = rust_biguint!(0u64); +// b_mock +// .execute_tx(owner_addr, lp_farm_builder, &rust_zero, |sc| { +// sc.add_sc_address_to_whitelist(managed_address!(proxy_address)); +// }) +// .assert_ok(); +// b_mock +// .execute_tx(owner_addr, staking_farm_builder, &rust_zero, |sc| { +// sc.add_sc_address_to_whitelist(managed_address!(proxy_address)); +// }) +// .assert_ok(); +// } + +// pub fn setup_proxy( +// owner_addr: &Address, +// lp_farm_address: &Address, +// staking_farm_address: &Address, +// pair_address: &Address, +// b_mock: &mut BlockchainStateWrapper, +// builder: ProxyContractObjBuilder, +// ) -> ContractObjWrapper, ProxyContractObjBuilder> +// where +// ProxyContractObjBuilder: +// 'static + Copy + Fn() -> farm_staking_proxy_legacy::ContractObj, +// { +// let rust_zero = rust_biguint!(0u64); +// let proxy_wrapper = +// b_mock.create_sc_account(&rust_zero, Some(owner_addr), builder, PROXY_WASM_PATH); + +// b_mock +// .execute_tx(owner_addr, &proxy_wrapper, &rust_zero, |sc| { +// sc.init(); + +// sc.pair_address().set(managed_address!(pair_address)); +// sc.lp_farm_address().set(managed_address!(lp_farm_address)); +// sc.lp_farm_token_id() +// .set(managed_token_id!(LP_FARM_TOKEN_ID)); +// sc.staking_farm_address() +// .set(managed_address!(staking_farm_address)); +// sc.staking_token_id() +// .set(managed_token_id!(STAKING_TOKEN_ID)); +// sc.staking_farm_token_id() +// .set(managed_token_id!(STAKING_FARM_TOKEN_ID)); +// sc.dual_yield_token_id() +// .set(&managed_token_id!(DUAL_YIELD_TOKEN_ID)); +// }) +// .assert_ok(); + +// let dual_yield_token_roles = [ +// EsdtLocalRole::NftCreate, +// EsdtLocalRole::NftAddQuantity, +// EsdtLocalRole::NftBurn, +// ]; +// b_mock.set_esdt_local_roles( +// proxy_wrapper.address_ref(), +// DUAL_YIELD_TOKEN_ID, +// &dual_yield_token_roles[..], +// ); + +// proxy_wrapper +// } diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock index cb02bd384..d441ce738 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock @@ -198,7 +198,7 @@ version = "0.0.0" dependencies = [ "common_structs", "farm-staking", - "farm-with-locked-rewards", + "farm-v-13", "multiversx-sc", "multiversx-sc-modules", "pair", @@ -214,33 +214,10 @@ dependencies = [ ] [[package]] -name = "farm-with-locked-rewards" +name = "farm-v-13" version = "0.0.0" dependencies = [ - "common_errors", - "common_structs", - "config", - "contexts", - "energy-factory", - "energy-query", - "events", - "farm", - "farm-boosted-yields", - "farm_base_impl", - "farm_token", - "fixed-supply-token", - "locking_module", - "mergeable", "multiversx-sc", - "multiversx-sc-modules", - "pausable", - "permissions_module", - "rewards", - "sc_whitelist_module", - "token_send", - "utils", - "week-timekeeping", - "weekly-rewards-splitting", ] [[package]] diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs b/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs index 2ed024e96..f96e39727 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs +++ b/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs @@ -5,9 +5,10 @@ //////////////////////////////////////////////////// // Init: 1 +// Upgrade: 1 // Endpoints: 9 // Async Callback (empty): 1 -// Total number of exported functions: 11 +// Total number of exported functions: 12 #![no_std] @@ -18,6 +19,7 @@ multiversx_sc_wasm_adapter::endpoints! { farm_staking_proxy_legacy ( init => init + upgrade => upgrade unstakeFarmTokens => unstake_farm_tokens setTransferRoleDualYieldToken => set_transfer_role_dual_yield_token getDualYieldTokenId => dual_yield_token_id diff --git a/legacy-contracts/farm-v-13/Cargo.lock b/legacy-contracts/farm-v-13/Cargo.lock new file mode 100644 index 000000000..07b1eab79 --- /dev/null +++ b/legacy-contracts/farm-v-13/Cargo.lock @@ -0,0 +1,2593 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "Inflector" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" +dependencies = [ + "lazy_static", + "regex", +] + +[[package]] +name = "addr2line" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +dependencies = [ + "memchr", +] + +[[package]] +name = "anstream" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "is_terminal_polyfill", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" + +[[package]] +name = "anstyle-parse" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "anstyle-wincon" +version = "3.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +dependencies = [ + "anstyle", + "windows-sys 0.52.0", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "backtrace" +version = "0.3.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "bech32" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" + +[[package]] +name = "bip39" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" +dependencies = [ + "bitcoin_hashes", + "rand 0.8.5", + "rand_core 0.6.4", + "serde", + "unicode-normalization", +] + +[[package]] +name = "bitcoin_hashes" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "bstr" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" +dependencies = [ + "memchr", + "serde", +] + +[[package]] +name = "bumpalo" +version = "3.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" + +[[package]] +name = "cc" +version = "1.0.104" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "clap" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" +dependencies = [ + "clap_builder", + "clap_derive", +] + +[[package]] +name = "clap_builder" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" +dependencies = [ + "anstream", + "anstyle", + "clap_lex", + "strsim", +] + +[[package]] +name = "clap_derive" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "clap_lex" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" + +[[package]] +name = "colorchoice" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" + +[[package]] +name = "colored" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" +dependencies = [ + "lazy_static", + "windows-sys 0.48.0", +] + +[[package]] +name = "common-path" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" + +[[package]] +name = "convert_case" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "copy_dir" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" +dependencies = [ + "walkdir", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" + +[[package]] +name = "cpufeatures" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "curve25519-dalek" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" +dependencies = [ + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", + "subtle", + "zeroize", +] + +[[package]] +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "crypto-common", + "subtle", +] + +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "ed25519" +version = "1.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" +dependencies = [ + "signature", +] + +[[package]] +name = "ed25519-dalek" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +dependencies = [ + "curve25519-dalek", + "ed25519", + "rand 0.7.3", + "serde", + "sha2 0.9.9", + "zeroize", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "encoding_rs" +version = "0.8.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v-13-meta" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-meta", +] + +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + +[[package]] +name = "flate2" +version = "1.0.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures-channel" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" + +[[package]] +name = "futures-io" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" + +[[package]] +name = "futures-sink" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" + +[[package]] +name = "futures-task" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-util" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" +dependencies = [ + "futures-core", + "futures-io", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", +] + +[[package]] +name = "gimli" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" + +[[package]] +name = "globset" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" +dependencies = [ + "aho-corasick", + "bstr", + "log", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "h2" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" +dependencies = [ + "atomic-waker", + "bytes", + "fnv", + "futures-core", + "futures-sink", + "http", + "indexmap", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +dependencies = [ + "ahash", + "serde", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "http" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "hyper" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +dependencies = [ + "futures-util", + "http", + "hyper", + "hyper-util", + "rustls", + "rustls-pki-types", + "tokio", + "tokio-rustls", + "tower-service", +] + +[[package]] +name = "hyper-tls" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" +dependencies = [ + "bytes", + "http-body-util", + "hyper", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", +] + +[[package]] +name = "hyper-util" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", +] + +[[package]] +name = "idna" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "ignore" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" +dependencies = [ + "crossbeam-deque", + "globset", + "log", + "memchr", + "regex-automata", + "same-file", + "walkdir", + "winapi-util", +] + +[[package]] +name = "indexmap" +version = "2.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +dependencies = [ + "equivalent", + "hashbrown", + "serde", +] + +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "js-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "keccak" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" +dependencies = [ + "cpufeatures", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "libc" +version = "0.2.155" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" + +[[package]] +name = "linux-raw-sys" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" + +[[package]] +name = "lock_api" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" +dependencies = [ + "autocfg", + "scopeguard", +] + +[[package]] +name = "lockfree-object-pool" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" + +[[package]] +name = "log" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "miniz_oxide" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +dependencies = [ + "adler", +] + +[[package]] +name = "mio" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "multiversx-chain-scenario-format" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" +dependencies = [ + "bech32", + "hex", + "num-bigint", + "num-traits", + "serde", + "serde_json", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" +dependencies = [ + "bitflags 2.5.0", + "colored", + "ed25519-dalek", + "hex", + "hex-literal", + "itertools", + "multiversx-chain-vm-executor", + "num-bigint", + "num-traits", + "rand 0.8.5", + "rand_seeder", + "sha2 0.10.8", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm-executor" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags 2.5.0", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "num-bigint", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-meta" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" +dependencies = [ + "clap", + "colored", + "common-path", + "convert_case", + "copy_dir", + "hex", + "lazy_static", + "multiversx-sc", + "pathdiff", + "reqwest", + "ruplacer", + "rustc_version", + "semver", + "serde", + "serde_json", + "toml", + "wasmparser", + "wasmprinter", + "zip", +] + +[[package]] +name = "multiversx-sc-scenario" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" +dependencies = [ + "base64", + "bech32", + "clap", + "colored", + "hex", + "itertools", + "log", + "multiversx-chain-scenario-format", + "multiversx-chain-vm", + "multiversx-chain-vm-executor", + "multiversx-sc", + "multiversx-sc-meta", + "multiversx-sdk", + "num-bigint", + "num-traits", + "pathdiff", + "serde", + "serde_json", + "sha2 0.10.8", + "tokio", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sdk" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" +dependencies = [ + "anyhow", + "base64", + "bech32", + "bip39", + "hex", + "hmac", + "itertools", + "pbkdf2", + "pem", + "rand 0.8.5", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "sha2 0.10.8", + "sha3", + "tokio", + "zeroize", +] + +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-bigint" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + +[[package]] +name = "object" +version = "0.36.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "opaque-debug" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" + +[[package]] +name = "openssl" +version = "0.10.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +dependencies = [ + "bitflags 2.5.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "parking_lot" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall", + "smallvec", + "windows-targets 0.52.5", +] + +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + +[[package]] +name = "pbkdf2" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "pem" +version = "3.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" +dependencies = [ + "base64", + "serde", +] + +[[package]] +name = "percent-encoding" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" + +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkg-config" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.15", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] + +[[package]] +name = "rand_seeder" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "redox_syscall" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +dependencies = [ + "bitflags 2.5.0", +] + +[[package]] +name = "regex" +version = "1.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + +[[package]] +name = "reqwest" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" +dependencies = [ + "base64", + "bytes", + "encoding_rs", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-rustls", + "hyper-tls", + "hyper-util", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "system-configuration", + "tokio", + "tokio-native-tls", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "winreg", +] + +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.15", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "ruplacer" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" +dependencies = [ + "Inflector", + "anyhow", + "clap", + "colored", + "ignore", + "regex", +] + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags 2.5.0", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.52.0", +] + +[[package]] +name = "rustls" +version = "0.23.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-pemfile" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +dependencies = [ + "base64", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + +[[package]] +name = "rustls-webpki" +version = "0.102.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" +dependencies = [ + "bitflags 2.5.0", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "serde" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" +dependencies = [ + "indexmap", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_spanned" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "sha2" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" +dependencies = [ + "digest 0.10.7", + "keccak", +] + +[[package]] +name = "signal-hook-registry" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" +dependencies = [ + "libc", +] + +[[package]] +name = "signature" +version = "1.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" + +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "socket2" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + +[[package]] +name = "strsim" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" + +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "tempfile" +version = "3.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +dependencies = [ + "cfg-if", + "fastrand", + "rustix", + "windows-sys 0.52.0", +] + +[[package]] +name = "thiserror" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tinyvec" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +dependencies = [ + "backtrace", + "bytes", + "libc", + "mio", + "num_cpus", + "parking_lot", + "pin-project-lite", + "signal-hook-registry", + "socket2", + "tokio-macros", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-macros" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "0.8.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "pin-project-lite", + "tracing-core", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "url" +version = "2.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", +] + +[[package]] +name = "utf8parse" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +dependencies = [ + "cfg-if", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" + +[[package]] +name = "wasmparser" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" +dependencies = [ + "ahash", + "bitflags 2.5.0", + "hashbrown", + "indexmap", + "semver", + "serde", +] + +[[package]] +name = "wasmprinter" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" +dependencies = [ + "anyhow", + "wasmparser", +] + +[[package]] +name = "web-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "winapi-util" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.5", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +dependencies = [ + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" + +[[package]] +name = "winnow" +version = "0.6.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + +[[package]] +name = "zerocopy" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zip" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" +dependencies = [ + "arbitrary", + "crc32fast", + "crossbeam-utils", + "displaydoc", + "flate2", + "indexmap", + "memchr", + "thiserror", + "zopfli", +] + +[[package]] +name = "zopfli" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" +dependencies = [ + "bumpalo", + "crc32fast", + "lockfree-object-pool", + "log", + "once_cell", + "simd-adler32", +] diff --git a/legacy-contracts/farm-v-13/Cargo.toml b/legacy-contracts/farm-v-13/Cargo.toml new file mode 100644 index 000000000..73bb2feaa --- /dev/null +++ b/legacy-contracts/farm-v-13/Cargo.toml @@ -0,0 +1,18 @@ +[package] +name = "farm-v-13" +version = "0.0.0" +authors = ["you"] +edition = "2021" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "0.50.4" + +[dev-dependencies] +num-bigint = "0.4" + +[dev-dependencies.multiversx-sc-scenario] +version = "0.50.4" diff --git a/legacy-contracts/farm-v-13/meta/Cargo.toml b/legacy-contracts/farm-v-13/meta/Cargo.toml new file mode 100644 index 000000000..e8981d02c --- /dev/null +++ b/legacy-contracts/farm-v-13/meta/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "farm-v-13-meta" +version = "0.0.0" +edition = "2021" +publish = false + +[dependencies.farm-v-13] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.4" +default-features = false diff --git a/legacy-contracts/farm-v-13/meta/src/main.rs b/legacy-contracts/farm-v-13/meta/src/main.rs new file mode 100644 index 000000000..11be3279d --- /dev/null +++ b/legacy-contracts/farm-v-13/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-v-13/multiversx.json b/legacy-contracts/farm-v-13/multiversx.json new file mode 100644 index 000000000..736553962 --- /dev/null +++ b/legacy-contracts/farm-v-13/multiversx.json @@ -0,0 +1,3 @@ +{ + "language": "rust" +} \ No newline at end of file diff --git a/legacy-contracts/farm-v-13/src/lib.rs b/legacy-contracts/farm-v-13/src/lib.rs new file mode 100644 index 000000000..50f3bed11 --- /dev/null +++ b/legacy-contracts/farm-v-13/src/lib.rs @@ -0,0 +1,58 @@ +#![no_std] + +use multiversx_sc::derive_imports::*; +use multiversx_sc::imports::*; + +type ExitFarmResultType = + MultiValue2, EsdtTokenPayment>; + +#[derive( + ManagedVecItem, + TopEncode, + TopDecode, + NestedEncode, + NestedDecode, + TypeAbi, + Clone, + PartialEq, + Debug, +)] +pub struct FarmTokenAttributes { + pub reward_per_share: BigUint, + pub original_entering_epoch: u64, + pub entering_epoch: u64, + pub initial_farming_amount: BigUint, + pub compounded_reward: BigUint, + pub current_farm_amount: BigUint, +} + +#[multiversx_sc::contract] +pub trait FarmV13 { + #[init] + fn init(&self) {} + + #[upgrade] + fn upgrade(&self) {} + + #[payable("*")] + #[endpoint(exitFarm)] + fn exit_farm( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> ExitFarmResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(calculateRewardsForGivenPosition)] + fn calculate_rewards_for_given_position( + &self, + _amount: BigUint, + _attributes: FarmTokenAttributes, + ) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn end_produce_rewards(&self) {} +} diff --git a/legacy-contracts/farm-v-13/wasm/Cargo.lock b/legacy-contracts/farm-v-13/wasm/Cargo.lock new file mode 100644 index 000000000..3913dc656 --- /dev/null +++ b/legacy-contracts/farm-v-13/wasm/Cargo.lock @@ -0,0 +1,188 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "farm-v-13-wasm" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-wasm-adapter", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/legacy-contracts/farm-v-13/wasm/Cargo.toml b/legacy-contracts/farm-v-13/wasm/Cargo.toml new file mode 100644 index 000000000..70ce8ff84 --- /dev/null +++ b/legacy-contracts/farm-v-13/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "farm-v-13-wasm" +version = "0.0.0" +edition = "2021" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.farm-v-13] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "0.50.4" + +[workspace] +members = ["."] diff --git a/legacy-contracts/farm-v-13/wasm/src/lib.rs b/legacy-contracts/farm-v-13/wasm/src/lib.rs new file mode 100644 index 000000000..850923617 --- /dev/null +++ b/legacy-contracts/farm-v-13/wasm/src/lib.rs @@ -0,0 +1,29 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Upgrade: 1 +// Endpoints: 3 +// Async Callback (empty): 1 +// Total number of exported functions: 6 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + farm_v_13 + ( + init => init + upgrade => upgrade + exitFarm => exit_farm + calculateRewardsForGivenPosition => calculate_rewards_for_given_position + end_produce_rewards => end_produce_rewards + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} From 343f8d8fb20e071ca8d3abf8f17ba674150b0b40 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 2 Jul 2024 02:08:49 +0300 Subject: [PATCH 071/103] farm staking proxy legacy sc rename to v1.3 --- Cargo.lock | 22 +++++++++---------- Cargo.toml | 4 ++-- .../meta/src/main.rs | 3 --- .../.gitignore | 0 .../Cargo.toml | 2 +- .../meta/Cargo.toml | 4 ++-- .../farm-staking-proxy-v-13/meta/src/main.rs | 3 +++ .../multiversx.json | 0 .../src/dual_yield_token.rs | 0 .../src/external_contracts_interactions.rs | 0 .../src/lib.rs | 0 .../src/lp_farm_token.rs | 0 .../src/result_types.rs | 0 .../tests/constants/mod.rs | 0 .../tests/staking_farm_with_lp.rs | 0 .../mod.rs | 0 .../mod.rs | 0 .../mod.rs | 0 .../wasm/Cargo.lock | 6 ++--- .../wasm/Cargo.toml | 4 ++-- .../wasm/src/lib.rs | 2 +- 21 files changed, 25 insertions(+), 25 deletions(-) delete mode 100644 legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/.gitignore (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/Cargo.toml (97%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/meta/Cargo.toml (71%) create mode 100644 legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/multiversx.json (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/src/dual_yield_token.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/src/external_contracts_interactions.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/src/lib.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/src/lp_farm_token.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/src/result_types.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/tests/constants/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/tests/staking_farm_with_lp.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/tests/staking_farm_with_lp_external_contracts/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/tests/staking_farm_with_lp_staking_contract_setup/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/wasm/Cargo.lock (99%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/wasm/Cargo.toml (87%) rename legacy-contracts/{farm-staking-proxy-legacy => farm-staking-proxy-v-13}/wasm/src/lib.rs (97%) diff --git a/Cargo.lock b/Cargo.lock index 9b2bb784e..313f2eb05 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -885,7 +885,15 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-legacy" +name = "farm-staking-proxy-meta" +version = "0.0.0" +dependencies = [ + "farm-staking-proxy", + "multiversx-sc-meta", +] + +[[package]] +name = "farm-staking-proxy-v-13" version = "0.0.0" dependencies = [ "common_structs", @@ -909,18 +917,10 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-legacy-meta" +name = "farm-staking-proxy-v-13-meta" version = "0.0.0" dependencies = [ - "farm-staking-proxy-legacy", - "multiversx-sc-meta", -] - -[[package]] -name = "farm-staking-proxy-meta" -version = "0.0.0" -dependencies = [ - "farm-staking-proxy", + "farm-staking-proxy-v-13", "multiversx-sc-meta", ] diff --git a/Cargo.toml b/Cargo.toml index 537839c76..88a66788f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -39,8 +39,8 @@ members = [ "legacy-contracts/simple-lock-legacy", "legacy-contracts/simple-lock-legacy/meta", - "legacy-contracts/farm-staking-proxy-legacy", - "legacy-contracts/farm-staking-proxy-legacy/meta", + "legacy-contracts/farm-staking-proxy-v-13", + "legacy-contracts/farm-staking-proxy-v-13/meta", "legacy-contracts/farm-v-13", "legacy-contracts/farm-v-13/meta", diff --git a/legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs b/legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs deleted file mode 100644 index 98ff6943a..000000000 --- a/legacy-contracts/farm-staking-proxy-legacy/meta/src/main.rs +++ /dev/null @@ -1,3 +0,0 @@ -fn main() { - multiversx_sc_meta::cli_main::(); -} diff --git a/legacy-contracts/farm-staking-proxy-legacy/.gitignore b/legacy-contracts/farm-staking-proxy-v-13/.gitignore similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/.gitignore rename to legacy-contracts/farm-staking-proxy-v-13/.gitignore diff --git a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml b/legacy-contracts/farm-staking-proxy-v-13/Cargo.toml similarity index 97% rename from legacy-contracts/farm-staking-proxy-legacy/Cargo.toml rename to legacy-contracts/farm-staking-proxy-v-13/Cargo.toml index d85ae3897..a6e296a92 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v-13/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "farm-staking-proxy-legacy" +name = "farm-staking-proxy-v-13" version = "0.0.0" authors = ["MultiversX "] edition = "2021" diff --git a/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml b/legacy-contracts/farm-staking-proxy-v-13/meta/Cargo.toml similarity index 71% rename from legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml rename to legacy-contracts/farm-staking-proxy-v-13/meta/Cargo.toml index 4f7087bb4..d8697f9f8 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/meta/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v-13/meta/Cargo.toml @@ -1,11 +1,11 @@ [package] -name = "farm-staking-proxy-legacy-meta" +name = "farm-staking-proxy-v-13-meta" version = "0.0.0" edition = "2021" publish = false authors = ["MultiversX "] -[dependencies.farm-staking-proxy-legacy] +[dependencies.farm-staking-proxy-v-13] path = ".." [dependencies.multiversx-sc-meta] diff --git a/legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs b/legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs new file mode 100644 index 000000000..0c5fc84db --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-staking-proxy-legacy/multiversx.json b/legacy-contracts/farm-staking-proxy-v-13/multiversx.json similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/multiversx.json rename to legacy-contracts/farm-staking-proxy-v-13/multiversx.json diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/dual_yield_token.rs b/legacy-contracts/farm-staking-proxy-v-13/src/dual_yield_token.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/src/dual_yield_token.rs rename to legacy-contracts/farm-staking-proxy-v-13/src/dual_yield_token.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs b/legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/src/external_contracts_interactions.rs rename to legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/lib.rs b/legacy-contracts/farm-staking-proxy-v-13/src/lib.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/src/lib.rs rename to legacy-contracts/farm-staking-proxy-v-13/src/lib.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/lp_farm_token.rs b/legacy-contracts/farm-staking-proxy-v-13/src/lp_farm_token.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/src/lp_farm_token.rs rename to legacy-contracts/farm-staking-proxy-v-13/src/lp_farm_token.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/src/result_types.rs b/legacy-contracts/farm-staking-proxy-v-13/src/result_types.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/src/result_types.rs rename to legacy-contracts/farm-staking-proxy-v-13/src/result_types.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs b/legacy-contracts/farm-staking-proxy-v-13/tests/constants/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/tests/constants/mod.rs rename to legacy-contracts/farm-staking-proxy-v-13/tests/constants/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs b/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp.rs rename to legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs b/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_external_contracts/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_external_contracts/mod.rs rename to legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_external_contracts/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs rename to legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs b/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_setup/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-legacy/tests/staking_farm_with_lp_staking_contract_setup/mod.rs rename to legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_setup/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock b/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.lock similarity index 99% rename from legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock rename to legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.lock index d441ce738..f011a6c64 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.lock +++ b/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.lock @@ -193,7 +193,7 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-legacy" +name = "farm-staking-proxy-v-13" version = "0.0.0" dependencies = [ "common_structs", @@ -206,10 +206,10 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-legacy-wasm" +name = "farm-staking-proxy-v-13-wasm" version = "0.0.0" dependencies = [ - "farm-staking-proxy-legacy", + "farm-staking-proxy-v-13", "multiversx-sc-wasm-adapter", ] diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml b/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.toml similarity index 87% rename from legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml rename to legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.toml index 0990dd0b6..760fe337f 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.toml @@ -5,7 +5,7 @@ # ########################################## [package] -name = "farm-staking-proxy-legacy-wasm" +name = "farm-staking-proxy-v-13-wasm" version = "0.0.0" edition = "2021" publish = false @@ -24,7 +24,7 @@ overflow-checks = false [profile.dev] panic = "abort" -[dependencies.farm-staking-proxy-legacy] +[dependencies.farm-staking-proxy-v-13] path = ".." [dependencies.multiversx-sc-wasm-adapter] diff --git a/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs b/legacy-contracts/farm-staking-proxy-v-13/wasm/src/lib.rs similarity index 97% rename from legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs rename to legacy-contracts/farm-staking-proxy-v-13/wasm/src/lib.rs index f96e39727..f926207ed 100644 --- a/legacy-contracts/farm-staking-proxy-legacy/wasm/src/lib.rs +++ b/legacy-contracts/farm-staking-proxy-v-13/wasm/src/lib.rs @@ -16,7 +16,7 @@ multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); multiversx_sc_wasm_adapter::endpoints! { - farm_staking_proxy_legacy + farm_staking_proxy_v_13 ( init => init upgrade => upgrade From ee45c1e23fbee23fce5692fc81e319ce6c2046f7 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 3 Jul 2024 21:44:44 +0300 Subject: [PATCH 072/103] Farm staking proxy legacy SC interactions update --- .../src/external_contracts_interactions.rs | 13 +++---------- legacy-contracts/farm-v-13/src/lib.rs | 4 ++++ 2 files changed, 7 insertions(+), 10 deletions(-) diff --git a/legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs b/legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs index 11c226cb8..9e6d3e49e 100644 --- a/legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs +++ b/legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs @@ -2,13 +2,10 @@ multiversx_sc::imports!(); use common_structs::{RawResultWrapper, RawResultsType}; use farm_staking::unstake_farm::ProxyTrait as _; -use multiversx_sc::storage::StorageKey; use pair::pair_actions::remove_liq::ProxyTrait as _; use crate::result_types::*; -pub static FARMING_TOKEN_STORAGE_KEY: &[u8] = b"farming_token_id"; - #[multiversx_sc::module] pub trait ExternalContractsInteractionsModule: crate::lp_farm_token::LpFarmTokenModule + token_merge_helper::TokenMergeHelperModule @@ -49,13 +46,9 @@ pub trait ExternalContractsInteractionsModule: fn get_lp_farming_token_identifier(&self) -> TokenIdentifier { let lp_farm_address = self.lp_farm_address().get(); - - let farming_token_mapper = SingleValueMapper::<_, _, ManagedAddress>::new_from_address( - lp_farm_address, - StorageKey::new(FARMING_TOKEN_STORAGE_KEY), - ); - - farming_token_mapper.get() + self.lp_farm_proxy_obj(lp_farm_address) + .farming_token_id() + .execute_on_dest_context() } // staking farm diff --git a/legacy-contracts/farm-v-13/src/lib.rs b/legacy-contracts/farm-v-13/src/lib.rs index 50f3bed11..4f1660e1d 100644 --- a/legacy-contracts/farm-v-13/src/lib.rs +++ b/legacy-contracts/farm-v-13/src/lib.rs @@ -55,4 +55,8 @@ pub trait FarmV13 { #[only_owner] #[endpoint] fn end_produce_rewards(&self) {} + + #[view(getFarmingTokenId)] + #[storage_mapper("farming_token_id")] + fn farming_token_id(&self) -> SingleValueMapper; } From 04285fa70303ea533c72e7c36d132c3c4b52667a Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 11 Jul 2024 15:55:40 +0300 Subject: [PATCH 073/103] user total farm position split --- common/modules/farm/config/src/config.rs | 61 ++-------- .../farm_base_impl/src/base_traits_impl.rs | 22 ++-- dex/farm-with-locked-rewards/src/lib.rs | 3 +- dex/farm-with-locked-rewards/wasm/src/lib.rs | 4 +- dex/farm/src/base_functions.rs | 23 ++-- dex/farm/src/lib.rs | 3 +- .../tests/farm_setup/multi_user_farm_setup.rs | 18 +-- dex/farm/wasm/src/lib.rs | 4 +- .../farm-boosted-yields/src/lib.rs | 4 +- .../tests/staking_farm_with_lp.rs | 4 +- .../mod.rs | 18 +-- .../farm-staking/src/base_impl_wrapper.rs | 29 +++-- .../src/claim_only_boosted_staking_rewards.rs | 21 ++-- .../src/claim_stake_farm_rewards.rs | 8 +- .../tests/farm_staking_energy_test.rs | 5 +- .../tests/farm_staking_setup/mod.rs | 4 +- farm-staking/farm-staking/wasm/src/lib.rs | 4 +- legacy-contracts/farm-v-13/wasm/src/lib.rs | 5 +- .../energy-factory/src/unlock_with_penalty.rs | 17 +++ .../tests/proxy_dex_test_setup/mod.rs | 4 +- .../proxy_dex/tests/proxy_farm_test.rs | 105 +++++++++--------- 21 files changed, 159 insertions(+), 207 deletions(-) diff --git a/common/modules/farm/config/src/config.rs b/common/modules/farm/config/src/config.rs index b712765e5..1f26eed6a 100644 --- a/common/modules/farm/config/src/config.rs +++ b/common/modules/farm/config/src/config.rs @@ -9,46 +9,12 @@ use pausable::State; pub const DEFAULT_NFT_DEPOSIT_MAX_LEN: usize = 10; pub const DEFAULT_FARM_POSITION_MIGRATION_NONCE: u64 = 1; -#[derive( - ManagedVecItem, - TopEncode, - TopDecode, - NestedEncode, - NestedDecode, - TypeAbi, - Clone, - PartialEq, - Debug, -)] -pub struct UserTotalFarmPosition { - pub total_farm_position: BigUint, - pub allow_external_claim_boosted_rewards: bool, -} - -impl Default for UserTotalFarmPosition { - fn default() -> Self { - Self { - total_farm_position: BigUint::zero(), - allow_external_claim_boosted_rewards: false, - } - } -} - #[multiversx_sc::module] pub trait ConfigModule: pausable::PausableModule + permissions_module::PermissionsModule { - #[endpoint(allowExternalClaimBoostedRewards)] - fn allow_external_claim_boosted_rewards(&self, allow_external_claim: bool) { + #[endpoint(setAllowExternalClaimBoostedRewards)] + fn set_allow_external_claim(&self, allow_external_claim: bool) { let caller = self.blockchain().get_caller(); - let mut user_total_farm_position = self.get_user_total_farm_position(&caller); - user_total_farm_position.allow_external_claim_boosted_rewards = allow_external_claim; - self.user_total_farm_position(&caller) - .set(user_total_farm_position); - } - - #[view(getAllowExternalClaimRewards)] - fn get_allow_external_claim_rewards(&self, user: ManagedAddress) -> bool { - let user_total_farm_position = self.get_user_total_farm_position(&user); - user_total_farm_position.allow_external_claim_boosted_rewards + self.allow_external_claim(&caller).set(allow_external_claim); } #[inline] @@ -57,18 +23,6 @@ pub trait ConfigModule: pausable::PausableModule + permissions_module::Permissio state == State::Active } - fn get_user_total_farm_position( - &self, - user: &ManagedAddress, - ) -> UserTotalFarmPosition { - let user_total_farm_position_mapper = self.user_total_farm_position(user); - if user_total_farm_position_mapper.is_empty() { - UserTotalFarmPosition::default() - } else { - user_total_farm_position_mapper.get() - } - } - fn is_old_farm_position(&self, token_nonce: Nonce) -> bool { let farm_position_migration_nonce = self.farm_position_migration_nonce().get(); token_nonce > 0 && token_nonce < farm_position_migration_nonce @@ -121,10 +75,11 @@ pub trait ConfigModule: pausable::PausableModule + permissions_module::Permissio #[view(getUserTotalFarmPosition)] #[storage_mapper("userTotalFarmPosition")] - fn user_total_farm_position( - &self, - user: &ManagedAddress, - ) -> SingleValueMapper>; + fn user_total_farm_position(&self, user: &ManagedAddress) -> SingleValueMapper; + + #[view(getAllowExternalClaim)] + #[storage_mapper("allowExternalClaim")] + fn allow_external_claim(&self, user: &ManagedAddress) -> SingleValueMapper; #[view(getFarmPositionMigrationNonce)] #[storage_mapper("farm_position_migration_nonce")] diff --git a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs index f26b15099..f7f5014ff 100644 --- a/common/modules/farm/farm_base_impl/src/base_traits_impl.rs +++ b/common/modules/farm/farm_base_impl/src/base_traits_impl.rs @@ -230,10 +230,8 @@ pub trait FarmContract { user: &ManagedAddress<::Api>, increase_farm_position_amount: &BigUint<::Api>, ) { - let mut user_total_farm_position = sc.get_user_total_farm_position(user); - user_total_farm_position.total_farm_position += increase_farm_position_amount; sc.user_total_farm_position(user) - .set(user_total_farm_position); + .update(|total_farm_position| *total_farm_position += increase_farm_position_amount); } fn decrease_user_farm_position( @@ -248,14 +246,16 @@ pub trait FarmContract { let token_attributes: FarmTokenAttributes<::Api> = farm_token_mapper.get_token_attributes(farm_position.token_nonce); - sc.user_total_farm_position(&token_attributes.original_owner) - .update(|user_total_farm_position| { - if user_total_farm_position.total_farm_position > farm_position.amount { - user_total_farm_position.total_farm_position -= &farm_position.amount; - } else { - user_total_farm_position.total_farm_position = BigUint::zero(); - } - }); + let user_total_farm_position_mapper = + sc.user_total_farm_position(&token_attributes.original_owner); + let mut user_total_farm_position = user_total_farm_position_mapper.get(); + + if user_total_farm_position > farm_position.amount { + user_total_farm_position -= &farm_position.amount; + user_total_farm_position_mapper.set(user_total_farm_position); + } else { + user_total_farm_position_mapper.clear(); + } } } diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index ab57eb826..91144b387 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -230,10 +230,9 @@ pub trait Farm: OptionalValue::Some(user) => user, OptionalValue::None => &caller, }; - let user_total_farm_position = self.get_user_total_farm_position(user); if user != &caller { require!( - user_total_farm_position.allow_external_claim_boosted_rewards, + self.allow_external_claim(user).get(), "Cannot claim rewards for this address" ); } diff --git a/dex/farm-with-locked-rewards/wasm/src/lib.rs b/dex/farm-with-locked-rewards/wasm/src/lib.rs index 37561d256..9efe33713 100644 --- a/dex/farm-with-locked-rewards/wasm/src/lib.rs +++ b/dex/farm-with-locked-rewards/wasm/src/lib.rs @@ -32,14 +32,14 @@ multiversx_sc_wasm_adapter::endpoints! { calculateRewardsForGivenPosition => calculate_rewards_for_given_position getRewardPerShare => reward_per_share getRewardReserve => reward_reserve - allowExternalClaimBoostedRewards => allow_external_claim_boosted_rewards - getAllowExternalClaimRewards => get_allow_external_claim_rewards + setAllowExternalClaimBoostedRewards => set_allow_external_claim getFarmingTokenId => farming_token_id getRewardTokenId => reward_token_id getPerBlockRewardAmount => per_block_reward_amount getLastRewardBlockNonce => last_reward_block_nonce getDivisionSafetyConstant => division_safety_constant getUserTotalFarmPosition => user_total_farm_position + getAllowExternalClaim => allow_external_claim getFarmPositionMigrationNonce => farm_position_migration_nonce setLockingScAddress => set_locking_sc_address setLockEpochs => set_lock_epochs diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index 48a59ac56..d6455a2b7 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -218,10 +218,8 @@ pub trait BaseFunctionsModule: } if migrated_amount > 0 { - let mut user_total_farm_position = self.get_user_total_farm_position(caller); - user_total_farm_position.total_farm_position += &migrated_amount; self.user_total_farm_position(caller) - .set(user_total_farm_position); + .update(|total_farm_position| *total_farm_position += &migrated_amount); } migrated_amount @@ -231,10 +229,16 @@ pub trait BaseFunctionsModule: if migrated_amount == BigUint::zero() { return; } - self.user_total_farm_position(caller) - .update(|user_total_farm_position| { - user_total_farm_position.total_farm_position -= migrated_amount; - }); + + let user_total_farm_position_mapper = self.user_total_farm_position(caller); + let mut user_total_farm_position = user_total_farm_position_mapper.get(); + + if user_total_farm_position > migrated_amount { + user_total_farm_position -= &migrated_amount; + user_total_farm_position_mapper.set(user_total_farm_position); + } else { + user_total_farm_position_mapper.clear(); + } } fn end_produce_rewards>(&self) { @@ -281,10 +285,9 @@ where sc: &::FarmSc, caller: &ManagedAddress<<::FarmSc as ContractBase>::Api>, ) -> BigUint<<::FarmSc as ContractBase>::Api> { - let user_total_farm_position = sc.get_user_total_farm_position(caller); - let user_farm_position = user_total_farm_position.total_farm_position; + let user_total_farm_position = sc.user_total_farm_position(caller).get(); - sc.claim_boosted_yields_rewards(caller, user_farm_position) + sc.claim_boosted_yields_rewards(caller, user_total_farm_position) } } diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index d51b9989c..0987dbbce 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -221,10 +221,9 @@ pub trait Farm: OptionalValue::Some(user) => user, OptionalValue::None => &caller, }; - let user_total_farm_position = self.get_user_total_farm_position(user); if user != &caller { require!( - user_total_farm_position.allow_external_claim_boosted_rewards, + self.allow_external_claim(&user).get(), "Cannot claim rewards for this address" ); } diff --git a/dex/farm/tests/farm_setup/multi_user_farm_setup.rs b/dex/farm/tests/farm_setup/multi_user_farm_setup.rs index 60a82cea2..cb12a2a1e 100644 --- a/dex/farm/tests/farm_setup/multi_user_farm_setup.rs +++ b/dex/farm/tests/farm_setup/multi_user_farm_setup.rs @@ -2,7 +2,7 @@ #![allow(deprecated)] use common_structs::FarmTokenAttributes; -use config::{ConfigModule, UserTotalFarmPosition}; +use config::ConfigModule; use multiversx_sc::codec::multi_types::OptionalValue; use multiversx_sc::{ storage::mappers::StorageTokenWrapper, @@ -610,12 +610,8 @@ where pub fn allow_external_claim_rewards(&mut self, user: &Address, allow_external_claim: bool) { self.b_mock .execute_tx(user, &self.farm_wrapper, &rust_biguint!(0), |sc| { - sc.user_total_farm_position(&managed_address!(user)).update( - |user_total_farm_position| { - user_total_farm_position.allow_external_claim_boosted_rewards = - allow_external_claim; - }, - ); + sc.allow_external_claim(&managed_address!(user)) + .set(allow_external_claim); }) .assert_ok(); } @@ -711,12 +707,8 @@ where pub fn set_user_total_farm_position(&mut self, user_addr: &Address, new_farm_position: u64) { self.b_mock .execute_tx(&self.owner, &self.farm_wrapper, &rust_biguint!(0), |sc| { - let user_farm_position = UserTotalFarmPosition { - total_farm_position: managed_biguint!(new_farm_position), - ..Default::default() - }; sc.user_total_farm_position(&managed_address!(user_addr)) - .set(user_farm_position); + .set(managed_biguint!(new_farm_position)); }) .assert_ok(); } @@ -729,7 +721,7 @@ where if expected_amount > 0 && !user_total_farm_position_mapper.is_empty() { assert_eq!( managed_biguint!(expected_amount), - user_total_farm_position_mapper.get().total_farm_position + user_total_farm_position_mapper.get() ); } }) diff --git a/dex/farm/wasm/src/lib.rs b/dex/farm/wasm/src/lib.rs index 60fe520f8..a4b92d26e 100644 --- a/dex/farm/wasm/src/lib.rs +++ b/dex/farm/wasm/src/lib.rs @@ -33,14 +33,14 @@ multiversx_sc_wasm_adapter::endpoints! { calculateRewardsForGivenPosition => calculate_rewards_for_given_position getRewardPerShare => reward_per_share getRewardReserve => reward_reserve - allowExternalClaimBoostedRewards => allow_external_claim_boosted_rewards - getAllowExternalClaimRewards => get_allow_external_claim_rewards + setAllowExternalClaimBoostedRewards => set_allow_external_claim getFarmingTokenId => farming_token_id getRewardTokenId => reward_token_id getPerBlockRewardAmount => per_block_reward_amount getLastRewardBlockNonce => last_reward_block_nonce getDivisionSafetyConstant => division_safety_constant getUserTotalFarmPosition => user_total_farm_position + getAllowExternalClaim => allow_external_claim getFarmPositionMigrationNonce => farm_position_migration_nonce registerFarmToken => register_farm_token getFarmTokenId => farm_token diff --git a/energy-integration/farm-boosted-yields/src/lib.rs b/energy-integration/farm-boosted-yields/src/lib.rs index 09bacc676..739907b2c 100644 --- a/energy-integration/farm-boosted-yields/src/lib.rs +++ b/energy-integration/farm-boosted-yields/src/lib.rs @@ -123,12 +123,12 @@ pub trait FarmBoostedYieldsModule: fn clear_user_energy_if_needed(&self, original_caller: &ManagedAddress) { let opt_config = self.try_get_boosted_yields_config(); - let user_total_farm_position = self.get_user_total_farm_position(original_caller); + let user_total_farm_position = self.user_total_farm_position(original_caller).get(); if let Some(config) = opt_config { let boosted_yields_factors = config.get_latest_factors(); self.clear_user_energy( original_caller, - &user_total_farm_position.total_farm_position, + &user_total_farm_position, &boosted_yields_factors.min_farm_amount, ); } diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs index 34fbe059e..1321443ee 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs @@ -773,7 +773,7 @@ fn claim_for_others_positive_test() { &setup.lp_farm_wrapper, &rust_biguint!(0), |sc| { - sc.allow_external_claim_boosted_rewards(true); + sc.set_allow_external_claim(true); }, ) .assert_ok(); @@ -785,7 +785,7 @@ fn claim_for_others_positive_test() { &setup.staking_farm_wrapper, &rust_biguint!(0), |sc| { - sc.allow_external_claim_boosted_rewards(true); + sc.set_allow_external_claim(true); }, ) .assert_ok(); diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs index 151a4f5ec..aba5f5713 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs @@ -1,6 +1,6 @@ #![allow(deprecated)] -use config::{ConfigModule, UserTotalFarmPosition}; +use config::ConfigModule; use energy_factory::energy::EnergyModule; use energy_query::Energy; use farm_with_locked_rewards::Farm; @@ -679,12 +679,8 @@ where &self.staking_farm_wrapper, &rust_biguint!(0), |sc| { - let user_farm_position = UserTotalFarmPosition { - total_farm_position: managed_biguint!(new_farm_position), - ..Default::default() - }; sc.user_total_farm_position(&managed_address!(user_addr)) - .set(user_farm_position); + .set(managed_biguint!(new_farm_position)); }, ) .assert_ok(); @@ -697,12 +693,8 @@ where &self.lp_farm_wrapper, &rust_biguint!(0), |sc| { - let user_farm_position = UserTotalFarmPosition { - total_farm_position: managed_biguint!(new_farm_position), - ..Default::default() - }; sc.user_total_farm_position(&managed_address!(user_addr)) - .set(user_farm_position); + .set(managed_biguint!(new_farm_position)); }, ) .assert_ok(); @@ -720,7 +712,7 @@ where if expected_amount > 0 && !user_total_farm_position_mapper.is_empty() { assert_eq!( managed_biguint!(expected_amount), - user_total_farm_position_mapper.get().total_farm_position + user_total_farm_position_mapper.get() ); } }) @@ -735,7 +727,7 @@ where if expected_amount > 0 && !user_total_farm_position_mapper.is_empty() { assert_eq!( managed_biguint!(expected_amount), - user_total_farm_position_mapper.get().total_farm_position + user_total_farm_position_mapper.get() ); } }) diff --git a/farm-staking/farm-staking/src/base_impl_wrapper.rs b/farm-staking/farm-staking/src/base_impl_wrapper.rs index 357d2f048..f2208cfde 100644 --- a/farm-staking/farm-staking/src/base_impl_wrapper.rs +++ b/farm-staking/farm-staking/src/base_impl_wrapper.rs @@ -62,12 +62,11 @@ where sc: &::FarmSc, caller: &ManagedAddress<<::FarmSc as ContractBase>::Api>, ) -> BigUint<<::FarmSc as ContractBase>::Api> { - let user_total_farm_position = sc.get_user_total_farm_position(caller); - let user_farm_position = user_total_farm_position.total_farm_position; + let user_total_farm_position = sc.user_total_farm_position(caller).get(); let mut boosted_rewards = BigUint::zero(); - if user_farm_position > 0 { - boosted_rewards = sc.claim_boosted_yields_rewards(caller, user_farm_position); + if user_total_farm_position > 0 { + boosted_rewards = sc.claim_boosted_yields_rewards(caller, user_total_farm_position); } boosted_rewards @@ -228,10 +227,8 @@ where user: &ManagedAddress<::Api>, increase_farm_position_amount: &BigUint<::Api>, ) { - let mut user_total_farm_position = sc.get_user_total_farm_position(user); - user_total_farm_position.total_farm_position += increase_farm_position_amount; sc.user_total_farm_position(user) - .set(user_total_farm_position); + .update(|total_farm_position| *total_farm_position += increase_farm_position_amount); } fn decrease_user_farm_position( @@ -246,13 +243,15 @@ where let token_attributes: StakingFarmTokenAttributes<::Api> = farm_token_mapper.get_token_attributes(farm_position.token_nonce); - sc.user_total_farm_position(&token_attributes.original_owner) - .update(|user_total_farm_position| { - if user_total_farm_position.total_farm_position > farm_position.amount { - user_total_farm_position.total_farm_position -= &farm_position.amount; - } else { - user_total_farm_position.total_farm_position = BigUint::zero(); - } - }); + let user_total_farm_position_mapper = + sc.user_total_farm_position(&token_attributes.original_owner); + let mut user_total_farm_position = user_total_farm_position_mapper.get(); + + if user_total_farm_position > farm_position.amount { + user_total_farm_position -= &farm_position.amount; + user_total_farm_position_mapper.set(user_total_farm_position); + } else { + user_total_farm_position_mapper.clear(); + } } } diff --git a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs index b13ccc62d..a1843a1f6 100644 --- a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs +++ b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs @@ -31,10 +31,9 @@ pub trait ClaimOnlyBoostedStakingRewardsModule: OptionalValue::Some(user) => user, OptionalValue::None => &caller, }; - let user_total_farm_position = self.get_user_total_farm_position(user); if user != &caller { require!( - user_total_farm_position.allow_external_claim_boosted_rewards, + self.allow_external_claim(user).get(), "Cannot claim rewards for this address" ); } @@ -62,10 +61,8 @@ pub trait ClaimOnlyBoostedStakingRewardsModule: } if migrated_amount > 0 { - let mut user_total_farm_position = self.get_user_total_farm_position(caller); - user_total_farm_position.total_farm_position += &migrated_amount; self.user_total_farm_position(caller) - .set(user_total_farm_position); + .update(|total_farm_position| *total_farm_position += &migrated_amount); } migrated_amount @@ -75,10 +72,16 @@ pub trait ClaimOnlyBoostedStakingRewardsModule: if migrated_amount == BigUint::zero() { return; } - self.user_total_farm_position(caller) - .update(|user_total_farm_position| { - user_total_farm_position.total_farm_position -= migrated_amount; - }); + + let user_total_farm_position_mapper = self.user_total_farm_position(caller); + let mut user_total_farm_position = user_total_farm_position_mapper.get(); + + if user_total_farm_position > migrated_amount { + user_total_farm_position -= &migrated_amount; + user_total_farm_position_mapper.set(user_total_farm_position); + } else { + user_total_farm_position_mapper.clear(); + } } // Cannot import the one from farm, as the Wrapper struct has different dependencies diff --git a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs index 93d4802ea..14aa23da7 100644 --- a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs @@ -74,11 +74,11 @@ pub trait ClaimStakeFarmRewardsModule: claim_result.storage_cache.farm_token_supply -= &virtual_farm_token.payment.amount; claim_result.storage_cache.farm_token_supply += &new_amount; - let mut user_total_farm_position = self.get_user_total_farm_position(&original_caller); - user_total_farm_position.total_farm_position -= &virtual_farm_token.payment.amount; - user_total_farm_position.total_farm_position += &new_amount; self.user_total_farm_position(&original_caller) - .set(user_total_farm_position); + .update(|total_farm_position| { + *total_farm_position -= &virtual_farm_token.payment.amount; + *total_farm_position += &new_amount; + }); virtual_farm_token.payment.amount = new_amount.clone(); virtual_farm_token.attributes.current_farm_amount = new_amount; diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index facc2025f..1274be166 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1050,11 +1050,8 @@ fn farm_staking_farm_position_migration_test() { 0, &rust_biguint!(10), |sc| { - let mut user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&user)); - user_total_farm_position.total_farm_position = managed_biguint!(0u64); sc.user_total_farm_position(&managed_address!(&user)) - .set(user_total_farm_position); + .set(managed_biguint!(0u64)); sc.farm_position_migration_nonce().set(5); }, diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index 369b029bd..0d0cd74f4 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -569,7 +569,7 @@ where pub fn allow_external_claim_rewards(&mut self, user: &Address, allow_claim: bool) { self.b_mock .execute_tx(user, &self.farm_wrapper, &rust_biguint!(0), |sc| { - sc.allow_external_claim_boosted_rewards(allow_claim); + sc.set_allow_external_claim(allow_claim); }) .assert_ok(); } @@ -755,7 +755,7 @@ where if expected_amount > 0 && !user_total_farm_position_mapper.is_empty() { assert_eq!( managed_biguint!(expected_amount), - user_total_farm_position_mapper.get().total_farm_position + user_total_farm_position_mapper.get() ); } }) diff --git a/farm-staking/farm-staking/wasm/src/lib.rs b/farm-staking/farm-staking/wasm/src/lib.rs index 4842309c2..a5dfd5522 100644 --- a/farm-staking/farm-staking/wasm/src/lib.rs +++ b/farm-staking/farm-staking/wasm/src/lib.rs @@ -36,14 +36,14 @@ multiversx_sc_wasm_adapter::endpoints! { getMinUnbondEpochs => min_unbond_epochs getRewardPerShare => reward_per_share getRewardReserve => reward_reserve - allowExternalClaimBoostedRewards => allow_external_claim_boosted_rewards - getAllowExternalClaimRewards => get_allow_external_claim_rewards + setAllowExternalClaimBoostedRewards => set_allow_external_claim getFarmingTokenId => farming_token_id getRewardTokenId => reward_token_id getPerBlockRewardAmount => per_block_reward_amount getLastRewardBlockNonce => last_reward_block_nonce getDivisionSafetyConstant => division_safety_constant getUserTotalFarmPosition => user_total_farm_position + getAllowExternalClaim => allow_external_claim getFarmPositionMigrationNonce => farm_position_migration_nonce registerFarmToken => register_farm_token getFarmTokenId => farm_token diff --git a/legacy-contracts/farm-v-13/wasm/src/lib.rs b/legacy-contracts/farm-v-13/wasm/src/lib.rs index 850923617..ad5759863 100644 --- a/legacy-contracts/farm-v-13/wasm/src/lib.rs +++ b/legacy-contracts/farm-v-13/wasm/src/lib.rs @@ -6,9 +6,9 @@ // Init: 1 // Upgrade: 1 -// Endpoints: 3 +// Endpoints: 4 // Async Callback (empty): 1 -// Total number of exported functions: 6 +// Total number of exported functions: 7 #![no_std] @@ -23,6 +23,7 @@ multiversx_sc_wasm_adapter::endpoints! { exitFarm => exit_farm calculateRewardsForGivenPosition => calculate_rewards_for_given_position end_produce_rewards => end_produce_rewards + getFarmingTokenId => farming_token_id ) } diff --git a/locked-asset/energy-factory/src/unlock_with_penalty.rs b/locked-asset/energy-factory/src/unlock_with_penalty.rs index 102565ed5..a92285128 100644 --- a/locked-asset/energy-factory/src/unlock_with_penalty.rs +++ b/locked-asset/energy-factory/src/unlock_with_penalty.rs @@ -195,3 +195,20 @@ pub trait UnlockWithPenaltyModule: token_amount * penalty_percentage_unlock / MAX_PENALTY_PERCENTAGE } } + + +// ‘4687451965350631993632991850’ +// ‘0015306081845241142641261742’ + +// { +// oldEnergyEntry: { +// amount: , +// lastUpdateEpoch: 1174, +// totalLockedTokens: ‘3253583484335230397626951’ +// }, +// newEnergyEntry: { +// amount: , +// lastUpdateEpoch: 1174, +// totalLockedTokens: ‘398’ +// } +// } diff --git a/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs b/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs index 322fedd61..73dd9d9c9 100644 --- a/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs +++ b/locked-asset/proxy_dex/tests/proxy_dex_test_setup/mod.rs @@ -1,3 +1,4 @@ +#![allow(dead_code)] #![allow(deprecated)] use common_structs::{LockedAssetTokenAttributesEx, UnlockMilestoneEx, UnlockScheduleEx}; @@ -157,7 +158,7 @@ where unlock_percent: 10_000, unlock_epoch: LOCK_OPTIONS[0], }); - + let old_token_attributes = LockedAssetTokenAttributesEx { is_merged: false, unlock_schedule: UnlockScheduleEx { unlock_milestones }, @@ -169,7 +170,6 @@ where &rust_biguint!(USER_BALANCE), &old_token_attributes, ); - // users lock tokens b_mock diff --git a/locked-asset/proxy_dex/tests/proxy_farm_test.rs b/locked-asset/proxy_dex/tests/proxy_farm_test.rs index 7f7a23b60..8e162a1e4 100644 --- a/locked-asset/proxy_dex/tests/proxy_farm_test.rs +++ b/locked-asset/proxy_dex/tests/proxy_farm_test.rs @@ -1221,12 +1221,10 @@ fn total_farm_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); - assert_eq!( - first_user_total_farm_position.total_farm_position, - managed_biguint!(0) - ); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); + assert_eq!(first_user_total_farm_position, managed_biguint!(0)); }) .assert_ok(); @@ -1250,10 +1248,11 @@ fn total_farm_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(USER_BALANCE) ); }) @@ -1280,10 +1279,11 @@ fn total_farm_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(USER_BALANCE * 2) ); }) @@ -1348,10 +1348,11 @@ fn total_farm_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(USER_BALANCE * 2) ); }) @@ -2379,12 +2380,8 @@ fn total_farm_position_migration_through_proxy_dex_test() { &setup.farm_locked_wrapper, &rust_biguint!(0), |sc| { - let mut first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); - first_user_total_farm_position.total_farm_position = managed_biguint!(0u64); - sc.user_total_farm_position(&managed_address!(&first_user)) - .set(first_user_total_farm_position); + .set(managed_biguint!(0u64)); sc.farm_position_migration_nonce().set(2u64); }, ) @@ -2393,12 +2390,10 @@ fn total_farm_position_migration_through_proxy_dex_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); - assert_eq!( - first_user_total_farm_position.total_farm_position, - managed_biguint!(0) - ); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); + assert_eq!(first_user_total_farm_position, managed_biguint!(0)); }) .assert_ok(); @@ -2420,10 +2415,11 @@ fn total_farm_position_migration_through_proxy_dex_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(USER_BALANCE) ); }) @@ -2453,10 +2449,11 @@ fn total_farm_position_migration_through_proxy_dex_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(USER_BALANCE * 2) ); }) @@ -2617,12 +2614,8 @@ fn total_farm_position_migration_mechanism_test() { &setup.farm_locked_wrapper, &rust_biguint!(0), |sc| { - let mut first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); - first_user_total_farm_position.total_farm_position = managed_biguint!(0u64); - sc.user_total_farm_position(&managed_address!(&first_user)) - .set(first_user_total_farm_position); + .set(managed_biguint!(0u64)); sc.farm_position_migration_nonce().set(6u64); }, ) @@ -2631,12 +2624,10 @@ fn total_farm_position_migration_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); - assert_eq!( - first_user_total_farm_position.total_farm_position, - managed_biguint!(0) - ); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); + assert_eq!(first_user_total_farm_position, managed_biguint!(0)); }) .assert_ok(); @@ -2665,10 +2656,11 @@ fn total_farm_position_migration_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(user_total_farm_position) ); }) @@ -2694,10 +2686,11 @@ fn total_farm_position_migration_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(user_total_farm_position) ); }) @@ -2722,10 +2715,11 @@ fn total_farm_position_migration_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(user_total_farm_position) ); }) @@ -2757,10 +2751,11 @@ fn total_farm_position_migration_mechanism_test() { setup .b_mock .execute_query(&setup.farm_locked_wrapper, |sc| { - let first_user_total_farm_position = - sc.get_user_total_farm_position(&managed_address!(&first_user)); + let first_user_total_farm_position = sc + .user_total_farm_position(&managed_address!(&first_user)) + .get(); assert_eq!( - first_user_total_farm_position.total_farm_position, + first_user_total_farm_position, managed_biguint!(user_total_farm_position) ); }) From 8fedc8fd81e3a539d1cf206e213a0de6b9612d5d Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 11 Jul 2024 16:09:31 +0300 Subject: [PATCH 074/103] clippy fix --- dex/farm/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 0987dbbce..08d447830 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -223,7 +223,7 @@ pub trait Farm: }; if user != &caller { require!( - self.allow_external_claim(&user).get(), + self.allow_external_claim(user).get(), "Cannot claim rewards for this address" ); } From 81b6253f4bd8fbc901da79c5935d184d3aeee410 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 12 Jul 2024 10:51:14 +0300 Subject: [PATCH 075/103] remove comments --- .../energy-factory/src/unlock_with_penalty.rs | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/locked-asset/energy-factory/src/unlock_with_penalty.rs b/locked-asset/energy-factory/src/unlock_with_penalty.rs index a92285128..102565ed5 100644 --- a/locked-asset/energy-factory/src/unlock_with_penalty.rs +++ b/locked-asset/energy-factory/src/unlock_with_penalty.rs @@ -195,20 +195,3 @@ pub trait UnlockWithPenaltyModule: token_amount * penalty_percentage_unlock / MAX_PENALTY_PERCENTAGE } } - - -// ‘4687451965350631993632991850’ -// ‘0015306081845241142641261742’ - -// { -// oldEnergyEntry: { -// amount: , -// lastUpdateEpoch: 1174, -// totalLockedTokens: ‘3253583484335230397626951’ -// }, -// newEnergyEntry: { -// amount: , -// lastUpdateEpoch: 1174, -// totalLockedTokens: ‘398’ -// } -// } From d2919367360fa647c065bb7f320a3168fbe6bcfe Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 16 Jul 2024 23:51:54 +0300 Subject: [PATCH 076/103] Proxy dex legacy contract --- Cargo.lock | 19 + Cargo.toml | 2 + legacy-contracts/proxy-dex-legacy/.gitignore | 7 + legacy-contracts/proxy-dex-legacy/Cargo.toml | 24 ++ legacy-contracts/proxy-dex-legacy/README.md | 24 ++ .../proxy-dex-legacy/meta/Cargo.toml | 14 + .../proxy-dex-legacy/meta/src/main.rs | 3 + .../proxy-dex-legacy/multiversx.json | 4 + .../proxy-dex-legacy/src/energy.rs | 109 +++++ .../proxy-dex-legacy/src/energy_update.rs | 135 ++++++ .../proxy-dex-legacy/src/events.rs | 149 +++++++ legacy-contracts/proxy-dex-legacy/src/lib.rs | 31 ++ .../src/migration_from_v1_2.rs | 116 +++++ .../proxy-dex-legacy/src/proxy_common.rs | 129 ++++++ .../proxy-dex-legacy/src/proxy_farm.rs | 159 +++++++ .../proxy-dex-legacy/src/proxy_pair.rs | 220 ++++++++++ .../proxy-dex-legacy/src/transfer_role.rs | 90 ++++ .../proxy-dex-legacy/testnet.toml | 0 .../proxy-dex-legacy/wasm/Cargo.lock | 398 ++++++++++++++++++ .../proxy-dex-legacy/wasm/Cargo.toml | 34 ++ .../proxy-dex-legacy/wasm/src/lib.rs | 44 ++ locked-asset/factory/src/lib.rs | 2 +- 22 files changed, 1712 insertions(+), 1 deletion(-) create mode 100644 legacy-contracts/proxy-dex-legacy/.gitignore create mode 100644 legacy-contracts/proxy-dex-legacy/Cargo.toml create mode 100644 legacy-contracts/proxy-dex-legacy/README.md create mode 100644 legacy-contracts/proxy-dex-legacy/meta/Cargo.toml create mode 100644 legacy-contracts/proxy-dex-legacy/meta/src/main.rs create mode 100644 legacy-contracts/proxy-dex-legacy/multiversx.json create mode 100644 legacy-contracts/proxy-dex-legacy/src/energy.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/energy_update.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/events.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/lib.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/proxy_common.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs create mode 100644 legacy-contracts/proxy-dex-legacy/src/transfer_role.rs create mode 100644 legacy-contracts/proxy-dex-legacy/testnet.toml create mode 100644 legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock create mode 100644 legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml create mode 100644 legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index d7e21d7f3..97f3c2e89 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2242,6 +2242,25 @@ dependencies = [ "proxy-deployer", ] +[[package]] +name = "proxy-dex-legacy" +version = "0.0.0" +dependencies = [ + "common_structs", + "factory", + "multiversx-sc", + "multiversx-sc-scenario", + "token_merge_helper", +] + +[[package]] +name = "proxy-dex-legacy-meta" +version = "0.0.0" +dependencies = [ + "multiversx-sc-meta", + "proxy-dex-legacy", +] + [[package]] name = "proxy_dex" version = "0.0.0" diff --git a/Cargo.toml b/Cargo.toml index 88a66788f..db13e51b2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -43,6 +43,8 @@ members = [ "legacy-contracts/farm-staking-proxy-v-13/meta", "legacy-contracts/farm-v-13", "legacy-contracts/farm-v-13/meta", + "legacy-contracts/proxy-dex-legacy", + "legacy-contracts/proxy-dex-legacy/meta", "locked-asset/", "locked-asset/distribution", diff --git a/legacy-contracts/proxy-dex-legacy/.gitignore b/legacy-contracts/proxy-dex-legacy/.gitignore new file mode 100644 index 000000000..eaf5915bd --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/.gitignore @@ -0,0 +1,7 @@ +# Generated by Cargo +# will have compiled files and executables +/target/ +*/target/ + +# The erdpy output +output diff --git a/legacy-contracts/proxy-dex-legacy/Cargo.toml b/legacy-contracts/proxy-dex-legacy/Cargo.toml new file mode 100644 index 000000000..cb6801e13 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/Cargo.toml @@ -0,0 +1,24 @@ +[package] +name = "proxy-dex-legacy" +version = "0.0.0" +edition = "2018" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "=0.50.5" +features = ["esdt-token-payment-legacy-decode"] + +[dev-dependencies.multiversx-sc-scenario] +version = "=0.50.5" + +[dependencies.common_structs] +path = "../../common/common_structs" + +[dependencies.token_merge_helper] +path = "../../common/modules/token_merge_helper" + +[dependencies.factory] +path = "../../locked-asset/factory" diff --git a/legacy-contracts/proxy-dex-legacy/README.md b/legacy-contracts/proxy-dex-legacy/README.md new file mode 100644 index 000000000..cfa338037 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/README.md @@ -0,0 +1,24 @@ +# DEX Proxy Smart Contract + +This document presents how one can deploy and configure a DEX Proxy Contract. +The bigger picture about what a DEX Proxy Contract can do can be found in the Repository's Root Readme. + +## Deployment + +The DEX Proxy contract can be deployed using `erdpy` and using the interraction snippets. + +The init parameters are: + +- asset_token_id. The TokenId of the asset that a locked asset represents. In case of Maiar Exchange it will be MEX. + +- locked_asset_token_id. The TokenId of the locked asset represents. In case of Maiar Exchange it will be Locked MEX. + +## Configuration workflow + +1. In order to complete the setup of the dex proxy contracts, Wrapped LP Token and Wrapped Farm token must be issued via `issueSftProxyPair` and `issueSftProxyFarm`. After this, setLocalRoles has to be called once for each of the two tokens, using for address the Proxy Address itself. + +2. In order to add a pair to intermediate, meaning a pair that is eligible to function with MEX, the admin should use `addPairToIntermediate` and `removeIntermediatedPair`. + +3. In order to add a farm to intermediate, meaning a farm that is eligible to function with MEX or with Wrapped LP Tokens, the admin should use `addFarmToIntermediate` and `removeIntermediatedFarm`. + +4. In order for the Setup to be complete, LocalMint + LocalBurn roles for MEX and NftBurn role for Locked MEX should be granted to the Proxy Contract. diff --git a/legacy-contracts/proxy-dex-legacy/meta/Cargo.toml b/legacy-contracts/proxy-dex-legacy/meta/Cargo.toml new file mode 100644 index 000000000..38efa5f0d --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/meta/Cargo.toml @@ -0,0 +1,14 @@ +[package] +name = "proxy-dex-legacy-meta" + +version = "0.0.0" +authors = [ "you",] +edition = "2018" +publish = false + +[dependencies.proxy-dex-legacy] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.5" +default-features = false diff --git a/legacy-contracts/proxy-dex-legacy/meta/src/main.rs b/legacy-contracts/proxy-dex-legacy/meta/src/main.rs new file mode 100644 index 000000000..c282d1ab7 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} \ No newline at end of file diff --git a/legacy-contracts/proxy-dex-legacy/multiversx.json b/legacy-contracts/proxy-dex-legacy/multiversx.json new file mode 100644 index 000000000..c2cab7433 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/multiversx.json @@ -0,0 +1,4 @@ +{ + "language": "rust" +} + diff --git a/legacy-contracts/proxy-dex-legacy/src/energy.rs b/legacy-contracts/proxy-dex-legacy/src/energy.rs new file mode 100644 index 000000000..651bbf544 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/energy.rs @@ -0,0 +1,109 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::Epoch; + +#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, Clone, PartialEq, Debug)] +pub struct Energy { + amount: BigInt, + last_update_epoch: Epoch, + total_locked_tokens: BigUint, +} + +impl Default for Energy { + fn default() -> Self { + Self { + amount: BigInt::zero(), + last_update_epoch: 0, + total_locked_tokens: BigUint::zero(), + } + } +} + +impl Energy { + #[inline] + pub fn new( + amount: BigInt, + last_update_epoch: Epoch, + total_locked_tokens: BigUint, + ) -> Self { + Energy { + amount, + last_update_epoch, + total_locked_tokens, + } + } + + pub fn new_zero_energy(current_epoch: Epoch) -> Self { + Self::new(BigInt::zero(), current_epoch, BigUint::zero()) + } + + fn add(&mut self, future_epoch: Epoch, current_epoch: Epoch, amount_per_epoch: &BigUint) { + if current_epoch >= future_epoch { + return; + } + + let epochs_diff = future_epoch - current_epoch; + let energy_added = amount_per_epoch * epochs_diff; + self.amount += BigInt::from(energy_added); + } + + fn subtract(&mut self, past_epoch: Epoch, current_epoch: Epoch, amount_per_epoch: &BigUint) { + if past_epoch >= current_epoch { + return; + } + + let epoch_diff = current_epoch - past_epoch; + let energy_decrease = amount_per_epoch * epoch_diff; + self.amount -= BigInt::from(energy_decrease); + } + + pub fn deplete(&mut self, current_epoch: Epoch) { + if self.last_update_epoch == current_epoch { + return; + } + + if self.total_locked_tokens > 0 { + self.subtract( + self.last_update_epoch, + current_epoch, + &self.total_locked_tokens.clone(), + ); + } + + self.last_update_epoch = current_epoch; + } + + pub fn refund_after_token_unlock( + &mut self, + unlock_amount: &BigUint, + unlock_epoch: Epoch, + current_epoch: Epoch, + ) { + self.add(current_epoch, unlock_epoch, unlock_amount); + self.total_locked_tokens -= unlock_amount; + } + + pub fn deplete_after_early_unlock( + &mut self, + unlock_amount: &BigUint, + unlock_epoch: Epoch, + current_epoch: Epoch, + ) { + self.subtract(current_epoch, unlock_epoch, unlock_amount); + self.total_locked_tokens -= unlock_amount; + } + + pub fn update_after_unlock_any( + &mut self, + unlock_amount: &BigUint, + unlock_epoch: Epoch, + current_epoch: Epoch, + ) { + if unlock_epoch < current_epoch { + self.refund_after_token_unlock(unlock_amount, unlock_epoch, current_epoch); + } else { + self.deplete_after_early_unlock(unlock_amount, unlock_epoch, current_epoch); + } + } +} diff --git a/legacy-contracts/proxy-dex-legacy/src/energy_update.rs b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs new file mode 100644 index 000000000..06921dd35 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs @@ -0,0 +1,135 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::LockedAssetTokenAttributesEx; +use factory::attr_ex_helper; + +use crate::{energy::Energy, proxy_common}; + +static LEGACY_LOCKED_TOKEN_ID_STORAGE_KEY: &[u8] = b"legacyLockedTokenId"; +static USER_ENERGY_STORAGE_KEY: &[u8] = b"userEnergy"; +static EXTENDED_ATTRIBUTES_ACTIVATION_NONCE_KEY: &[u8] = b"extended_attributes_activation_nonce"; + +mod energy_factory_proxy { + multiversx_sc::imports!(); + use crate::energy_update::Energy; + + #[multiversx_sc::proxy] + pub trait LockedTokenTransferModule { + #[endpoint(setUserEnergyAfterLockedTokenTransfer)] + fn set_user_energy_after_locked_token_transfer( + &self, + user: ManagedAddress, + energy: Energy, + ); + } +} + +#[multiversx_sc::module] +pub trait EnergyUpdateModule: + proxy_common::ProxyCommonModule + attr_ex_helper::AttrExHelper +{ + #[only_owner] + #[endpoint(setEnergyFactoryAddress)] + fn set_energy_factory_address(&self, sc_address: ManagedAddress) { + require!( + self.blockchain().is_smart_contract(&sc_address), + "Invalid address" + ); + + self.energy_factory_address().set(&sc_address); + } + + fn deduct_energy_from_user( + &self, + user: &ManagedAddress, + token_id: &TokenIdentifier, + token_nonce: u64, + token_amount: &BigUint, + ) { + let energy_factory_addr = self.energy_factory_address().get(); + let legacy_locked_token_id = self.get_legacy_locked_token_id(&energy_factory_addr); + if token_id != &legacy_locked_token_id { + return; + } + + let mut energy = self.get_energy_entry(user); + let current_epoch = self.blockchain().get_block_epoch(); + let attributes: LockedAssetTokenAttributesEx = + self.get_attributes_ex(token_id, token_nonce); + let amounts_per_epoch = attributes.get_unlock_amounts_per_epoch(token_amount); + for epoch_amount_pair in &amounts_per_epoch.pairs { + energy.update_after_unlock_any( + &epoch_amount_pair.amount, + epoch_amount_pair.epoch, + current_epoch, + ); + } + + self.set_energy_in_factory(user.clone(), energy, energy_factory_addr); + } + + fn set_energy_in_factory( + &self, + user: ManagedAddress, + energy: Energy, + energy_factory_addr: ManagedAddress, + ) { + let _: () = self + .energy_factory_proxy(energy_factory_addr) + .set_user_energy_after_locked_token_transfer(user, energy) + .execute_on_dest_context(); + } + + fn get_energy_entry(&self, user: &ManagedAddress) -> Energy { + let current_epoch = self.blockchain().get_block_epoch(); + if self.energy_factory_address().is_empty() { + return Energy::new_zero_energy(current_epoch); + } + + let energy_buffer: ManagedBuffer = self.read_storage_from_energy_factory(user); + if !energy_buffer.is_empty() { + let mut user_energy: Energy = Energy::top_decode(energy_buffer) + .unwrap_or_else(|_| sc_panic!("Failed decoding result from energy factory")); + user_energy.deplete(current_epoch); + + user_energy + } else { + Energy::new_zero_energy(current_epoch) + } + } + + fn read_storage_from_energy_factory(&self, user: &ManagedAddress) -> T { + let energy_factory_address = self.energy_factory_address().get(); + let mut key_buffer = ManagedBuffer::new_from_bytes(USER_ENERGY_STORAGE_KEY); + key_buffer.append(user.as_managed_buffer()); + + self.storage_raw() + .read_from_address(&energy_factory_address, key_buffer) + } + + fn get_legacy_locked_token_id(&self, energy_factory_addr: &ManagedAddress) -> TokenIdentifier { + self.storage_raw().read_from_address( + energy_factory_addr, + ManagedBuffer::new_from_bytes(LEGACY_LOCKED_TOKEN_ID_STORAGE_KEY), + ) + } + + fn get_extended_attributes_activation_nonce(&self) -> u64 { + let sc_address = self.locked_asset_factory_address().get(); + self.storage_raw().read_from_address( + &sc_address, + ManagedBuffer::new_from_bytes(EXTENDED_ATTRIBUTES_ACTIVATION_NONCE_KEY), + ) + } + + #[proxy] + fn energy_factory_proxy( + &self, + sc_address: ManagedAddress, + ) -> energy_factory_proxy::Proxy; + + #[view(getEnergyFactoryAddress)] + #[storage_mapper("energyFactoryAddress")] + fn energy_factory_address(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/proxy-dex-legacy/src/events.rs b/legacy-contracts/proxy-dex-legacy/src/events.rs new file mode 100644 index 000000000..3fefd8fb1 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/events.rs @@ -0,0 +1,149 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use crate::proxy_common::{WrappedFarmTokenAttributes, WrappedLpTokenAttributes}; + +#[derive(TypeAbi, TopEncode)] +pub struct RemoveLiquidityProxyEvent { + caller: ManagedAddress, + pair_address: ManagedAddress, + wrapped_lp_token_id: TokenIdentifier, + wrapped_lp_token_nonce: u64, + wrapped_lp_token_amount: BigUint, + wrapped_lp_attributes: WrappedLpTokenAttributes, + first_token_id: TokenIdentifier, + first_token_nonce: u64, + first_token_amount: BigUint, + second_token_id: TokenIdentifier, + second_token_nonce: u64, + second_token_amount: BigUint, + block: u64, + epoch: u64, + timestamp: u64, +} + +#[derive(TypeAbi, TopEncode)] +pub struct ExitFarmProxyEvent { + caller: ManagedAddress, + farm_address: ManagedAddress, + wrapped_farm_token_id: TokenIdentifier, + wrapped_farm_token_nonce: u64, + wrapped_farm_token_amount: BigUint, + wrapped_farm_attributes: WrappedFarmTokenAttributes, + farming_token_id: TokenIdentifier, + farming_token_nonce: u64, + farming_token_amount: BigUint, + reward_token_id: TokenIdentifier, + reward_token_nonce: u64, + reward_token_amount: BigUint, + block: u64, + epoch: u64, + timestamp: u64, +} + +#[multiversx_sc::module] +pub trait EventsModule { + fn emit_remove_liquidity_proxy_event( + self, + caller: &ManagedAddress, + pair_address: &ManagedAddress, + wrapped_lp_token_id: &TokenIdentifier, + wrapped_lp_token_nonce: u64, + wrapped_lp_token_amount: &BigUint, + wrapped_lp_attributes: &WrappedLpTokenAttributes, + first_token_id: &TokenIdentifier, + first_token_nonce: u64, + first_token_amount: &BigUint, + second_token_id: &TokenIdentifier, + second_token_nonce: u64, + second_token_amount: &BigUint, + ) { + let epoch = self.blockchain().get_block_epoch(); + self.remove_liquidity_proxy_event( + first_token_id, + second_token_id, + caller, + pair_address, + epoch, + &RemoveLiquidityProxyEvent { + caller: caller.clone(), + pair_address: pair_address.clone(), + first_token_id: first_token_id.clone(), + first_token_nonce, + first_token_amount: first_token_amount.clone(), + second_token_id: second_token_id.clone(), + second_token_nonce, + second_token_amount: second_token_amount.clone(), + wrapped_lp_token_id: wrapped_lp_token_id.clone(), + wrapped_lp_token_nonce, + wrapped_lp_token_amount: wrapped_lp_token_amount.clone(), + wrapped_lp_attributes: wrapped_lp_attributes.clone(), + block: self.blockchain().get_block_nonce(), + epoch, + timestamp: self.blockchain().get_block_timestamp(), + }, + ) + } + + fn emit_exit_farm_proxy_event( + self, + caller: &ManagedAddress, + farm_address: &ManagedAddress, + wrapped_farm_token_id: &TokenIdentifier, + wrapped_farm_token_nonce: u64, + wrapped_farm_token_amount: &BigUint, + wrapped_farm_attributes: &WrappedFarmTokenAttributes, + farming_token_id: &TokenIdentifier, + farming_token_nonce: u64, + farming_token_amount: &BigUint, + reward_token_id: &TokenIdentifier, + reward_token_nonce: u64, + reward_token_amount: &BigUint, + ) { + let epoch = self.blockchain().get_block_epoch(); + self.exit_farm_proxy_event( + farming_token_id, + caller, + farm_address, + epoch, + &ExitFarmProxyEvent { + caller: caller.clone(), + farm_address: farm_address.clone(), + farming_token_id: farming_token_id.clone(), + farming_token_nonce, + farming_token_amount: farming_token_amount.clone(), + wrapped_farm_token_id: wrapped_farm_token_id.clone(), + wrapped_farm_token_nonce, + wrapped_farm_token_amount: wrapped_farm_token_amount.clone(), + wrapped_farm_attributes: wrapped_farm_attributes.clone(), + reward_token_id: reward_token_id.clone(), + reward_token_nonce, + reward_token_amount: reward_token_amount.clone(), + block: self.blockchain().get_block_nonce(), + epoch, + timestamp: self.blockchain().get_block_timestamp(), + }, + ) + } + + #[event("remove_liquidity_proxy")] + fn remove_liquidity_proxy_event( + self, + #[indexed] first_token: &TokenIdentifier, + #[indexed] second_token: &TokenIdentifier, + #[indexed] caller: &ManagedAddress, + #[indexed] pair_address: &ManagedAddress, + #[indexed] epoch: u64, + remove_liquidity_proxy_event: &RemoveLiquidityProxyEvent, + ); + + #[event("exit_farm_proxy")] + fn exit_farm_proxy_event( + self, + #[indexed] farm_token: &TokenIdentifier, + #[indexed] caller: &ManagedAddress, + #[indexed] farm_address: &ManagedAddress, + #[indexed] epoch: u64, + exit_farm_proxy_event: &ExitFarmProxyEvent, + ); +} diff --git a/legacy-contracts/proxy-dex-legacy/src/lib.rs b/legacy-contracts/proxy-dex-legacy/src/lib.rs new file mode 100644 index 000000000..32305f10f --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/lib.rs @@ -0,0 +1,31 @@ +#![no_std] + +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +mod energy; +mod energy_update; +mod events; +pub mod migration_from_v1_2; +pub mod proxy_common; +pub mod proxy_farm; +mod proxy_pair; +pub mod transfer_role; + +use factory::attr_ex_helper; + +#[multiversx_sc::contract] +pub trait ProxyDexImpl: + proxy_common::ProxyCommonModule + + proxy_pair::ProxyPairModule + + proxy_farm::ProxyFarmModule + + token_merge_helper::TokenMergeHelperModule + + events::EventsModule + + energy_update::EnergyUpdateModule + + migration_from_v1_2::MigrationModule + + transfer_role::TransferRoleModule + + attr_ex_helper::AttrExHelper +{ + #[init] + fn init(&self) {} +} diff --git a/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs b/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs new file mode 100644 index 000000000..838954dd8 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs @@ -0,0 +1,116 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::RawResultWrapper; +use common_structs::RawResultsType; +use factory::attr_ex_helper; + +use super::events; +use super::proxy_common; +use super::proxy_pair; +use crate::energy_update; +use crate::proxy_common::WrappedFarmTokenAttributes; +use crate::proxy_farm; + +mod farm_v1_2_contract_proxy { + multiversx_sc::imports!(); + + #[multiversx_sc::proxy] + pub trait Farm { + #[payable("*")] + #[endpoint(migrateToNewFarm)] + fn migrate_to_new_farm( + &self, + orig_caller: ManagedAddress, + ) -> MultiValue2, EsdtTokenPayment>; + } +} + +#[multiversx_sc::module] +pub trait MigrationModule: + proxy_farm::ProxyFarmModule + + proxy_common::ProxyCommonModule + + proxy_pair::ProxyPairModule + + token_merge_helper::TokenMergeHelperModule + + events::EventsModule + + energy_update::EnergyUpdateModule + + attr_ex_helper::AttrExHelper +{ + #[payable("*")] + #[endpoint(migrateV1_2Position)] + fn migrate_v1_2_position(&self, farm_address: ManagedAddress) { + self.require_is_intermediated_farm(&farm_address); + self.require_wrapped_farm_token_id_not_empty(); + self.require_wrapped_lp_token_id_not_empty(); + + let (payment_token_id, payment_token_nonce, payment_amount) = + self.call_value().single_esdt().into_tuple(); + let wrapped_farm_token = self.wrapped_farm_token_id().get(); + require!( + payment_token_id == wrapped_farm_token, + "Should only be used with wrapped farm tokens" + ); + require!(payment_amount != 0u64, "Payment amount cannot be zero"); + + // The actual work starts here + let wrapped_farm_token_attrs = + self.get_wrapped_farm_token_attributes(&payment_token_id, payment_token_nonce); + let farm_token_id = wrapped_farm_token_attrs.farm_token_id.clone(); + let farm_token_nonce = wrapped_farm_token_attrs.farm_token_nonce; + let farm_amount = payment_amount.clone(); + + // Get the new farm position from the new contract. + let raw_results: RawResultsType = self + .farm_v1_2_contract_proxy(farm_address) + .migrate_to_new_farm(self.blockchain().get_sc_address()) + .with_esdt_transfer((farm_token_id, farm_token_nonce, farm_amount)) + .execute_on_dest_context(); + + let mut results_wrapper = RawResultWrapper::new(raw_results); + results_wrapper.trim_results_front(2); + + let new_pos: EsdtTokenPayment = results_wrapper.decode_next_result(); + let reward: EsdtTokenPayment = results_wrapper.decode_next_result(); + + // Burn the old proxy farm position + self.send() + .esdt_local_burn(&payment_token_id, payment_token_nonce, &payment_amount); + + // Create a new proxy farm position based on the new farm position. + let new_attrs = WrappedFarmTokenAttributes { + farm_token_id: new_pos.token_identifier.clone(), + farm_token_nonce: new_pos.token_nonce, + farm_token_amount: new_pos.amount.clone(), + farming_token_id: wrapped_farm_token_attrs.farming_token_id, + farming_token_nonce: wrapped_farm_token_attrs.farming_token_nonce, + farming_token_amount: self.rule_of_three_non_zero_result( + &payment_amount, + &wrapped_farm_token_attrs.farm_token_amount, + &wrapped_farm_token_attrs.farming_token_amount, + ), + }; + let new_nonce = + self.send() + .esdt_nft_create_compact(&wrapped_farm_token, &new_pos.amount, &new_attrs); + + let mut payments = ManagedVec::new(); + payments.push(EsdtTokenPayment::new( + wrapped_farm_token, + new_nonce, + new_pos.amount, + )); + + if reward.amount != 0u64 { + payments.push(reward); + } + + let caller = self.blockchain().get_caller(); + self.send().direct_multi(&caller, &payments); + } + + #[proxy] + fn farm_v1_2_contract_proxy( + &self, + to: ManagedAddress, + ) -> farm_v1_2_contract_proxy::Proxy; +} diff --git a/legacy-contracts/proxy-dex-legacy/src/proxy_common.rs b/legacy-contracts/proxy-dex-legacy/src/proxy_common.rs new file mode 100644 index 000000000..105f3cbc1 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/proxy_common.rs @@ -0,0 +1,129 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::Nonce; + +#[derive(ManagedVecItem, TopEncode, TopDecode, NestedEncode, NestedDecode, TypeAbi, Clone)] +pub struct WrappedLpTokenAttributes { + pub lp_token_id: TokenIdentifier, + pub lp_token_total_amount: BigUint, + pub locked_assets_invested: BigUint, + pub locked_assets_nonce: Nonce, +} + +#[derive(ManagedVecItem, TopEncode, TopDecode, NestedEncode, NestedDecode, TypeAbi, Clone)] +pub struct WrappedFarmTokenAttributes { + pub farm_token_id: TokenIdentifier, + pub farm_token_nonce: Nonce, + pub farm_token_amount: BigUint, + pub farming_token_id: TokenIdentifier, + pub farming_token_nonce: Nonce, + pub farming_token_amount: BigUint, +} + +#[multiversx_sc::module] +pub trait ProxyCommonModule { + fn get_wrapped_lp_token_attributes( + &self, + token_id: &TokenIdentifier, + token_nonce: Nonce, + ) -> WrappedLpTokenAttributes { + let token_info = self.blockchain().get_esdt_token_data( + &self.blockchain().get_sc_address(), + token_id, + token_nonce, + ); + + token_info.decode_attributes() + } + + fn get_wrapped_farm_token_attributes( + &self, + token_id: &TokenIdentifier, + token_nonce: Nonce, + ) -> WrappedFarmTokenAttributes { + let token_info = self.blockchain().get_esdt_token_data( + &self.blockchain().get_sc_address(), + token_id, + token_nonce, + ); + + token_info.decode_attributes() + } + + fn burn_payment_tokens( + &self, + payments: ManagedVecRefIterator>, + ) { + for payment in payments { + self.send().esdt_local_burn( + &payment.token_identifier, + payment.token_nonce, + &payment.amount, + ); + } + } + + fn send_multiple_tokens_if_not_zero( + &self, + destination: &ManagedAddress, + payments: &ManagedVec>, + ) { + let mut non_zero_payments = ManagedVec::new(); + for payment in payments { + if payment.amount > 0u32 { + non_zero_payments.push(payment); + } + } + + if !non_zero_payments.is_empty() { + self.send().direct_multi(destination, &non_zero_payments) + } + } + + #[storage_mapper("current_tx_accepted_funds")] + fn current_tx_accepted_funds(&self) -> MapMapper<(TokenIdentifier, Nonce), BigUint>; + + #[view(getAssetTokenId)] + #[storage_mapper("asset_token_id")] + fn asset_token_id(&self) -> SingleValueMapper; + + #[view(getLockedAssetTokenId)] + #[storage_mapper("locked_asset_token_id")] + fn locked_asset_token_id(&self) -> SingleValueMapper; + + #[view(getWrappedLpTokenId)] + #[storage_mapper("wrapped_lp_token_id")] + fn wrapped_lp_token_id(&self) -> SingleValueMapper; + + #[view(getWrappedFarmTokenId)] + #[storage_mapper("wrapped_farm_token_id")] + fn wrapped_farm_token_id(&self) -> SingleValueMapper; + + #[storage_mapper("locked_asset_factory_address")] + fn locked_asset_factory_address(&self) -> SingleValueMapper; + + #[storage_mapper("intermediated_farms")] + fn intermediated_farms(&self) -> SetMapper; + + #[view(getIntermediatedFarms)] + fn get_intermediated_farms(&self) -> MultiValueEncoded { + let mut result = MultiValueEncoded::new(); + for pair in self.intermediated_farms().iter() { + result.push(pair); + } + result + } + + #[storage_mapper("intermediated_pairs")] + fn intermediated_pairs(&self) -> SetMapper; + + #[view(getIntermediatedPairs)] + fn get_intermediated_pairs(&self) -> MultiValueEncoded { + let mut result = MultiValueEncoded::new(); + for pair in self.intermediated_pairs().iter() { + result.push(pair); + } + result + } +} diff --git a/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs b/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs new file mode 100644 index 000000000..bd39605e6 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs @@ -0,0 +1,159 @@ +#![allow(clippy::too_many_arguments)] + +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::Nonce; +use common_structs::{RawResultWrapper, RawResultsType}; +use factory::attr_ex_helper; + +use crate::energy_update; +use crate::proxy_common::WrappedFarmTokenAttributes; + +use super::events; +use super::proxy_common; +use super::proxy_pair; + +type ExitFarmResultType = + MultiValue2, EsdtTokenPayment>; + +mod farm_proxy { + multiversx_sc::imports!(); + + #[multiversx_sc::proxy] + pub trait FarmProxy { + #[payable("*")] + #[endpoint(exitFarm)] + fn exit_farm(&self) -> super::ExitFarmResultType; + } +} + +#[derive(ManagedVecItem, Clone)] +pub struct WrappedFarmToken { + pub token_amount: EsdtTokenPayment, + pub attributes: WrappedFarmTokenAttributes, +} + +#[multiversx_sc::module] +pub trait ProxyFarmModule: + proxy_common::ProxyCommonModule + + proxy_pair::ProxyPairModule + + token_merge_helper::TokenMergeHelperModule + + events::EventsModule + + energy_update::EnergyUpdateModule + + attr_ex_helper::AttrExHelper +{ + #[only_owner] + #[endpoint(addFarmToIntermediate)] + fn add_farm_to_intermediate(&self, farm_address: ManagedAddress) { + self.intermediated_farms().insert(farm_address); + } + + #[only_owner] + #[endpoint(removeIntermediatedFarm)] + fn remove_intermediated_farm(&self, farm_address: ManagedAddress) { + self.require_is_intermediated_farm(&farm_address); + self.intermediated_farms().remove(&farm_address); + } + + #[payable("*")] + #[endpoint(exitFarmProxy)] + fn exit_farm_proxy(&self, farm_address: &ManagedAddress) { + self.require_is_intermediated_farm(farm_address); + self.require_wrapped_farm_token_id_not_empty(); + self.require_wrapped_lp_token_id_not_empty(); + + let (token_id, token_nonce, amount) = self.call_value().single_esdt().into_tuple(); + + require!(amount != 0, "Payment amount cannot be zero"); + require!( + token_id == self.wrapped_farm_token_id().get(), + "Should only be used with wrapped farm tokens" + ); + + let wrapped_farm_token_attrs = + self.get_wrapped_farm_token_attributes(&token_id, token_nonce); + let farm_token_id = wrapped_farm_token_attrs.farm_token_id.clone(); + let farm_token_nonce = wrapped_farm_token_attrs.farm_token_nonce; + + let farm_result = self + .actual_exit_farm(farm_address, &farm_token_id, farm_token_nonce, &amount) + .into_tuple(); + let farming_token_returned = farm_result.0; + let reward_token_returned = farm_result.1; + + let caller = self.blockchain().get_caller(); + let mut payments_vec = ManagedVec::new(); + payments_vec.push(EsdtTokenPayment::new( + wrapped_farm_token_attrs.farming_token_id.clone(), + wrapped_farm_token_attrs.farming_token_nonce, + farming_token_returned.amount.clone(), + )); + payments_vec.push(EsdtTokenPayment::new( + reward_token_returned.token_identifier.clone(), + reward_token_returned.token_nonce, + reward_token_returned.amount.clone(), + )); + self.send_multiple_tokens_if_not_zero(&caller, &payments_vec); + self.send().esdt_local_burn(&token_id, token_nonce, &amount); + + if farming_token_returned.token_identifier == self.asset_token_id().get() { + self.send().esdt_local_burn( + &farming_token_returned.token_identifier, + 0, + &farming_token_returned.amount, + ); + } + + self.emit_exit_farm_proxy_event( + &caller, + farm_address, + &token_id, + token_nonce, + &amount, + &wrapped_farm_token_attrs, + &wrapped_farm_token_attrs.farming_token_id, + wrapped_farm_token_attrs.farming_token_nonce, + &farming_token_returned.amount, + &reward_token_returned.token_identifier, + reward_token_returned.token_nonce, + &reward_token_returned.amount, + ); + } + + fn actual_exit_farm( + &self, + farm_address: &ManagedAddress, + farm_token_id: &TokenIdentifier, + farm_token_nonce: Nonce, + amount: &BigUint, + ) -> ExitFarmResultType { + let raw_results: RawResultsType = self + .farm_contract_proxy(farm_address.clone()) + .exit_farm() + .with_esdt_transfer((farm_token_id.clone(), farm_token_nonce, amount.clone())) + .execute_on_dest_context(); + + let mut results_wrapper = RawResultWrapper::new(raw_results); + results_wrapper.trim_results_front(2); + + let farming_tokens = results_wrapper.decode_next_result(); + let reward_tokens = results_wrapper.decode_next_result(); + + (farming_tokens, reward_tokens).into() + } + + fn require_is_intermediated_farm(&self, address: &ManagedAddress) { + require!( + self.intermediated_farms().contains(address), + "Not an intermediated farm" + ); + } + + fn require_wrapped_farm_token_id_not_empty(&self) { + require!(!self.wrapped_farm_token_id().is_empty(), "Empty token id"); + } + + #[proxy] + fn farm_contract_proxy(&self, to: ManagedAddress) -> farm_proxy::Proxy; +} diff --git a/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs b/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs new file mode 100644 index 000000000..d0bc68b4a --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs @@ -0,0 +1,220 @@ +#![allow(clippy::too_many_arguments)] +#![allow(clippy::comparison_chain)] +#![allow(clippy::vec_init_then_push)] + +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::{RawResultWrapper, RawResultsType}; +use factory::attr_ex_helper; + +use crate::energy_update; +use crate::proxy_common::WrappedLpTokenAttributes; + +use super::events; +use super::proxy_common; + +type RemoveLiquidityResultType = + MultiValue2, EsdtTokenPayment>; + +mod pair_proxy { + multiversx_sc::imports!(); + + #[multiversx_sc::proxy] + pub trait PairProxy { + #[payable("*")] + #[endpoint(removeLiquidity)] + fn remove_liquidity( + &self, + first_token_amount_min: BigUint, + second_token_amount_min: BigUint, + ) -> super::RemoveLiquidityResultType; + + #[view(getLpTokenIdentifier)] + fn get_lp_token_identifier(&self) -> TokenIdentifier; + } +} + +#[derive(ManagedVecItem, Clone)] +pub struct WrappedLpToken { + pub token_amount: EsdtTokenPayment, + pub attributes: WrappedLpTokenAttributes, +} + +#[multiversx_sc::module] +pub trait ProxyPairModule: + proxy_common::ProxyCommonModule + + token_merge_helper::TokenMergeHelperModule + + events::EventsModule + + energy_update::EnergyUpdateModule + + attr_ex_helper::AttrExHelper +{ + #[only_owner] + #[endpoint(addPairToIntermediate)] + fn add_pair_to_intermediate(&self, pair_address: ManagedAddress) { + self.intermediated_pairs().insert(pair_address); + } + + #[only_owner] + #[endpoint(removeIntermediatedPair)] + fn remove_intermediated_pair(&self, pair_address: ManagedAddress) { + self.require_is_intermediated_pair(&pair_address); + self.intermediated_pairs().remove(&pair_address); + } + + #[payable("*")] + #[endpoint(removeLiquidityProxy)] + fn remove_liquidity_proxy( + &self, + pair_address: ManagedAddress, + first_token_amount_min: BigUint, + second_token_amount_min: BigUint, + ) { + self.require_is_intermediated_pair(&pair_address); + self.require_wrapped_lp_token_id_not_empty(); + + let (token_id, token_nonce, amount) = self.call_value().single_esdt().into_tuple(); + require!(token_nonce != 0, "Can only be called with an SFT"); + require!(amount != 0, "Payment amount cannot be zero"); + + let wrapped_lp_token_id = self.wrapped_lp_token_id().get(); + require!(token_id == wrapped_lp_token_id, "Wrong input token"); + + let caller = self.blockchain().get_caller(); + let lp_token_id = self.ask_for_lp_token_id(&pair_address); + let attributes = self.get_wrapped_lp_token_attributes(&token_id, token_nonce); + require!(lp_token_id == attributes.lp_token_id, "Bad input address"); + + let locked_asset_token_id = self.locked_asset_token_id().get(); + let asset_token_id = self.asset_token_id().get(); + + let tokens_for_position = self + .actual_remove_liquidity( + &pair_address, + &lp_token_id, + &amount, + &first_token_amount_min, + &second_token_amount_min, + ) + .into_tuple(); + + let fungible_token_id: TokenIdentifier; + let fungible_token_amount: BigUint; + let assets_received: BigUint; + let locked_assets_invested = self.rule_of_three_non_zero_result( + &amount, + &attributes.lp_token_total_amount, + &attributes.locked_assets_invested, + ); + + if tokens_for_position.1.token_identifier == asset_token_id { + assets_received = tokens_for_position.1.amount.clone(); + fungible_token_id = tokens_for_position.0.token_identifier.clone(); + fungible_token_amount = tokens_for_position.0.amount.clone(); + } else { + sc_panic!("Bad tokens received from pair SC"); + } + + // Send back the tokens removed from pair sc. + let locked_assets_to_send = + core::cmp::min(assets_received.clone(), locked_assets_invested.clone()); + let mut payments_vec = ManagedVec::new(); + payments_vec.push(EsdtTokenPayment::new( + fungible_token_id.clone(), + 0, + fungible_token_amount.clone(), + )); + payments_vec.push(EsdtTokenPayment::new( + locked_asset_token_id.clone(), + attributes.locked_assets_nonce, + locked_assets_to_send.clone(), + )); + self.send_multiple_tokens_if_not_zero(&caller, &payments_vec); + + // Do cleanup + if assets_received > locked_assets_invested { + let difference = assets_received - locked_assets_invested; + self.send() + .direct_esdt(&caller, &asset_token_id, 0, &difference); + } else if assets_received < locked_assets_invested { + let difference = locked_assets_invested - assets_received; + self.deduct_energy_from_user( + &caller, + &locked_asset_token_id, + attributes.locked_assets_nonce, + &difference, + ); + self.send().esdt_local_burn( + &locked_asset_token_id, + attributes.locked_assets_nonce, + &difference, + ); + } + + self.send() + .esdt_local_burn(&asset_token_id, 0, &locked_assets_to_send); + self.send() + .esdt_local_burn(&wrapped_lp_token_id, token_nonce, &amount); + + self.emit_remove_liquidity_proxy_event( + &caller, + &pair_address, + &token_id, + token_nonce, + &amount, + &attributes, + &tokens_for_position.0.token_identifier, + 0, + &tokens_for_position.0.amount, + &tokens_for_position.1.token_identifier, + 0, + &tokens_for_position.1.amount, + ); + } + + fn actual_remove_liquidity( + &self, + pair_address: &ManagedAddress, + lp_token_id: &TokenIdentifier, + liquidity: &BigUint, + first_token_amount_min: &BigUint, + second_token_amount_min: &BigUint, + ) -> RemoveLiquidityResultType { + let raw_results: RawResultsType = self + .pair_contract_proxy(pair_address.clone()) + .remove_liquidity( + first_token_amount_min.clone(), + second_token_amount_min.clone(), + ) + .with_esdt_transfer((lp_token_id.clone(), 0, liquidity.clone())) + .execute_on_dest_context(); + + let mut results_wrapper = RawResultWrapper::new(raw_results); + results_wrapper.trim_results_front(2); + + let first_token = results_wrapper.decode_next_result(); + let second_token = results_wrapper.decode_next_result(); + + (first_token, second_token).into() + } + + fn ask_for_lp_token_id(&self, pair_address: &ManagedAddress) -> TokenIdentifier { + self.pair_contract_proxy(pair_address.clone()) + .get_lp_token_identifier() + .execute_on_dest_context() + } + + fn require_is_intermediated_pair(&self, address: &ManagedAddress) { + require!( + self.intermediated_pairs().contains(address), + "Not an intermediated pair" + ); + } + + fn require_wrapped_lp_token_id_not_empty(&self) { + require!(!self.wrapped_lp_token_id().is_empty(), "Empty token id"); + } + + #[proxy] + fn pair_contract_proxy(&self, to: ManagedAddress) -> pair_proxy::Proxy; +} diff --git a/legacy-contracts/proxy-dex-legacy/src/transfer_role.rs b/legacy-contracts/proxy-dex-legacy/src/transfer_role.rs new file mode 100644 index 000000000..ad0787e4e --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/src/transfer_role.rs @@ -0,0 +1,90 @@ +multiversx_sc::imports!(); + +use super::proxy_common; + +#[multiversx_sc::module] +pub trait TransferRoleModule: proxy_common::ProxyCommonModule { + /// Sets the transfer role for the given address. Defaults to own SC address. + #[only_owner] + #[endpoint(setTransferRoleLockedLpToken)] + fn set_transfer_role_locked_lp_token(&self, opt_address: OptionalValue) { + let locked_lp_token_id = self.wrapped_lp_token_id().get(); + let role_dest_address = match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + }; + let roles = [EsdtLocalRole::Transfer]; + + self.send() + .esdt_system_sc_proxy() + .set_special_roles( + &role_dest_address, + &locked_lp_token_id, + roles.iter().cloned(), + ) + .async_call_and_exit() + } + + /// Removes the transfer role for the given address. Defaults to own SC address. + #[only_owner] + #[endpoint(unsetTransferRoleLockedLpToken)] + fn unset_transfer_role_locked_lp_token(&self, opt_address: OptionalValue) { + let locked_lp_token_id = self.wrapped_lp_token_id().get(); + let role_dest_address = match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + }; + let roles = [EsdtLocalRole::Transfer]; + + self.send() + .esdt_system_sc_proxy() + .unset_special_roles( + &role_dest_address, + &locked_lp_token_id, + roles.iter().cloned(), + ) + .async_call_and_exit() + } + + /// Sets the transfer role for the given address. Defaults to own SC address. + #[only_owner] + #[endpoint(setTransferRoleLockedFarmToken)] + fn set_transfer_role_locked_farm_token(&self, opt_address: OptionalValue) { + let locked_farm_token_id = self.wrapped_farm_token_id().get(); + let role_dest_address = match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + }; + let roles = [EsdtLocalRole::Transfer]; + + self.send() + .esdt_system_sc_proxy() + .set_special_roles( + &role_dest_address, + &locked_farm_token_id, + roles.iter().cloned(), + ) + .async_call_and_exit() + } + + /// Removes the transfer role for the given address. Defaults to own SC address. + #[only_owner] + #[endpoint(unsetTransferRoleLockedFarmToken)] + fn unset_transfer_role_locked_farm_token(&self, opt_address: OptionalValue) { + let locked_farm_token_id = self.wrapped_farm_token_id().get(); + let role_dest_address = match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + }; + let roles = [EsdtLocalRole::Transfer]; + + self.send() + .esdt_system_sc_proxy() + .unset_special_roles( + &role_dest_address, + &locked_farm_token_id, + roles.iter().cloned(), + ) + .async_call_and_exit() + } +} diff --git a/legacy-contracts/proxy-dex-legacy/testnet.toml b/legacy-contracts/proxy-dex-legacy/testnet.toml new file mode 100644 index 000000000..e69de29bb diff --git a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock new file mode 100644 index 000000000..a3143553e --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock @@ -0,0 +1,398 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "cfg-if" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822" + +[[package]] +name = "common_errors" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "common_structs" +version = "0.0.0" +dependencies = [ + "fixed-supply-token", + "math", + "mergeable", + "multiversx-sc", + "unwrappable", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "energy-factory" +version = "0.0.0" +dependencies = [ + "common_structs", + "legacy_token_decode_module", + "math", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "sc_whitelist_module", + "simple-lock", + "unwrappable", + "utils", +] + +[[package]] +name = "factory" +version = "0.0.0" +dependencies = [ + "arrayvec", + "common_errors", + "common_structs", + "energy-factory", + "itertools", + "multiversx-sc", + "multiversx-sc-modules", + "token_merge_helper", + "token_send", + "wee_alloc", +] + +[[package]] +name = "fixed-supply-token" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "itertools" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +dependencies = [ + "either", +] + +[[package]] +name = "legacy_token_decode_module" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "utils", +] + +[[package]] +name = "libc" +version = "0.2.118" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06e509672465a0504304aa87f9f176f2b2b716ed8fb105ebe5c02dc6dce96a94" + +[[package]] +name = "math" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "memory_units" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8452105ba047068f40ff7093dd1d9da90898e63dd61736462e9cdda6a90ad3c3" + +[[package]] +name = "mergeable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-modules" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "proxy-dex-legacy" +version = "0.0.0" +dependencies = [ + "common_structs", + "factory", + "multiversx-sc", + "token_merge_helper", +] + +[[package]] +name = "proxy-dex-legacy-wasm" +version = "0.0.0" +dependencies = [ + "multiversx-sc-wasm-adapter", + "proxy-dex-legacy", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "sc_whitelist_module" +version = "0.0.0" +dependencies = [ + "common_errors", + "multiversx-sc", +] + +[[package]] +name = "simple-lock" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "multiversx-sc-modules", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "token_merge_helper" +version = "0.0.0" +dependencies = [ + "common_errors", + "multiversx-sc", +] + +[[package]] +name = "token_send" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "multiversx-sc", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "unwrappable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "utils" +version = "0.0.0" +dependencies = [ + "common_structs", + "fixed-supply-token", + "mergeable", + "multiversx-sc", +] + +[[package]] +name = "wee_alloc" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dbb3b5a6b2bb17cb6ad44a2e68a43e8d2722c997da10e928665c72ec6c0a0b8e" +dependencies = [ + "cfg-if", + "libc", + "memory_units", + "winapi", +] + +[[package]] +name = "winapi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" +dependencies = [ + "winapi-i686-pc-windows-gnu", + "winapi-x86_64-pc-windows-gnu", +] + +[[package]] +name = "winapi-i686-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" + +[[package]] +name = "winapi-x86_64-pc-windows-gnu" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" diff --git a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml new file mode 100644 index 000000000..fa6f756fe --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "proxy-dex-legacy-wasm" +version = "0.0.0" +edition = "2018" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.proxy-dex-legacy] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "=0.50.5" + +[workspace] +members = ["."] diff --git a/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs b/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs new file mode 100644 index 000000000..5d418f971 --- /dev/null +++ b/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs @@ -0,0 +1,44 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 20 +// Async Callback (empty): 1 +// Total number of exported functions: 22 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + proxy_dex_legacy + ( + init => init + getAssetTokenId => asset_token_id + getLockedAssetTokenId => locked_asset_token_id + getWrappedLpTokenId => wrapped_lp_token_id + getWrappedFarmTokenId => wrapped_farm_token_id + getIntermediatedFarms => get_intermediated_farms + getIntermediatedPairs => get_intermediated_pairs + addPairToIntermediate => add_pair_to_intermediate + removeIntermediatedPair => remove_intermediated_pair + removeLiquidityProxy => remove_liquidity_proxy + addFarmToIntermediate => add_farm_to_intermediate + removeIntermediatedFarm => remove_intermediated_farm + exitFarmProxy => exit_farm_proxy + setEnergyFactoryAddress => set_energy_factory_address + getEnergyFactoryAddress => energy_factory_address + migrateV1_2Position => migrate_v1_2_position + setTransferRoleLockedLpToken => set_transfer_role_locked_lp_token + unsetTransferRoleLockedLpToken => unset_transfer_role_locked_lp_token + setTransferRoleLockedFarmToken => set_transfer_role_locked_farm_token + unsetTransferRoleLockedFarmToken => unset_transfer_role_locked_farm_token + getExtendedAttributesActivationNonce => extended_attributes_activation_nonce + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/locked-asset/factory/src/lib.rs b/locked-asset/factory/src/lib.rs index bd27c4752..268ff0c05 100644 --- a/locked-asset/factory/src/lib.rs +++ b/locked-asset/factory/src/lib.rs @@ -1,6 +1,6 @@ #![no_std] -mod attr_ex_helper; +pub mod attr_ex_helper; mod cache; mod events; pub mod locked_asset; From 04dbeda70a9daf0874076328f2134b786d6e799d Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 17 Jul 2024 01:04:54 +0300 Subject: [PATCH 077/103] Factory legacy contract --- Cargo.lock | 22 +- Cargo.toml | 2 + legacy-contracts/factory-legacy/.gitignore | 7 + legacy-contracts/factory-legacy/Cargo.toml | 27 ++ legacy-contracts/factory-legacy/README.md | 26 ++ .../factory-legacy/meta/Cargo.toml | 14 + .../factory-legacy/meta/src/main.rs | 3 + .../factory-legacy/multiversx.json | 4 + .../factory-legacy/src/attr_ex_helper.rs | 68 ++++ legacy-contracts/factory-legacy/src/cache.rs | 49 +++ legacy-contracts/factory-legacy/src/events.rs | 123 ++++++ legacy-contracts/factory-legacy/src/lib.rs | 363 ++++++++++++++++++ .../factory-legacy/src/locked_asset.rs | 209 ++++++++++ .../src/locked_asset_token_merge.rs | 162 ++++++++ .../factory-legacy/src/migration.rs | 61 +++ legacy-contracts/factory-legacy/testnet.toml | 0 .../factory-legacy/wasm/Cargo.lock | 255 ++++++++++++ .../factory-legacy/wasm/Cargo.toml | 34 ++ .../factory-legacy/wasm/src/lib.rs | 45 +++ legacy-contracts/farm-v-13/wasm/src/lib.rs | 5 +- legacy-contracts/proxy-dex-legacy/Cargo.toml | 4 +- .../proxy-dex-legacy/src/energy_update.rs | 5 +- legacy-contracts/proxy-dex-legacy/src/lib.rs | 2 +- .../src/migration_from_v1_2.rs | 2 +- .../proxy-dex-legacy/src/proxy_farm.rs | 2 +- .../proxy-dex-legacy/src/proxy_pair.rs | 2 +- .../proxy-dex-legacy/wasm/Cargo.lock | 137 +------ 27 files changed, 1487 insertions(+), 146 deletions(-) create mode 100644 legacy-contracts/factory-legacy/.gitignore create mode 100644 legacy-contracts/factory-legacy/Cargo.toml create mode 100644 legacy-contracts/factory-legacy/README.md create mode 100644 legacy-contracts/factory-legacy/meta/Cargo.toml create mode 100644 legacy-contracts/factory-legacy/meta/src/main.rs create mode 100644 legacy-contracts/factory-legacy/multiversx.json create mode 100644 legacy-contracts/factory-legacy/src/attr_ex_helper.rs create mode 100644 legacy-contracts/factory-legacy/src/cache.rs create mode 100644 legacy-contracts/factory-legacy/src/events.rs create mode 100644 legacy-contracts/factory-legacy/src/lib.rs create mode 100644 legacy-contracts/factory-legacy/src/locked_asset.rs create mode 100644 legacy-contracts/factory-legacy/src/locked_asset_token_merge.rs create mode 100644 legacy-contracts/factory-legacy/src/migration.rs create mode 100644 legacy-contracts/factory-legacy/testnet.toml create mode 100644 legacy-contracts/factory-legacy/wasm/Cargo.lock create mode 100644 legacy-contracts/factory-legacy/wasm/Cargo.toml create mode 100644 legacy-contracts/factory-legacy/wasm/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index 97f3c2e89..04e8e5188 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -757,6 +757,26 @@ dependencies = [ "multiversx-sc-meta", ] +[[package]] +name = "factory-legacy" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "multiversx-sc", + "multiversx-sc-modules", + "multiversx-sc-scenario", + "token_merge_helper", +] + +[[package]] +name = "factory-legacy-meta" +version = "0.0.0" +dependencies = [ + "factory-legacy", + "multiversx-sc-meta", +] + [[package]] name = "farm" version = "0.0.0" @@ -2247,7 +2267,7 @@ name = "proxy-dex-legacy" version = "0.0.0" dependencies = [ "common_structs", - "factory", + "factory-legacy", "multiversx-sc", "multiversx-sc-scenario", "token_merge_helper", diff --git a/Cargo.toml b/Cargo.toml index db13e51b2..7a6041dc6 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -45,6 +45,8 @@ members = [ "legacy-contracts/farm-v-13/meta", "legacy-contracts/proxy-dex-legacy", "legacy-contracts/proxy-dex-legacy/meta", + "legacy-contracts/factory-legacy", + "legacy-contracts/factory-legacy/meta", "locked-asset/", "locked-asset/distribution", diff --git a/legacy-contracts/factory-legacy/.gitignore b/legacy-contracts/factory-legacy/.gitignore new file mode 100644 index 000000000..eaf5915bd --- /dev/null +++ b/legacy-contracts/factory-legacy/.gitignore @@ -0,0 +1,7 @@ +# Generated by Cargo +# will have compiled files and executables +/target/ +*/target/ + +# The erdpy output +output diff --git a/legacy-contracts/factory-legacy/Cargo.toml b/legacy-contracts/factory-legacy/Cargo.toml new file mode 100644 index 000000000..bff8b6fa4 --- /dev/null +++ b/legacy-contracts/factory-legacy/Cargo.toml @@ -0,0 +1,27 @@ +[package] +name = "factory-legacy" +publish = false +version = "0.0.0" +edition = "2018" + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "=0.50.5" +features = ["esdt-token-payment-legacy-decode"] + +[dependencies.multiversx-sc-modules] +version = "=0.50.5" + +[dev-dependencies.multiversx-sc-scenario] +version = "=0.50.5" + +[dependencies.common_structs] +path = "../../common/common_structs" + +[dependencies.common_errors] +path = "../../common/common_errors" + +[dependencies.token_merge_helper] +path = "../../common/modules/token_merge_helper" \ No newline at end of file diff --git a/legacy-contracts/factory-legacy/README.md b/legacy-contracts/factory-legacy/README.md new file mode 100644 index 000000000..b61d85ad8 --- /dev/null +++ b/legacy-contracts/factory-legacy/README.md @@ -0,0 +1,26 @@ +# Locked Asset Factory Smart Contract + +This document presents how one can deploy and configure a Locked Asset Factory Contract. +The bigger picture about what a Locked Asset Factory Contract can do can be found in the Repository's Root Readme. + +## Deployment + +The Locked Asset Factory contract can be deployed using `erdpy` and using the interraction snippets. + +The init parameters are: + +- asset_token_id. The TokenId of the asset that a locked asset represents. In case of Maiar Exchange it will be MEX. + +- default_unlock_period. A vector of unlock milestones. This represents a period since each epoch in the vector will be added with a starting epoch. + +The Contract requires LocalMint and LocalBurn for asset token. + +## Creating and Forwarding SFTs + +Before creating LockedAssetLockens, the owner has to issue those tokens using `issueLockedAssetToken` and after this he also has to give the NftCreate, NftAddQuantity and NftBurn roles to the contract unsing `setLocalRolesLockedAssetToken`. + +The Contract has an endpoint `createAndForward` that can be called in order to request an amount of Locked MEX. Only those addresses in the `whitelisted_contracts` set can call this endpoint. This whitelist can be configured by the admin using `whitelist` and `removeWhitelist` endpoints. + +## Unlocking MEX + +A user that has Locked MEX can unlock it and can receive the Locked MEX "remaining" and the unlocked MEX amount. The newly created Locked MEX will have its unlock milestones re-calculated such that the percents unlocking schedule will be updated to the new locked amount. For example: if default_unlock_period is `0x000000000000000232`, `0x000000000000000432` it would mean that after `0000000000000002` epochs, should unlock `32`.to_dec() (`50`) percent of the amount. After the first unlock at epoch 3 let's say, the next unlock milestone will be recalculated as `0x000000000000000464`. Notice the `50%` become `100%`. diff --git a/legacy-contracts/factory-legacy/meta/Cargo.toml b/legacy-contracts/factory-legacy/meta/Cargo.toml new file mode 100644 index 000000000..01027f67e --- /dev/null +++ b/legacy-contracts/factory-legacy/meta/Cargo.toml @@ -0,0 +1,14 @@ +[package] +name = "factory-legacy-meta" + +version = "0.0.0" +authors = [ "you",] +edition = "2018" +publish = false + +[dependencies.factory-legacy] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.5" +default-features = false \ No newline at end of file diff --git a/legacy-contracts/factory-legacy/meta/src/main.rs b/legacy-contracts/factory-legacy/meta/src/main.rs new file mode 100644 index 000000000..64a2b3bb3 --- /dev/null +++ b/legacy-contracts/factory-legacy/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} \ No newline at end of file diff --git a/legacy-contracts/factory-legacy/multiversx.json b/legacy-contracts/factory-legacy/multiversx.json new file mode 100644 index 000000000..c2cab7433 --- /dev/null +++ b/legacy-contracts/factory-legacy/multiversx.json @@ -0,0 +1,4 @@ +{ + "language": "rust" +} + diff --git a/legacy-contracts/factory-legacy/src/attr_ex_helper.rs b/legacy-contracts/factory-legacy/src/attr_ex_helper.rs new file mode 100644 index 000000000..322bb0b73 --- /dev/null +++ b/legacy-contracts/factory-legacy/src/attr_ex_helper.rs @@ -0,0 +1,68 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::LockedAssetTokenAttributes; +use common_structs::LockedAssetTokenAttributesEx; +use common_structs::UnlockMilestoneEx; +use common_structs::UnlockScheduleEx; + +// 1% = 1_000; +pub const _PRECISION_EXTENDED: u64 = 100_000u64; + +// From 1 to 1_000; +pub const PRECISION_EX_INCREASE: u64 = 1_000u64; + +#[multiversx_sc::module] +pub trait AttrExHelper { + fn get_attributes_ex( + &self, + token_id: &TokenIdentifier, + token_nonce: u64, + attr_ex_activation: u64, + ) -> LockedAssetTokenAttributesEx { + let token_info = self.blockchain().get_esdt_token_data( + &self.blockchain().get_sc_address(), + token_id, + token_nonce, + ); + + if token_nonce < attr_ex_activation { + let attr = self + .serializer() + .top_decode_from_managed_buffer::>( + &token_info.attributes, + ); + self.convert_attr_to_attr_ex(&attr) + } else { + self.serializer() + .top_decode_from_managed_buffer::>( + &token_info.attributes, + ) + } + } + + fn convert_attr_to_attr_ex( + &self, + attr: &LockedAssetTokenAttributes, + ) -> LockedAssetTokenAttributesEx { + let mut new_milestones: ManagedVec = ManagedVec::new(); + + for milestones in attr.unlock_schedule.unlock_milestones.iter() { + new_milestones.push(UnlockMilestoneEx { + unlock_epoch: milestones.unlock_epoch, + unlock_percent: (milestones.unlock_percent as u64) * PRECISION_EX_INCREASE, + }); + } + + LockedAssetTokenAttributesEx { + unlock_schedule: UnlockScheduleEx { + unlock_milestones: new_milestones, + }, + is_merged: attr.is_merged, + } + } + + #[view(getExtendedAttributesActivationNonce)] + #[storage_mapper("extended_attributes_activation_nonce")] + fn extended_attributes_activation_nonce(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/factory-legacy/src/cache.rs b/legacy-contracts/factory-legacy/src/cache.rs new file mode 100644 index 000000000..24d1a031d --- /dev/null +++ b/legacy-contracts/factory-legacy/src/cache.rs @@ -0,0 +1,49 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::{Nonce, UnlockScheduleEx}; + +use crate::attr_ex_helper; + +use super::locked_asset; + +#[multiversx_sc::module] +pub trait CacheModule: locked_asset::LockedAssetModule + attr_ex_helper::AttrExHelper { + #[inline(always)] + fn get_sft_nonce_for_unlock_schedule( + &self, + unlock_schedule: &UnlockScheduleEx, + ) -> Option { + self.nonce_cache_ex().get(unlock_schedule) + } + + #[view(getUnlockScheduleForSFTNonce)] + fn get_unlock_schedule_for_sft_nonce( + &self, + nonce: Nonce, + ) -> Option> { + self.unlock_schedule_cache_ex().get(&nonce) + } + + #[inline(always)] + fn cache_unlock_schedule_and_nonce( + &self, + unlock_schedule: &UnlockScheduleEx, + nonce: Nonce, + ) { + self.nonce_cache_ex().insert(unlock_schedule.clone(), nonce); + self.unlock_schedule_cache_ex() + .insert(nonce, unlock_schedule.clone()); + } + + #[view(getCacheSize)] + fn get_cache_size(&self) -> usize { + self.nonce_cache_ex().len() + } + + #[storage_mapper("nonce_cache_ex")] + fn nonce_cache_ex(&self) -> MapMapper, Nonce>; + + #[storage_mapper("unlock_schedule_cache_ex")] + fn unlock_schedule_cache_ex(&self) -> MapMapper>; +} diff --git a/legacy-contracts/factory-legacy/src/events.rs b/legacy-contracts/factory-legacy/src/events.rs new file mode 100644 index 000000000..149c7af5c --- /dev/null +++ b/legacy-contracts/factory-legacy/src/events.rs @@ -0,0 +1,123 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::LockedAssetTokenAttributesEx; + +#[derive(TypeAbi, TopEncode)] +pub struct CreateAndForwardEvent { + caller: ManagedAddress, + destination: ManagedAddress, + locked_asset_token_id: TokenIdentifier, + locked_asset_token_nonce: u64, + locked_asset_token_amount: BigUint, + locked_assets_attributes: LockedAssetTokenAttributesEx, + start_epoch: u64, + block: u64, + epoch: u64, + timestamp: u64, +} + +#[derive(TypeAbi, TopEncode)] +pub struct UnlockAssetsEvent { + caller: ManagedAddress, + input_locked_assets_token_id: TokenIdentifier, + input_locked_assets_token_nonce: u64, + input_locked_assets_token_amount: BigUint, + output_locked_assets_token_id: TokenIdentifier, + output_locked_assets_token_nonce: u64, + output_locked_assets_token_amount: BigUint, + asset_token_id: TokenIdentifier, + asset_token_amount: BigUint, + input_assets_attributes: LockedAssetTokenAttributesEx, + output_assets_attributes: LockedAssetTokenAttributesEx, + block: u64, + epoch: u64, + timestamp: u64, +} + +#[multiversx_sc::module] +pub trait EventsModule { + fn emit_create_and_forward_event( + self, + caller: &ManagedAddress, + destination: &ManagedAddress, + locked_asset_token_id: &TokenIdentifier, + locked_asset_token_nonce: u64, + locked_asset_token_amount: &BigUint, + locked_assets_attributes: &LockedAssetTokenAttributesEx, + start_epoch: u64, + ) { + let epoch = self.blockchain().get_block_epoch(); + self.create_and_forward_event( + caller, + destination, + epoch, + &CreateAndForwardEvent { + caller: caller.clone(), + destination: destination.clone(), + locked_asset_token_id: locked_asset_token_id.clone(), + locked_asset_token_nonce, + locked_asset_token_amount: locked_asset_token_amount.clone(), + locked_assets_attributes: locked_assets_attributes.clone(), + start_epoch, + block: self.blockchain().get_block_nonce(), + epoch, + timestamp: self.blockchain().get_block_timestamp(), + }, + ) + } + + fn emit_unlock_assets_event( + self, + caller: &ManagedAddress, + input_locked_assets_token_id: &TokenIdentifier, + input_locked_assets_token_nonce: u64, + input_locked_assets_token_amount: &BigUint, + output_locked_assets_token_id: &TokenIdentifier, + output_locked_assets_token_nonce: u64, + output_locked_assets_token_amount: &BigUint, + asset_token_id: &TokenIdentifier, + asset_token_amount: &BigUint, + input_assets_attributes: &LockedAssetTokenAttributesEx, + output_assets_attributes: &LockedAssetTokenAttributesEx, + ) { + let epoch = self.blockchain().get_block_epoch(); + self.unlock_assets_event( + caller, + epoch, + &UnlockAssetsEvent { + caller: caller.clone(), + input_locked_assets_token_id: input_locked_assets_token_id.clone(), + input_locked_assets_token_nonce, + input_locked_assets_token_amount: input_locked_assets_token_amount.clone(), + output_locked_assets_token_id: output_locked_assets_token_id.clone(), + output_locked_assets_token_nonce, + output_locked_assets_token_amount: output_locked_assets_token_amount.clone(), + asset_token_id: asset_token_id.clone(), + asset_token_amount: asset_token_amount.clone(), + input_assets_attributes: input_assets_attributes.clone(), + output_assets_attributes: output_assets_attributes.clone(), + block: self.blockchain().get_block_nonce(), + epoch, + timestamp: self.blockchain().get_block_timestamp(), + }, + ) + } + + #[event("create_and_forward")] + fn create_and_forward_event( + self, + #[indexed] caller: &ManagedAddress, + #[indexed] destination: &ManagedAddress, + #[indexed] epoch: u64, + swap_event: &CreateAndForwardEvent, + ); + + #[event("unlock_assets")] + fn unlock_assets_event( + self, + #[indexed] caller: &ManagedAddress, + #[indexed] epoch: u64, + swap_event: &UnlockAssetsEvent, + ); +} diff --git a/legacy-contracts/factory-legacy/src/lib.rs b/legacy-contracts/factory-legacy/src/lib.rs new file mode 100644 index 000000000..56449f8d1 --- /dev/null +++ b/legacy-contracts/factory-legacy/src/lib.rs @@ -0,0 +1,363 @@ +#![no_std] + +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use attr_ex_helper::PRECISION_EX_INCREASE; +use common_structs::{ + Epoch, LockedAssetTokenAttributesEx, UnlockMilestoneEx, UnlockPeriod, UnlockScheduleEx, +}; + +pub mod attr_ex_helper; +mod cache; +mod events; +pub mod locked_asset; +pub mod locked_asset_token_merge; +pub mod migration; + +const ADDITIONAL_AMOUNT_TO_CREATE: u64 = 1; +const EPOCHS_IN_MONTH: u64 = 30; + +#[derive(TypeAbi, TopEncode, TopDecode)] +pub struct OldEsdtTokenPayment { + pub token_type: EsdtTokenType, + pub payment: EsdtTokenPayment, +} + +impl OldEsdtTokenPayment { + pub fn new(payment: EsdtTokenPayment) -> Self { + Self { + token_type: payment.token_type(), + payment, + } + } +} + +#[multiversx_sc::contract] +pub trait LockedAssetFactory: + locked_asset::LockedAssetModule + + cache::CacheModule + + token_merge_helper::TokenMergeHelperModule + + locked_asset_token_merge::LockedAssetTokenMergeModule + + events::EventsModule + + attr_ex_helper::AttrExHelper + + migration::LockedTokenMigrationModule + + multiversx_sc_modules::pause::PauseModule +{ + #[init] + fn init(&self) { + self.set_paused(true); + } + + #[only_owner] + #[endpoint] + fn whitelist(&self, address: ManagedAddress) { + let is_new = self.whitelisted_contracts().insert(address); + require!(is_new, "ManagedAddress already whitelisted"); + } + + #[only_owner] + #[endpoint(removeWhitelist)] + fn remove_whitelist(&self, address: ManagedAddress) { + let is_removed = self.whitelisted_contracts().remove(&address); + require!(is_removed, "ManagedAddresss not whitelisted"); + } + + #[endpoint(createAndForwardCustomPeriod)] + fn create_and_forward_custom_period( + &self, + amount: BigUint, + address: ManagedAddress, + start_epoch: Epoch, + unlock_period: UnlockPeriod, + ) -> OldEsdtTokenPayment { + self.require_not_paused(); + + let caller = self.blockchain().get_caller(); + require!( + self.whitelisted_contracts().contains(&caller), + "Permission denied" + ); + require!(!unlock_period.unlock_milestones.is_empty(), "Empty arg"); + + let month_start_epoch = self.get_month_start_epoch(start_epoch); + let attr = LockedAssetTokenAttributesEx { + unlock_schedule: self.create_unlock_schedule(month_start_epoch, unlock_period), + is_merged: false, + }; + + let new_token = self.produce_tokens_and_send(&amount, &attr, &address); + + self.emit_create_and_forward_event( + &caller, + &address, + &new_token.token_identifier, + new_token.token_nonce, + &new_token.amount, + &attr, + month_start_epoch, + ); + + OldEsdtTokenPayment::new(new_token) + } + + #[endpoint(createAndForward)] + fn create_and_forward( + &self, + amount: BigUint, + address: ManagedAddress, + start_epoch: Epoch, + ) -> OldEsdtTokenPayment { + self.require_not_paused(); + + let caller = self.blockchain().get_caller(); + require!( + self.whitelisted_contracts().contains(&caller), + "Permission denied" + ); + require!( + !self.locked_asset_token_id().is_empty(), + "Locked Asset Token not registered" + ); + require!(amount > 0, "Zero input amount"); + + let month_start_epoch = self.get_month_start_epoch(start_epoch); + let unlock_period = self.default_unlock_period().get(); + let attr = LockedAssetTokenAttributesEx { + unlock_schedule: self.create_unlock_schedule(month_start_epoch, unlock_period), + is_merged: false, + }; + + let new_token = self.produce_tokens_and_send(&amount, &attr, &address); + + self.emit_create_and_forward_event( + &caller, + &address, + &new_token.token_identifier, + new_token.token_nonce, + &new_token.amount, + &attr, + start_epoch, + ); + + OldEsdtTokenPayment::new(new_token) + } + + #[payable("*")] + #[endpoint(unlockAssets)] + fn unlock_assets(&self) { + self.require_not_paused(); + + let (token_id, token_nonce, amount) = self.call_value().single_esdt().into_tuple(); + let locked_token_id = self.locked_asset_token_id().get(); + require!(token_id == locked_token_id, "Bad payment token"); + + let attr_ex_activation = self.extended_attributes_activation_nonce().get(); + let attributes = self.get_attributes_ex(&token_id, token_nonce, attr_ex_activation); + let unlock_schedule = &attributes.unlock_schedule; + + let month_start_epoch = self.get_month_start_epoch(self.blockchain().get_block_epoch()); + let unlock_amount = self.get_unlock_amount( + &amount, + month_start_epoch, + &unlock_schedule.unlock_milestones, + ); + require!(amount >= unlock_amount, "Cannot unlock more than locked"); + require!(unlock_amount > 0u64, "Method called too soon"); + + let caller = self.blockchain().get_caller(); + self.mint_and_send_assets(&caller, &unlock_amount); + + let mut output_locked_assets_token_amount = + EsdtTokenPayment::new(token_id.clone(), 0, BigUint::zero()); + let mut output_locked_asset_attributes = LockedAssetTokenAttributesEx { + unlock_schedule: UnlockScheduleEx { + unlock_milestones: ManagedVec::new(), + }, + is_merged: false, + }; + + let locked_remaining = &amount - &unlock_amount; + if locked_remaining > 0u64 { + let new_unlock_milestones = self.create_new_unlock_milestones( + month_start_epoch, + &unlock_schedule.unlock_milestones, + ); + output_locked_asset_attributes = LockedAssetTokenAttributesEx { + unlock_schedule: UnlockScheduleEx { + unlock_milestones: new_unlock_milestones, + }, + is_merged: attributes.is_merged, + }; + output_locked_assets_token_amount = self.produce_tokens_and_send( + &locked_remaining, + &output_locked_asset_attributes, + &caller, + ); + } + + self.send() + .esdt_local_burn(&locked_token_id, token_nonce, &amount); + + let initial_amounts_per_epoch = attributes.get_unlock_amounts_per_epoch(&amount); + let final_amounts_per_epoch = + output_locked_asset_attributes.get_unlock_amounts_per_epoch(&locked_remaining); + self.update_energy_after_unlock( + caller.clone(), + initial_amounts_per_epoch, + final_amounts_per_epoch, + ); + + self.emit_unlock_assets_event( + &caller, + &token_id, + token_nonce, + &amount, + &output_locked_assets_token_amount.token_identifier, + output_locked_assets_token_amount.token_nonce, + &output_locked_assets_token_amount.amount, + &self.asset_token_id().get(), + &unlock_amount, + &attributes, + &output_locked_asset_attributes, + ); + } + + fn get_month_start_epoch(&self, epoch: Epoch) -> Epoch { + epoch - (epoch - self.init_epoch().get()) % EPOCHS_IN_MONTH + } + + fn produce_tokens_and_send( + &self, + amount: &BigUint, + attributes: &LockedAssetTokenAttributesEx, + address: &ManagedAddress, + ) -> EsdtTokenPayment { + let result = self.get_sft_nonce_for_unlock_schedule(&attributes.unlock_schedule); + let sent_nonce = match result { + Option::Some(cached_nonce) => { + self.add_quantity_and_send_locked_assets(amount, cached_nonce, address); + cached_nonce + } + Option::None => { + let do_cache_result = !attributes.is_merged; + + let additional_amount_to_create = if do_cache_result { + BigUint::from(ADDITIONAL_AMOUNT_TO_CREATE) + } else { + BigUint::zero() + }; + + let new_nonce = self.create_and_send_locked_assets( + amount, + &additional_amount_to_create, + address, + attributes, + ); + + if do_cache_result { + self.cache_unlock_schedule_and_nonce(&attributes.unlock_schedule, new_nonce); + } + new_nonce + } + }; + + let token_id = self.locked_asset_token_id().get(); + EsdtTokenPayment::new(token_id, sent_nonce, amount.clone()) + } + + #[only_owner] + #[endpoint(setTransferRoleForAddress)] + fn set_transfer_role_for_address(&self, opt_address: OptionalValue) { + let address = match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + }; + + self.send() + .esdt_system_sc_proxy() + .set_special_roles( + &address, + &self.locked_asset_token_id().get(), + [EsdtLocalRole::Transfer][..].iter().cloned(), + ) + .async_call_and_exit() + } + + #[only_owner] + #[endpoint(unsetTransferRoleForAddress)] + fn unset_transfer_role_for_address(&self, opt_address: OptionalValue) { + let address = match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + }; + + self.send() + .esdt_system_sc_proxy() + .unset_special_roles( + &address, + &self.locked_asset_token_id().get(), + [EsdtLocalRole::Transfer][..].iter().cloned(), + ) + .async_call_and_exit() + } + + #[only_owner] + #[endpoint(setBurnRoleForAddress)] + fn set_burn_role_for_address(&self, opt_address: OptionalValue) { + let address = match opt_address { + OptionalValue::Some(addr) => addr, + OptionalValue::None => self.blockchain().get_sc_address(), + }; + + self.send() + .esdt_system_sc_proxy() + .set_special_roles( + &address, + &self.locked_asset_token_id().get(), + [EsdtLocalRole::NftBurn][..].iter().cloned(), + ) + .async_call_and_exit() + } + + fn create_unlock_schedule( + &self, + start_epoch: Epoch, + unlock_period: UnlockPeriod, + ) -> UnlockScheduleEx { + let mut result = ManagedVec::new(); + for milestone in unlock_period.unlock_milestones.iter() { + result.push(UnlockMilestoneEx { + unlock_epoch: milestone.unlock_epoch + start_epoch, + unlock_percent: milestone.unlock_percent as u64 * PRECISION_EX_INCREASE, + }); + } + UnlockScheduleEx { + unlock_milestones: result, + } + } + + #[view(getLastErrorMessage)] + #[storage_mapper("last_error_message")] + fn last_error_message(&self) -> SingleValueMapper; + + #[view(getInitEpoch)] + #[storage_mapper("init_epoch")] + fn init_epoch(&self) -> SingleValueMapper; + + #[storage_mapper("whitelist")] + fn whitelisted_contracts(&self) -> SetMapper; + + #[view(getWhitelistedContracts)] + fn get_whitelisted_contracts(&self) -> MultiValueEncoded { + let mut result = MultiValueEncoded::new(); + for pair in self.whitelisted_contracts().iter() { + result.push(pair); + } + result + } + + #[view(getDefaultUnlockPeriod)] + #[storage_mapper("default_unlock_period")] + fn default_unlock_period(&self) -> SingleValueMapper>; +} diff --git a/legacy-contracts/factory-legacy/src/locked_asset.rs b/legacy-contracts/factory-legacy/src/locked_asset.rs new file mode 100644 index 000000000..a1e02cc8d --- /dev/null +++ b/legacy-contracts/factory-legacy/src/locked_asset.rs @@ -0,0 +1,209 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::*; + +use crate::attr_ex_helper::{self, PRECISION_EX_INCREASE}; + +pub const ONE_MILLION: u64 = 1_000_000u64; +pub const TEN_THOUSAND: u64 = 10_000u64; +pub const PERCENTAGE_TOTAL_EX: u64 = 100_000u64; +pub const MAX_MILESTONES_IN_SCHEDULE: usize = 64; +pub const DOUBLE_MAX_MILESTONES_IN_SCHEDULE: usize = 2 * MAX_MILESTONES_IN_SCHEDULE; + +use core::fmt::Debug; + +#[derive(ManagedVecItem)] +pub struct LockedTokenEx { + pub token_amount: EsdtTokenPayment, + pub attributes: LockedAssetTokenAttributesEx, +} + +#[derive(ManagedVecItem, Clone, Debug)] +pub struct EpochAmountPair { + pub epoch: u64, + pub amount: BigUint, +} + +#[multiversx_sc::module] +pub trait LockedAssetModule: attr_ex_helper::AttrExHelper { + fn create_and_send_locked_assets( + &self, + amount: &BigUint, + additional_amount_to_create: &BigUint, + address: &ManagedAddress, + attributes: &LockedAssetTokenAttributesEx, + ) -> Nonce { + let token_id = self.locked_asset_token_id().get(); + let last_created_nonce = self.send().esdt_nft_create_compact( + &token_id, + &(amount + additional_amount_to_create), + attributes, + ); + self.send() + .direct_esdt(address, &token_id, last_created_nonce, amount); + + last_created_nonce + } + + fn add_quantity_and_send_locked_assets( + &self, + amount: &BigUint, + sft_nonce: Nonce, + address: &ManagedAddress, + ) { + let token_id = self.locked_asset_token_id().get(); + self.send().esdt_local_mint(&token_id, sft_nonce, amount); + + self.send() + .direct_esdt(address, &token_id, sft_nonce, amount); + } + + fn get_unlock_amount( + &self, + amount: &BigUint, + current_epoch: Epoch, + unlock_milestones: &ManagedVec, + ) -> BigUint { + amount * &BigUint::from(self.get_unlock_percent(current_epoch, unlock_milestones)) + / PERCENTAGE_TOTAL_EX + } + + fn get_unlock_percent( + &self, + current_epoch: Epoch, + unlock_milestones: &ManagedVec, + ) -> u64 { + let mut unlock_percent = 0u64; + + for milestone in unlock_milestones.into_iter() { + if milestone.unlock_epoch <= current_epoch { + unlock_percent += milestone.unlock_percent; + } + } + + require!( + unlock_percent <= PERCENTAGE_TOTAL_EX, + "unlock percent greater than max" + ); + + unlock_percent + } + + fn create_new_unlock_milestones( + &self, + current_epoch: Epoch, + old_unlock_milestones: &ManagedVec, + ) -> ManagedVec { + let unlock_percent = self.get_unlock_percent(current_epoch, old_unlock_milestones); + let unlock_percent_remaining = PERCENTAGE_TOTAL_EX - unlock_percent; + + if unlock_percent_remaining == 0 { + return ManagedVec::new(); + } + + let mut unlock_milestones_merged = + ArrayVec::::new(); + for old_milestone in old_unlock_milestones.iter() { + if old_milestone.unlock_epoch > current_epoch { + let new_unlock_percent = + old_milestone.unlock_percent * PRECISION_EX_INCREASE * ONE_MILLION + / unlock_percent_remaining; + unlock_milestones_merged.push(UnlockMilestoneEx { + unlock_epoch: old_milestone.unlock_epoch, + unlock_percent: new_unlock_percent, + }); + } + } + + self.distribute_leftover(&mut unlock_milestones_merged); + self.get_non_zero_percent_milestones_as_vec(&unlock_milestones_merged) + } + + fn distribute_leftover( + &self, + unlock_milestones_merged: &mut ArrayVec, + ) { + let mut sum_of_new_percents = 0u64; + for milestone in unlock_milestones_merged.iter() { + sum_of_new_percents += milestone.unlock_percent / TEN_THOUSAND; + } + let mut leftover = PERCENTAGE_TOTAL_EX - sum_of_new_percents; + + while leftover != 0 { + let mut max_rounding_error = 0; + let mut max_rounding_error_index = 0; + for index in 0..unlock_milestones_merged.len() { + let rounding_error = unlock_milestones_merged[index].unlock_percent % TEN_THOUSAND; + if rounding_error >= max_rounding_error { + max_rounding_error = rounding_error; + max_rounding_error_index = index; + } + } + + leftover -= 1; + unlock_milestones_merged[max_rounding_error_index].unlock_percent = + ((unlock_milestones_merged[max_rounding_error_index].unlock_percent + / TEN_THOUSAND) + + 1) + * TEN_THOUSAND; + } + } + + fn get_non_zero_percent_milestones_as_vec( + &self, + unlock_milestones_merged: &ArrayVec, + ) -> ManagedVec { + let mut new_unlock_milestones = ManagedVec::new(); + + for el in unlock_milestones_merged.iter() { + let percent_rounded = el.unlock_percent / TEN_THOUSAND; + if percent_rounded != 0 { + new_unlock_milestones.push(UnlockMilestoneEx { + unlock_epoch: el.unlock_epoch, + unlock_percent: percent_rounded, + }); + } + } + + new_unlock_milestones + } + + fn validate_unlock_milestones(&self, unlock_milestones: &ManagedVec) { + require!(!unlock_milestones.is_empty(), "Empty param"); + + let mut percents_sum: u8 = 0; + let mut last_milestone_unlock_epoch: u64 = 0; + + for milestone in unlock_milestones.into_iter() { + require!( + milestone.unlock_epoch >= last_milestone_unlock_epoch, + "Unlock epochs not in order" + ); + require!( + milestone.unlock_percent <= 100, + "Unlock percent more than 100" + ); + last_milestone_unlock_epoch = milestone.unlock_epoch; + percents_sum += milestone.unlock_percent; + } + + require!(percents_sum == 100, "Percents do not sum up to 100"); + } + + fn mint_and_send_assets(&self, dest: &ManagedAddress, amount: &BigUint) { + if amount > &0 { + let asset_token_id = self.asset_token_id().get(); + self.send().esdt_local_mint(&asset_token_id, 0, amount); + self.send().direct_esdt(dest, &asset_token_id, 0, amount); + } + } + + #[view(getLockedAssetTokenId)] + #[storage_mapper("locked_asset_token_id")] + fn locked_asset_token_id(&self) -> SingleValueMapper; + + #[view(getAssetTokenId)] + #[storage_mapper("asset_token_id")] + fn asset_token_id(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/factory-legacy/src/locked_asset_token_merge.rs b/legacy-contracts/factory-legacy/src/locked_asset_token_merge.rs new file mode 100644 index 000000000..8cb637658 --- /dev/null +++ b/legacy-contracts/factory-legacy/src/locked_asset_token_merge.rs @@ -0,0 +1,162 @@ +multiversx_sc::imports!(); +multiversx_sc::derive_imports!(); + +use common_structs::*; + +use crate::attr_ex_helper::{self, PRECISION_EX_INCREASE}; + +use super::locked_asset; +use super::locked_asset::{ + EpochAmountPair, LockedTokenEx, DOUBLE_MAX_MILESTONES_IN_SCHEDULE, MAX_MILESTONES_IN_SCHEDULE, + ONE_MILLION, PERCENTAGE_TOTAL_EX, +}; + +#[multiversx_sc::module] +pub trait LockedAssetTokenMergeModule: + locked_asset::LockedAssetModule + + token_merge_helper::TokenMergeHelperModule + + attr_ex_helper::AttrExHelper +{ + fn burn_tokens_from_payments(&self, payments: &ManagedVec) { + for entry in payments { + self.send() + .esdt_local_burn(&entry.token_identifier, entry.token_nonce, &entry.amount); + } + } + + fn get_merged_locked_asset_token_amount_and_attributes( + &self, + payments: &ManagedVec, + ) -> (BigUint, LockedAssetTokenAttributesEx) { + require!(!payments.is_empty(), "Cannot merge with 0 tokens"); + + let mut tokens = ManagedVec::new(); + let mut sum_amount = BigUint::zero(); + let locked_asset_token_id = self.locked_asset_token_id().get(); + let attr_ex_activation = self.extended_attributes_activation_nonce().get(); + for entry in payments { + require!( + entry.token_identifier == locked_asset_token_id, + "Bad token id" + ); + + tokens.push(LockedTokenEx { + token_amount: EsdtTokenPayment::new( + entry.token_identifier.clone(), + entry.token_nonce, + entry.amount.clone(), + ), + attributes: self.get_attributes_ex( + &entry.token_identifier, + entry.token_nonce, + attr_ex_activation, + ), + }); + sum_amount += &entry.amount; + } + + if tokens.len() == 1 { + let token_0 = tokens.get(0); + return (token_0.token_amount.amount.clone(), token_0.attributes); + } + + let attrs = LockedAssetTokenAttributesEx { + unlock_schedule: self.aggregated_unlock_schedule(&tokens), + is_merged: true, + }; + + (sum_amount, attrs) + } + + fn calculate_new_unlock_milestones( + &self, + unlock_epoch_amount_merged: &ArrayVec< + EpochAmountPair, + DOUBLE_MAX_MILESTONES_IN_SCHEDULE, + >, + amount_total: &BigUint, + ) -> ManagedVec { + let mut unlock_milestones_merged = + ArrayVec::::new(); + + for el in unlock_epoch_amount_merged.iter() { + let unlock_percent = &(&el.amount * PRECISION_EX_INCREASE * ONE_MILLION) / amount_total; + + // Accumulate even the percents of 0 + unlock_milestones_merged.push(UnlockMilestoneEx { + unlock_epoch: el.epoch, + unlock_percent: unlock_percent.to_u64().unwrap(), + }) + } + + self.distribute_leftover(&mut unlock_milestones_merged); + self.get_non_zero_percent_milestones_as_vec(&unlock_milestones_merged) + } + + fn aggregated_unlock_schedule( + &self, + tokens: &ManagedVec>, + ) -> UnlockScheduleEx { + let mut array = + ArrayVec::, DOUBLE_MAX_MILESTONES_IN_SCHEDULE>::new(); + + let mut sum = BigUint::zero(); + for locked_token in tokens.iter() { + for milestone in locked_token + .attributes + .unlock_schedule + .unlock_milestones + .iter() + { + require!( + array.len() < DOUBLE_MAX_MILESTONES_IN_SCHEDULE, + "too many unlock milestones" + ); + array.push(EpochAmountPair { + epoch: milestone.unlock_epoch, + amount: self.rule_of_three( + &BigUint::from(milestone.unlock_percent), + &BigUint::from(PERCENTAGE_TOTAL_EX), + &locked_token.token_amount.amount, + ), + }); + } + sum += &locked_token.token_amount.amount; + } + array.sort_unstable_by(|a, b| a.epoch.cmp(&b.epoch)); + + let default = EpochAmountPair { + epoch: 0u64, + amount: BigUint::zero(), + }; + let mut unlock_epoch_amount_merged = + ArrayVec::, DOUBLE_MAX_MILESTONES_IN_SCHEDULE>::new(); + for elem in array.iter() { + let last = unlock_epoch_amount_merged.last().unwrap_or(&default); + + if elem.epoch == last.epoch || elem.epoch == last.epoch + 1 { + let new_elem = EpochAmountPair { + epoch: elem.epoch, + amount: &last.amount + &elem.amount, + }; + unlock_epoch_amount_merged.pop(); + unlock_epoch_amount_merged.push(new_elem); + } else { + unlock_epoch_amount_merged.push(elem.clone()); + } + } + require!(sum != 0u64, "Sum cannot be zero"); + require!( + unlock_epoch_amount_merged.len() < MAX_MILESTONES_IN_SCHEDULE, + "Too many milestones" + ); + require!(!unlock_epoch_amount_merged.is_empty(), "Empty milestones"); + + let new_unlock_milestones = + self.calculate_new_unlock_milestones(&unlock_epoch_amount_merged, &sum); + + UnlockScheduleEx { + unlock_milestones: new_unlock_milestones, + } + } +} diff --git a/legacy-contracts/factory-legacy/src/migration.rs b/legacy-contracts/factory-legacy/src/migration.rs new file mode 100644 index 000000000..393f82a59 --- /dev/null +++ b/legacy-contracts/factory-legacy/src/migration.rs @@ -0,0 +1,61 @@ +multiversx_sc::imports!(); + +use common_structs::UnlockEpochAmountPairs; + +mod energy_factory_proxy { + use common_structs::UnlockEpochAmountPairs; + + multiversx_sc::imports!(); + + #[multiversx_sc::proxy] + pub trait EnergyFactoryProxy { + #[endpoint(updateEnergyAfterOldTokenUnlock)] + fn update_energy_after_old_token_unlock( + &self, + original_caller: ManagedAddress, + initial_epoch_amount_pairs: UnlockEpochAmountPairs, + final_epoch_amount_pairs: UnlockEpochAmountPairs, + ); + } +} + +#[multiversx_sc::module] +pub trait LockedTokenMigrationModule: + crate::locked_asset::LockedAssetModule + crate::attr_ex_helper::AttrExHelper +{ + #[only_owner] + #[endpoint(setNewFactoryAddress)] + fn set_new_factory_address(&self, sc_address: ManagedAddress) { + require!( + !sc_address.is_zero() && self.blockchain().is_smart_contract(&sc_address), + "Invalid SC address" + ); + self.new_factory_address().set(&sc_address); + } + + fn update_energy_after_unlock( + &self, + caller: ManagedAddress, + initial_epoch_amount_pairs: UnlockEpochAmountPairs, + final_epoch_amount_pairs: UnlockEpochAmountPairs, + ) { + let new_factory_address = self.new_factory_address().get(); + let _: IgnoreValue = self + .new_factory_proxy_builder(new_factory_address) + .update_energy_after_old_token_unlock( + caller, + initial_epoch_amount_pairs, + final_epoch_amount_pairs, + ) + .execute_on_dest_context(); + } + + #[proxy] + fn new_factory_proxy_builder( + &self, + sc_address: ManagedAddress, + ) -> energy_factory_proxy::Proxy; + + #[storage_mapper("newFactoryAddress")] + fn new_factory_address(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/factory-legacy/testnet.toml b/legacy-contracts/factory-legacy/testnet.toml new file mode 100644 index 000000000..e69de29bb diff --git a/legacy-contracts/factory-legacy/wasm/Cargo.lock b/legacy-contracts/factory-legacy/wasm/Cargo.lock new file mode 100644 index 000000000..50cc43b0b --- /dev/null +++ b/legacy-contracts/factory-legacy/wasm/Cargo.lock @@ -0,0 +1,255 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "common_errors" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "common_structs" +version = "0.0.0" +dependencies = [ + "fixed-supply-token", + "math", + "mergeable", + "multiversx-sc", + "unwrappable", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "factory-legacy" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "multiversx-sc", + "multiversx-sc-modules", + "token_merge_helper", +] + +[[package]] +name = "factory-legacy-wasm" +version = "0.0.0" +dependencies = [ + "factory-legacy", + "multiversx-sc-wasm-adapter", +] + +[[package]] +name = "fixed-supply-token" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "math" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "mergeable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-modules" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "token_merge_helper" +version = "0.0.0" +dependencies = [ + "common_errors", + "multiversx-sc", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "unwrappable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] diff --git a/legacy-contracts/factory-legacy/wasm/Cargo.toml b/legacy-contracts/factory-legacy/wasm/Cargo.toml new file mode 100644 index 000000000..bd05eac77 --- /dev/null +++ b/legacy-contracts/factory-legacy/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "factory-legacy-wasm" +version = "0.0.0" +edition = "2018" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.factory-legacy] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "=0.50.5" + +[workspace] +members = ["."] diff --git a/legacy-contracts/factory-legacy/wasm/src/lib.rs b/legacy-contracts/factory-legacy/wasm/src/lib.rs new file mode 100644 index 000000000..1ddbeb62c --- /dev/null +++ b/legacy-contracts/factory-legacy/wasm/src/lib.rs @@ -0,0 +1,45 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 21 +// Async Callback (empty): 1 +// Total number of exported functions: 23 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + factory_legacy + ( + init => init + whitelist => whitelist + removeWhitelist => remove_whitelist + createAndForwardCustomPeriod => create_and_forward_custom_period + createAndForward => create_and_forward + unlockAssets => unlock_assets + setTransferRoleForAddress => set_transfer_role_for_address + unsetTransferRoleForAddress => unset_transfer_role_for_address + setBurnRoleForAddress => set_burn_role_for_address + getLastErrorMessage => last_error_message + getInitEpoch => init_epoch + getWhitelistedContracts => get_whitelisted_contracts + getDefaultUnlockPeriod => default_unlock_period + getLockedAssetTokenId => locked_asset_token_id + getAssetTokenId => asset_token_id + getUnlockScheduleForSFTNonce => get_unlock_schedule_for_sft_nonce + getCacheSize => get_cache_size + getExtendedAttributesActivationNonce => extended_attributes_activation_nonce + setNewFactoryAddress => set_new_factory_address + pause => pause_endpoint + unpause => unpause_endpoint + isPaused => paused_status + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/legacy-contracts/farm-v-13/wasm/src/lib.rs b/legacy-contracts/farm-v-13/wasm/src/lib.rs index 850923617..ad5759863 100644 --- a/legacy-contracts/farm-v-13/wasm/src/lib.rs +++ b/legacy-contracts/farm-v-13/wasm/src/lib.rs @@ -6,9 +6,9 @@ // Init: 1 // Upgrade: 1 -// Endpoints: 3 +// Endpoints: 4 // Async Callback (empty): 1 -// Total number of exported functions: 6 +// Total number of exported functions: 7 #![no_std] @@ -23,6 +23,7 @@ multiversx_sc_wasm_adapter::endpoints! { exitFarm => exit_farm calculateRewardsForGivenPosition => calculate_rewards_for_given_position end_produce_rewards => end_produce_rewards + getFarmingTokenId => farming_token_id ) } diff --git a/legacy-contracts/proxy-dex-legacy/Cargo.toml b/legacy-contracts/proxy-dex-legacy/Cargo.toml index cb6801e13..d91ce9636 100644 --- a/legacy-contracts/proxy-dex-legacy/Cargo.toml +++ b/legacy-contracts/proxy-dex-legacy/Cargo.toml @@ -20,5 +20,5 @@ path = "../../common/common_structs" [dependencies.token_merge_helper] path = "../../common/modules/token_merge_helper" -[dependencies.factory] -path = "../../locked-asset/factory" +[dependencies.factory-legacy] +path = "../factory-legacy" diff --git a/legacy-contracts/proxy-dex-legacy/src/energy_update.rs b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs index 06921dd35..e1bb7725a 100644 --- a/legacy-contracts/proxy-dex-legacy/src/energy_update.rs +++ b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs @@ -2,7 +2,7 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use common_structs::LockedAssetTokenAttributesEx; -use factory::attr_ex_helper; +use factory_legacy::attr_ex_helper; use crate::{energy::Energy, proxy_common}; @@ -55,8 +55,9 @@ pub trait EnergyUpdateModule: let mut energy = self.get_energy_entry(user); let current_epoch = self.blockchain().get_block_epoch(); + let extended_attributes_activation_nonce = self.get_extended_attributes_activation_nonce(); let attributes: LockedAssetTokenAttributesEx = - self.get_attributes_ex(token_id, token_nonce); + self.get_attributes_ex(token_id, token_nonce, extended_attributes_activation_nonce); let amounts_per_epoch = attributes.get_unlock_amounts_per_epoch(token_amount); for epoch_amount_pair in &amounts_per_epoch.pairs { energy.update_after_unlock_any( diff --git a/legacy-contracts/proxy-dex-legacy/src/lib.rs b/legacy-contracts/proxy-dex-legacy/src/lib.rs index 32305f10f..e62a10190 100644 --- a/legacy-contracts/proxy-dex-legacy/src/lib.rs +++ b/legacy-contracts/proxy-dex-legacy/src/lib.rs @@ -12,7 +12,7 @@ pub mod proxy_farm; mod proxy_pair; pub mod transfer_role; -use factory::attr_ex_helper; +use factory_legacy::attr_ex_helper; #[multiversx_sc::contract] pub trait ProxyDexImpl: diff --git a/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs b/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs index 838954dd8..871e42259 100644 --- a/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs +++ b/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs @@ -3,7 +3,7 @@ multiversx_sc::derive_imports!(); use common_structs::RawResultWrapper; use common_structs::RawResultsType; -use factory::attr_ex_helper; +use factory_legacy::attr_ex_helper; use super::events; use super::proxy_common; diff --git a/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs b/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs index bd39605e6..d875c5486 100644 --- a/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs +++ b/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs @@ -5,7 +5,7 @@ multiversx_sc::derive_imports!(); use common_structs::Nonce; use common_structs::{RawResultWrapper, RawResultsType}; -use factory::attr_ex_helper; +use factory_legacy::attr_ex_helper; use crate::energy_update; use crate::proxy_common::WrappedFarmTokenAttributes; diff --git a/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs b/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs index d0bc68b4a..c8ec2607c 100644 --- a/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs +++ b/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs @@ -6,7 +6,7 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use common_structs::{RawResultWrapper, RawResultsType}; -use factory::attr_ex_helper; +use factory_legacy::attr_ex_helper; use crate::energy_update; use crate::proxy_common::WrappedLpTokenAttributes; diff --git a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock index a3143553e..df92fe170 100644 --- a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock +++ b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock @@ -20,12 +20,6 @@ version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" -[[package]] -name = "cfg-if" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4785bdd1c96b2a846b2bd7cc02e86b6b3dbf14e7e53446c4f54c92a361040822" - [[package]] name = "common_errors" version = "0.0.0" @@ -44,12 +38,6 @@ dependencies = [ "unwrappable", ] -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - [[package]] name = "endian-type" version = "0.1.2" @@ -57,35 +45,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" [[package]] -name = "energy-factory" +name = "factory-legacy" version = "0.0.0" dependencies = [ - "common_structs", - "legacy_token_decode_module", - "math", - "mergeable", - "multiversx-sc", - "multiversx-sc-modules", - "sc_whitelist_module", - "simple-lock", - "unwrappable", - "utils", -] - -[[package]] -name = "factory" -version = "0.0.0" -dependencies = [ - "arrayvec", "common_errors", "common_structs", - "energy-factory", - "itertools", "multiversx-sc", "multiversx-sc-modules", "token_merge_helper", - "token_send", - "wee_alloc", ] [[package]] @@ -107,30 +74,6 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" -[[package]] -name = "itertools" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" -dependencies = [ - "either", -] - -[[package]] -name = "legacy_token_decode_module" -version = "0.0.0" -dependencies = [ - "common_structs", - "multiversx-sc", - "utils", -] - -[[package]] -name = "libc" -version = "0.2.118" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06e509672465a0504304aa87f9f176f2b2b716ed8fb105ebe5c02dc6dce96a94" - [[package]] name = "math" version = "0.0.0" @@ -138,12 +81,6 @@ dependencies = [ "multiversx-sc", ] -[[package]] -name = "memory_units" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8452105ba047068f40ff7093dd1d9da90898e63dd61736462e9cdda6a90ad3c3" - [[package]] name = "mergeable" version = "0.0.0" @@ -251,7 +188,7 @@ name = "proxy-dex-legacy" version = "0.0.0" dependencies = [ "common_structs", - "factory", + "factory-legacy", "multiversx-sc", "token_merge_helper", ] @@ -283,23 +220,6 @@ dependencies = [ "nibble_vec", ] -[[package]] -name = "sc_whitelist_module" -version = "0.0.0" -dependencies = [ - "common_errors", - "multiversx-sc", -] - -[[package]] -name = "simple-lock" -version = "0.0.0" -dependencies = [ - "common_structs", - "multiversx-sc", - "multiversx-sc-modules", -] - [[package]] name = "smallvec" version = "1.13.2" @@ -325,15 +245,6 @@ dependencies = [ "multiversx-sc", ] -[[package]] -name = "token_send" -version = "0.0.0" -dependencies = [ - "common_errors", - "common_structs", - "multiversx-sc", -] - [[package]] name = "unicode-ident" version = "1.0.12" @@ -352,47 +263,3 @@ version = "0.0.0" dependencies = [ "multiversx-sc", ] - -[[package]] -name = "utils" -version = "0.0.0" -dependencies = [ - "common_structs", - "fixed-supply-token", - "mergeable", - "multiversx-sc", -] - -[[package]] -name = "wee_alloc" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbb3b5a6b2bb17cb6ad44a2e68a43e8d2722c997da10e928665c72ec6c0a0b8e" -dependencies = [ - "cfg-if", - "libc", - "memory_units", - "winapi", -] - -[[package]] -name = "winapi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" -dependencies = [ - "winapi-i686-pc-windows-gnu", - "winapi-x86_64-pc-windows-gnu", -] - -[[package]] -name = "winapi-i686-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" - -[[package]] -name = "winapi-x86_64-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" From 4e5e21cde3601d0ba1a0792d35920952b9334bf1 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 17 Jul 2024 12:18:47 +0300 Subject: [PATCH 078/103] remove setAllowExternalClaim --- common/modules/farm/config/src/config.rs | 11 ++++++----- dex/farm-with-locked-rewards/wasm/src/lib.rs | 5 ++--- dex/farm/wasm/src/lib.rs | 5 ++--- energy-integration/fees-collector/src/config.rs | 13 +++++++------ energy-integration/fees-collector/wasm/src/lib.rs | 5 ++--- .../tests/staking_farm_with_lp.rs | 6 ++++-- .../farm-staking/tests/farm_staking_setup/mod.rs | 3 ++- farm-staking/farm-staking/wasm/src/lib.rs | 5 ++--- 8 files changed, 27 insertions(+), 26 deletions(-) diff --git a/common/modules/farm/config/src/config.rs b/common/modules/farm/config/src/config.rs index 1f26eed6a..46564e5c0 100644 --- a/common/modules/farm/config/src/config.rs +++ b/common/modules/farm/config/src/config.rs @@ -11,11 +11,12 @@ pub const DEFAULT_FARM_POSITION_MIGRATION_NONCE: u64 = 1; #[multiversx_sc::module] pub trait ConfigModule: pausable::PausableModule + permissions_module::PermissionsModule { - #[endpoint(setAllowExternalClaimBoostedRewards)] - fn set_allow_external_claim(&self, allow_external_claim: bool) { - let caller = self.blockchain().get_caller(); - self.allow_external_claim(&caller).set(allow_external_claim); - } + // Disabled for this version of the exchange + // #[endpoint(setAllowExternalClaimBoostedRewards)] + // fn set_allow_external_claim(&self, allow_external_claim: bool) { + // let caller = self.blockchain().get_caller(); + // self.allow_external_claim(&caller).set(allow_external_claim); + // } #[inline] fn is_active(&self) -> bool { diff --git a/dex/farm-with-locked-rewards/wasm/src/lib.rs b/dex/farm-with-locked-rewards/wasm/src/lib.rs index 9efe33713..e8aa3099f 100644 --- a/dex/farm-with-locked-rewards/wasm/src/lib.rs +++ b/dex/farm-with-locked-rewards/wasm/src/lib.rs @@ -6,9 +6,9 @@ // Init: 1 // Upgrade: 1 -// Endpoints: 67 +// Endpoints: 66 // Async Callback: 1 -// Total number of exported functions: 70 +// Total number of exported functions: 69 #![no_std] @@ -32,7 +32,6 @@ multiversx_sc_wasm_adapter::endpoints! { calculateRewardsForGivenPosition => calculate_rewards_for_given_position getRewardPerShare => reward_per_share getRewardReserve => reward_reserve - setAllowExternalClaimBoostedRewards => set_allow_external_claim getFarmingTokenId => farming_token_id getRewardTokenId => reward_token_id getPerBlockRewardAmount => per_block_reward_amount diff --git a/dex/farm/wasm/src/lib.rs b/dex/farm/wasm/src/lib.rs index a4b92d26e..525d76239 100644 --- a/dex/farm/wasm/src/lib.rs +++ b/dex/farm/wasm/src/lib.rs @@ -6,9 +6,9 @@ // Init: 1 // Upgrade: 1 -// Endpoints: 64 +// Endpoints: 63 // Async Callback: 1 -// Total number of exported functions: 67 +// Total number of exported functions: 66 #![no_std] @@ -33,7 +33,6 @@ multiversx_sc_wasm_adapter::endpoints! { calculateRewardsForGivenPosition => calculate_rewards_for_given_position getRewardPerShare => reward_per_share getRewardReserve => reward_reserve - setAllowExternalClaimBoostedRewards => set_allow_external_claim getFarmingTokenId => farming_token_id getRewardTokenId => reward_token_id getPerBlockRewardAmount => per_block_reward_amount diff --git a/energy-integration/fees-collector/src/config.rs b/energy-integration/fees-collector/src/config.rs index a21dc6d6b..e65282d17 100644 --- a/energy-integration/fees-collector/src/config.rs +++ b/energy-integration/fees-collector/src/config.rs @@ -60,12 +60,13 @@ pub trait ConfigModule { self.all_tokens().set(&all_tokens_vec); } - #[endpoint(setAllowExternalClaimRewards)] - fn set_allow_external_claim_rewards(&self, allow_external_claim_rewards: bool) { - let caller = self.blockchain().get_caller(); - self.allow_external_claim_rewards(&caller) - .set(allow_external_claim_rewards); - } + // Disabled for this version of the exchange + // #[endpoint(setAllowExternalClaimRewards)] + // fn set_allow_external_claim_rewards(&self, allow_external_claim_rewards: bool) { + // let caller = self.blockchain().get_caller(); + // self.allow_external_claim_rewards(&caller) + // .set(allow_external_claim_rewards); + // } #[view(getLockedTokenId)] #[storage_mapper("lockedTokenId")] diff --git a/energy-integration/fees-collector/wasm/src/lib.rs b/energy-integration/fees-collector/wasm/src/lib.rs index 283f21a67..77034bd4a 100644 --- a/energy-integration/fees-collector/wasm/src/lib.rs +++ b/energy-integration/fees-collector/wasm/src/lib.rs @@ -6,9 +6,9 @@ // Init: 1 // Upgrade: 1 -// Endpoints: 38 +// Endpoints: 37 // Async Callback (empty): 1 -// Total number of exported functions: 41 +// Total number of exported functions: 40 #![no_std] @@ -26,7 +26,6 @@ multiversx_sc_wasm_adapter::endpoints! { removeKnownContracts => remove_known_contracts addKnownTokens => add_known_tokens removeKnownTokens => remove_known_tokens - setAllowExternalClaimRewards => set_allow_external_claim_rewards getLockedTokenId => locked_token_id getAllTokens => get_all_tokens getAllKnownContracts => known_contracts diff --git a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs index 1321443ee..50b62cb93 100644 --- a/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs +++ b/farm-staking/farm-staking-proxy/tests/staking_farm_with_lp.rs @@ -773,7 +773,8 @@ fn claim_for_others_positive_test() { &setup.lp_farm_wrapper, &rust_biguint!(0), |sc| { - sc.set_allow_external_claim(true); + sc.allow_external_claim(&managed_address!(&user_address)) + .set(true); }, ) .assert_ok(); @@ -785,7 +786,8 @@ fn claim_for_others_positive_test() { &setup.staking_farm_wrapper, &rust_biguint!(0), |sc| { - sc.set_allow_external_claim(true); + sc.allow_external_claim(&managed_address!(&user_address)) + .set(true); }, ) .assert_ok(); diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index 0d0cd74f4..90513e2d6 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -569,7 +569,8 @@ where pub fn allow_external_claim_rewards(&mut self, user: &Address, allow_claim: bool) { self.b_mock .execute_tx(user, &self.farm_wrapper, &rust_biguint!(0), |sc| { - sc.set_allow_external_claim(allow_claim); + sc.allow_external_claim(&managed_address!(user)) + .set(allow_claim); }) .assert_ok(); } diff --git a/farm-staking/farm-staking/wasm/src/lib.rs b/farm-staking/farm-staking/wasm/src/lib.rs index a5dfd5522..9489b1d7e 100644 --- a/farm-staking/farm-staking/wasm/src/lib.rs +++ b/farm-staking/farm-staking/wasm/src/lib.rs @@ -6,9 +6,9 @@ // Init: 1 // Upgrade: 1 -// Endpoints: 70 +// Endpoints: 69 // Async Callback: 1 -// Total number of exported functions: 73 +// Total number of exported functions: 72 #![no_std] @@ -36,7 +36,6 @@ multiversx_sc_wasm_adapter::endpoints! { getMinUnbondEpochs => min_unbond_epochs getRewardPerShare => reward_per_share getRewardReserve => reward_reserve - setAllowExternalClaimBoostedRewards => set_allow_external_claim getFarmingTokenId => farming_token_id getRewardTokenId => reward_token_id getPerBlockRewardAmount => per_block_reward_amount From b7fedabb4eeb69ef72d0c27508a1255316ad1971 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 31 Jul 2024 00:19:01 +0300 Subject: [PATCH 079/103] legacy contracts only with signatures --- Cargo.lock | 99 +- Cargo.toml | 18 +- .../farm-staking-proxy-v-13/meta/src/main.rs | 3 - .../.gitignore | 0 .../Cargo.toml | 6 +- .../meta/Cargo.toml | 4 +- .../farm-staking-proxy-v13/meta/src/main.rs | 3 + .../multiversx.json | 0 .../src/dual_yield_token.rs | 0 .../src/external_contracts_interactions.rs | 2 +- .../src/lib.rs | 0 .../src/lp_farm_token.rs | 0 .../src/result_types.rs | 0 .../tests/constants/mod.rs | 0 .../tests/staking_farm_with_lp.rs | 0 .../mod.rs | 0 .../mod.rs | 0 .../mod.rs | 0 .../wasm/Cargo.lock | 10 +- .../wasm/Cargo.toml | 4 +- .../wasm/src/lib.rs | 2 +- legacy-contracts/farm-v-13/meta/src/main.rs | 3 - legacy-contracts/farm-v-13/src/lib.rs | 62 - legacy-contracts/farm-v-13/wasm/src/lib.rs | 30 - .../{farm-v-13 => farm-v12}/Cargo.lock | 0 .../{farm-v-13 => farm-v12}/Cargo.toml | 2 +- .../{farm-v-13 => farm-v12}/meta/Cargo.toml | 4 +- legacy-contracts/farm-v12/meta/src/main.rs | 3 + .../{farm-v-13 => farm-v12}/multiversx.json | 0 legacy-contracts/farm-v12/src/lib.rs | 211 ++ .../{farm-v-13 => farm-v12}/wasm/Cargo.lock | 6 +- .../{farm-v-13 => farm-v12}/wasm/Cargo.toml | 4 +- legacy-contracts/farm-v12/wasm/src/lib.rs | 60 + .../farm-v13-custom-rewards/Cargo.lock | 2593 +++++++++++++++++ .../farm-v13-custom-rewards/Cargo.toml | 18 + .../farm-v13-custom-rewards/meta/Cargo.toml | 12 + .../farm-v13-custom-rewards/meta/src/main.rs | 3 + .../farm-v13-custom-rewards/multiversx.json | 3 + .../farm-v13-custom-rewards/src/lib.rs | 254 ++ .../farm-v13-custom-rewards/wasm/Cargo.lock | 188 ++ .../farm-v13-custom-rewards/wasm/Cargo.toml | 34 + .../farm-v13-custom-rewards/wasm/src/lib.rs | 62 + .../farm-v13-locked-rewards/Cargo.lock | 2593 +++++++++++++++++ .../farm-v13-locked-rewards/Cargo.toml | 18 + .../farm-v13-locked-rewards/meta/Cargo.toml | 12 + .../farm-v13-locked-rewards/meta/src/main.rs | 3 + .../farm-v13-locked-rewards/multiversx.json | 3 + .../farm-v13-locked-rewards/src/lib.rs | 275 ++ .../farm-v13-locked-rewards/wasm/Cargo.lock | 188 ++ .../farm-v13-locked-rewards/wasm/Cargo.toml | 34 + .../farm-v13-locked-rewards/wasm/src/lib.rs | 62 + legacy-contracts/farm-v13/Cargo.lock | 2593 +++++++++++++++++ legacy-contracts/farm-v13/Cargo.toml | 18 + legacy-contracts/farm-v13/meta/Cargo.toml | 12 + legacy-contracts/farm-v13/meta/src/main.rs | 3 + legacy-contracts/farm-v13/multiversx.json | 3 + legacy-contracts/farm-v13/src/lib.rs | 306 ++ legacy-contracts/farm-v13/wasm/Cargo.lock | 188 ++ legacy-contracts/farm-v13/wasm/Cargo.toml | 34 + legacy-contracts/farm-v13/wasm/src/lib.rs | 65 + .../price-discovery-v1/Cargo.lock | 2593 +++++++++++++++++ .../price-discovery-v1/Cargo.toml | 18 + .../price-discovery-v1/meta/Cargo.toml | 12 + .../price-discovery-v1/meta/src/main.rs | 3 + .../price-discovery-v1/multiversx.json | 3 + .../price-discovery-v1/src/lib.rs | 130 + .../price-discovery-v1/wasm/Cargo.lock | 188 ++ .../price-discovery-v1/wasm/Cargo.toml | 34 + .../price-discovery-v1/wasm/src/lib.rs | 47 + .../price-discovery-v2/Cargo.lock | 2593 +++++++++++++++++ .../price-discovery-v2/Cargo.toml | 18 + .../price-discovery-v2/meta/Cargo.toml | 12 + .../price-discovery-v2/meta/src/main.rs | 3 + .../price-discovery-v2/multiversx.json | 3 + .../price-discovery-v2/src/lib.rs | 130 + .../price-discovery-v2/wasm/Cargo.lock | 188 ++ .../price-discovery-v2/wasm/Cargo.toml | 34 + .../price-discovery-v2/wasm/src/lib.rs | 47 + 78 files changed, 16038 insertions(+), 131 deletions(-) delete mode 100644 legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/.gitignore (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/Cargo.toml (92%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/meta/Cargo.toml (72%) create mode 100644 legacy-contracts/farm-staking-proxy-v13/meta/src/main.rs rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/multiversx.json (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/src/dual_yield_token.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/src/external_contracts_interactions.rs (99%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/src/lib.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/src/lp_farm_token.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/src/result_types.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/tests/constants/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/tests/staking_farm_with_lp.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/tests/staking_farm_with_lp_external_contracts/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/tests/staking_farm_with_lp_staking_contract_setup/mod.rs (100%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/wasm/Cargo.lock (98%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/wasm/Cargo.toml (87%) rename legacy-contracts/{farm-staking-proxy-v-13 => farm-staking-proxy-v13}/wasm/src/lib.rs (97%) delete mode 100644 legacy-contracts/farm-v-13/meta/src/main.rs delete mode 100644 legacy-contracts/farm-v-13/src/lib.rs delete mode 100644 legacy-contracts/farm-v-13/wasm/src/lib.rs rename legacy-contracts/{farm-v-13 => farm-v12}/Cargo.lock (100%) rename legacy-contracts/{farm-v-13 => farm-v12}/Cargo.toml (93%) rename legacy-contracts/{farm-v-13 => farm-v12}/meta/Cargo.toml (75%) create mode 100644 legacy-contracts/farm-v12/meta/src/main.rs rename legacy-contracts/{farm-v-13 => farm-v12}/multiversx.json (100%) create mode 100644 legacy-contracts/farm-v12/src/lib.rs rename legacy-contracts/{farm-v-13 => farm-v12}/wasm/Cargo.lock (98%) rename legacy-contracts/{farm-v-13 => farm-v12}/wasm/Cargo.toml (91%) create mode 100644 legacy-contracts/farm-v12/wasm/src/lib.rs create mode 100644 legacy-contracts/farm-v13-custom-rewards/Cargo.lock create mode 100644 legacy-contracts/farm-v13-custom-rewards/Cargo.toml create mode 100644 legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml create mode 100644 legacy-contracts/farm-v13-custom-rewards/meta/src/main.rs create mode 100644 legacy-contracts/farm-v13-custom-rewards/multiversx.json create mode 100644 legacy-contracts/farm-v13-custom-rewards/src/lib.rs create mode 100644 legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock create mode 100644 legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml create mode 100644 legacy-contracts/farm-v13-custom-rewards/wasm/src/lib.rs create mode 100644 legacy-contracts/farm-v13-locked-rewards/Cargo.lock create mode 100644 legacy-contracts/farm-v13-locked-rewards/Cargo.toml create mode 100644 legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml create mode 100644 legacy-contracts/farm-v13-locked-rewards/meta/src/main.rs create mode 100644 legacy-contracts/farm-v13-locked-rewards/multiversx.json create mode 100644 legacy-contracts/farm-v13-locked-rewards/src/lib.rs create mode 100644 legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock create mode 100644 legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml create mode 100644 legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs create mode 100644 legacy-contracts/farm-v13/Cargo.lock create mode 100644 legacy-contracts/farm-v13/Cargo.toml create mode 100644 legacy-contracts/farm-v13/meta/Cargo.toml create mode 100644 legacy-contracts/farm-v13/meta/src/main.rs create mode 100644 legacy-contracts/farm-v13/multiversx.json create mode 100644 legacy-contracts/farm-v13/src/lib.rs create mode 100644 legacy-contracts/farm-v13/wasm/Cargo.lock create mode 100644 legacy-contracts/farm-v13/wasm/Cargo.toml create mode 100644 legacy-contracts/farm-v13/wasm/src/lib.rs create mode 100644 legacy-contracts/price-discovery-v1/Cargo.lock create mode 100644 legacy-contracts/price-discovery-v1/Cargo.toml create mode 100644 legacy-contracts/price-discovery-v1/meta/Cargo.toml create mode 100644 legacy-contracts/price-discovery-v1/meta/src/main.rs create mode 100644 legacy-contracts/price-discovery-v1/multiversx.json create mode 100644 legacy-contracts/price-discovery-v1/src/lib.rs create mode 100644 legacy-contracts/price-discovery-v1/wasm/Cargo.lock create mode 100644 legacy-contracts/price-discovery-v1/wasm/Cargo.toml create mode 100644 legacy-contracts/price-discovery-v1/wasm/src/lib.rs create mode 100644 legacy-contracts/price-discovery-v2/Cargo.lock create mode 100644 legacy-contracts/price-discovery-v2/Cargo.toml create mode 100644 legacy-contracts/price-discovery-v2/meta/Cargo.toml create mode 100644 legacy-contracts/price-discovery-v2/meta/src/main.rs create mode 100644 legacy-contracts/price-discovery-v2/multiversx.json create mode 100644 legacy-contracts/price-discovery-v2/src/lib.rs create mode 100644 legacy-contracts/price-discovery-v2/wasm/Cargo.lock create mode 100644 legacy-contracts/price-discovery-v2/wasm/Cargo.toml create mode 100644 legacy-contracts/price-discovery-v2/wasm/src/lib.rs diff --git a/Cargo.lock b/Cargo.lock index 04e8e5188..43e7acf34 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -913,14 +913,14 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-v-13" +name = "farm-staking-proxy-v13" version = "0.0.0" dependencies = [ "common_structs", "energy-factory", "energy-query", "farm-staking", - "farm-v-13", + "farm-v13-locked-rewards", "farm_token", "hex", "locking_module", @@ -937,15 +937,15 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-v-13-meta" +name = "farm-staking-proxy-v13-meta" version = "0.0.0" dependencies = [ - "farm-staking-proxy-v-13", + "farm-staking-proxy-v13", "multiversx-sc-meta", ] [[package]] -name = "farm-v-13" +name = "farm-v12" version = "0.0.0" dependencies = [ "multiversx-sc", @@ -954,10 +954,61 @@ dependencies = [ ] [[package]] -name = "farm-v-13-meta" +name = "farm-v12-meta" version = "0.0.0" dependencies = [ - "farm-v-13", + "farm-v12", + "multiversx-sc-meta", +] + +[[package]] +name = "farm-v13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v13-custom-rewards" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v13-custom-rewards-meta" +version = "0.0.0" +dependencies = [ + "farm-v13-custom-rewards", + "multiversx-sc-meta", +] + +[[package]] +name = "farm-v13-locked-rewards" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v13-locked-rewards-meta" +version = "0.0.0" +dependencies = [ + "farm-v13-locked-rewards", + "multiversx-sc-meta", +] + +[[package]] +name = "farm-v13-meta" +version = "0.0.0" +dependencies = [ + "farm-v13", "multiversx-sc-meta", ] @@ -2232,6 +2283,40 @@ dependencies = [ "price-discovery", ] +[[package]] +name = "price-discovery-v1" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "price-discovery-v1-meta" +version = "0.0.0" +dependencies = [ + "multiversx-sc-meta", + "price-discovery-v1", +] + +[[package]] +name = "price-discovery-v2" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "price-discovery-v2-meta" +version = "0.0.0" +dependencies = [ + "multiversx-sc-meta", + "price-discovery-v2", +] + [[package]] name = "proc-macro2" version = "1.0.82" diff --git a/Cargo.toml b/Cargo.toml index 7a6041dc6..6c3af3ab3 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -39,14 +39,24 @@ members = [ "legacy-contracts/simple-lock-legacy", "legacy-contracts/simple-lock-legacy/meta", - "legacy-contracts/farm-staking-proxy-v-13", - "legacy-contracts/farm-staking-proxy-v-13/meta", - "legacy-contracts/farm-v-13", - "legacy-contracts/farm-v-13/meta", + "legacy-contracts/farm-staking-proxy-v13", + "legacy-contracts/farm-staking-proxy-v13/meta", + "legacy-contracts/farm-v12", + "legacy-contracts/farm-v12/meta", + "legacy-contracts/farm-v13", + "legacy-contracts/farm-v13/meta", + "legacy-contracts/farm-v13-locked-rewards", + "legacy-contracts/farm-v13-locked-rewards/meta", + "legacy-contracts/farm-v13-custom-rewards", + "legacy-contracts/farm-v13-custom-rewards/meta", "legacy-contracts/proxy-dex-legacy", "legacy-contracts/proxy-dex-legacy/meta", "legacy-contracts/factory-legacy", "legacy-contracts/factory-legacy/meta", + "legacy-contracts/price-discovery-v1", + "legacy-contracts/price-discovery-v1/meta", + "legacy-contracts/price-discovery-v2", + "legacy-contracts/price-discovery-v2/meta", "locked-asset/", "locked-asset/distribution", diff --git a/legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs b/legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs deleted file mode 100644 index 0c5fc84db..000000000 --- a/legacy-contracts/farm-staking-proxy-v-13/meta/src/main.rs +++ /dev/null @@ -1,3 +0,0 @@ -fn main() { - multiversx_sc_meta::cli_main::(); -} diff --git a/legacy-contracts/farm-staking-proxy-v-13/.gitignore b/legacy-contracts/farm-staking-proxy-v13/.gitignore similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/.gitignore rename to legacy-contracts/farm-staking-proxy-v13/.gitignore diff --git a/legacy-contracts/farm-staking-proxy-v-13/Cargo.toml b/legacy-contracts/farm-staking-proxy-v13/Cargo.toml similarity index 92% rename from legacy-contracts/farm-staking-proxy-v-13/Cargo.toml rename to legacy-contracts/farm-staking-proxy-v13/Cargo.toml index 8fdeaefb2..f530c7e09 100644 --- a/legacy-contracts/farm-staking-proxy-v-13/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v13/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "farm-staking-proxy-v-13" +name = "farm-staking-proxy-v13" version = "0.0.0" authors = ["MultiversX "] edition = "2021" @@ -27,8 +27,8 @@ path = "../../farm-staking/farm-staking" [dependencies.pair] path = "../../dex/pair" -[dependencies.farm-v-13] -path = "../farm-v-13" +[dependencies.farm-v13-locked-rewards] +path = "../farm-v13-locked-rewards" [dev-dependencies.energy-factory] path = "../../locked-asset/energy-factory" diff --git a/legacy-contracts/farm-staking-proxy-v-13/meta/Cargo.toml b/legacy-contracts/farm-staking-proxy-v13/meta/Cargo.toml similarity index 72% rename from legacy-contracts/farm-staking-proxy-v-13/meta/Cargo.toml rename to legacy-contracts/farm-staking-proxy-v13/meta/Cargo.toml index f2075e1a4..bd22d73c1 100644 --- a/legacy-contracts/farm-staking-proxy-v-13/meta/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v13/meta/Cargo.toml @@ -1,11 +1,11 @@ [package] -name = "farm-staking-proxy-v-13-meta" +name = "farm-staking-proxy-v13-meta" version = "0.0.0" edition = "2021" publish = false authors = ["MultiversX "] -[dependencies.farm-staking-proxy-v-13] +[dependencies.farm-staking-proxy-v13] path = ".." [dependencies.multiversx-sc-meta] diff --git a/legacy-contracts/farm-staking-proxy-v13/meta/src/main.rs b/legacy-contracts/farm-staking-proxy-v13/meta/src/main.rs new file mode 100644 index 000000000..d25b3a0c4 --- /dev/null +++ b/legacy-contracts/farm-staking-proxy-v13/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-staking-proxy-v-13/multiversx.json b/legacy-contracts/farm-staking-proxy-v13/multiversx.json similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/multiversx.json rename to legacy-contracts/farm-staking-proxy-v13/multiversx.json diff --git a/legacy-contracts/farm-staking-proxy-v-13/src/dual_yield_token.rs b/legacy-contracts/farm-staking-proxy-v13/src/dual_yield_token.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/src/dual_yield_token.rs rename to legacy-contracts/farm-staking-proxy-v13/src/dual_yield_token.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs b/legacy-contracts/farm-staking-proxy-v13/src/external_contracts_interactions.rs similarity index 99% rename from legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs rename to legacy-contracts/farm-staking-proxy-v13/src/external_contracts_interactions.rs index 9e6d3e49e..69f250578 100644 --- a/legacy-contracts/farm-staking-proxy-v-13/src/external_contracts_interactions.rs +++ b/legacy-contracts/farm-staking-proxy-v13/src/external_contracts_interactions.rs @@ -134,7 +134,7 @@ pub trait ExternalContractsInteractionsModule: fn staking_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_staking::Proxy; #[proxy] - fn lp_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_v_13::Proxy; + fn lp_farm_proxy_obj(&self, sc_address: ManagedAddress) -> farm_v13_locked_rewards::Proxy; #[proxy] fn pair_proxy_obj(&self, sc_address: ManagedAddress) -> pair::Proxy; diff --git a/legacy-contracts/farm-staking-proxy-v-13/src/lib.rs b/legacy-contracts/farm-staking-proxy-v13/src/lib.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/src/lib.rs rename to legacy-contracts/farm-staking-proxy-v13/src/lib.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/src/lp_farm_token.rs b/legacy-contracts/farm-staking-proxy-v13/src/lp_farm_token.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/src/lp_farm_token.rs rename to legacy-contracts/farm-staking-proxy-v13/src/lp_farm_token.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/src/result_types.rs b/legacy-contracts/farm-staking-proxy-v13/src/result_types.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/src/result_types.rs rename to legacy-contracts/farm-staking-proxy-v13/src/result_types.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/tests/constants/mod.rs b/legacy-contracts/farm-staking-proxy-v13/tests/constants/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/tests/constants/mod.rs rename to legacy-contracts/farm-staking-proxy-v13/tests/constants/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp.rs b/legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp.rs rename to legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_external_contracts/mod.rs b/legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp_external_contracts/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_external_contracts/mod.rs rename to legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp_external_contracts/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs b/legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs rename to legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp_staking_contract_interactions/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_setup/mod.rs b/legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp_staking_contract_setup/mod.rs similarity index 100% rename from legacy-contracts/farm-staking-proxy-v-13/tests/staking_farm_with_lp_staking_contract_setup/mod.rs rename to legacy-contracts/farm-staking-proxy-v13/tests/staking_farm_with_lp_staking_contract_setup/mod.rs diff --git a/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.lock b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.lock similarity index 98% rename from legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.lock rename to legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.lock index 1c37aeb5b..0b23c164b 100644 --- a/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.lock +++ b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.lock @@ -193,12 +193,12 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-v-13" +name = "farm-staking-proxy-v13" version = "0.0.0" dependencies = [ "common_structs", "farm-staking", - "farm-v-13", + "farm-v13-locked-rewards", "multiversx-sc", "multiversx-sc-modules", "pair", @@ -206,15 +206,15 @@ dependencies = [ ] [[package]] -name = "farm-staking-proxy-v-13-wasm" +name = "farm-staking-proxy-v13-wasm" version = "0.0.0" dependencies = [ - "farm-staking-proxy-v-13", + "farm-staking-proxy-v13", "multiversx-sc-wasm-adapter", ] [[package]] -name = "farm-v-13" +name = "farm-v13-locked-rewards" version = "0.0.0" dependencies = [ "multiversx-sc", diff --git a/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.toml b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.toml similarity index 87% rename from legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.toml rename to legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.toml index 37ccbf235..8f9b2ad96 100644 --- a/legacy-contracts/farm-staking-proxy-v-13/wasm/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.toml @@ -5,7 +5,7 @@ # ########################################## [package] -name = "farm-staking-proxy-v-13-wasm" +name = "farm-staking-proxy-v13-wasm" version = "0.0.0" edition = "2021" publish = false @@ -24,7 +24,7 @@ overflow-checks = false [profile.dev] panic = "abort" -[dependencies.farm-staking-proxy-v-13] +[dependencies.farm-staking-proxy-v13] path = ".." [dependencies.multiversx-sc-wasm-adapter] diff --git a/legacy-contracts/farm-staking-proxy-v-13/wasm/src/lib.rs b/legacy-contracts/farm-staking-proxy-v13/wasm/src/lib.rs similarity index 97% rename from legacy-contracts/farm-staking-proxy-v-13/wasm/src/lib.rs rename to legacy-contracts/farm-staking-proxy-v13/wasm/src/lib.rs index f926207ed..28c215d78 100644 --- a/legacy-contracts/farm-staking-proxy-v-13/wasm/src/lib.rs +++ b/legacy-contracts/farm-staking-proxy-v13/wasm/src/lib.rs @@ -16,7 +16,7 @@ multiversx_sc_wasm_adapter::allocator!(); multiversx_sc_wasm_adapter::panic_handler!(); multiversx_sc_wasm_adapter::endpoints! { - farm_staking_proxy_v_13 + farm_staking_proxy_v13 ( init => init upgrade => upgrade diff --git a/legacy-contracts/farm-v-13/meta/src/main.rs b/legacy-contracts/farm-v-13/meta/src/main.rs deleted file mode 100644 index 11be3279d..000000000 --- a/legacy-contracts/farm-v-13/meta/src/main.rs +++ /dev/null @@ -1,3 +0,0 @@ -fn main() { - multiversx_sc_meta::cli_main::(); -} diff --git a/legacy-contracts/farm-v-13/src/lib.rs b/legacy-contracts/farm-v-13/src/lib.rs deleted file mode 100644 index 4f1660e1d..000000000 --- a/legacy-contracts/farm-v-13/src/lib.rs +++ /dev/null @@ -1,62 +0,0 @@ -#![no_std] - -use multiversx_sc::derive_imports::*; -use multiversx_sc::imports::*; - -type ExitFarmResultType = - MultiValue2, EsdtTokenPayment>; - -#[derive( - ManagedVecItem, - TopEncode, - TopDecode, - NestedEncode, - NestedDecode, - TypeAbi, - Clone, - PartialEq, - Debug, -)] -pub struct FarmTokenAttributes { - pub reward_per_share: BigUint, - pub original_entering_epoch: u64, - pub entering_epoch: u64, - pub initial_farming_amount: BigUint, - pub compounded_reward: BigUint, - pub current_farm_amount: BigUint, -} - -#[multiversx_sc::contract] -pub trait FarmV13 { - #[init] - fn init(&self) {} - - #[upgrade] - fn upgrade(&self) {} - - #[payable("*")] - #[endpoint(exitFarm)] - fn exit_farm( - &self, - _opt_accept_funds_func: OptionalValue, - ) -> ExitFarmResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); - } - - #[view(calculateRewardsForGivenPosition)] - fn calculate_rewards_for_given_position( - &self, - _amount: BigUint, - _attributes: FarmTokenAttributes, - ) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); - } - - #[only_owner] - #[endpoint] - fn end_produce_rewards(&self) {} - - #[view(getFarmingTokenId)] - #[storage_mapper("farming_token_id")] - fn farming_token_id(&self) -> SingleValueMapper; -} diff --git a/legacy-contracts/farm-v-13/wasm/src/lib.rs b/legacy-contracts/farm-v-13/wasm/src/lib.rs deleted file mode 100644 index ad5759863..000000000 --- a/legacy-contracts/farm-v-13/wasm/src/lib.rs +++ /dev/null @@ -1,30 +0,0 @@ -// Code generated by the multiversx-sc build system. DO NOT EDIT. - -//////////////////////////////////////////////////// -////////////////// AUTO-GENERATED ////////////////// -//////////////////////////////////////////////////// - -// Init: 1 -// Upgrade: 1 -// Endpoints: 4 -// Async Callback (empty): 1 -// Total number of exported functions: 7 - -#![no_std] - -multiversx_sc_wasm_adapter::allocator!(); -multiversx_sc_wasm_adapter::panic_handler!(); - -multiversx_sc_wasm_adapter::endpoints! { - farm_v_13 - ( - init => init - upgrade => upgrade - exitFarm => exit_farm - calculateRewardsForGivenPosition => calculate_rewards_for_given_position - end_produce_rewards => end_produce_rewards - getFarmingTokenId => farming_token_id - ) -} - -multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/legacy-contracts/farm-v-13/Cargo.lock b/legacy-contracts/farm-v12/Cargo.lock similarity index 100% rename from legacy-contracts/farm-v-13/Cargo.lock rename to legacy-contracts/farm-v12/Cargo.lock diff --git a/legacy-contracts/farm-v-13/Cargo.toml b/legacy-contracts/farm-v12/Cargo.toml similarity index 93% rename from legacy-contracts/farm-v-13/Cargo.toml rename to legacy-contracts/farm-v12/Cargo.toml index c5e7940db..3aa922b85 100644 --- a/legacy-contracts/farm-v-13/Cargo.toml +++ b/legacy-contracts/farm-v12/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "farm-v-13" +name = "farm-v12" version = "0.0.0" authors = ["you"] edition = "2021" diff --git a/legacy-contracts/farm-v-13/meta/Cargo.toml b/legacy-contracts/farm-v12/meta/Cargo.toml similarity index 75% rename from legacy-contracts/farm-v-13/meta/Cargo.toml rename to legacy-contracts/farm-v12/meta/Cargo.toml index 7caffff1e..3a195e0ed 100644 --- a/legacy-contracts/farm-v-13/meta/Cargo.toml +++ b/legacy-contracts/farm-v12/meta/Cargo.toml @@ -1,10 +1,10 @@ [package] -name = "farm-v-13-meta" +name = "farm-v12-meta" version = "0.0.0" edition = "2021" publish = false -[dependencies.farm-v-13] +[dependencies.farm-v12] path = ".." [dependencies.multiversx-sc-meta] diff --git a/legacy-contracts/farm-v12/meta/src/main.rs b/legacy-contracts/farm-v12/meta/src/main.rs new file mode 100644 index 000000000..bfef42f9b --- /dev/null +++ b/legacy-contracts/farm-v12/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-v-13/multiversx.json b/legacy-contracts/farm-v12/multiversx.json similarity index 100% rename from legacy-contracts/farm-v-13/multiversx.json rename to legacy-contracts/farm-v12/multiversx.json diff --git a/legacy-contracts/farm-v12/src/lib.rs b/legacy-contracts/farm-v12/src/lib.rs new file mode 100644 index 000000000..2623c773f --- /dev/null +++ b/legacy-contracts/farm-v12/src/lib.rs @@ -0,0 +1,211 @@ +#![no_std] + +use multiversx_sc::derive_imports::*; +use multiversx_sc::imports::*; + +type Nonce = u64; +type ExitFarmResultType = + MultiValue2, EsdtTokenPayment>; + +#[derive(TopEncode, TopDecode, PartialEq, TypeAbi)] +pub enum State { + Inactive, + Active, + Migrate, +} + +#[multiversx_sc::contract] +pub trait FarmV12 { + #[init] + fn init(&self) {} + + #[payable("*")] + #[endpoint(acceptFee)] + fn accept_fee(&self, _token_in: TokenIdentifier, _amount: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(calculateRewardsForGivenPosition)] + fn calculate_rewards_for_given_position( + &self, + _amount: BigUint, + _attributes_raw: ManagedBuffer, + ) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(end_produce_rewards_as_owner)] + fn end_produce_rewards_as_owner(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(exitFarm)] + fn exit_farm( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> ExitFarmResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getBurnedTokenAmount)] + fn burned_tokens(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getCurrentBlockFee)] + fn current_block_fee_storage(&self) -> Option<(Nonce, BigUint)> { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getDivisionSafetyConstant)] + fn division_safety_constant(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmTokenId)] + fn farm_token_id(&self) -> TokenIdentifier { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmTokenSupply)] + fn get_farm_token_supply(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmingTokenId)] + fn farming_token_id(&self) -> TokenIdentifier { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmingTokenReserve)] + fn farming_token_reserve(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLastErrorMessage)] + fn last_error_message(&self) -> ManagedBuffer { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLastRewardBlockNonce)] + fn last_reward_block_nonce(&self) -> Nonce { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLockedAssetFactoryManagedAddress)] + fn locked_asset_factory_address(&self) -> ManagedAddress { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLockedRewardAprMuliplier)] + fn locked_rewards_apr_multiplier(&self) -> u8 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getMinimumFarmingEpoch)] + fn minimum_farming_epoch(&self) -> u8 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getOwner)] + fn owner(&self) -> ManagedAddress { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getPairContractManagedAddress)] + fn pair_contract_address(&self) -> ManagedAddress { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getPenaltyPercent)] + fn penalty_percent(&self) -> u64 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getPerBlockRewardAmount)] + fn per_block_reward_amount(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getRewardPerShare)] + fn reward_per_share(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getRewardReserve)] + fn reward_reserve(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getRewardTokenId)] + fn reward_token_id(&self) -> TokenIdentifier { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getRouterManagedAddress)] + fn router_address(&self) -> ManagedAddress { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getState)] + fn state(&self) -> State { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getTransferExecGasLimit)] + fn transfer_exec_gas_limit(&self) -> u64 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getUndistributedFees)] + fn undistributed_fee_storage(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(pause)] + fn pause(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(resume)] + fn resume(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(setPerBlockRewardAmount)] + fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setTransferRoleFarmToken)] + fn set_transfer_role_farm_token(&self, _opt_address: OptionalValue) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_locked_rewards_apr_multiplier)] + fn set_locked_rewards_apr_multiplier(&self, _muliplier: u8) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_minimum_farming_epochs)] + fn set_minimum_farming_epochs(&self, _epochs: u8) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_penalty_percent)] + fn set_penalty_percent(&self, _percent: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_transfer_exec_gas_limit)] + fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(start_produce_rewards)] + fn start_produce_rewards(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } +} diff --git a/legacy-contracts/farm-v-13/wasm/Cargo.lock b/legacy-contracts/farm-v12/wasm/Cargo.lock similarity index 98% rename from legacy-contracts/farm-v-13/wasm/Cargo.lock rename to legacy-contracts/farm-v12/wasm/Cargo.lock index 3913dc656..aedadbc26 100644 --- a/legacy-contracts/farm-v-13/wasm/Cargo.lock +++ b/legacy-contracts/farm-v12/wasm/Cargo.lock @@ -27,17 +27,17 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" [[package]] -name = "farm-v-13" +name = "farm-v12" version = "0.0.0" dependencies = [ "multiversx-sc", ] [[package]] -name = "farm-v-13-wasm" +name = "farm-v12-wasm" version = "0.0.0" dependencies = [ - "farm-v-13", + "farm-v12", "multiversx-sc-wasm-adapter", ] diff --git a/legacy-contracts/farm-v-13/wasm/Cargo.toml b/legacy-contracts/farm-v12/wasm/Cargo.toml similarity index 91% rename from legacy-contracts/farm-v-13/wasm/Cargo.toml rename to legacy-contracts/farm-v12/wasm/Cargo.toml index d1cba483c..00f6566ac 100644 --- a/legacy-contracts/farm-v-13/wasm/Cargo.toml +++ b/legacy-contracts/farm-v12/wasm/Cargo.toml @@ -5,7 +5,7 @@ # ########################################## [package] -name = "farm-v-13-wasm" +name = "farm-v12-wasm" version = "0.0.0" edition = "2021" publish = false @@ -24,7 +24,7 @@ overflow-checks = false [profile.dev] panic = "abort" -[dependencies.farm-v-13] +[dependencies.farm-v12] path = ".." [dependencies.multiversx-sc-wasm-adapter] diff --git a/legacy-contracts/farm-v12/wasm/src/lib.rs b/legacy-contracts/farm-v12/wasm/src/lib.rs new file mode 100644 index 000000000..90db50ccf --- /dev/null +++ b/legacy-contracts/farm-v12/wasm/src/lib.rs @@ -0,0 +1,60 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 36 +// Async Callback (empty): 1 +// Total number of exported functions: 38 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + farm_v12 + ( + init => init + acceptFee => accept_fee + calculateRewardsForGivenPosition => calculate_rewards_for_given_position + end_produce_rewards_as_owner => end_produce_rewards_as_owner + exitFarm => exit_farm + getBurnedTokenAmount => burned_tokens + getCurrentBlockFee => current_block_fee_storage + getDivisionSafetyConstant => division_safety_constant + getFarmTokenId => farm_token_id + getFarmTokenSupply => get_farm_token_supply + getFarmingTokenId => farming_token_id + getFarmingTokenReserve => farming_token_reserve + getLastErrorMessage => last_error_message + getLastRewardBlockNonce => last_reward_block_nonce + getLockedAssetFactoryManagedAddress => locked_asset_factory_address + getLockedRewardAprMuliplier => locked_rewards_apr_multiplier + getMinimumFarmingEpoch => minimum_farming_epoch + getOwner => owner + getPairContractManagedAddress => pair_contract_address + getPenaltyPercent => penalty_percent + getPerBlockRewardAmount => per_block_reward_amount + getRewardPerShare => reward_per_share + getRewardReserve => reward_reserve + getRewardTokenId => reward_token_id + getRouterManagedAddress => router_address + getState => state + getTransferExecGasLimit => transfer_exec_gas_limit + getUndistributedFees => undistributed_fee_storage + pause => pause + resume => resume + setPerBlockRewardAmount => set_per_block_reward_amount + setTransferRoleFarmToken => set_transfer_role_farm_token + set_locked_rewards_apr_multiplier => set_locked_rewards_apr_multiplier + set_minimum_farming_epochs => set_minimum_farming_epochs + set_penalty_percent => set_penalty_percent + set_transfer_exec_gas_limit => set_transfer_exec_gas_limit + start_produce_rewards => start_produce_rewards + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/legacy-contracts/farm-v13-custom-rewards/Cargo.lock b/legacy-contracts/farm-v13-custom-rewards/Cargo.lock new file mode 100644 index 000000000..07b1eab79 --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/Cargo.lock @@ -0,0 +1,2593 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "Inflector" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" +dependencies = [ + "lazy_static", + "regex", +] + +[[package]] +name = "addr2line" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +dependencies = [ + "memchr", +] + +[[package]] +name = "anstream" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "is_terminal_polyfill", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" + +[[package]] +name = "anstyle-parse" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "anstyle-wincon" +version = "3.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +dependencies = [ + "anstyle", + "windows-sys 0.52.0", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "backtrace" +version = "0.3.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "bech32" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" + +[[package]] +name = "bip39" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" +dependencies = [ + "bitcoin_hashes", + "rand 0.8.5", + "rand_core 0.6.4", + "serde", + "unicode-normalization", +] + +[[package]] +name = "bitcoin_hashes" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "bstr" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" +dependencies = [ + "memchr", + "serde", +] + +[[package]] +name = "bumpalo" +version = "3.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" + +[[package]] +name = "cc" +version = "1.0.104" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "clap" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" +dependencies = [ + "clap_builder", + "clap_derive", +] + +[[package]] +name = "clap_builder" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" +dependencies = [ + "anstream", + "anstyle", + "clap_lex", + "strsim", +] + +[[package]] +name = "clap_derive" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "clap_lex" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" + +[[package]] +name = "colorchoice" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" + +[[package]] +name = "colored" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" +dependencies = [ + "lazy_static", + "windows-sys 0.48.0", +] + +[[package]] +name = "common-path" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" + +[[package]] +name = "convert_case" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "copy_dir" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" +dependencies = [ + "walkdir", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" + +[[package]] +name = "cpufeatures" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "curve25519-dalek" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" +dependencies = [ + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", + "subtle", + "zeroize", +] + +[[package]] +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "crypto-common", + "subtle", +] + +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "ed25519" +version = "1.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" +dependencies = [ + "signature", +] + +[[package]] +name = "ed25519-dalek" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +dependencies = [ + "curve25519-dalek", + "ed25519", + "rand 0.7.3", + "serde", + "sha2 0.9.9", + "zeroize", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "encoding_rs" +version = "0.8.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v-13-meta" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-meta", +] + +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + +[[package]] +name = "flate2" +version = "1.0.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures-channel" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" + +[[package]] +name = "futures-io" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" + +[[package]] +name = "futures-sink" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" + +[[package]] +name = "futures-task" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-util" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" +dependencies = [ + "futures-core", + "futures-io", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", +] + +[[package]] +name = "gimli" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" + +[[package]] +name = "globset" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" +dependencies = [ + "aho-corasick", + "bstr", + "log", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "h2" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" +dependencies = [ + "atomic-waker", + "bytes", + "fnv", + "futures-core", + "futures-sink", + "http", + "indexmap", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +dependencies = [ + "ahash", + "serde", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "http" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "hyper" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +dependencies = [ + "futures-util", + "http", + "hyper", + "hyper-util", + "rustls", + "rustls-pki-types", + "tokio", + "tokio-rustls", + "tower-service", +] + +[[package]] +name = "hyper-tls" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" +dependencies = [ + "bytes", + "http-body-util", + "hyper", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", +] + +[[package]] +name = "hyper-util" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", +] + +[[package]] +name = "idna" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "ignore" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" +dependencies = [ + "crossbeam-deque", + "globset", + "log", + "memchr", + "regex-automata", + "same-file", + "walkdir", + "winapi-util", +] + +[[package]] +name = "indexmap" +version = "2.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +dependencies = [ + "equivalent", + "hashbrown", + "serde", +] + +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "js-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "keccak" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" +dependencies = [ + "cpufeatures", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "libc" +version = "0.2.155" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" + +[[package]] +name = "linux-raw-sys" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" + +[[package]] +name = "lock_api" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" +dependencies = [ + "autocfg", + "scopeguard", +] + +[[package]] +name = "lockfree-object-pool" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" + +[[package]] +name = "log" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "miniz_oxide" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +dependencies = [ + "adler", +] + +[[package]] +name = "mio" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "multiversx-chain-scenario-format" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" +dependencies = [ + "bech32", + "hex", + "num-bigint", + "num-traits", + "serde", + "serde_json", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" +dependencies = [ + "bitflags 2.5.0", + "colored", + "ed25519-dalek", + "hex", + "hex-literal", + "itertools", + "multiversx-chain-vm-executor", + "num-bigint", + "num-traits", + "rand 0.8.5", + "rand_seeder", + "sha2 0.10.8", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm-executor" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags 2.5.0", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "num-bigint", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-meta" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" +dependencies = [ + "clap", + "colored", + "common-path", + "convert_case", + "copy_dir", + "hex", + "lazy_static", + "multiversx-sc", + "pathdiff", + "reqwest", + "ruplacer", + "rustc_version", + "semver", + "serde", + "serde_json", + "toml", + "wasmparser", + "wasmprinter", + "zip", +] + +[[package]] +name = "multiversx-sc-scenario" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" +dependencies = [ + "base64", + "bech32", + "clap", + "colored", + "hex", + "itertools", + "log", + "multiversx-chain-scenario-format", + "multiversx-chain-vm", + "multiversx-chain-vm-executor", + "multiversx-sc", + "multiversx-sc-meta", + "multiversx-sdk", + "num-bigint", + "num-traits", + "pathdiff", + "serde", + "serde_json", + "sha2 0.10.8", + "tokio", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sdk" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" +dependencies = [ + "anyhow", + "base64", + "bech32", + "bip39", + "hex", + "hmac", + "itertools", + "pbkdf2", + "pem", + "rand 0.8.5", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "sha2 0.10.8", + "sha3", + "tokio", + "zeroize", +] + +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-bigint" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + +[[package]] +name = "object" +version = "0.36.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "opaque-debug" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" + +[[package]] +name = "openssl" +version = "0.10.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +dependencies = [ + "bitflags 2.5.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "parking_lot" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall", + "smallvec", + "windows-targets 0.52.5", +] + +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + +[[package]] +name = "pbkdf2" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "pem" +version = "3.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" +dependencies = [ + "base64", + "serde", +] + +[[package]] +name = "percent-encoding" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" + +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkg-config" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.15", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] + +[[package]] +name = "rand_seeder" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "redox_syscall" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +dependencies = [ + "bitflags 2.5.0", +] + +[[package]] +name = "regex" +version = "1.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + +[[package]] +name = "reqwest" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" +dependencies = [ + "base64", + "bytes", + "encoding_rs", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-rustls", + "hyper-tls", + "hyper-util", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "system-configuration", + "tokio", + "tokio-native-tls", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "winreg", +] + +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.15", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "ruplacer" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" +dependencies = [ + "Inflector", + "anyhow", + "clap", + "colored", + "ignore", + "regex", +] + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags 2.5.0", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.52.0", +] + +[[package]] +name = "rustls" +version = "0.23.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-pemfile" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +dependencies = [ + "base64", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + +[[package]] +name = "rustls-webpki" +version = "0.102.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" +dependencies = [ + "bitflags 2.5.0", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "serde" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" +dependencies = [ + "indexmap", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_spanned" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "sha2" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" +dependencies = [ + "digest 0.10.7", + "keccak", +] + +[[package]] +name = "signal-hook-registry" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" +dependencies = [ + "libc", +] + +[[package]] +name = "signature" +version = "1.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" + +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "socket2" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + +[[package]] +name = "strsim" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" + +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "tempfile" +version = "3.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +dependencies = [ + "cfg-if", + "fastrand", + "rustix", + "windows-sys 0.52.0", +] + +[[package]] +name = "thiserror" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tinyvec" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +dependencies = [ + "backtrace", + "bytes", + "libc", + "mio", + "num_cpus", + "parking_lot", + "pin-project-lite", + "signal-hook-registry", + "socket2", + "tokio-macros", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-macros" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "0.8.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "pin-project-lite", + "tracing-core", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "url" +version = "2.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", +] + +[[package]] +name = "utf8parse" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +dependencies = [ + "cfg-if", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" + +[[package]] +name = "wasmparser" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" +dependencies = [ + "ahash", + "bitflags 2.5.0", + "hashbrown", + "indexmap", + "semver", + "serde", +] + +[[package]] +name = "wasmprinter" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" +dependencies = [ + "anyhow", + "wasmparser", +] + +[[package]] +name = "web-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "winapi-util" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.5", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +dependencies = [ + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" + +[[package]] +name = "winnow" +version = "0.6.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + +[[package]] +name = "zerocopy" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zip" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" +dependencies = [ + "arbitrary", + "crc32fast", + "crossbeam-utils", + "displaydoc", + "flate2", + "indexmap", + "memchr", + "thiserror", + "zopfli", +] + +[[package]] +name = "zopfli" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" +dependencies = [ + "bumpalo", + "crc32fast", + "lockfree-object-pool", + "log", + "once_cell", + "simd-adler32", +] diff --git a/legacy-contracts/farm-v13-custom-rewards/Cargo.toml b/legacy-contracts/farm-v13-custom-rewards/Cargo.toml new file mode 100644 index 000000000..c0a35e39c --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/Cargo.toml @@ -0,0 +1,18 @@ +[package] +name = "farm-v13-custom-rewards" +version = "0.0.0" +authors = ["you"] +edition = "2021" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "0.50.5" + +[dev-dependencies] +num-bigint = "0.4" + +[dev-dependencies.multiversx-sc-scenario] +version = "0.50.5" diff --git a/legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml b/legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml new file mode 100644 index 000000000..a5038c44a --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "farm-v13-custom-rewards-meta" +version = "0.0.0" +edition = "2021" +publish = false + +[dependencies.farm-v13-custom-rewards] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.5" +default-features = false diff --git a/legacy-contracts/farm-v13-custom-rewards/meta/src/main.rs b/legacy-contracts/farm-v13-custom-rewards/meta/src/main.rs new file mode 100644 index 000000000..d5a799634 --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-v13-custom-rewards/multiversx.json b/legacy-contracts/farm-v13-custom-rewards/multiversx.json new file mode 100644 index 000000000..736553962 --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/multiversx.json @@ -0,0 +1,3 @@ +{ + "language": "rust" +} \ No newline at end of file diff --git a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs new file mode 100644 index 000000000..81a4d4e5a --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs @@ -0,0 +1,254 @@ +#![no_std] + +use multiversx_sc::derive_imports::*; +use multiversx_sc::imports::*; + +type Nonce = u64; +type EnterFarmResultType = EsdtTokenPayment; +type ClaimRewardsResultType = + MultiValue2, EsdtTokenPayment>; +type ExitFarmResultType = + MultiValue2, EsdtTokenPayment>; + +#[derive(TopEncode, TopDecode, PartialEq, TypeAbi)] +pub enum State { + Inactive, + Active, +} + +#[derive(ManagedVecItem, TopEncode, TopDecode, NestedEncode, NestedDecode, TypeAbi, Clone)] +pub struct FarmTokenAttributes { + pub reward_per_share: BigUint, + pub original_entering_epoch: u64, + pub entering_epoch: u64, + pub initial_farming_amount: BigUint, + pub compounded_reward: BigUint, + pub current_farm_amount: BigUint, +} + +#[multiversx_sc::contract] +pub trait FarmV13LockedRewards { + #[init] + fn init(&self) {} + + #[only_owner] + #[endpoint(addAddressToWhitelist)] + fn add_address_to_whitelist(&self, _address: ManagedAddress) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(calculateRewardsForGivenPosition)] + fn calculate_rewards_for_given_position( + &self, + _amount: BigUint, + _attributes: FarmTokenAttributes, + ) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(claimRewards)] + fn claim_rewards( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> ClaimRewardsResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[payable("*")] + #[endpoint(depositRewards)] + fn deposit_rewards(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(end_produce_rewards)] + fn end_produce_rewards(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(enterFarm)] + fn enter_farm( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> EnterFarmResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(exitFarm)] + fn exit_farm( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> ExitFarmResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getBlockForEndRewards)] + fn block_for_end_rewards(&self) -> u64 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getBurnGasLimit)] + fn burn_gas_limit(&self) -> u64 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getDivisionSafetyConstant)] + fn division_safety_constant(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmTokenId)] + fn farm_token_id(&self) -> TokenIdentifier { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmTokenSupply)] + fn farm_token_supply(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmingTokenId)] + fn farming_token_id(&self) -> TokenIdentifier { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLastErrorMessage)] + fn last_error_message(&self) -> ManagedBuffer { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLastRewardBlockNonce)] + fn last_reward_block_nonce(&self) -> Nonce { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getMinimumFarmingEpoch)] + fn minimum_farming_epochs(&self) -> u8 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getOwner)] + fn owner(&self) -> ManagedAddress { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getPenaltyPercent)] + fn penalty_percent(&self) -> u64 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getPerBlockRewardAmount)] + fn per_block_reward_amount(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getRewardPerShare)] + fn reward_per_share(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getRewardReserve)] + fn reward_reserve(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getRewardTokenId)] + fn reward_token_id(&self) -> TokenIdentifier { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getState)] + fn state(&self) -> State { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getTransferExecGasLimit)] + fn transfer_exec_gas_limit(&self) -> u64 { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getWhitelist)] + fn whitelist(&self) -> UnorderedSetMapper { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(mergeFarmTokens)] + fn merge_farm_tokens( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> EsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(pause)] + fn pause(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("EGLD")] + #[endpoint(registerFarmToken)] + fn register_farm_token( + &self, + _token_display_name: ManagedBuffer, + _token_ticker: ManagedBuffer, + _num_decimals: usize, + ) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(removeAddressFromWhitelist)] + fn remove_address_from_whitelist(&self, _address: ManagedAddress) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(resume)] + fn resume(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setBlockForEndRewards)] + fn set_block_for_end_rewards(&self, _block_end: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(setLocalRolesFarmToken)] + fn set_local_roles_farm_token(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(setPerBlockRewardAmount)] + fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_burn_gas_limit)] + fn set_burn_gas_limit(&self, _gas_limit: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_minimum_farming_epochs)] + fn set_minimum_farming_epochs(&self, _epochs: u8) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_penalty_percent)] + fn set_penalty_percent(&self, _percent: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(set_transfer_exec_gas_limit)] + fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(startProduceRewards)] + fn start_produce_rewards(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } +} diff --git a/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock new file mode 100644 index 000000000..fd532c2d9 --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock @@ -0,0 +1,188 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "farm-v13-custom-rewards" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "farm-v13-custom-rewards-wasm" +version = "0.0.0" +dependencies = [ + "farm-v13-custom-rewards", + "multiversx-sc-wasm-adapter", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml new file mode 100644 index 000000000..2a05d93a7 --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "farm-v13-custom-rewards-wasm" +version = "0.0.0" +edition = "2021" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.farm-v13-custom-rewards] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "0.50.5" + +[workspace] +members = ["."] diff --git a/legacy-contracts/farm-v13-custom-rewards/wasm/src/lib.rs b/legacy-contracts/farm-v13-custom-rewards/wasm/src/lib.rs new file mode 100644 index 000000000..1c377fcbd --- /dev/null +++ b/legacy-contracts/farm-v13-custom-rewards/wasm/src/lib.rs @@ -0,0 +1,62 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 38 +// Async Callback (empty): 1 +// Total number of exported functions: 40 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + farm_v13_custom_rewards + ( + init => init + addAddressToWhitelist => add_address_to_whitelist + calculateRewardsForGivenPosition => calculate_rewards_for_given_position + claimRewards => claim_rewards + depositRewards => deposit_rewards + end_produce_rewards => end_produce_rewards + enterFarm => enter_farm + exitFarm => exit_farm + getBlockForEndRewards => block_for_end_rewards + getBurnGasLimit => burn_gas_limit + getDivisionSafetyConstant => division_safety_constant + getFarmTokenId => farm_token_id + getFarmTokenSupply => farm_token_supply + getFarmingTokenId => farming_token_id + getLastErrorMessage => last_error_message + getLastRewardBlockNonce => last_reward_block_nonce + getMinimumFarmingEpoch => minimum_farming_epochs + getOwner => owner + getPenaltyPercent => penalty_percent + getPerBlockRewardAmount => per_block_reward_amount + getRewardPerShare => reward_per_share + getRewardReserve => reward_reserve + getRewardTokenId => reward_token_id + getState => state + getTransferExecGasLimit => transfer_exec_gas_limit + getWhitelist => whitelist + mergeFarmTokens => merge_farm_tokens + pause => pause + registerFarmToken => register_farm_token + removeAddressFromWhitelist => remove_address_from_whitelist + resume => resume + setBlockForEndRewards => set_block_for_end_rewards + setLocalRolesFarmToken => set_local_roles_farm_token + setPerBlockRewardAmount => set_per_block_reward_amount + set_burn_gas_limit => set_burn_gas_limit + set_minimum_farming_epochs => set_minimum_farming_epochs + set_penalty_percent => set_penalty_percent + set_transfer_exec_gas_limit => set_transfer_exec_gas_limit + startProduceRewards => start_produce_rewards + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/legacy-contracts/farm-v13-locked-rewards/Cargo.lock b/legacy-contracts/farm-v13-locked-rewards/Cargo.lock new file mode 100644 index 000000000..07b1eab79 --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/Cargo.lock @@ -0,0 +1,2593 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "Inflector" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" +dependencies = [ + "lazy_static", + "regex", +] + +[[package]] +name = "addr2line" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +dependencies = [ + "memchr", +] + +[[package]] +name = "anstream" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "is_terminal_polyfill", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" + +[[package]] +name = "anstyle-parse" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "anstyle-wincon" +version = "3.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +dependencies = [ + "anstyle", + "windows-sys 0.52.0", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "backtrace" +version = "0.3.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "bech32" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" + +[[package]] +name = "bip39" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" +dependencies = [ + "bitcoin_hashes", + "rand 0.8.5", + "rand_core 0.6.4", + "serde", + "unicode-normalization", +] + +[[package]] +name = "bitcoin_hashes" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "bstr" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" +dependencies = [ + "memchr", + "serde", +] + +[[package]] +name = "bumpalo" +version = "3.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" + +[[package]] +name = "cc" +version = "1.0.104" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "clap" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" +dependencies = [ + "clap_builder", + "clap_derive", +] + +[[package]] +name = "clap_builder" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" +dependencies = [ + "anstream", + "anstyle", + "clap_lex", + "strsim", +] + +[[package]] +name = "clap_derive" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "clap_lex" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" + +[[package]] +name = "colorchoice" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" + +[[package]] +name = "colored" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" +dependencies = [ + "lazy_static", + "windows-sys 0.48.0", +] + +[[package]] +name = "common-path" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" + +[[package]] +name = "convert_case" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "copy_dir" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" +dependencies = [ + "walkdir", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" + +[[package]] +name = "cpufeatures" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "curve25519-dalek" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" +dependencies = [ + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", + "subtle", + "zeroize", +] + +[[package]] +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "crypto-common", + "subtle", +] + +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "ed25519" +version = "1.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" +dependencies = [ + "signature", +] + +[[package]] +name = "ed25519-dalek" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +dependencies = [ + "curve25519-dalek", + "ed25519", + "rand 0.7.3", + "serde", + "sha2 0.9.9", + "zeroize", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "encoding_rs" +version = "0.8.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v-13-meta" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-meta", +] + +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + +[[package]] +name = "flate2" +version = "1.0.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures-channel" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" + +[[package]] +name = "futures-io" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" + +[[package]] +name = "futures-sink" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" + +[[package]] +name = "futures-task" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-util" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" +dependencies = [ + "futures-core", + "futures-io", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", +] + +[[package]] +name = "gimli" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" + +[[package]] +name = "globset" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" +dependencies = [ + "aho-corasick", + "bstr", + "log", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "h2" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" +dependencies = [ + "atomic-waker", + "bytes", + "fnv", + "futures-core", + "futures-sink", + "http", + "indexmap", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +dependencies = [ + "ahash", + "serde", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "http" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "hyper" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +dependencies = [ + "futures-util", + "http", + "hyper", + "hyper-util", + "rustls", + "rustls-pki-types", + "tokio", + "tokio-rustls", + "tower-service", +] + +[[package]] +name = "hyper-tls" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" +dependencies = [ + "bytes", + "http-body-util", + "hyper", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", +] + +[[package]] +name = "hyper-util" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", +] + +[[package]] +name = "idna" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "ignore" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" +dependencies = [ + "crossbeam-deque", + "globset", + "log", + "memchr", + "regex-automata", + "same-file", + "walkdir", + "winapi-util", +] + +[[package]] +name = "indexmap" +version = "2.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +dependencies = [ + "equivalent", + "hashbrown", + "serde", +] + +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "js-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "keccak" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" +dependencies = [ + "cpufeatures", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "libc" +version = "0.2.155" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" + +[[package]] +name = "linux-raw-sys" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" + +[[package]] +name = "lock_api" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" +dependencies = [ + "autocfg", + "scopeguard", +] + +[[package]] +name = "lockfree-object-pool" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" + +[[package]] +name = "log" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "miniz_oxide" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +dependencies = [ + "adler", +] + +[[package]] +name = "mio" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "multiversx-chain-scenario-format" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" +dependencies = [ + "bech32", + "hex", + "num-bigint", + "num-traits", + "serde", + "serde_json", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" +dependencies = [ + "bitflags 2.5.0", + "colored", + "ed25519-dalek", + "hex", + "hex-literal", + "itertools", + "multiversx-chain-vm-executor", + "num-bigint", + "num-traits", + "rand 0.8.5", + "rand_seeder", + "sha2 0.10.8", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm-executor" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags 2.5.0", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "num-bigint", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-meta" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" +dependencies = [ + "clap", + "colored", + "common-path", + "convert_case", + "copy_dir", + "hex", + "lazy_static", + "multiversx-sc", + "pathdiff", + "reqwest", + "ruplacer", + "rustc_version", + "semver", + "serde", + "serde_json", + "toml", + "wasmparser", + "wasmprinter", + "zip", +] + +[[package]] +name = "multiversx-sc-scenario" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" +dependencies = [ + "base64", + "bech32", + "clap", + "colored", + "hex", + "itertools", + "log", + "multiversx-chain-scenario-format", + "multiversx-chain-vm", + "multiversx-chain-vm-executor", + "multiversx-sc", + "multiversx-sc-meta", + "multiversx-sdk", + "num-bigint", + "num-traits", + "pathdiff", + "serde", + "serde_json", + "sha2 0.10.8", + "tokio", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sdk" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" +dependencies = [ + "anyhow", + "base64", + "bech32", + "bip39", + "hex", + "hmac", + "itertools", + "pbkdf2", + "pem", + "rand 0.8.5", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "sha2 0.10.8", + "sha3", + "tokio", + "zeroize", +] + +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-bigint" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + +[[package]] +name = "object" +version = "0.36.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "opaque-debug" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" + +[[package]] +name = "openssl" +version = "0.10.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +dependencies = [ + "bitflags 2.5.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "parking_lot" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall", + "smallvec", + "windows-targets 0.52.5", +] + +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + +[[package]] +name = "pbkdf2" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "pem" +version = "3.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" +dependencies = [ + "base64", + "serde", +] + +[[package]] +name = "percent-encoding" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" + +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkg-config" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.15", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] + +[[package]] +name = "rand_seeder" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "redox_syscall" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +dependencies = [ + "bitflags 2.5.0", +] + +[[package]] +name = "regex" +version = "1.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + +[[package]] +name = "reqwest" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" +dependencies = [ + "base64", + "bytes", + "encoding_rs", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-rustls", + "hyper-tls", + "hyper-util", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "system-configuration", + "tokio", + "tokio-native-tls", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "winreg", +] + +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.15", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "ruplacer" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" +dependencies = [ + "Inflector", + "anyhow", + "clap", + "colored", + "ignore", + "regex", +] + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags 2.5.0", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.52.0", +] + +[[package]] +name = "rustls" +version = "0.23.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-pemfile" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +dependencies = [ + "base64", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + +[[package]] +name = "rustls-webpki" +version = "0.102.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" +dependencies = [ + "bitflags 2.5.0", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "serde" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" +dependencies = [ + "indexmap", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_spanned" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "sha2" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" +dependencies = [ + "digest 0.10.7", + "keccak", +] + +[[package]] +name = "signal-hook-registry" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" +dependencies = [ + "libc", +] + +[[package]] +name = "signature" +version = "1.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" + +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "socket2" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + +[[package]] +name = "strsim" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" + +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "tempfile" +version = "3.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +dependencies = [ + "cfg-if", + "fastrand", + "rustix", + "windows-sys 0.52.0", +] + +[[package]] +name = "thiserror" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tinyvec" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +dependencies = [ + "backtrace", + "bytes", + "libc", + "mio", + "num_cpus", + "parking_lot", + "pin-project-lite", + "signal-hook-registry", + "socket2", + "tokio-macros", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-macros" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "0.8.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "pin-project-lite", + "tracing-core", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "url" +version = "2.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", +] + +[[package]] +name = "utf8parse" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +dependencies = [ + "cfg-if", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" + +[[package]] +name = "wasmparser" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" +dependencies = [ + "ahash", + "bitflags 2.5.0", + "hashbrown", + "indexmap", + "semver", + "serde", +] + +[[package]] +name = "wasmprinter" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" +dependencies = [ + "anyhow", + "wasmparser", +] + +[[package]] +name = "web-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "winapi-util" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.5", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +dependencies = [ + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" + +[[package]] +name = "winnow" +version = "0.6.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + +[[package]] +name = "zerocopy" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zip" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" +dependencies = [ + "arbitrary", + "crc32fast", + "crossbeam-utils", + "displaydoc", + "flate2", + "indexmap", + "memchr", + "thiserror", + "zopfli", +] + +[[package]] +name = "zopfli" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" +dependencies = [ + "bumpalo", + "crc32fast", + "lockfree-object-pool", + "log", + "once_cell", + "simd-adler32", +] diff --git a/legacy-contracts/farm-v13-locked-rewards/Cargo.toml b/legacy-contracts/farm-v13-locked-rewards/Cargo.toml new file mode 100644 index 000000000..315ac407f --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/Cargo.toml @@ -0,0 +1,18 @@ +[package] +name = "farm-v13-locked-rewards" +version = "0.0.0" +authors = ["you"] +edition = "2021" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "0.50.5" + +[dev-dependencies] +num-bigint = "0.4" + +[dev-dependencies.multiversx-sc-scenario] +version = "0.50.5" diff --git a/legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml b/legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml new file mode 100644 index 000000000..2fe5738aa --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "farm-v13-locked-rewards-meta" +version = "0.0.0" +edition = "2021" +publish = false + +[dependencies.farm-v13-locked-rewards] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.5" +default-features = false diff --git a/legacy-contracts/farm-v13-locked-rewards/meta/src/main.rs b/legacy-contracts/farm-v13-locked-rewards/meta/src/main.rs new file mode 100644 index 000000000..09e0655ed --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-v13-locked-rewards/multiversx.json b/legacy-contracts/farm-v13-locked-rewards/multiversx.json new file mode 100644 index 000000000..736553962 --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/multiversx.json @@ -0,0 +1,3 @@ +{ + "language": "rust" +} \ No newline at end of file diff --git a/legacy-contracts/farm-v13-locked-rewards/src/lib.rs b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs new file mode 100644 index 000000000..7dc899f89 --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs @@ -0,0 +1,275 @@ +#![no_std] + +use multiversx_sc::derive_imports::*; +use multiversx_sc::imports::*; + +type Nonce = u64; +type ExitFarmResultType = + MultiValue2, EsdtTokenPayment>; + +#[derive(TopEncode, TopDecode, PartialEq, TypeAbi)] +pub enum State { + Inactive, + Active, +} + +#[derive( + ManagedVecItem, + TopEncode, + TopDecode, + NestedEncode, + NestedDecode, + TypeAbi, + Clone, + PartialEq, + Debug, +)] +pub struct FarmTokenAttributes { + pub reward_per_share: BigUint, + pub original_entering_epoch: u64, + pub entering_epoch: u64, + pub initial_farming_amount: BigUint, + pub compounded_reward: BigUint, + pub current_farm_amount: BigUint, +} + +#[derive(ManagedVecItem, TopEncode, TopDecode, NestedEncode, NestedDecode, TypeAbi, Clone)] +pub struct FarmTokenAttributesV1_2 { + pub reward_per_share: BigUint, + pub original_entering_epoch: u64, + pub entering_epoch: u64, + pub apr_multiplier: u8, + pub with_locked_rewards: bool, + pub initial_farming_amount: BigUint, + pub compounded_reward: BigUint, + pub current_farm_amount: BigUint, +} + +#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq)] +pub enum FarmMigrationRole { + Old, + New, + NewWithLock, +} + +#[derive(TypeAbi, TopEncode, TopDecode)] +pub struct FarmMigrationConfig { + migration_role: FarmMigrationRole, + old_farm_address: ManagedAddress, + old_farm_token_id: TokenIdentifier, +} + +#[multiversx_sc::contract] +pub trait FarmV13LockedRewards { + #[init] + fn init(&self) {} + + #[upgrade] + fn upgrade(&self) {} + + #[payable("*")] + #[endpoint(exitFarm)] + fn exit_farm( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> ExitFarmResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(mergeFarmTokens)] + fn merge_farm_tokens( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> EsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(calculateRewardsForGivenPosition)] + fn calculate_rewards_for_given_position( + &self, + _amount: BigUint, + _attributes: FarmTokenAttributes, + ) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn end_produce_rewards(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setPerBlockRewardAmount)] + fn set_per_block_rewards(&self, _per_block_amount: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_penalty_percent(&self, _percent: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_minimum_farming_epochs(&self, _epochs: u8) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_burn_gas_limit(&self, _gas_limit: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(setRpsAndStartRewards)] + fn set_rps_and_start_rewards(&self, _rps: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn pause(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn resume(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(startProduceRewards)] + fn start_produce_rewards_as_owner(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setFarmTokenSupply)] + fn set_farm_token_supply(&self, _supply: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setFarmMigrationConfig)] + fn set_farm_migration_config( + &self, + _old_farm_address: ManagedAddress, + _old_farm_token_id: TokenIdentifier, + _new_farm_address: ManagedAddress, + _new_farm_with_lock_address: ManagedAddress, + ) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[payable("EGLD")] + #[endpoint(registerFarmToken)] + fn register_farm_token( + &self, + _token_display_name: ManagedBuffer, + _token_ticker: ManagedBuffer, + _num_decimals: usize, + ) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setLocalRolesFarmToken)] + fn set_local_roles_farm_token(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(migrateFromV1_2Farm)] + fn migrate_from_v1_2_farm( + &self, + _old_attrs: FarmTokenAttributesV1_2, + _orig_caller: ManagedAddress, + ) -> EsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmMigrationConfiguration)] + #[storage_mapper("farm_migration_config")] + fn farm_migration_config(&self) -> SingleValueMapper>; + + #[view(getFarmTokenSupply)] + #[storage_mapper("farm_token_supply")] + fn farm_token_supply(&self) -> SingleValueMapper; + + #[view(getLastErrorMessage)] + #[storage_mapper("last_error_message")] + fn last_error_message(&self) -> SingleValueMapper; + + #[view(getState)] + #[storage_mapper("state")] + fn state(&self) -> SingleValueMapper; + + #[view(getFarmingTokenId)] + #[storage_mapper("farming_token_id")] + fn farming_token_id(&self) -> SingleValueMapper; + + #[view(getRewardTokenId)] + #[storage_mapper("reward_token_id")] + fn reward_token_id(&self) -> SingleValueMapper; + + #[view(getPenaltyPercent)] + #[storage_mapper("penalty_percent")] + fn penalty_percent(&self) -> SingleValueMapper; + + #[view(getMinimumFarmingEpoch)] + #[storage_mapper("minimum_farming_epochs")] + fn minimum_farming_epochs(&self) -> SingleValueMapper; + + #[view(getPerBlockRewardAmount)] + #[storage_mapper("per_block_reward_amount")] + fn per_block_reward_amount(&self) -> SingleValueMapper; + + #[storage_mapper("produce_rewards_enabled")] + fn produce_rewards_enabled(&self) -> SingleValueMapper; + + #[view(getLastRewardBlockNonce)] + #[storage_mapper("last_reward_block_nonce")] + fn last_reward_block_nonce(&self) -> SingleValueMapper; + + #[view(getFarmTokenId)] + #[storage_mapper("farm_token_id")] + fn farm_token_id(&self) -> SingleValueMapper; + + #[view(getDivisionSafetyConstant)] + #[storage_mapper("division_safety_constant")] + fn division_safety_constant(&self) -> SingleValueMapper; + + #[view(getPairContractManagedAddress)] + #[storage_mapper("pair_contract_address")] + fn pair_contract_address(&self) -> SingleValueMapper; + + #[view(getBurnGasLimit)] + #[storage_mapper("burn_gas_limit")] + fn burn_gas_limit(&self) -> SingleValueMapper; + + #[view(getLockedAssetFactoryManagedAddress)] + #[storage_mapper("locked_asset_factory_address")] + fn locked_asset_factory_address(&self) -> SingleValueMapper; + + #[view(getRewardPerShare)] + #[storage_mapper("reward_per_share")] + fn reward_per_share(&self) -> SingleValueMapper; + + #[view(getRewardReserve)] + #[storage_mapper("reward_reserve")] + fn reward_reserve(&self) -> SingleValueMapper; + + #[view(getTransferExecGasLimit)] + #[storage_mapper("transfer_exec_gas_limit")] + fn transfer_exec_gas_limit(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock new file mode 100644 index 000000000..32f373d1c --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock @@ -0,0 +1,188 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "farm-v13-locked-rewards" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "farm-v13-locked-rewards-wasm" +version = "0.0.0" +dependencies = [ + "farm-v13-locked-rewards", + "multiversx-sc-wasm-adapter", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml new file mode 100644 index 000000000..83789310d --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "farm-v13-locked-rewards-wasm" +version = "0.0.0" +edition = "2021" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.farm-v13-locked-rewards] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "0.50.5" + +[workspace] +members = ["."] diff --git a/legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs b/legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs new file mode 100644 index 000000000..c51ed969b --- /dev/null +++ b/legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs @@ -0,0 +1,62 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Upgrade: 1 +// Endpoints: 36 +// Async Callback (empty): 1 +// Total number of exported functions: 39 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + farm_v13_locked_rewards + ( + init => init + upgrade => upgrade + exitFarm => exit_farm + mergeFarmTokens => merge_farm_tokens + calculateRewardsForGivenPosition => calculate_rewards_for_given_position + end_produce_rewards => end_produce_rewards + setPerBlockRewardAmount => set_per_block_rewards + set_penalty_percent => set_penalty_percent + set_minimum_farming_epochs => set_minimum_farming_epochs + set_transfer_exec_gas_limit => set_transfer_exec_gas_limit + set_burn_gas_limit => set_burn_gas_limit + setRpsAndStartRewards => set_rps_and_start_rewards + pause => pause + resume => resume + startProduceRewards => start_produce_rewards_as_owner + setFarmTokenSupply => set_farm_token_supply + setFarmMigrationConfig => set_farm_migration_config + registerFarmToken => register_farm_token + setLocalRolesFarmToken => set_local_roles_farm_token + migrateFromV1_2Farm => migrate_from_v1_2_farm + getFarmMigrationConfiguration => farm_migration_config + getFarmTokenSupply => farm_token_supply + getLastErrorMessage => last_error_message + getState => state + getFarmingTokenId => farming_token_id + getRewardTokenId => reward_token_id + getPenaltyPercent => penalty_percent + getMinimumFarmingEpoch => minimum_farming_epochs + getPerBlockRewardAmount => per_block_reward_amount + getLastRewardBlockNonce => last_reward_block_nonce + getFarmTokenId => farm_token_id + getDivisionSafetyConstant => division_safety_constant + getPairContractManagedAddress => pair_contract_address + getBurnGasLimit => burn_gas_limit + getLockedAssetFactoryManagedAddress => locked_asset_factory_address + getRewardPerShare => reward_per_share + getRewardReserve => reward_reserve + getTransferExecGasLimit => transfer_exec_gas_limit + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/legacy-contracts/farm-v13/Cargo.lock b/legacy-contracts/farm-v13/Cargo.lock new file mode 100644 index 000000000..07b1eab79 --- /dev/null +++ b/legacy-contracts/farm-v13/Cargo.lock @@ -0,0 +1,2593 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "Inflector" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" +dependencies = [ + "lazy_static", + "regex", +] + +[[package]] +name = "addr2line" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +dependencies = [ + "memchr", +] + +[[package]] +name = "anstream" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "is_terminal_polyfill", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" + +[[package]] +name = "anstyle-parse" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "anstyle-wincon" +version = "3.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +dependencies = [ + "anstyle", + "windows-sys 0.52.0", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "backtrace" +version = "0.3.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "bech32" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" + +[[package]] +name = "bip39" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" +dependencies = [ + "bitcoin_hashes", + "rand 0.8.5", + "rand_core 0.6.4", + "serde", + "unicode-normalization", +] + +[[package]] +name = "bitcoin_hashes" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "bstr" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" +dependencies = [ + "memchr", + "serde", +] + +[[package]] +name = "bumpalo" +version = "3.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" + +[[package]] +name = "cc" +version = "1.0.104" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "clap" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" +dependencies = [ + "clap_builder", + "clap_derive", +] + +[[package]] +name = "clap_builder" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" +dependencies = [ + "anstream", + "anstyle", + "clap_lex", + "strsim", +] + +[[package]] +name = "clap_derive" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "clap_lex" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" + +[[package]] +name = "colorchoice" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" + +[[package]] +name = "colored" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" +dependencies = [ + "lazy_static", + "windows-sys 0.48.0", +] + +[[package]] +name = "common-path" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" + +[[package]] +name = "convert_case" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "copy_dir" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" +dependencies = [ + "walkdir", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" + +[[package]] +name = "cpufeatures" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "curve25519-dalek" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" +dependencies = [ + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", + "subtle", + "zeroize", +] + +[[package]] +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "crypto-common", + "subtle", +] + +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "ed25519" +version = "1.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" +dependencies = [ + "signature", +] + +[[package]] +name = "ed25519-dalek" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +dependencies = [ + "curve25519-dalek", + "ed25519", + "rand 0.7.3", + "serde", + "sha2 0.9.9", + "zeroize", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "encoding_rs" +version = "0.8.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v-13-meta" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-meta", +] + +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + +[[package]] +name = "flate2" +version = "1.0.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures-channel" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" + +[[package]] +name = "futures-io" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" + +[[package]] +name = "futures-sink" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" + +[[package]] +name = "futures-task" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-util" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" +dependencies = [ + "futures-core", + "futures-io", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", +] + +[[package]] +name = "gimli" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" + +[[package]] +name = "globset" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" +dependencies = [ + "aho-corasick", + "bstr", + "log", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "h2" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" +dependencies = [ + "atomic-waker", + "bytes", + "fnv", + "futures-core", + "futures-sink", + "http", + "indexmap", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +dependencies = [ + "ahash", + "serde", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "http" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "hyper" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +dependencies = [ + "futures-util", + "http", + "hyper", + "hyper-util", + "rustls", + "rustls-pki-types", + "tokio", + "tokio-rustls", + "tower-service", +] + +[[package]] +name = "hyper-tls" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" +dependencies = [ + "bytes", + "http-body-util", + "hyper", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", +] + +[[package]] +name = "hyper-util" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", +] + +[[package]] +name = "idna" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "ignore" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" +dependencies = [ + "crossbeam-deque", + "globset", + "log", + "memchr", + "regex-automata", + "same-file", + "walkdir", + "winapi-util", +] + +[[package]] +name = "indexmap" +version = "2.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +dependencies = [ + "equivalent", + "hashbrown", + "serde", +] + +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "js-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "keccak" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" +dependencies = [ + "cpufeatures", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "libc" +version = "0.2.155" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" + +[[package]] +name = "linux-raw-sys" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" + +[[package]] +name = "lock_api" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" +dependencies = [ + "autocfg", + "scopeguard", +] + +[[package]] +name = "lockfree-object-pool" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" + +[[package]] +name = "log" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "miniz_oxide" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +dependencies = [ + "adler", +] + +[[package]] +name = "mio" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "multiversx-chain-scenario-format" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" +dependencies = [ + "bech32", + "hex", + "num-bigint", + "num-traits", + "serde", + "serde_json", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" +dependencies = [ + "bitflags 2.5.0", + "colored", + "ed25519-dalek", + "hex", + "hex-literal", + "itertools", + "multiversx-chain-vm-executor", + "num-bigint", + "num-traits", + "rand 0.8.5", + "rand_seeder", + "sha2 0.10.8", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm-executor" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags 2.5.0", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "num-bigint", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-meta" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" +dependencies = [ + "clap", + "colored", + "common-path", + "convert_case", + "copy_dir", + "hex", + "lazy_static", + "multiversx-sc", + "pathdiff", + "reqwest", + "ruplacer", + "rustc_version", + "semver", + "serde", + "serde_json", + "toml", + "wasmparser", + "wasmprinter", + "zip", +] + +[[package]] +name = "multiversx-sc-scenario" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" +dependencies = [ + "base64", + "bech32", + "clap", + "colored", + "hex", + "itertools", + "log", + "multiversx-chain-scenario-format", + "multiversx-chain-vm", + "multiversx-chain-vm-executor", + "multiversx-sc", + "multiversx-sc-meta", + "multiversx-sdk", + "num-bigint", + "num-traits", + "pathdiff", + "serde", + "serde_json", + "sha2 0.10.8", + "tokio", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sdk" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" +dependencies = [ + "anyhow", + "base64", + "bech32", + "bip39", + "hex", + "hmac", + "itertools", + "pbkdf2", + "pem", + "rand 0.8.5", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "sha2 0.10.8", + "sha3", + "tokio", + "zeroize", +] + +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-bigint" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + +[[package]] +name = "object" +version = "0.36.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "opaque-debug" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" + +[[package]] +name = "openssl" +version = "0.10.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +dependencies = [ + "bitflags 2.5.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "parking_lot" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall", + "smallvec", + "windows-targets 0.52.5", +] + +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + +[[package]] +name = "pbkdf2" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "pem" +version = "3.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" +dependencies = [ + "base64", + "serde", +] + +[[package]] +name = "percent-encoding" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" + +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkg-config" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.15", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] + +[[package]] +name = "rand_seeder" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "redox_syscall" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +dependencies = [ + "bitflags 2.5.0", +] + +[[package]] +name = "regex" +version = "1.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + +[[package]] +name = "reqwest" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" +dependencies = [ + "base64", + "bytes", + "encoding_rs", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-rustls", + "hyper-tls", + "hyper-util", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "system-configuration", + "tokio", + "tokio-native-tls", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "winreg", +] + +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.15", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "ruplacer" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" +dependencies = [ + "Inflector", + "anyhow", + "clap", + "colored", + "ignore", + "regex", +] + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags 2.5.0", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.52.0", +] + +[[package]] +name = "rustls" +version = "0.23.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-pemfile" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +dependencies = [ + "base64", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + +[[package]] +name = "rustls-webpki" +version = "0.102.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" +dependencies = [ + "bitflags 2.5.0", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "serde" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" +dependencies = [ + "indexmap", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_spanned" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "sha2" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" +dependencies = [ + "digest 0.10.7", + "keccak", +] + +[[package]] +name = "signal-hook-registry" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" +dependencies = [ + "libc", +] + +[[package]] +name = "signature" +version = "1.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" + +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "socket2" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + +[[package]] +name = "strsim" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" + +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "tempfile" +version = "3.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +dependencies = [ + "cfg-if", + "fastrand", + "rustix", + "windows-sys 0.52.0", +] + +[[package]] +name = "thiserror" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tinyvec" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +dependencies = [ + "backtrace", + "bytes", + "libc", + "mio", + "num_cpus", + "parking_lot", + "pin-project-lite", + "signal-hook-registry", + "socket2", + "tokio-macros", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-macros" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "0.8.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "pin-project-lite", + "tracing-core", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "url" +version = "2.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", +] + +[[package]] +name = "utf8parse" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +dependencies = [ + "cfg-if", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" + +[[package]] +name = "wasmparser" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" +dependencies = [ + "ahash", + "bitflags 2.5.0", + "hashbrown", + "indexmap", + "semver", + "serde", +] + +[[package]] +name = "wasmprinter" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" +dependencies = [ + "anyhow", + "wasmparser", +] + +[[package]] +name = "web-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "winapi-util" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.5", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +dependencies = [ + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" + +[[package]] +name = "winnow" +version = "0.6.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + +[[package]] +name = "zerocopy" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zip" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" +dependencies = [ + "arbitrary", + "crc32fast", + "crossbeam-utils", + "displaydoc", + "flate2", + "indexmap", + "memchr", + "thiserror", + "zopfli", +] + +[[package]] +name = "zopfli" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" +dependencies = [ + "bumpalo", + "crc32fast", + "lockfree-object-pool", + "log", + "once_cell", + "simd-adler32", +] diff --git a/legacy-contracts/farm-v13/Cargo.toml b/legacy-contracts/farm-v13/Cargo.toml new file mode 100644 index 000000000..a72ce8f75 --- /dev/null +++ b/legacy-contracts/farm-v13/Cargo.toml @@ -0,0 +1,18 @@ +[package] +name = "farm-v13" +version = "0.0.0" +authors = ["you"] +edition = "2021" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "0.50.5" + +[dev-dependencies] +num-bigint = "0.4" + +[dev-dependencies.multiversx-sc-scenario] +version = "0.50.5" diff --git a/legacy-contracts/farm-v13/meta/Cargo.toml b/legacy-contracts/farm-v13/meta/Cargo.toml new file mode 100644 index 000000000..c1db07489 --- /dev/null +++ b/legacy-contracts/farm-v13/meta/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "farm-v13-meta" +version = "0.0.0" +edition = "2021" +publish = false + +[dependencies.farm-v13] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.5" +default-features = false diff --git a/legacy-contracts/farm-v13/meta/src/main.rs b/legacy-contracts/farm-v13/meta/src/main.rs new file mode 100644 index 000000000..e5e10c77e --- /dev/null +++ b/legacy-contracts/farm-v13/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/farm-v13/multiversx.json b/legacy-contracts/farm-v13/multiversx.json new file mode 100644 index 000000000..736553962 --- /dev/null +++ b/legacy-contracts/farm-v13/multiversx.json @@ -0,0 +1,3 @@ +{ + "language": "rust" +} \ No newline at end of file diff --git a/legacy-contracts/farm-v13/src/lib.rs b/legacy-contracts/farm-v13/src/lib.rs new file mode 100644 index 000000000..204a3cfb1 --- /dev/null +++ b/legacy-contracts/farm-v13/src/lib.rs @@ -0,0 +1,306 @@ +#![no_std] + +use multiversx_sc::derive_imports::*; +use multiversx_sc::imports::*; + +type Nonce = u64; +type EnterFarmResultType = EsdtTokenPayment; +type CompoundRewardsResultType = EsdtTokenPayment; +type ClaimRewardsResultType = + MultiValue2, EsdtTokenPayment>; +type ExitFarmResultType = + MultiValue2, EsdtTokenPayment>; + +#[derive(TopEncode, TopDecode, PartialEq, TypeAbi)] +pub enum State { + Inactive, + Active, +} + +#[derive( + ManagedVecItem, + TopEncode, + TopDecode, + NestedEncode, + NestedDecode, + TypeAbi, + Clone, + PartialEq, + Debug, +)] +pub struct FarmTokenAttributes { + pub reward_per_share: BigUint, + pub original_entering_epoch: u64, + pub entering_epoch: u64, + pub initial_farming_amount: BigUint, + pub compounded_reward: BigUint, + pub current_farm_amount: BigUint, +} + +#[derive(ManagedVecItem, TopEncode, TopDecode, NestedEncode, NestedDecode, TypeAbi, Clone)] +pub struct FarmTokenAttributesV1_2 { + pub reward_per_share: BigUint, + pub original_entering_epoch: u64, + pub entering_epoch: u64, + pub apr_multiplier: u8, + pub with_locked_rewards: bool, + pub initial_farming_amount: BigUint, + pub compounded_reward: BigUint, + pub current_farm_amount: BigUint, +} + +#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, PartialEq)] +pub enum FarmMigrationRole { + Old, + New, + NewWithLock, +} + +#[derive(TypeAbi, TopEncode, TopDecode)] +pub struct FarmMigrationConfig { + migration_role: FarmMigrationRole, + old_farm_address: ManagedAddress, + old_farm_token_id: TokenIdentifier, +} + +#[multiversx_sc::contract] +pub trait FarmV13LockedRewards { + #[init] + fn init(&self) {} + + #[upgrade] + fn upgrade(&self) {} + + #[payable("*")] + #[endpoint(enterFarm)] + fn enter_farm( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> EnterFarmResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(exitFarm)] + fn exit_farm( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> ExitFarmResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(claimRewards)] + fn claim_rewards( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> ClaimRewardsResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(compoundRewards)] + fn compound_rewards( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> CompoundRewardsResultType { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(mergeFarmTokens)] + fn merge_farm_tokens( + &self, + _opt_accept_funds_func: OptionalValue, + ) -> EsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(calculateRewardsForGivenPosition)] + fn calculate_rewards_for_given_position( + &self, + _amount: BigUint, + _attributes: FarmTokenAttributes, + ) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn end_produce_rewards(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setPerBlockRewardAmount)] + fn set_per_block_rewards(&self, _per_block_amount: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_penalty_percent(&self, _percent: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_minimum_farming_epochs(&self, _epochs: u8) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn set_burn_gas_limit(&self, _gas_limit: u64) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn pause(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint] + fn resume(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(startProduceRewards)] + fn start_produce_rewards_as_owner(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setFarmTokenSupply)] + fn set_farm_token_supply(&self, _supply: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setFarmMigrationConfig)] + fn set_farm_migration_config( + &self, + _old_farm_address: ManagedAddress, + _old_farm_token_id: TokenIdentifier, + _new_farm_address: ManagedAddress, + _new_farm_with_lock_address: ManagedAddress, + ) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[payable("EGLD")] + #[endpoint(registerFarmToken)] + fn register_farm_token( + &self, + _token_display_name: ManagedBuffer, + _token_ticker: ManagedBuffer, + _num_decimals: usize, + ) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(setLocalRolesFarmToken)] + fn set_local_roles_farm_token(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[endpoint(setRpsAndStartRewards)] + fn set_rps_and_start_rewards(&self, _rps: BigUint) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint(migrateFromV1_2Farm)] + fn migrate_from_v1_2_farm( + &self, + _old_attrs: FarmTokenAttributesV1_2, + _orig_caller: ManagedAddress, + ) -> EsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getFarmMigrationConfiguration)] + #[storage_mapper("farm_migration_config")] + fn farm_migration_config(&self) -> SingleValueMapper>; + + #[view(getFarmTokenSupply)] + #[storage_mapper("farm_token_supply")] + fn farm_token_supply(&self) -> SingleValueMapper; + + #[view(getLastErrorMessage)] + #[storage_mapper("last_error_message")] + fn last_error_message(&self) -> SingleValueMapper; + + #[view(getState)] + #[storage_mapper("state")] + fn state(&self) -> SingleValueMapper; + + #[view(getFarmingTokenId)] + #[storage_mapper("farming_token_id")] + fn farming_token_id(&self) -> SingleValueMapper; + + #[view(getRewardTokenId)] + #[storage_mapper("reward_token_id")] + fn reward_token_id(&self) -> SingleValueMapper; + + #[view(getPenaltyPercent)] + #[storage_mapper("penalty_percent")] + fn penalty_percent(&self) -> SingleValueMapper; + + #[view(getMinimumFarmingEpoch)] + #[storage_mapper("minimum_farming_epochs")] + fn minimum_farming_epochs(&self) -> SingleValueMapper; + + #[view(getPerBlockRewardAmount)] + #[storage_mapper("per_block_reward_amount")] + fn per_block_reward_amount(&self) -> SingleValueMapper; + + #[storage_mapper("produce_rewards_enabled")] + fn produce_rewards_enabled(&self) -> SingleValueMapper; + + #[view(getLastRewardBlockNonce)] + #[storage_mapper("last_reward_block_nonce")] + fn last_reward_block_nonce(&self) -> SingleValueMapper; + + #[view(getFarmTokenId)] + #[storage_mapper("farm_token_id")] + fn farm_token_id(&self) -> SingleValueMapper; + + #[view(getDivisionSafetyConstant)] + #[storage_mapper("division_safety_constant")] + fn division_safety_constant(&self) -> SingleValueMapper; + + #[view(getPairContractManagedAddress)] + #[storage_mapper("pair_contract_address")] + fn pair_contract_address(&self) -> SingleValueMapper; + + #[view(getBurnGasLimit)] + #[storage_mapper("burn_gas_limit")] + fn burn_gas_limit(&self) -> SingleValueMapper; + + #[view(getLockedAssetFactoryManagedAddress)] + #[storage_mapper("locked_asset_factory_address")] + fn locked_asset_factory_address(&self) -> SingleValueMapper; + + #[view(getRewardPerShare)] + #[storage_mapper("reward_per_share")] + fn reward_per_share(&self) -> SingleValueMapper; + + #[view(getRewardReserve)] + #[storage_mapper("reward_reserve")] + fn reward_reserve(&self) -> SingleValueMapper; + + #[view(getTransferExecGasLimit)] + #[storage_mapper("transfer_exec_gas_limit")] + fn transfer_exec_gas_limit(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/farm-v13/wasm/Cargo.lock b/legacy-contracts/farm-v13/wasm/Cargo.lock new file mode 100644 index 000000000..a294288ec --- /dev/null +++ b/legacy-contracts/farm-v13/wasm/Cargo.lock @@ -0,0 +1,188 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "farm-v13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "farm-v13-wasm" +version = "0.0.0" +dependencies = [ + "farm-v13", + "multiversx-sc-wasm-adapter", +] + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/legacy-contracts/farm-v13/wasm/Cargo.toml b/legacy-contracts/farm-v13/wasm/Cargo.toml new file mode 100644 index 000000000..a334d9dbc --- /dev/null +++ b/legacy-contracts/farm-v13/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "farm-v13-wasm" +version = "0.0.0" +edition = "2021" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.farm-v13] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "0.50.5" + +[workspace] +members = ["."] diff --git a/legacy-contracts/farm-v13/wasm/src/lib.rs b/legacy-contracts/farm-v13/wasm/src/lib.rs new file mode 100644 index 000000000..d589b7dbf --- /dev/null +++ b/legacy-contracts/farm-v13/wasm/src/lib.rs @@ -0,0 +1,65 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Upgrade: 1 +// Endpoints: 39 +// Async Callback (empty): 1 +// Total number of exported functions: 42 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + farm_v13 + ( + init => init + upgrade => upgrade + enterFarm => enter_farm + exitFarm => exit_farm + claimRewards => claim_rewards + compoundRewards => compound_rewards + mergeFarmTokens => merge_farm_tokens + calculateRewardsForGivenPosition => calculate_rewards_for_given_position + end_produce_rewards => end_produce_rewards + setPerBlockRewardAmount => set_per_block_rewards + set_penalty_percent => set_penalty_percent + set_minimum_farming_epochs => set_minimum_farming_epochs + set_transfer_exec_gas_limit => set_transfer_exec_gas_limit + set_burn_gas_limit => set_burn_gas_limit + pause => pause + resume => resume + startProduceRewards => start_produce_rewards_as_owner + setFarmTokenSupply => set_farm_token_supply + setFarmMigrationConfig => set_farm_migration_config + registerFarmToken => register_farm_token + setLocalRolesFarmToken => set_local_roles_farm_token + setRpsAndStartRewards => set_rps_and_start_rewards + migrateFromV1_2Farm => migrate_from_v1_2_farm + getFarmMigrationConfiguration => farm_migration_config + getFarmTokenSupply => farm_token_supply + getLastErrorMessage => last_error_message + getState => state + getFarmingTokenId => farming_token_id + getRewardTokenId => reward_token_id + getPenaltyPercent => penalty_percent + getMinimumFarmingEpoch => minimum_farming_epochs + getPerBlockRewardAmount => per_block_reward_amount + getLastRewardBlockNonce => last_reward_block_nonce + getFarmTokenId => farm_token_id + getDivisionSafetyConstant => division_safety_constant + getPairContractManagedAddress => pair_contract_address + getBurnGasLimit => burn_gas_limit + getLockedAssetFactoryManagedAddress => locked_asset_factory_address + getRewardPerShare => reward_per_share + getRewardReserve => reward_reserve + getTransferExecGasLimit => transfer_exec_gas_limit + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/legacy-contracts/price-discovery-v1/Cargo.lock b/legacy-contracts/price-discovery-v1/Cargo.lock new file mode 100644 index 000000000..07b1eab79 --- /dev/null +++ b/legacy-contracts/price-discovery-v1/Cargo.lock @@ -0,0 +1,2593 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "Inflector" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" +dependencies = [ + "lazy_static", + "regex", +] + +[[package]] +name = "addr2line" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +dependencies = [ + "memchr", +] + +[[package]] +name = "anstream" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "is_terminal_polyfill", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" + +[[package]] +name = "anstyle-parse" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "anstyle-wincon" +version = "3.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +dependencies = [ + "anstyle", + "windows-sys 0.52.0", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "backtrace" +version = "0.3.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "bech32" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" + +[[package]] +name = "bip39" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" +dependencies = [ + "bitcoin_hashes", + "rand 0.8.5", + "rand_core 0.6.4", + "serde", + "unicode-normalization", +] + +[[package]] +name = "bitcoin_hashes" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "bstr" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" +dependencies = [ + "memchr", + "serde", +] + +[[package]] +name = "bumpalo" +version = "3.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" + +[[package]] +name = "cc" +version = "1.0.104" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "clap" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" +dependencies = [ + "clap_builder", + "clap_derive", +] + +[[package]] +name = "clap_builder" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" +dependencies = [ + "anstream", + "anstyle", + "clap_lex", + "strsim", +] + +[[package]] +name = "clap_derive" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "clap_lex" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" + +[[package]] +name = "colorchoice" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" + +[[package]] +name = "colored" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" +dependencies = [ + "lazy_static", + "windows-sys 0.48.0", +] + +[[package]] +name = "common-path" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" + +[[package]] +name = "convert_case" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "copy_dir" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" +dependencies = [ + "walkdir", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" + +[[package]] +name = "cpufeatures" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "curve25519-dalek" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" +dependencies = [ + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", + "subtle", + "zeroize", +] + +[[package]] +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "crypto-common", + "subtle", +] + +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "ed25519" +version = "1.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" +dependencies = [ + "signature", +] + +[[package]] +name = "ed25519-dalek" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +dependencies = [ + "curve25519-dalek", + "ed25519", + "rand 0.7.3", + "serde", + "sha2 0.9.9", + "zeroize", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "encoding_rs" +version = "0.8.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v-13-meta" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-meta", +] + +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + +[[package]] +name = "flate2" +version = "1.0.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures-channel" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" + +[[package]] +name = "futures-io" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" + +[[package]] +name = "futures-sink" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" + +[[package]] +name = "futures-task" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-util" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" +dependencies = [ + "futures-core", + "futures-io", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", +] + +[[package]] +name = "gimli" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" + +[[package]] +name = "globset" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" +dependencies = [ + "aho-corasick", + "bstr", + "log", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "h2" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" +dependencies = [ + "atomic-waker", + "bytes", + "fnv", + "futures-core", + "futures-sink", + "http", + "indexmap", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +dependencies = [ + "ahash", + "serde", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "http" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "hyper" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +dependencies = [ + "futures-util", + "http", + "hyper", + "hyper-util", + "rustls", + "rustls-pki-types", + "tokio", + "tokio-rustls", + "tower-service", +] + +[[package]] +name = "hyper-tls" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" +dependencies = [ + "bytes", + "http-body-util", + "hyper", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", +] + +[[package]] +name = "hyper-util" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", +] + +[[package]] +name = "idna" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "ignore" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" +dependencies = [ + "crossbeam-deque", + "globset", + "log", + "memchr", + "regex-automata", + "same-file", + "walkdir", + "winapi-util", +] + +[[package]] +name = "indexmap" +version = "2.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +dependencies = [ + "equivalent", + "hashbrown", + "serde", +] + +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "js-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "keccak" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" +dependencies = [ + "cpufeatures", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "libc" +version = "0.2.155" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" + +[[package]] +name = "linux-raw-sys" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" + +[[package]] +name = "lock_api" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" +dependencies = [ + "autocfg", + "scopeguard", +] + +[[package]] +name = "lockfree-object-pool" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" + +[[package]] +name = "log" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "miniz_oxide" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +dependencies = [ + "adler", +] + +[[package]] +name = "mio" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "multiversx-chain-scenario-format" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" +dependencies = [ + "bech32", + "hex", + "num-bigint", + "num-traits", + "serde", + "serde_json", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" +dependencies = [ + "bitflags 2.5.0", + "colored", + "ed25519-dalek", + "hex", + "hex-literal", + "itertools", + "multiversx-chain-vm-executor", + "num-bigint", + "num-traits", + "rand 0.8.5", + "rand_seeder", + "sha2 0.10.8", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm-executor" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags 2.5.0", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "num-bigint", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-meta" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" +dependencies = [ + "clap", + "colored", + "common-path", + "convert_case", + "copy_dir", + "hex", + "lazy_static", + "multiversx-sc", + "pathdiff", + "reqwest", + "ruplacer", + "rustc_version", + "semver", + "serde", + "serde_json", + "toml", + "wasmparser", + "wasmprinter", + "zip", +] + +[[package]] +name = "multiversx-sc-scenario" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" +dependencies = [ + "base64", + "bech32", + "clap", + "colored", + "hex", + "itertools", + "log", + "multiversx-chain-scenario-format", + "multiversx-chain-vm", + "multiversx-chain-vm-executor", + "multiversx-sc", + "multiversx-sc-meta", + "multiversx-sdk", + "num-bigint", + "num-traits", + "pathdiff", + "serde", + "serde_json", + "sha2 0.10.8", + "tokio", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sdk" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" +dependencies = [ + "anyhow", + "base64", + "bech32", + "bip39", + "hex", + "hmac", + "itertools", + "pbkdf2", + "pem", + "rand 0.8.5", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "sha2 0.10.8", + "sha3", + "tokio", + "zeroize", +] + +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-bigint" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + +[[package]] +name = "object" +version = "0.36.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "opaque-debug" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" + +[[package]] +name = "openssl" +version = "0.10.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +dependencies = [ + "bitflags 2.5.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "parking_lot" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall", + "smallvec", + "windows-targets 0.52.5", +] + +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + +[[package]] +name = "pbkdf2" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "pem" +version = "3.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" +dependencies = [ + "base64", + "serde", +] + +[[package]] +name = "percent-encoding" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" + +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkg-config" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.15", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] + +[[package]] +name = "rand_seeder" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "redox_syscall" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +dependencies = [ + "bitflags 2.5.0", +] + +[[package]] +name = "regex" +version = "1.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + +[[package]] +name = "reqwest" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" +dependencies = [ + "base64", + "bytes", + "encoding_rs", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-rustls", + "hyper-tls", + "hyper-util", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "system-configuration", + "tokio", + "tokio-native-tls", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "winreg", +] + +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.15", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "ruplacer" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" +dependencies = [ + "Inflector", + "anyhow", + "clap", + "colored", + "ignore", + "regex", +] + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags 2.5.0", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.52.0", +] + +[[package]] +name = "rustls" +version = "0.23.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-pemfile" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +dependencies = [ + "base64", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + +[[package]] +name = "rustls-webpki" +version = "0.102.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" +dependencies = [ + "bitflags 2.5.0", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "serde" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" +dependencies = [ + "indexmap", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_spanned" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "sha2" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" +dependencies = [ + "digest 0.10.7", + "keccak", +] + +[[package]] +name = "signal-hook-registry" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" +dependencies = [ + "libc", +] + +[[package]] +name = "signature" +version = "1.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" + +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "socket2" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + +[[package]] +name = "strsim" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" + +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "tempfile" +version = "3.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +dependencies = [ + "cfg-if", + "fastrand", + "rustix", + "windows-sys 0.52.0", +] + +[[package]] +name = "thiserror" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tinyvec" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +dependencies = [ + "backtrace", + "bytes", + "libc", + "mio", + "num_cpus", + "parking_lot", + "pin-project-lite", + "signal-hook-registry", + "socket2", + "tokio-macros", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-macros" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "0.8.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "pin-project-lite", + "tracing-core", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "url" +version = "2.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", +] + +[[package]] +name = "utf8parse" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +dependencies = [ + "cfg-if", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" + +[[package]] +name = "wasmparser" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" +dependencies = [ + "ahash", + "bitflags 2.5.0", + "hashbrown", + "indexmap", + "semver", + "serde", +] + +[[package]] +name = "wasmprinter" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" +dependencies = [ + "anyhow", + "wasmparser", +] + +[[package]] +name = "web-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "winapi-util" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.5", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +dependencies = [ + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" + +[[package]] +name = "winnow" +version = "0.6.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + +[[package]] +name = "zerocopy" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zip" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" +dependencies = [ + "arbitrary", + "crc32fast", + "crossbeam-utils", + "displaydoc", + "flate2", + "indexmap", + "memchr", + "thiserror", + "zopfli", +] + +[[package]] +name = "zopfli" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" +dependencies = [ + "bumpalo", + "crc32fast", + "lockfree-object-pool", + "log", + "once_cell", + "simd-adler32", +] diff --git a/legacy-contracts/price-discovery-v1/Cargo.toml b/legacy-contracts/price-discovery-v1/Cargo.toml new file mode 100644 index 000000000..48a77d04f --- /dev/null +++ b/legacy-contracts/price-discovery-v1/Cargo.toml @@ -0,0 +1,18 @@ +[package] +name = "price-discovery-v1" +version = "0.0.0" +authors = ["you"] +edition = "2021" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "0.50.5" + +[dev-dependencies] +num-bigint = "0.4" + +[dev-dependencies.multiversx-sc-scenario] +version = "0.50.5" diff --git a/legacy-contracts/price-discovery-v1/meta/Cargo.toml b/legacy-contracts/price-discovery-v1/meta/Cargo.toml new file mode 100644 index 000000000..1c78eb1f1 --- /dev/null +++ b/legacy-contracts/price-discovery-v1/meta/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "price-discovery-v1-meta" +version = "0.0.0" +edition = "2021" +publish = false + +[dependencies.price-discovery-v1] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.5" +default-features = false diff --git a/legacy-contracts/price-discovery-v1/meta/src/main.rs b/legacy-contracts/price-discovery-v1/meta/src/main.rs new file mode 100644 index 000000000..e9b6d8d7e --- /dev/null +++ b/legacy-contracts/price-discovery-v1/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/price-discovery-v1/multiversx.json b/legacy-contracts/price-discovery-v1/multiversx.json new file mode 100644 index 000000000..736553962 --- /dev/null +++ b/legacy-contracts/price-discovery-v1/multiversx.json @@ -0,0 +1,3 @@ +{ + "language": "rust" +} \ No newline at end of file diff --git a/legacy-contracts/price-discovery-v1/src/lib.rs b/legacy-contracts/price-discovery-v1/src/lib.rs new file mode 100644 index 000000000..1f4852e54 --- /dev/null +++ b/legacy-contracts/price-discovery-v1/src/lib.rs @@ -0,0 +1,130 @@ +#![no_std] + +use multiversx_sc::derive_imports::*; +use multiversx_sc::imports::*; + +#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, PartialEq)] +pub enum Phase { + Idle, + NoPenalty, + LinearIncreasingPenalty { penalty_percentage: BigUint }, + OnlyWithdrawFixedPenalty { penalty_percentage: BigUint }, + Redeem, +} + +#[multiversx_sc::contract] +pub trait PriceDiscoveryV1 { + #[init] + fn init(&self) {} + + #[payable("*")] + #[endpoint] + fn deposit(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint] + fn withdraw(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint] + fn redeem(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getCurrentPrice)] + fn calculate_price(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getCurrentPhase)] + fn get_current_phase(&self) -> Phase { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[payable("EGLD")] + #[endpoint(issueRedeemToken)] + fn issue_redeem_token( + &self, + _token_name: ManagedBuffer, + _token_ticker: ManagedBuffer, + _nr_decimals: usize, + ) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(createInitialRedeemTokens)] + fn create_initial_redeem_tokens(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLaunchedTokenId)] + #[storage_mapper("launchedTokenId")] + fn launched_token_id(&self) -> SingleValueMapper; + + #[view(getAcceptedTokenId)] + #[storage_mapper("acceptedTokenId")] + fn accepted_token_id(&self) -> SingleValueMapper; + + #[view(getLaunchedTokenBalance)] + #[storage_mapper("launchedTokenBalance")] + fn launched_token_balance(&self) -> SingleValueMapper; + + #[view(getAcceptedTokenBalance)] + #[storage_mapper("acceptedTokenBalance")] + fn accepted_token_balance(&self) -> SingleValueMapper; + + #[view(getStartBlock)] + #[storage_mapper("startBlock")] + fn start_block(&self) -> SingleValueMapper; + + #[view(getEndBlock)] + #[storage_mapper("endBlock")] + fn end_block(&self) -> SingleValueMapper; + + #[view(getRedeemTokenId)] + #[storage_mapper("redeemTokenId")] + fn redeem_token_id(&self) -> SingleValueMapper; + + #[view(getRedeemTokenTotalCirculatingSupply)] + #[storage_mapper("totalCirculatingSupply")] + fn redeem_token_total_circulating_supply(&self, token_nonce: u64) + -> SingleValueMapper; + + #[view(getMinLaunchedTokenPrice)] + #[storage_mapper("minLaunchedTokenPrice")] + fn min_launched_token_price(&self) -> SingleValueMapper; + + #[view(getPricePrecision)] + #[storage_mapper("pricePrecision")] + fn price_precision(&self) -> SingleValueMapper; + + #[view(getNoLimitPhaseDurationBlocks)] + #[storage_mapper("noLimitPhaseDurationBlocks")] + fn no_limit_phase_duration_blocks(&self) -> SingleValueMapper; + + #[view(getLinearPenaltyPhaseDurationBlocks)] + #[storage_mapper("linearPenaltyPhaseDurationBlocks")] + fn linear_penalty_phase_duration_blocks(&self) -> SingleValueMapper; + + #[view(getFixedPenaltyPhaseDurationBlocks)] + #[storage_mapper("fixedPenaltyPhaseDurationBlocks")] + fn fixed_penalty_phase_duration_blocks(&self) -> SingleValueMapper; + + #[view(getPenaltyMinPercentage)] + #[storage_mapper("penaltyMinPercentage")] + fn penalty_min_percentage(&self) -> SingleValueMapper; + + #[view(getPenaltyMaxPercentage)] + #[storage_mapper("penaltyMaxPercentage")] + fn penalty_max_percentage(&self) -> SingleValueMapper; + + #[view(getFixedPenaltyPercentage)] + #[storage_mapper("fixedPenaltyPercentage")] + fn fixed_penalty_percentage(&self) -> SingleValueMapper; +} diff --git a/legacy-contracts/price-discovery-v1/wasm/Cargo.lock b/legacy-contracts/price-discovery-v1/wasm/Cargo.lock new file mode 100644 index 000000000..82df55d0c --- /dev/null +++ b/legacy-contracts/price-discovery-v1/wasm/Cargo.lock @@ -0,0 +1,188 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "price-discovery-v1" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "price-discovery-v1-wasm" +version = "0.0.0" +dependencies = [ + "multiversx-sc-wasm-adapter", + "price-discovery-v1", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/legacy-contracts/price-discovery-v1/wasm/Cargo.toml b/legacy-contracts/price-discovery-v1/wasm/Cargo.toml new file mode 100644 index 000000000..458d208f7 --- /dev/null +++ b/legacy-contracts/price-discovery-v1/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "price-discovery-v1-wasm" +version = "0.0.0" +edition = "2021" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.price-discovery-v1] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "0.50.5" + +[workspace] +members = ["."] diff --git a/legacy-contracts/price-discovery-v1/wasm/src/lib.rs b/legacy-contracts/price-discovery-v1/wasm/src/lib.rs new file mode 100644 index 000000000..638f4282c --- /dev/null +++ b/legacy-contracts/price-discovery-v1/wasm/src/lib.rs @@ -0,0 +1,47 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 23 +// Async Callback (empty): 1 +// Total number of exported functions: 25 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + price_discovery_v1 + ( + init => init + deposit => deposit + withdraw => withdraw + redeem => redeem + getCurrentPrice => calculate_price + getCurrentPhase => get_current_phase + issueRedeemToken => issue_redeem_token + createInitialRedeemTokens => create_initial_redeem_tokens + getLaunchedTokenId => launched_token_id + getAcceptedTokenId => accepted_token_id + getLaunchedTokenBalance => launched_token_balance + getAcceptedTokenBalance => accepted_token_balance + getStartBlock => start_block + getEndBlock => end_block + getRedeemTokenId => redeem_token_id + getRedeemTokenTotalCirculatingSupply => redeem_token_total_circulating_supply + getMinLaunchedTokenPrice => min_launched_token_price + getPricePrecision => price_precision + getNoLimitPhaseDurationBlocks => no_limit_phase_duration_blocks + getLinearPenaltyPhaseDurationBlocks => linear_penalty_phase_duration_blocks + getFixedPenaltyPhaseDurationBlocks => fixed_penalty_phase_duration_blocks + getPenaltyMinPercentage => penalty_min_percentage + getPenaltyMaxPercentage => penalty_max_percentage + getFixedPenaltyPercentage => fixed_penalty_percentage + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} diff --git a/legacy-contracts/price-discovery-v2/Cargo.lock b/legacy-contracts/price-discovery-v2/Cargo.lock new file mode 100644 index 000000000..07b1eab79 --- /dev/null +++ b/legacy-contracts/price-discovery-v2/Cargo.lock @@ -0,0 +1,2593 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "Inflector" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" +dependencies = [ + "lazy_static", + "regex", +] + +[[package]] +name = "addr2line" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" + +[[package]] +name = "ahash" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" +dependencies = [ + "cfg-if", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +dependencies = [ + "memchr", +] + +[[package]] +name = "anstream" +version = "0.6.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" +dependencies = [ + "anstyle", + "anstyle-parse", + "anstyle-query", + "anstyle-wincon", + "colorchoice", + "is_terminal_polyfill", + "utf8parse", +] + +[[package]] +name = "anstyle" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" + +[[package]] +name = "anstyle-parse" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" +dependencies = [ + "utf8parse", +] + +[[package]] +name = "anstyle-query" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "anstyle-wincon" +version = "3.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" +dependencies = [ + "anstyle", + "windows-sys 0.52.0", +] + +[[package]] +name = "anyhow" +version = "1.0.86" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" + +[[package]] +name = "arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "backtrace" +version = "0.3.73" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" +dependencies = [ + "addr2line", + "cc", + "cfg-if", + "libc", + "miniz_oxide", + "object", + "rustc-demangle", +] + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "bech32" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" + +[[package]] +name = "bip39" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" +dependencies = [ + "bitcoin_hashes", + "rand 0.8.5", + "rand_core 0.6.4", + "serde", + "unicode-normalization", +] + +[[package]] +name = "bitcoin_hashes" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "block-buffer" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "bstr" +version = "1.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" +dependencies = [ + "memchr", + "serde", +] + +[[package]] +name = "bumpalo" +version = "3.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" + +[[package]] +name = "cc" +version = "1.0.104" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" + +[[package]] +name = "cfg-if" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" + +[[package]] +name = "clap" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" +dependencies = [ + "clap_builder", + "clap_derive", +] + +[[package]] +name = "clap_builder" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" +dependencies = [ + "anstream", + "anstyle", + "clap_lex", + "strsim", +] + +[[package]] +name = "clap_derive" +version = "4.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "clap_lex" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" + +[[package]] +name = "colorchoice" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" + +[[package]] +name = "colored" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" +dependencies = [ + "lazy_static", + "windows-sys 0.48.0", +] + +[[package]] +name = "common-path" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" + +[[package]] +name = "convert_case" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "copy_dir" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" +dependencies = [ + "walkdir", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" + +[[package]] +name = "cpufeatures" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +dependencies = [ + "libc", +] + +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" + +[[package]] +name = "crypto-common" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "curve25519-dalek" +version = "3.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" +dependencies = [ + "byteorder", + "digest 0.9.0", + "rand_core 0.5.1", + "subtle", + "zeroize", +] + +[[package]] +name = "derive_arbitrary" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "digest" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" +dependencies = [ + "generic-array", +] + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer 0.10.4", + "crypto-common", + "subtle", +] + +[[package]] +name = "displaydoc" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "ed25519" +version = "1.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" +dependencies = [ + "signature", +] + +[[package]] +name = "ed25519-dalek" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" +dependencies = [ + "curve25519-dalek", + "ed25519", + "rand 0.7.3", + "serde", + "sha2 0.9.9", + "zeroize", +] + +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + +[[package]] +name = "encoding_rs" +version = "0.8.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "equivalent" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "farm-v-13" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "multiversx-sc-scenario", + "num-bigint", +] + +[[package]] +name = "farm-v-13-meta" +version = "0.0.0" +dependencies = [ + "farm-v-13", + "multiversx-sc-meta", +] + +[[package]] +name = "fastrand" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" + +[[package]] +name = "flate2" +version = "1.0.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foreign-types" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +dependencies = [ + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-shared" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" + +[[package]] +name = "form_urlencoded" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures-channel" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" + +[[package]] +name = "futures-io" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" + +[[package]] +name = "futures-sink" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" + +[[package]] +name = "futures-task" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-util" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" +dependencies = [ + "futures-core", + "futures-io", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "pin-utils", + "slab", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "getrandom" +version = "0.1.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.9.0+wasi-snapshot-preview1", +] + +[[package]] +name = "getrandom" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" +dependencies = [ + "cfg-if", + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", +] + +[[package]] +name = "gimli" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" + +[[package]] +name = "globset" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" +dependencies = [ + "aho-corasick", + "bstr", + "log", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "h2" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" +dependencies = [ + "atomic-waker", + "bytes", + "fnv", + "futures-core", + "futures-sink", + "http", + "indexmap", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" +dependencies = [ + "ahash", + "serde", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "http" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" +dependencies = [ + "bytes", + "fnv", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" +dependencies = [ + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "hyper" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "h2", + "http", + "http-body", + "httparse", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +dependencies = [ + "futures-util", + "http", + "hyper", + "hyper-util", + "rustls", + "rustls-pki-types", + "tokio", + "tokio-rustls", + "tower-service", +] + +[[package]] +name = "hyper-tls" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" +dependencies = [ + "bytes", + "http-body-util", + "hyper", + "hyper-util", + "native-tls", + "tokio", + "tokio-native-tls", + "tower-service", +] + +[[package]] +name = "hyper-util" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" +dependencies = [ + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "pin-project-lite", + "socket2", + "tokio", + "tower", + "tower-service", + "tracing", +] + +[[package]] +name = "idna" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + +[[package]] +name = "ignore" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" +dependencies = [ + "crossbeam-deque", + "globset", + "log", + "memchr", + "regex-automata", + "same-file", + "walkdir", + "winapi-util", +] + +[[package]] +name = "indexmap" +version = "2.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" +dependencies = [ + "equivalent", + "hashbrown", + "serde", +] + +[[package]] +name = "ipnet" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" + +[[package]] +name = "is_terminal_polyfill" +version = "1.70.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" + +[[package]] +name = "itertools" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" + +[[package]] +name = "js-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +dependencies = [ + "wasm-bindgen", +] + +[[package]] +name = "keccak" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" +dependencies = [ + "cpufeatures", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + +[[package]] +name = "libc" +version = "0.2.155" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" + +[[package]] +name = "linux-raw-sys" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" + +[[package]] +name = "lock_api" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" +dependencies = [ + "autocfg", + "scopeguard", +] + +[[package]] +name = "lockfree-object-pool" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" + +[[package]] +name = "log" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "memchr" +version = "2.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" + +[[package]] +name = "mime" +version = "0.3.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" + +[[package]] +name = "miniz_oxide" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" +dependencies = [ + "adler", +] + +[[package]] +name = "mio" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" +dependencies = [ + "libc", + "wasi 0.11.0+wasi-snapshot-preview1", + "windows-sys 0.48.0", +] + +[[package]] +name = "multiversx-chain-scenario-format" +version = "0.22.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" +dependencies = [ + "bech32", + "hex", + "num-bigint", + "num-traits", + "serde", + "serde_json", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" +dependencies = [ + "bitflags 2.5.0", + "colored", + "ed25519-dalek", + "hex", + "hex-literal", + "itertools", + "multiversx-chain-vm-executor", + "num-bigint", + "num-traits", + "rand 0.8.5", + "rand_seeder", + "sha2 0.10.8", + "sha3", +] + +[[package]] +name = "multiversx-chain-vm-executor" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags 2.5.0", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "num-bigint", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-meta" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" +dependencies = [ + "clap", + "colored", + "common-path", + "convert_case", + "copy_dir", + "hex", + "lazy_static", + "multiversx-sc", + "pathdiff", + "reqwest", + "ruplacer", + "rustc_version", + "semver", + "serde", + "serde_json", + "toml", + "wasmparser", + "wasmprinter", + "zip", +] + +[[package]] +name = "multiversx-sc-scenario" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" +dependencies = [ + "base64", + "bech32", + "clap", + "colored", + "hex", + "itertools", + "log", + "multiversx-chain-scenario-format", + "multiversx-chain-vm", + "multiversx-chain-vm-executor", + "multiversx-sc", + "multiversx-sc-meta", + "multiversx-sdk", + "num-bigint", + "num-traits", + "pathdiff", + "serde", + "serde_json", + "sha2 0.10.8", + "tokio", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sdk" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" +dependencies = [ + "anyhow", + "base64", + "bech32", + "bip39", + "hex", + "hmac", + "itertools", + "pbkdf2", + "pem", + "rand 0.8.5", + "reqwest", + "serde", + "serde_json", + "serde_repr", + "sha2 0.10.8", + "sha3", + "tokio", + "zeroize", +] + +[[package]] +name = "native-tls" +version = "0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" +dependencies = [ + "libc", + "log", + "openssl", + "openssl-probe", + "openssl-sys", + "schannel", + "security-framework", + "security-framework-sys", + "tempfile", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-bigint" +version = "0.4.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "num_cpus" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" +dependencies = [ + "hermit-abi", + "libc", +] + +[[package]] +name = "object" +version = "0.36.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" +dependencies = [ + "memchr", +] + +[[package]] +name = "once_cell" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" + +[[package]] +name = "opaque-debug" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" + +[[package]] +name = "openssl" +version = "0.10.64" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" +dependencies = [ + "bitflags 2.5.0", + "cfg-if", + "foreign-types", + "libc", + "once_cell", + "openssl-macros", + "openssl-sys", +] + +[[package]] +name = "openssl-macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "openssl-probe" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" + +[[package]] +name = "openssl-sys" +version = "0.9.102" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" +dependencies = [ + "cc", + "libc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "parking_lot" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall", + "smallvec", + "windows-targets 0.52.5", +] + +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + +[[package]] +name = "pbkdf2" +version = "0.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" +dependencies = [ + "digest 0.10.7", +] + +[[package]] +name = "pem" +version = "3.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" +dependencies = [ + "base64", + "serde", +] + +[[package]] +name = "percent-encoding" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" + +[[package]] +name = "pin-project" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pkg-config" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" + +[[package]] +name = "ppv-lite86" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "rand" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" +dependencies = [ + "getrandom 0.1.16", + "libc", + "rand_chacha 0.2.2", + "rand_core 0.5.1", + "rand_hc", +] + +[[package]] +name = "rand" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" +dependencies = [ + "ppv-lite86", + "rand_core 0.5.1", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" +dependencies = [ + "getrandom 0.1.16", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.15", +] + +[[package]] +name = "rand_hc" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" +dependencies = [ + "rand_core 0.5.1", +] + +[[package]] +name = "rand_seeder" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" +dependencies = [ + "rand_core 0.6.4", +] + +[[package]] +name = "redox_syscall" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" +dependencies = [ + "bitflags 2.5.0", +] + +[[package]] +name = "regex" +version = "1.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" + +[[package]] +name = "reqwest" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" +dependencies = [ + "base64", + "bytes", + "encoding_rs", + "futures-channel", + "futures-core", + "futures-util", + "h2", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-rustls", + "hyper-tls", + "hyper-util", + "ipnet", + "js-sys", + "log", + "mime", + "native-tls", + "once_cell", + "percent-encoding", + "pin-project-lite", + "rustls-pemfile", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "system-configuration", + "tokio", + "tokio-native-tls", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "winreg", +] + +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.15", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "ruplacer" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" +dependencies = [ + "Inflector", + "anyhow", + "clap", + "colored", + "ignore", + "regex", +] + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" + +[[package]] +name = "rustc_version" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +dependencies = [ + "bitflags 2.5.0", + "errno", + "libc", + "linux-raw-sys", + "windows-sys 0.52.0", +] + +[[package]] +name = "rustls" +version = "0.23.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-pemfile" +version = "2.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +dependencies = [ + "base64", + "rustls-pki-types", +] + +[[package]] +name = "rustls-pki-types" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" + +[[package]] +name = "rustls-webpki" +version = "0.102.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "ryu" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "schannel" +version = "0.1.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "security-framework" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" +dependencies = [ + "bitflags 2.5.0", + "core-foundation", + "core-foundation-sys", + "libc", + "security-framework-sys", +] + +[[package]] +name = "security-framework-sys" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "semver" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" + +[[package]] +name = "serde" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.203" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.119" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" +dependencies = [ + "indexmap", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "serde_repr" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_spanned" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" +dependencies = [ + "serde", +] + +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "sha2" +version = "0.9.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + +[[package]] +name = "sha2" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" +dependencies = [ + "cfg-if", + "cpufeatures", + "digest 0.10.7", +] + +[[package]] +name = "sha3" +version = "0.10.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" +dependencies = [ + "digest 0.10.7", + "keccak", +] + +[[package]] +name = "signal-hook-registry" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" +dependencies = [ + "libc", +] + +[[package]] +name = "signature" +version = "1.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" + +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + +[[package]] +name = "slab" +version = "0.4.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" +dependencies = [ + "autocfg", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "socket2" +version = "0.5.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +dependencies = [ + "libc", + "windows-sys 0.52.0", +] + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + +[[package]] +name = "strsim" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" + +[[package]] +name = "system-configuration" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +dependencies = [ + "bitflags 1.3.2", + "core-foundation", + "system-configuration-sys", +] + +[[package]] +name = "system-configuration-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "tempfile" +version = "3.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +dependencies = [ + "cfg-if", + "fastrand", + "rustix", + "windows-sys 0.52.0", +] + +[[package]] +name = "thiserror" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tinyvec" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.38.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" +dependencies = [ + "backtrace", + "bytes", + "libc", + "mio", + "num_cpus", + "parking_lot", + "pin-project-lite", + "signal-hook-registry", + "socket2", + "tokio-macros", + "windows-sys 0.48.0", +] + +[[package]] +name = "tokio-macros" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tokio-native-tls" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" +dependencies = [ + "native-tls", + "tokio", +] + +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "0.8.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "toml_edit", +] + +[[package]] +name = "toml_datetime" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" +dependencies = [ + "serde", +] + +[[package]] +name = "toml_edit" +version = "0.22.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" +dependencies = [ + "indexmap", + "serde", + "serde_spanned", + "toml_datetime", + "winnow", +] + +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "futures-core", + "futures-util", + "pin-project", + "pin-project-lite", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + +[[package]] +name = "tower-service" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" + +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "pin-project-lite", + "tracing-core", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "typenum" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" + +[[package]] +name = "unicode-bidi" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unicode-normalization" +version = "0.1.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-segmentation" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" + +[[package]] +name = "url" +version = "2.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", +] + +[[package]] +name = "utf8parse" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.9.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" + +[[package]] +name = "wasi" +version = "0.11.0+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" + +[[package]] +name = "wasm-bindgen" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +dependencies = [ + "cfg-if", + "wasm-bindgen-macro", +] + +[[package]] +name = "wasm-bindgen-backend" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +dependencies = [ + "bumpalo", + "log", + "once_cell", + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.42" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" +dependencies = [ + "cfg-if", + "js-sys", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-backend", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.92" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" + +[[package]] +name = "wasmparser" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" +dependencies = [ + "ahash", + "bitflags 2.5.0", + "hashbrown", + "indexmap", + "semver", + "serde", +] + +[[package]] +name = "wasmprinter" +version = "0.208.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" +dependencies = [ + "anyhow", + "wasmparser", +] + +[[package]] +name = "web-sys" +version = "0.3.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "winapi-util" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" +dependencies = [ + "windows-sys 0.52.0", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.5", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" +dependencies = [ + "windows_aarch64_gnullvm 0.52.5", + "windows_aarch64_msvc 0.52.5", + "windows_i686_gnu 0.52.5", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.5", + "windows_x86_64_gnu 0.52.5", + "windows_x86_64_gnullvm 0.52.5", + "windows_x86_64_msvc 0.52.5", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" + +[[package]] +name = "winnow" +version = "0.6.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" +dependencies = [ + "memchr", +] + +[[package]] +name = "winreg" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if", + "windows-sys 0.48.0", +] + +[[package]] +name = "zerocopy" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zeroize" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" +dependencies = [ + "zeroize_derive", +] + +[[package]] +name = "zeroize_derive" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zip" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" +dependencies = [ + "arbitrary", + "crc32fast", + "crossbeam-utils", + "displaydoc", + "flate2", + "indexmap", + "memchr", + "thiserror", + "zopfli", +] + +[[package]] +name = "zopfli" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" +dependencies = [ + "bumpalo", + "crc32fast", + "lockfree-object-pool", + "log", + "once_cell", + "simd-adler32", +] diff --git a/legacy-contracts/price-discovery-v2/Cargo.toml b/legacy-contracts/price-discovery-v2/Cargo.toml new file mode 100644 index 000000000..ab0dddc4b --- /dev/null +++ b/legacy-contracts/price-discovery-v2/Cargo.toml @@ -0,0 +1,18 @@ +[package] +name = "price-discovery-v2" +version = "0.0.0" +authors = ["you"] +edition = "2021" +publish = false + +[lib] +path = "src/lib.rs" + +[dependencies.multiversx-sc] +version = "0.50.5" + +[dev-dependencies] +num-bigint = "0.4" + +[dev-dependencies.multiversx-sc-scenario] +version = "0.50.5" diff --git a/legacy-contracts/price-discovery-v2/meta/Cargo.toml b/legacy-contracts/price-discovery-v2/meta/Cargo.toml new file mode 100644 index 000000000..bb8a32afb --- /dev/null +++ b/legacy-contracts/price-discovery-v2/meta/Cargo.toml @@ -0,0 +1,12 @@ +[package] +name = "price-discovery-v2-meta" +version = "0.0.0" +edition = "2021" +publish = false + +[dependencies.price-discovery-v2] +path = ".." + +[dependencies.multiversx-sc-meta] +version = "0.50.5" +default-features = false diff --git a/legacy-contracts/price-discovery-v2/meta/src/main.rs b/legacy-contracts/price-discovery-v2/meta/src/main.rs new file mode 100644 index 000000000..49e9a3810 --- /dev/null +++ b/legacy-contracts/price-discovery-v2/meta/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + multiversx_sc_meta::cli_main::(); +} diff --git a/legacy-contracts/price-discovery-v2/multiversx.json b/legacy-contracts/price-discovery-v2/multiversx.json new file mode 100644 index 000000000..736553962 --- /dev/null +++ b/legacy-contracts/price-discovery-v2/multiversx.json @@ -0,0 +1,3 @@ +{ + "language": "rust" +} \ No newline at end of file diff --git a/legacy-contracts/price-discovery-v2/src/lib.rs b/legacy-contracts/price-discovery-v2/src/lib.rs new file mode 100644 index 000000000..77563ae78 --- /dev/null +++ b/legacy-contracts/price-discovery-v2/src/lib.rs @@ -0,0 +1,130 @@ +#![no_std] + +use multiversx_sc::derive_imports::*; +use multiversx_sc::imports::*; + +#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, PartialEq)] +pub enum Phase { + Idle, + NoPenalty, + LinearIncreasingPenalty { penalty_percentage: BigUint }, + OnlyWithdrawFixedPenalty { penalty_percentage: BigUint }, + Redeem, +} + +#[multiversx_sc::contract] +pub trait PriceDiscoveryV2 { + #[init] + fn init(&self) {} + + #[payable("*")] + #[endpoint] + fn deposit(&self) -> EsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint] + fn withdraw(&self) -> EgldOrEsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[payable("*")] + #[endpoint] + fn redeem(&self) -> EgldOrEsdtTokenPayment { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getCurrentPrice)] + fn calculate_price(&self) -> BigUint { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getCurrentPhase)] + fn get_current_phase(&self) -> Phase { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[payable("EGLD")] + #[endpoint(issueRedeemToken)] + fn issue_redeem_token( + &self, + _token_name: ManagedBuffer, + _token_ticker: ManagedBuffer, + _nr_decimals: usize, + ) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[only_owner] + #[endpoint(createInitialRedeemTokens)] + fn create_initial_redeem_tokens(&self) { + sc_panic!("This is a legacy contract, should not be interacted with"); + } + + #[view(getLaunchedTokenId)] + #[storage_mapper("launchedTokenId")] + fn launched_token_id(&self) -> SingleValueMapper; + + #[view(getAcceptedTokenId)] + #[storage_mapper("acceptedTokenId")] + fn accepted_token_id(&self) -> SingleValueMapper; + + #[view(getLaunchedTokenBalance)] + #[storage_mapper("launchedTokenBalance")] + fn launched_token_balance(&self) -> SingleValueMapper; + + #[view(getAcceptedTokenBalance)] + #[storage_mapper("acceptedTokenBalance")] + fn accepted_token_balance(&self) -> SingleValueMapper; + + #[view(getStartBlock)] + #[storage_mapper("startBlock")] + fn start_block(&self) -> SingleValueMapper; + + #[view(getEndBlock)] + #[storage_mapper("endBlock")] + fn end_block(&self) -> SingleValueMapper; + + #[view(getMinLaunchedTokenPrice)] + #[storage_mapper("minLaunchedTokenPrice")] + fn min_launched_token_price(&self) -> SingleValueMapper; + + #[view(getPricePrecision)] + #[storage_mapper("pricePrecision")] + fn price_precision(&self) -> SingleValueMapper; + + #[view(getNoLimitPhaseDurationBlocks)] + #[storage_mapper("noLimitPhaseDurationBlocks")] + fn no_limit_phase_duration_blocks(&self) -> SingleValueMapper; + + #[view(getLinearPenaltyPhaseDurationBlocks)] + #[storage_mapper("linearPenaltyPhaseDurationBlocks")] + fn linear_penalty_phase_duration_blocks(&self) -> SingleValueMapper; + + #[view(getFixedPenaltyPhaseDurationBlocks)] + #[storage_mapper("fixedPenaltyPhaseDurationBlocks")] + fn fixed_penalty_phase_duration_blocks(&self) -> SingleValueMapper; + + #[view(getPenaltyMinPercentage)] + #[storage_mapper("penaltyMinPercentage")] + fn penalty_min_percentage(&self) -> SingleValueMapper; + + #[view(getPenaltyMaxPercentage)] + #[storage_mapper("penaltyMaxPercentage")] + fn penalty_max_percentage(&self) -> SingleValueMapper; + + #[view(getFixedPenaltyPercentage)] + #[storage_mapper("fixedPenaltyPercentage")] + fn fixed_penalty_percentage(&self) -> SingleValueMapper; + + #[view(getRedeemTokenId)] + #[storage_mapper("redeemTokenId")] + fn redeem_token(&self) -> NonFungibleTokenMapper; + + #[view(getRedeemTokenTotalCirculatingSupply)] + #[storage_mapper("totalCirculatingSupply")] + fn redeem_token_total_circulating_supply(&self, token_nonce: u64) + -> SingleValueMapper; +} diff --git a/legacy-contracts/price-discovery-v2/wasm/Cargo.lock b/legacy-contracts/price-discovery-v2/wasm/Cargo.lock new file mode 100644 index 000000000..635dbdb44 --- /dev/null +++ b/legacy-contracts/price-discovery-v2/wasm/Cargo.lock @@ -0,0 +1,188 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 3 + +[[package]] +name = "arrayvec" +version = "0.7.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" + +[[package]] +name = "autocfg" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" + +[[package]] +name = "bitflags" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" + +[[package]] +name = "endian-type" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hex-literal" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" + +[[package]] +name = "multiversx-sc" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +dependencies = [ + "bitflags", + "hex-literal", + "multiversx-sc-codec", + "multiversx-sc-derive", + "num-traits", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +dependencies = [ + "arrayvec", + "multiversx-sc-codec-derive", + "unwrap-infallible", +] + +[[package]] +name = "multiversx-sc-codec-derive" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "multiversx-sc-derive" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +dependencies = [ + "hex", + "proc-macro2", + "quote", + "radix_trie", + "syn", +] + +[[package]] +name = "multiversx-sc-wasm-adapter" +version = "0.50.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "nibble_vec" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" +dependencies = [ + "smallvec", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", +] + +[[package]] +name = "price-discovery-v2" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "price-discovery-v2-wasm" +version = "0.0.0" +dependencies = [ + "multiversx-sc-wasm-adapter", + "price-discovery-v2", +] + +[[package]] +name = "proc-macro2" +version = "1.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "quote" +version = "1.0.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "radix_trie" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" +dependencies = [ + "endian-type", + "nibble_vec", +] + +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + +[[package]] +name = "syn" +version = "2.0.61" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "unicode-ident" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" + +[[package]] +name = "unwrap-infallible" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" diff --git a/legacy-contracts/price-discovery-v2/wasm/Cargo.toml b/legacy-contracts/price-discovery-v2/wasm/Cargo.toml new file mode 100644 index 000000000..0ca10975d --- /dev/null +++ b/legacy-contracts/price-discovery-v2/wasm/Cargo.toml @@ -0,0 +1,34 @@ +# Code generated by the multiversx-sc build system. DO NOT EDIT. + +# ########################################## +# ############## AUTO-GENERATED ############# +# ########################################## + +[package] +name = "price-discovery-v2-wasm" +version = "0.0.0" +edition = "2021" +publish = false + +[lib] +crate-type = ["cdylib"] + +[profile.release] +codegen-units = 1 +opt-level = "z" +lto = true +debug = false +panic = "abort" +overflow-checks = false + +[profile.dev] +panic = "abort" + +[dependencies.price-discovery-v2] +path = ".." + +[dependencies.multiversx-sc-wasm-adapter] +version = "0.50.5" + +[workspace] +members = ["."] diff --git a/legacy-contracts/price-discovery-v2/wasm/src/lib.rs b/legacy-contracts/price-discovery-v2/wasm/src/lib.rs new file mode 100644 index 000000000..30ec83460 --- /dev/null +++ b/legacy-contracts/price-discovery-v2/wasm/src/lib.rs @@ -0,0 +1,47 @@ +// Code generated by the multiversx-sc build system. DO NOT EDIT. + +//////////////////////////////////////////////////// +////////////////// AUTO-GENERATED ////////////////// +//////////////////////////////////////////////////// + +// Init: 1 +// Endpoints: 23 +// Async Callback (empty): 1 +// Total number of exported functions: 25 + +#![no_std] + +multiversx_sc_wasm_adapter::allocator!(); +multiversx_sc_wasm_adapter::panic_handler!(); + +multiversx_sc_wasm_adapter::endpoints! { + price_discovery_v2 + ( + init => init + deposit => deposit + withdraw => withdraw + redeem => redeem + getCurrentPrice => calculate_price + getCurrentPhase => get_current_phase + issueRedeemToken => issue_redeem_token + createInitialRedeemTokens => create_initial_redeem_tokens + getLaunchedTokenId => launched_token_id + getAcceptedTokenId => accepted_token_id + getLaunchedTokenBalance => launched_token_balance + getAcceptedTokenBalance => accepted_token_balance + getStartBlock => start_block + getEndBlock => end_block + getMinLaunchedTokenPrice => min_launched_token_price + getPricePrecision => price_precision + getNoLimitPhaseDurationBlocks => no_limit_phase_duration_blocks + getLinearPenaltyPhaseDurationBlocks => linear_penalty_phase_duration_blocks + getFixedPenaltyPhaseDurationBlocks => fixed_penalty_phase_duration_blocks + getPenaltyMinPercentage => penalty_min_percentage + getPenaltyMaxPercentage => penalty_max_percentage + getFixedPenaltyPercentage => fixed_penalty_percentage + getRedeemTokenId => redeem_token + getRedeemTokenTotalCirculatingSupply => redeem_token_total_circulating_supply + ) +} + +multiversx_sc_wasm_adapter::async_callback_empty! {} From 28030df5ccb24ccbc22a38044954c6e626259665 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 31 Jul 2024 00:26:10 +0300 Subject: [PATCH 080/103] legacy contracts sc error text change --- legacy-contracts/farm-v12/src/lib.rs | 72 +++++++++--------- .../farm-v13-custom-rewards/src/lib.rs | 76 +++++++++---------- .../farm-v13-locked-rewards/src/lib.rs | 36 ++++----- legacy-contracts/farm-v13/src/lib.rs | 44 +++++------ .../price-discovery-v1/src/lib.rs | 14 ++-- .../price-discovery-v2/src/lib.rs | 14 ++-- 6 files changed, 128 insertions(+), 128 deletions(-) diff --git a/legacy-contracts/farm-v12/src/lib.rs b/legacy-contracts/farm-v12/src/lib.rs index 2623c773f..c126c2135 100644 --- a/legacy-contracts/farm-v12/src/lib.rs +++ b/legacy-contracts/farm-v12/src/lib.rs @@ -22,7 +22,7 @@ pub trait FarmV12 { #[payable("*")] #[endpoint(acceptFee)] fn accept_fee(&self, _token_in: TokenIdentifier, _amount: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(calculateRewardsForGivenPosition)] @@ -31,12 +31,12 @@ pub trait FarmV12 { _amount: BigUint, _attributes_raw: ManagedBuffer, ) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(end_produce_rewards_as_owner)] fn end_produce_rewards_as_owner(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -45,167 +45,167 @@ pub trait FarmV12 { &self, _opt_accept_funds_func: OptionalValue, ) -> ExitFarmResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getBurnedTokenAmount)] fn burned_tokens(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getCurrentBlockFee)] fn current_block_fee_storage(&self) -> Option<(Nonce, BigUint)> { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getDivisionSafetyConstant)] fn division_safety_constant(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmTokenId)] fn farm_token_id(&self) -> TokenIdentifier { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmTokenSupply)] fn get_farm_token_supply(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmingTokenId)] fn farming_token_id(&self) -> TokenIdentifier { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmingTokenReserve)] fn farming_token_reserve(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLastErrorMessage)] fn last_error_message(&self) -> ManagedBuffer { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLastRewardBlockNonce)] fn last_reward_block_nonce(&self) -> Nonce { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLockedAssetFactoryManagedAddress)] fn locked_asset_factory_address(&self) -> ManagedAddress { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLockedRewardAprMuliplier)] fn locked_rewards_apr_multiplier(&self) -> u8 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getMinimumFarmingEpoch)] fn minimum_farming_epoch(&self) -> u8 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getOwner)] fn owner(&self) -> ManagedAddress { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getPairContractManagedAddress)] fn pair_contract_address(&self) -> ManagedAddress { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getPenaltyPercent)] fn penalty_percent(&self) -> u64 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getPerBlockRewardAmount)] fn per_block_reward_amount(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getRewardPerShare)] fn reward_per_share(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getRewardReserve)] fn reward_reserve(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getRewardTokenId)] fn reward_token_id(&self) -> TokenIdentifier { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getRouterManagedAddress)] fn router_address(&self) -> ManagedAddress { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getState)] fn state(&self) -> State { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getTransferExecGasLimit)] fn transfer_exec_gas_limit(&self) -> u64 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getUndistributedFees)] fn undistributed_fee_storage(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(pause)] fn pause(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(resume)] fn resume(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(setPerBlockRewardAmount)] fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(setTransferRoleFarmToken)] fn set_transfer_role_farm_token(&self, _opt_address: OptionalValue) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_locked_rewards_apr_multiplier)] fn set_locked_rewards_apr_multiplier(&self, _muliplier: u8) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_minimum_farming_epochs)] fn set_minimum_farming_epochs(&self, _epochs: u8) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_penalty_percent)] fn set_penalty_percent(&self, _percent: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_transfer_exec_gas_limit)] fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(start_produce_rewards)] fn start_produce_rewards(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } } diff --git a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs index 81a4d4e5a..4708be991 100644 --- a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs @@ -34,7 +34,7 @@ pub trait FarmV13LockedRewards { #[only_owner] #[endpoint(addAddressToWhitelist)] fn add_address_to_whitelist(&self, _address: ManagedAddress) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(calculateRewardsForGivenPosition)] @@ -43,7 +43,7 @@ pub trait FarmV13LockedRewards { _amount: BigUint, _attributes: FarmTokenAttributes, ) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -52,19 +52,19 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> ClaimRewardsResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[payable("*")] #[endpoint(depositRewards)] fn deposit_rewards(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(end_produce_rewards)] fn end_produce_rewards(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -73,7 +73,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> EnterFarmResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -82,97 +82,97 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> ExitFarmResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getBlockForEndRewards)] fn block_for_end_rewards(&self) -> u64 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getBurnGasLimit)] fn burn_gas_limit(&self) -> u64 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getDivisionSafetyConstant)] fn division_safety_constant(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmTokenId)] fn farm_token_id(&self) -> TokenIdentifier { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmTokenSupply)] fn farm_token_supply(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmingTokenId)] fn farming_token_id(&self) -> TokenIdentifier { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLastErrorMessage)] fn last_error_message(&self) -> ManagedBuffer { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLastRewardBlockNonce)] fn last_reward_block_nonce(&self) -> Nonce { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getMinimumFarmingEpoch)] fn minimum_farming_epochs(&self) -> u8 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getOwner)] fn owner(&self) -> ManagedAddress { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getPenaltyPercent)] fn penalty_percent(&self) -> u64 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getPerBlockRewardAmount)] fn per_block_reward_amount(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getRewardPerShare)] fn reward_per_share(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getRewardReserve)] fn reward_reserve(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getRewardTokenId)] fn reward_token_id(&self) -> TokenIdentifier { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getState)] fn state(&self) -> State { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getTransferExecGasLimit)] fn transfer_exec_gas_limit(&self) -> u64 { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getWhitelist)] fn whitelist(&self) -> UnorderedSetMapper { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -181,12 +181,12 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> EsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(pause)] fn pause(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("EGLD")] @@ -197,58 +197,58 @@ pub trait FarmV13LockedRewards { _token_ticker: ManagedBuffer, _num_decimals: usize, ) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(removeAddressFromWhitelist)] fn remove_address_from_whitelist(&self, _address: ManagedAddress) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(resume)] fn resume(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(setBlockForEndRewards)] fn set_block_for_end_rewards(&self, _block_end: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(setLocalRolesFarmToken)] fn set_local_roles_farm_token(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(setPerBlockRewardAmount)] fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_burn_gas_limit)] fn set_burn_gas_limit(&self, _gas_limit: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_minimum_farming_epochs)] fn set_minimum_farming_epochs(&self, _epochs: u8) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_penalty_percent)] fn set_penalty_percent(&self, _percent: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_transfer_exec_gas_limit)] fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(startProduceRewards)] fn start_produce_rewards(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } } diff --git a/legacy-contracts/farm-v13-locked-rewards/src/lib.rs b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs index 7dc899f89..af7864b21 100644 --- a/legacy-contracts/farm-v13-locked-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs @@ -73,7 +73,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> ExitFarmResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -82,7 +82,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> EsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(calculateRewardsForGivenPosition)] @@ -91,71 +91,71 @@ pub trait FarmV13LockedRewards { _amount: BigUint, _attributes: FarmTokenAttributes, ) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn end_produce_rewards(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(setPerBlockRewardAmount)] fn set_per_block_rewards(&self, _per_block_amount: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_penalty_percent(&self, _percent: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_minimum_farming_epochs(&self, _epochs: u8) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_burn_gas_limit(&self, _gas_limit: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(setRpsAndStartRewards)] fn set_rps_and_start_rewards(&self, _rps: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn pause(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn resume(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(startProduceRewards)] fn start_produce_rewards_as_owner(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(setFarmTokenSupply)] fn set_farm_token_supply(&self, _supply: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] @@ -167,7 +167,7 @@ pub trait FarmV13LockedRewards { _new_farm_address: ManagedAddress, _new_farm_with_lock_address: ManagedAddress, ) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] @@ -179,13 +179,13 @@ pub trait FarmV13LockedRewards { _token_ticker: ManagedBuffer, _num_decimals: usize, ) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(setLocalRolesFarmToken)] fn set_local_roles_farm_token(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -195,7 +195,7 @@ pub trait FarmV13LockedRewards { _old_attrs: FarmTokenAttributesV1_2, _orig_caller: ManagedAddress, ) -> EsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmMigrationConfiguration)] diff --git a/legacy-contracts/farm-v13/src/lib.rs b/legacy-contracts/farm-v13/src/lib.rs index 204a3cfb1..047d6923a 100644 --- a/legacy-contracts/farm-v13/src/lib.rs +++ b/legacy-contracts/farm-v13/src/lib.rs @@ -77,7 +77,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> EnterFarmResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -86,7 +86,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> ExitFarmResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -95,7 +95,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> ClaimRewardsResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -104,7 +104,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> CompoundRewardsResultType { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -113,7 +113,7 @@ pub trait FarmV13LockedRewards { &self, _opt_accept_funds_func: OptionalValue, ) -> EsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(calculateRewardsForGivenPosition)] @@ -122,66 +122,66 @@ pub trait FarmV13LockedRewards { _amount: BigUint, _attributes: FarmTokenAttributes, ) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn end_produce_rewards(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(setPerBlockRewardAmount)] fn set_per_block_rewards(&self, _per_block_amount: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_penalty_percent(&self, _percent: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_minimum_farming_epochs(&self, _epochs: u8) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn set_burn_gas_limit(&self, _gas_limit: u64) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn pause(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint] fn resume(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(startProduceRewards)] fn start_produce_rewards_as_owner(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } - + #[only_owner] #[endpoint(setFarmTokenSupply)] fn set_farm_token_supply(&self, _supply: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] @@ -193,7 +193,7 @@ pub trait FarmV13LockedRewards { _new_farm_address: ManagedAddress, _new_farm_with_lock_address: ManagedAddress, ) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] @@ -205,18 +205,18 @@ pub trait FarmV13LockedRewards { _token_ticker: ManagedBuffer, _num_decimals: usize, ) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(setLocalRolesFarmToken)] fn set_local_roles_farm_token(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(setRpsAndStartRewards)] fn set_rps_and_start_rewards(&self, _rps: BigUint) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] @@ -226,7 +226,7 @@ pub trait FarmV13LockedRewards { _old_attrs: FarmTokenAttributesV1_2, _orig_caller: ManagedAddress, ) -> EsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getFarmMigrationConfiguration)] diff --git a/legacy-contracts/price-discovery-v1/src/lib.rs b/legacy-contracts/price-discovery-v1/src/lib.rs index 1f4852e54..065cfecec 100644 --- a/legacy-contracts/price-discovery-v1/src/lib.rs +++ b/legacy-contracts/price-discovery-v1/src/lib.rs @@ -20,29 +20,29 @@ pub trait PriceDiscoveryV1 { #[payable("*")] #[endpoint] fn deposit(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] #[endpoint] fn withdraw(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] #[endpoint] fn redeem(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getCurrentPrice)] fn calculate_price(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getCurrentPhase)] fn get_current_phase(&self) -> Phase { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] @@ -54,13 +54,13 @@ pub trait PriceDiscoveryV1 { _token_ticker: ManagedBuffer, _nr_decimals: usize, ) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(createInitialRedeemTokens)] fn create_initial_redeem_tokens(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLaunchedTokenId)] diff --git a/legacy-contracts/price-discovery-v2/src/lib.rs b/legacy-contracts/price-discovery-v2/src/lib.rs index 77563ae78..cf63515a3 100644 --- a/legacy-contracts/price-discovery-v2/src/lib.rs +++ b/legacy-contracts/price-discovery-v2/src/lib.rs @@ -20,29 +20,29 @@ pub trait PriceDiscoveryV2 { #[payable("*")] #[endpoint] fn deposit(&self) -> EsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] #[endpoint] fn withdraw(&self) -> EgldOrEsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[payable("*")] #[endpoint] fn redeem(&self) -> EgldOrEsdtTokenPayment { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getCurrentPrice)] fn calculate_price(&self) -> BigUint { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getCurrentPhase)] fn get_current_phase(&self) -> Phase { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] @@ -54,13 +54,13 @@ pub trait PriceDiscoveryV2 { _token_ticker: ManagedBuffer, _nr_decimals: usize, ) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[endpoint(createInitialRedeemTokens)] fn create_initial_redeem_tokens(&self) { - sc_panic!("This is a legacy contract, should not be interacted with"); + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[view(getLaunchedTokenId)] From 6e1623fa576d509596c64da8f2256e5210dd8f5c Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 31 Jul 2024 10:24:30 +0300 Subject: [PATCH 081/103] factory-legacy SC audit updates --- Cargo.lock | 1 + legacy-contracts/factory-legacy/Cargo.toml | 5 +- .../factory-legacy/src/migration.rs | 20 +------ .../factory-legacy/wasm/Cargo.lock | 53 +++++++++++++++++++ 4 files changed, 60 insertions(+), 19 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 43e7acf34..82bd11558 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -763,6 +763,7 @@ version = "0.0.0" dependencies = [ "common_errors", "common_structs", + "energy-factory", "multiversx-sc", "multiversx-sc-modules", "multiversx-sc-scenario", diff --git a/legacy-contracts/factory-legacy/Cargo.toml b/legacy-contracts/factory-legacy/Cargo.toml index bff8b6fa4..f1dee1bb8 100644 --- a/legacy-contracts/factory-legacy/Cargo.toml +++ b/legacy-contracts/factory-legacy/Cargo.toml @@ -24,4 +24,7 @@ path = "../../common/common_structs" path = "../../common/common_errors" [dependencies.token_merge_helper] -path = "../../common/modules/token_merge_helper" \ No newline at end of file +path = "../../common/modules/token_merge_helper" + +[dependencies.energy-factory] +path = "../../locked-asset/energy-factory" \ No newline at end of file diff --git a/legacy-contracts/factory-legacy/src/migration.rs b/legacy-contracts/factory-legacy/src/migration.rs index 393f82a59..653b93aa0 100644 --- a/legacy-contracts/factory-legacy/src/migration.rs +++ b/legacy-contracts/factory-legacy/src/migration.rs @@ -1,23 +1,7 @@ multiversx_sc::imports!(); use common_structs::UnlockEpochAmountPairs; - -mod energy_factory_proxy { - use common_structs::UnlockEpochAmountPairs; - - multiversx_sc::imports!(); - - #[multiversx_sc::proxy] - pub trait EnergyFactoryProxy { - #[endpoint(updateEnergyAfterOldTokenUnlock)] - fn update_energy_after_old_token_unlock( - &self, - original_caller: ManagedAddress, - initial_epoch_amount_pairs: UnlockEpochAmountPairs, - final_epoch_amount_pairs: UnlockEpochAmountPairs, - ); - } -} +use energy_factory::migration::ProxyTrait as _; #[multiversx_sc::module] pub trait LockedTokenMigrationModule: @@ -54,7 +38,7 @@ pub trait LockedTokenMigrationModule: fn new_factory_proxy_builder( &self, sc_address: ManagedAddress, - ) -> energy_factory_proxy::Proxy; + ) -> energy_factory::Proxy; #[storage_mapper("newFactoryAddress")] fn new_factory_address(&self) -> SingleValueMapper; diff --git a/legacy-contracts/factory-legacy/wasm/Cargo.lock b/legacy-contracts/factory-legacy/wasm/Cargo.lock index 50cc43b0b..84827ca96 100644 --- a/legacy-contracts/factory-legacy/wasm/Cargo.lock +++ b/legacy-contracts/factory-legacy/wasm/Cargo.lock @@ -44,12 +44,29 @@ version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" +[[package]] +name = "energy-factory" +version = "0.0.0" +dependencies = [ + "common_structs", + "legacy_token_decode_module", + "math", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "sc_whitelist_module", + "simple-lock", + "unwrappable", + "utils", +] + [[package]] name = "factory-legacy" version = "0.0.0" dependencies = [ "common_errors", "common_structs", + "energy-factory", "multiversx-sc", "multiversx-sc-modules", "token_merge_helper", @@ -82,6 +99,15 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" +[[package]] +name = "legacy_token_decode_module" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "utils", +] + [[package]] name = "math" version = "0.0.0" @@ -210,6 +236,23 @@ dependencies = [ "nibble_vec", ] +[[package]] +name = "sc_whitelist_module" +version = "0.0.0" +dependencies = [ + "common_errors", + "multiversx-sc", +] + +[[package]] +name = "simple-lock" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "multiversx-sc-modules", +] + [[package]] name = "smallvec" version = "1.13.2" @@ -253,3 +296,13 @@ version = "0.0.0" dependencies = [ "multiversx-sc", ] + +[[package]] +name = "utils" +version = "0.0.0" +dependencies = [ + "common_structs", + "fixed-supply-token", + "mergeable", + "multiversx-sc", +] From 75b6fa7019b23ef45f97f097a7523a2f1ee5f95b Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 31 Jul 2024 11:10:58 +0300 Subject: [PATCH 082/103] proxy-dex-legacy audit updates --- Cargo.lock | 4 + .../common-modules/energy-query/src/lib.rs | 3 - .../farm-v13-locked-rewards/src/lib.rs | 2 +- legacy-contracts/proxy-dex-legacy/Cargo.toml | 12 ++ .../proxy-dex-legacy/src/energy.rs | 109 ----------- .../proxy-dex-legacy/src/energy_update.rs | 68 +------ legacy-contracts/proxy-dex-legacy/src/lib.rs | 4 +- .../src/migration_from_v1_2.rs | 116 ----------- .../proxy-dex-legacy/src/proxy_farm.rs | 19 +- .../proxy-dex-legacy/src/proxy_pair.rs | 27 +-- .../proxy-dex-legacy/wasm/Cargo.lock | 183 ++++++++++++++++++ .../proxy-dex-legacy/wasm/src/lib.rs | 9 +- 12 files changed, 218 insertions(+), 338 deletions(-) delete mode 100644 legacy-contracts/proxy-dex-legacy/src/energy.rs delete mode 100644 legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs diff --git a/Cargo.lock b/Cargo.lock index 82bd11558..3b7a33332 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2353,9 +2353,13 @@ name = "proxy-dex-legacy" version = "0.0.0" dependencies = [ "common_structs", + "energy-factory", + "energy-query", "factory-legacy", + "farm-v13-locked-rewards", "multiversx-sc", "multiversx-sc-scenario", + "pair", "token_merge_helper", ] diff --git a/energy-integration/common-modules/energy-query/src/lib.rs b/energy-integration/common-modules/energy-query/src/lib.rs index 4f4e2e7af..00ee89507 100644 --- a/energy-integration/common-modules/energy-query/src/lib.rs +++ b/energy-integration/common-modules/energy-query/src/lib.rs @@ -77,9 +77,6 @@ pub trait EnergyQueryModule { .read_from_address(&energy_factory_address, key) } - #[proxy] - fn energy_factory_proxy(&self, sc_address: ManagedAddress) -> energy_factory::Proxy; - #[view(getEnergyFactoryAddress)] #[storage_mapper("energyFactoryAddress")] fn energy_factory_address(&self) -> SingleValueMapper; diff --git a/legacy-contracts/farm-v13-locked-rewards/src/lib.rs b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs index af7864b21..abd6f7bb8 100644 --- a/legacy-contracts/farm-v13-locked-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs @@ -4,7 +4,7 @@ use multiversx_sc::derive_imports::*; use multiversx_sc::imports::*; type Nonce = u64; -type ExitFarmResultType = +pub type ExitFarmResultType = MultiValue2, EsdtTokenPayment>; #[derive(TopEncode, TopDecode, PartialEq, TypeAbi)] diff --git a/legacy-contracts/proxy-dex-legacy/Cargo.toml b/legacy-contracts/proxy-dex-legacy/Cargo.toml index d91ce9636..0443092ed 100644 --- a/legacy-contracts/proxy-dex-legacy/Cargo.toml +++ b/legacy-contracts/proxy-dex-legacy/Cargo.toml @@ -22,3 +22,15 @@ path = "../../common/modules/token_merge_helper" [dependencies.factory-legacy] path = "../factory-legacy" + +[dependencies.energy-factory] +path = "../../locked-asset/energy-factory" + +[dependencies.energy-query] +path = "../../energy-integration/common-modules/energy-query" + +[dependencies.farm-v13-locked-rewards] +path = "../farm-v13-locked-rewards" + +[dependencies.pair] +path = "../../dex/pair" \ No newline at end of file diff --git a/legacy-contracts/proxy-dex-legacy/src/energy.rs b/legacy-contracts/proxy-dex-legacy/src/energy.rs deleted file mode 100644 index 651bbf544..000000000 --- a/legacy-contracts/proxy-dex-legacy/src/energy.rs +++ /dev/null @@ -1,109 +0,0 @@ -multiversx_sc::imports!(); -multiversx_sc::derive_imports!(); - -use common_structs::Epoch; - -#[derive(TypeAbi, TopEncode, TopDecode, NestedEncode, NestedDecode, Clone, PartialEq, Debug)] -pub struct Energy { - amount: BigInt, - last_update_epoch: Epoch, - total_locked_tokens: BigUint, -} - -impl Default for Energy { - fn default() -> Self { - Self { - amount: BigInt::zero(), - last_update_epoch: 0, - total_locked_tokens: BigUint::zero(), - } - } -} - -impl Energy { - #[inline] - pub fn new( - amount: BigInt, - last_update_epoch: Epoch, - total_locked_tokens: BigUint, - ) -> Self { - Energy { - amount, - last_update_epoch, - total_locked_tokens, - } - } - - pub fn new_zero_energy(current_epoch: Epoch) -> Self { - Self::new(BigInt::zero(), current_epoch, BigUint::zero()) - } - - fn add(&mut self, future_epoch: Epoch, current_epoch: Epoch, amount_per_epoch: &BigUint) { - if current_epoch >= future_epoch { - return; - } - - let epochs_diff = future_epoch - current_epoch; - let energy_added = amount_per_epoch * epochs_diff; - self.amount += BigInt::from(energy_added); - } - - fn subtract(&mut self, past_epoch: Epoch, current_epoch: Epoch, amount_per_epoch: &BigUint) { - if past_epoch >= current_epoch { - return; - } - - let epoch_diff = current_epoch - past_epoch; - let energy_decrease = amount_per_epoch * epoch_diff; - self.amount -= BigInt::from(energy_decrease); - } - - pub fn deplete(&mut self, current_epoch: Epoch) { - if self.last_update_epoch == current_epoch { - return; - } - - if self.total_locked_tokens > 0 { - self.subtract( - self.last_update_epoch, - current_epoch, - &self.total_locked_tokens.clone(), - ); - } - - self.last_update_epoch = current_epoch; - } - - pub fn refund_after_token_unlock( - &mut self, - unlock_amount: &BigUint, - unlock_epoch: Epoch, - current_epoch: Epoch, - ) { - self.add(current_epoch, unlock_epoch, unlock_amount); - self.total_locked_tokens -= unlock_amount; - } - - pub fn deplete_after_early_unlock( - &mut self, - unlock_amount: &BigUint, - unlock_epoch: Epoch, - current_epoch: Epoch, - ) { - self.subtract(current_epoch, unlock_epoch, unlock_amount); - self.total_locked_tokens -= unlock_amount; - } - - pub fn update_after_unlock_any( - &mut self, - unlock_amount: &BigUint, - unlock_epoch: Epoch, - current_epoch: Epoch, - ) { - if unlock_epoch < current_epoch { - self.refund_after_token_unlock(unlock_amount, unlock_epoch, current_epoch); - } else { - self.deplete_after_early_unlock(unlock_amount, unlock_epoch, current_epoch); - } - } -} diff --git a/legacy-contracts/proxy-dex-legacy/src/energy_update.rs b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs index e1bb7725a..880cce46b 100644 --- a/legacy-contracts/proxy-dex-legacy/src/energy_update.rs +++ b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs @@ -2,44 +2,18 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); use common_structs::LockedAssetTokenAttributesEx; +use energy_factory::{energy::Energy, locked_token_transfer::ProxyTrait as _}; use factory_legacy::attr_ex_helper; -use crate::{energy::Energy, proxy_common}; +use crate::proxy_common; static LEGACY_LOCKED_TOKEN_ID_STORAGE_KEY: &[u8] = b"legacyLockedTokenId"; -static USER_ENERGY_STORAGE_KEY: &[u8] = b"userEnergy"; static EXTENDED_ATTRIBUTES_ACTIVATION_NONCE_KEY: &[u8] = b"extended_attributes_activation_nonce"; -mod energy_factory_proxy { - multiversx_sc::imports!(); - use crate::energy_update::Energy; - - #[multiversx_sc::proxy] - pub trait LockedTokenTransferModule { - #[endpoint(setUserEnergyAfterLockedTokenTransfer)] - fn set_user_energy_after_locked_token_transfer( - &self, - user: ManagedAddress, - energy: Energy, - ); - } -} - #[multiversx_sc::module] pub trait EnergyUpdateModule: - proxy_common::ProxyCommonModule + attr_ex_helper::AttrExHelper + proxy_common::ProxyCommonModule + attr_ex_helper::AttrExHelper + energy_query::EnergyQueryModule { - #[only_owner] - #[endpoint(setEnergyFactoryAddress)] - fn set_energy_factory_address(&self, sc_address: ManagedAddress) { - require!( - self.blockchain().is_smart_contract(&sc_address), - "Invalid address" - ); - - self.energy_factory_address().set(&sc_address); - } - fn deduct_energy_from_user( &self, user: &ManagedAddress, @@ -82,33 +56,6 @@ pub trait EnergyUpdateModule: .execute_on_dest_context(); } - fn get_energy_entry(&self, user: &ManagedAddress) -> Energy { - let current_epoch = self.blockchain().get_block_epoch(); - if self.energy_factory_address().is_empty() { - return Energy::new_zero_energy(current_epoch); - } - - let energy_buffer: ManagedBuffer = self.read_storage_from_energy_factory(user); - if !energy_buffer.is_empty() { - let mut user_energy: Energy = Energy::top_decode(energy_buffer) - .unwrap_or_else(|_| sc_panic!("Failed decoding result from energy factory")); - user_energy.deplete(current_epoch); - - user_energy - } else { - Energy::new_zero_energy(current_epoch) - } - } - - fn read_storage_from_energy_factory(&self, user: &ManagedAddress) -> T { - let energy_factory_address = self.energy_factory_address().get(); - let mut key_buffer = ManagedBuffer::new_from_bytes(USER_ENERGY_STORAGE_KEY); - key_buffer.append(user.as_managed_buffer()); - - self.storage_raw() - .read_from_address(&energy_factory_address, key_buffer) - } - fn get_legacy_locked_token_id(&self, energy_factory_addr: &ManagedAddress) -> TokenIdentifier { self.storage_raw().read_from_address( energy_factory_addr, @@ -125,12 +72,5 @@ pub trait EnergyUpdateModule: } #[proxy] - fn energy_factory_proxy( - &self, - sc_address: ManagedAddress, - ) -> energy_factory_proxy::Proxy; - - #[view(getEnergyFactoryAddress)] - #[storage_mapper("energyFactoryAddress")] - fn energy_factory_address(&self) -> SingleValueMapper; + fn energy_factory_proxy(&self, sc_address: ManagedAddress) -> energy_factory::Proxy; } diff --git a/legacy-contracts/proxy-dex-legacy/src/lib.rs b/legacy-contracts/proxy-dex-legacy/src/lib.rs index e62a10190..d5034c31d 100644 --- a/legacy-contracts/proxy-dex-legacy/src/lib.rs +++ b/legacy-contracts/proxy-dex-legacy/src/lib.rs @@ -3,10 +3,8 @@ multiversx_sc::imports!(); multiversx_sc::derive_imports!(); -mod energy; mod energy_update; mod events; -pub mod migration_from_v1_2; pub mod proxy_common; pub mod proxy_farm; mod proxy_pair; @@ -22,9 +20,9 @@ pub trait ProxyDexImpl: + token_merge_helper::TokenMergeHelperModule + events::EventsModule + energy_update::EnergyUpdateModule - + migration_from_v1_2::MigrationModule + transfer_role::TransferRoleModule + attr_ex_helper::AttrExHelper + + energy_query::EnergyQueryModule { #[init] fn init(&self) {} diff --git a/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs b/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs deleted file mode 100644 index 871e42259..000000000 --- a/legacy-contracts/proxy-dex-legacy/src/migration_from_v1_2.rs +++ /dev/null @@ -1,116 +0,0 @@ -multiversx_sc::imports!(); -multiversx_sc::derive_imports!(); - -use common_structs::RawResultWrapper; -use common_structs::RawResultsType; -use factory_legacy::attr_ex_helper; - -use super::events; -use super::proxy_common; -use super::proxy_pair; -use crate::energy_update; -use crate::proxy_common::WrappedFarmTokenAttributes; -use crate::proxy_farm; - -mod farm_v1_2_contract_proxy { - multiversx_sc::imports!(); - - #[multiversx_sc::proxy] - pub trait Farm { - #[payable("*")] - #[endpoint(migrateToNewFarm)] - fn migrate_to_new_farm( - &self, - orig_caller: ManagedAddress, - ) -> MultiValue2, EsdtTokenPayment>; - } -} - -#[multiversx_sc::module] -pub trait MigrationModule: - proxy_farm::ProxyFarmModule - + proxy_common::ProxyCommonModule - + proxy_pair::ProxyPairModule - + token_merge_helper::TokenMergeHelperModule - + events::EventsModule - + energy_update::EnergyUpdateModule - + attr_ex_helper::AttrExHelper -{ - #[payable("*")] - #[endpoint(migrateV1_2Position)] - fn migrate_v1_2_position(&self, farm_address: ManagedAddress) { - self.require_is_intermediated_farm(&farm_address); - self.require_wrapped_farm_token_id_not_empty(); - self.require_wrapped_lp_token_id_not_empty(); - - let (payment_token_id, payment_token_nonce, payment_amount) = - self.call_value().single_esdt().into_tuple(); - let wrapped_farm_token = self.wrapped_farm_token_id().get(); - require!( - payment_token_id == wrapped_farm_token, - "Should only be used with wrapped farm tokens" - ); - require!(payment_amount != 0u64, "Payment amount cannot be zero"); - - // The actual work starts here - let wrapped_farm_token_attrs = - self.get_wrapped_farm_token_attributes(&payment_token_id, payment_token_nonce); - let farm_token_id = wrapped_farm_token_attrs.farm_token_id.clone(); - let farm_token_nonce = wrapped_farm_token_attrs.farm_token_nonce; - let farm_amount = payment_amount.clone(); - - // Get the new farm position from the new contract. - let raw_results: RawResultsType = self - .farm_v1_2_contract_proxy(farm_address) - .migrate_to_new_farm(self.blockchain().get_sc_address()) - .with_esdt_transfer((farm_token_id, farm_token_nonce, farm_amount)) - .execute_on_dest_context(); - - let mut results_wrapper = RawResultWrapper::new(raw_results); - results_wrapper.trim_results_front(2); - - let new_pos: EsdtTokenPayment = results_wrapper.decode_next_result(); - let reward: EsdtTokenPayment = results_wrapper.decode_next_result(); - - // Burn the old proxy farm position - self.send() - .esdt_local_burn(&payment_token_id, payment_token_nonce, &payment_amount); - - // Create a new proxy farm position based on the new farm position. - let new_attrs = WrappedFarmTokenAttributes { - farm_token_id: new_pos.token_identifier.clone(), - farm_token_nonce: new_pos.token_nonce, - farm_token_amount: new_pos.amount.clone(), - farming_token_id: wrapped_farm_token_attrs.farming_token_id, - farming_token_nonce: wrapped_farm_token_attrs.farming_token_nonce, - farming_token_amount: self.rule_of_three_non_zero_result( - &payment_amount, - &wrapped_farm_token_attrs.farm_token_amount, - &wrapped_farm_token_attrs.farming_token_amount, - ), - }; - let new_nonce = - self.send() - .esdt_nft_create_compact(&wrapped_farm_token, &new_pos.amount, &new_attrs); - - let mut payments = ManagedVec::new(); - payments.push(EsdtTokenPayment::new( - wrapped_farm_token, - new_nonce, - new_pos.amount, - )); - - if reward.amount != 0u64 { - payments.push(reward); - } - - let caller = self.blockchain().get_caller(); - self.send().direct_multi(&caller, &payments); - } - - #[proxy] - fn farm_v1_2_contract_proxy( - &self, - to: ManagedAddress, - ) -> farm_v1_2_contract_proxy::Proxy; -} diff --git a/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs b/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs index d875c5486..faa105228 100644 --- a/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs +++ b/legacy-contracts/proxy-dex-legacy/src/proxy_farm.rs @@ -14,19 +14,7 @@ use super::events; use super::proxy_common; use super::proxy_pair; -type ExitFarmResultType = - MultiValue2, EsdtTokenPayment>; - -mod farm_proxy { - multiversx_sc::imports!(); - - #[multiversx_sc::proxy] - pub trait FarmProxy { - #[payable("*")] - #[endpoint(exitFarm)] - fn exit_farm(&self) -> super::ExitFarmResultType; - } -} +use farm_v13_locked_rewards::ExitFarmResultType; #[derive(ManagedVecItem, Clone)] pub struct WrappedFarmToken { @@ -42,6 +30,7 @@ pub trait ProxyFarmModule: + events::EventsModule + energy_update::EnergyUpdateModule + attr_ex_helper::AttrExHelper + + energy_query::EnergyQueryModule { #[only_owner] #[endpoint(addFarmToIntermediate)] @@ -130,7 +119,7 @@ pub trait ProxyFarmModule: ) -> ExitFarmResultType { let raw_results: RawResultsType = self .farm_contract_proxy(farm_address.clone()) - .exit_farm() + .exit_farm(OptionalValue::::None) .with_esdt_transfer((farm_token_id.clone(), farm_token_nonce, amount.clone())) .execute_on_dest_context(); @@ -155,5 +144,5 @@ pub trait ProxyFarmModule: } #[proxy] - fn farm_contract_proxy(&self, to: ManagedAddress) -> farm_proxy::Proxy; + fn farm_contract_proxy(&self, to: ManagedAddress) -> farm_v13_locked_rewards::Proxy; } diff --git a/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs b/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs index c8ec2607c..279343cf4 100644 --- a/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs +++ b/legacy-contracts/proxy-dex-legacy/src/proxy_pair.rs @@ -7,6 +7,9 @@ multiversx_sc::derive_imports!(); use common_structs::{RawResultWrapper, RawResultsType}; use factory_legacy::attr_ex_helper; +use pair::config::ProxyTrait as _; +use pair::pair_actions::common_result_types::RemoveLiquidityResultType; +use pair::pair_actions::remove_liq::ProxyTrait as _; use crate::energy_update; use crate::proxy_common::WrappedLpTokenAttributes; @@ -14,27 +17,6 @@ use crate::proxy_common::WrappedLpTokenAttributes; use super::events; use super::proxy_common; -type RemoveLiquidityResultType = - MultiValue2, EsdtTokenPayment>; - -mod pair_proxy { - multiversx_sc::imports!(); - - #[multiversx_sc::proxy] - pub trait PairProxy { - #[payable("*")] - #[endpoint(removeLiquidity)] - fn remove_liquidity( - &self, - first_token_amount_min: BigUint, - second_token_amount_min: BigUint, - ) -> super::RemoveLiquidityResultType; - - #[view(getLpTokenIdentifier)] - fn get_lp_token_identifier(&self) -> TokenIdentifier; - } -} - #[derive(ManagedVecItem, Clone)] pub struct WrappedLpToken { pub token_amount: EsdtTokenPayment, @@ -48,6 +30,7 @@ pub trait ProxyPairModule: + events::EventsModule + energy_update::EnergyUpdateModule + attr_ex_helper::AttrExHelper + + energy_query::EnergyQueryModule { #[only_owner] #[endpoint(addPairToIntermediate)] @@ -216,5 +199,5 @@ pub trait ProxyPairModule: } #[proxy] - fn pair_contract_proxy(&self, to: ManagedAddress) -> pair_proxy::Proxy; + fn pair_contract_proxy(&self, to: ManagedAddress) -> pair::Proxy; } diff --git a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock index df92fe170..063bdc08a 100644 --- a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock +++ b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock @@ -20,6 +20,13 @@ version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +[[package]] +name = "common-types" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + [[package]] name = "common_errors" version = "0.0.0" @@ -38,23 +45,79 @@ dependencies = [ "unwrappable", ] +[[package]] +name = "either" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" + [[package]] name = "endian-type" version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" +[[package]] +name = "energy-factory" +version = "0.0.0" +dependencies = [ + "common_structs", + "legacy_token_decode_module", + "math", + "mergeable", + "multiversx-sc", + "multiversx-sc-modules", + "sc_whitelist_module", + "simple-lock", + "unwrappable", + "utils", +] + +[[package]] +name = "energy-query" +version = "0.0.0" +dependencies = [ + "energy-factory", + "multiversx-sc", +] + [[package]] name = "factory-legacy" version = "0.0.0" dependencies = [ "common_errors", "common_structs", + "energy-factory", "multiversx-sc", "multiversx-sc-modules", "token_merge_helper", ] +[[package]] +name = "farm-v13-locked-rewards" +version = "0.0.0" +dependencies = [ + "multiversx-sc", +] + +[[package]] +name = "fees-collector" +version = "0.0.0" +dependencies = [ + "common-types", + "common_errors", + "energy-factory", + "energy-query", + "locking_module", + "multiversx-sc", + "multiversx-sc-modules", + "sc_whitelist_module", + "simple-lock", + "utils", + "week-timekeeping", + "weekly-rewards-splitting", +] + [[package]] name = "fixed-supply-token" version = "0.0.0" @@ -74,6 +137,33 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" +[[package]] +name = "itertools" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" +dependencies = [ + "either", +] + +[[package]] +name = "legacy_token_decode_module" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "utils", +] + +[[package]] +name = "locking_module" +version = "0.0.0" +dependencies = [ + "energy-factory", + "multiversx-sc", + "simple-lock", +] + [[package]] name = "math" version = "0.0.0" @@ -174,6 +264,39 @@ dependencies = [ "autocfg", ] +[[package]] +name = "pair" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "fees-collector", + "itertools", + "multiversx-sc", + "pausable", + "permissions_module", + "simple-lock", + "token_send", + "utils", +] + +[[package]] +name = "pausable" +version = "0.0.0" +dependencies = [ + "multiversx-sc", + "permissions_module", +] + +[[package]] +name = "permissions_module" +version = "0.0.0" +dependencies = [ + "bitflags", + "common_errors", + "multiversx-sc", +] + [[package]] name = "proc-macro2" version = "1.0.82" @@ -188,8 +311,12 @@ name = "proxy-dex-legacy" version = "0.0.0" dependencies = [ "common_structs", + "energy-factory", + "energy-query", "factory-legacy", + "farm-v13-locked-rewards", "multiversx-sc", + "pair", "token_merge_helper", ] @@ -220,6 +347,23 @@ dependencies = [ "nibble_vec", ] +[[package]] +name = "sc_whitelist_module" +version = "0.0.0" +dependencies = [ + "common_errors", + "multiversx-sc", +] + +[[package]] +name = "simple-lock" +version = "0.0.0" +dependencies = [ + "common_structs", + "multiversx-sc", + "multiversx-sc-modules", +] + [[package]] name = "smallvec" version = "1.13.2" @@ -245,6 +389,15 @@ dependencies = [ "multiversx-sc", ] +[[package]] +name = "token_send" +version = "0.0.0" +dependencies = [ + "common_errors", + "common_structs", + "multiversx-sc", +] + [[package]] name = "unicode-ident" version = "1.0.12" @@ -263,3 +416,33 @@ version = "0.0.0" dependencies = [ "multiversx-sc", ] + +[[package]] +name = "utils" +version = "0.0.0" +dependencies = [ + "common_structs", + "fixed-supply-token", + "mergeable", + "multiversx-sc", +] + +[[package]] +name = "week-timekeeping" +version = "0.0.0" +dependencies = [ + "common-types", + "multiversx-sc", +] + +[[package]] +name = "weekly-rewards-splitting" +version = "0.0.0" +dependencies = [ + "common-types", + "energy-query", + "math", + "multiversx-sc", + "unwrappable", + "week-timekeeping", +] diff --git a/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs b/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs index 5d418f971..bc4c8d085 100644 --- a/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs +++ b/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 20 +// Endpoints: 19 // Async Callback (empty): 1 -// Total number of exported functions: 22 +// Total number of exported functions: 21 #![no_std] @@ -30,14 +30,13 @@ multiversx_sc_wasm_adapter::endpoints! { addFarmToIntermediate => add_farm_to_intermediate removeIntermediatedFarm => remove_intermediated_farm exitFarmProxy => exit_farm_proxy - setEnergyFactoryAddress => set_energy_factory_address - getEnergyFactoryAddress => energy_factory_address - migrateV1_2Position => migrate_v1_2_position setTransferRoleLockedLpToken => set_transfer_role_locked_lp_token unsetTransferRoleLockedLpToken => unset_transfer_role_locked_lp_token setTransferRoleLockedFarmToken => set_transfer_role_locked_farm_token unsetTransferRoleLockedFarmToken => unset_transfer_role_locked_farm_token getExtendedAttributesActivationNonce => extended_attributes_activation_nonce + setEnergyFactoryAddress => set_energy_factory_address + getEnergyFactoryAddress => energy_factory_address ) } From 04782742190a035e577440cc1122279365b7fe5e Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 31 Jul 2024 13:54:40 +0300 Subject: [PATCH 083/103] remove commented code --- common/modules/farm/config/src/config.rs | 8 +------- energy-integration/fees-collector/src/config.rs | 9 +-------- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/common/modules/farm/config/src/config.rs b/common/modules/farm/config/src/config.rs index 46564e5c0..88858153e 100644 --- a/common/modules/farm/config/src/config.rs +++ b/common/modules/farm/config/src/config.rs @@ -11,13 +11,6 @@ pub const DEFAULT_FARM_POSITION_MIGRATION_NONCE: u64 = 1; #[multiversx_sc::module] pub trait ConfigModule: pausable::PausableModule + permissions_module::PermissionsModule { - // Disabled for this version of the exchange - // #[endpoint(setAllowExternalClaimBoostedRewards)] - // fn set_allow_external_claim(&self, allow_external_claim: bool) { - // let caller = self.blockchain().get_caller(); - // self.allow_external_claim(&caller).set(allow_external_claim); - // } - #[inline] fn is_active(&self) -> bool { let state = self.state().get(); @@ -78,6 +71,7 @@ pub trait ConfigModule: pausable::PausableModule + permissions_module::Permissio #[storage_mapper("userTotalFarmPosition")] fn user_total_farm_position(&self, user: &ManagedAddress) -> SingleValueMapper; + // Update for this storage disabled for this version of the exchange #[view(getAllowExternalClaim)] #[storage_mapper("allowExternalClaim")] fn allow_external_claim(&self, user: &ManagedAddress) -> SingleValueMapper; diff --git a/energy-integration/fees-collector/src/config.rs b/energy-integration/fees-collector/src/config.rs index e65282d17..72fa1fc70 100644 --- a/energy-integration/fees-collector/src/config.rs +++ b/energy-integration/fees-collector/src/config.rs @@ -60,14 +60,6 @@ pub trait ConfigModule { self.all_tokens().set(&all_tokens_vec); } - // Disabled for this version of the exchange - // #[endpoint(setAllowExternalClaimRewards)] - // fn set_allow_external_claim_rewards(&self, allow_external_claim_rewards: bool) { - // let caller = self.blockchain().get_caller(); - // self.allow_external_claim_rewards(&caller) - // .set(allow_external_claim_rewards); - // } - #[view(getLockedTokenId)] #[storage_mapper("lockedTokenId")] fn locked_token_id(&self) -> SingleValueMapper; @@ -87,6 +79,7 @@ pub trait ConfigModule { #[storage_mapper("allTokens")] fn all_tokens(&self) -> SingleValueMapper>; + // Update for this storage disabled for this version of the exchange #[view(getAllowExternalClaimRewards)] #[storage_mapper("allowExternalClaimRewards")] fn allow_external_claim_rewards(&self, user: &ManagedAddress) -> SingleValueMapper; From 2ca12e41de740c578476d2b8ebe9b0cfa1287012 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 1 Aug 2024 13:18:56 +0300 Subject: [PATCH 084/103] farm supply for week fix. incl claimBoosted aggr --- dex/farm-with-locked-rewards/src/lib.rs | 6 ++ dex/farm/src/lib.rs | 5 ++ dex/farm/tests/total_farm_position_test.rs | 58 +++++++++++++++++++ .../src/claim_only_boosted_staking_rewards.rs | 8 +++ .../src/claim_stake_farm_rewards.rs | 4 +- 5 files changed, 79 insertions(+), 2 deletions(-) diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index 91144b387..84d7dc7f4 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -237,7 +237,13 @@ pub trait Farm: ); } + let mut storage_cache = StorageCache::new(self); + NoMintWrapper::::generate_aggregated_rewards(self, &mut storage_cache); + let boosted_rewards = self.claim_only_boosted_payment(user); + + self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); + self.send_to_lock_contract_non_zero( self.reward_token_id().get(), boosted_rewards, diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 08d447830..211b05e02 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -228,10 +228,15 @@ pub trait Farm: ); } + let mut storage_cache = StorageCache::new(self); + Wrapper::::generate_aggregated_rewards(self, &mut storage_cache); + let boosted_rewards = self.claim_only_boosted_payment(user); let boosted_rewards_payment = EsdtTokenPayment::new(self.reward_token_id().get(), 0, boosted_rewards); + self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); + self.send_payment_non_zero(user, &boosted_rewards_payment); boosted_rewards_payment diff --git a/dex/farm/tests/total_farm_position_test.rs b/dex/farm/tests/total_farm_position_test.rs index b7ca1be7b..e0819d411 100644 --- a/dex/farm/tests/total_farm_position_test.rs +++ b/dex/farm/tests/total_farm_position_test.rs @@ -1193,3 +1193,61 @@ fn total_farm_position_through_simple_lock_test() { &rust_biguint!(first_received_reward_amt), ); } + +#[test] +fn claim_only_boosted_rewards_per_week_test() { + DebugApi::dummy(); + let mut farm_setup = MultiUserFarmSetup::new( + farm::contract_obj, + energy_factory_mock::contract_obj, + energy_update::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + let temp_user = farm_setup.third_user.clone(); + + // first user enter farm + let farm_in_amount = 100_000_000; + let first_user = farm_setup.first_user.clone(); + farm_setup.set_user_energy(&first_user, 1_000, 2, 1); + farm_setup.enter_farm(&first_user, farm_in_amount); + + farm_setup.check_farm_token_supply(farm_in_amount); + + farm_setup.b_mock.set_block_nonce(10); + farm_setup.b_mock.set_block_epoch(6); + farm_setup.set_user_energy(&first_user, 1_000, 6, 1); + farm_setup.set_user_energy(&temp_user, 1, 6, 1); + farm_setup.enter_farm(&temp_user, 1); + farm_setup.exit_farm(&temp_user, 2, 1); + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 13, 1); + farm_setup.b_mock.set_block_nonce(20); + farm_setup.b_mock.set_block_epoch(13); + + let boosted_rewards = 2_500; + let second_week_received_reward_amt = + farm_setup.claim_boosted_rewards_for_user(&first_user, &first_user); + + assert_eq!(second_week_received_reward_amt, boosted_rewards); + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 15, 1); + farm_setup.b_mock.set_block_nonce(30); + farm_setup.b_mock.set_block_epoch(15); + let third_week_received_reward_amt = + farm_setup.claim_boosted_rewards_for_user(&first_user, &first_user); + + // Should be equal to half base generated rewards + full boosted generated rewards + assert_eq!(third_week_received_reward_amt, boosted_rewards); + + farm_setup.b_mock.check_esdt_balance( + &first_user, + REWARD_TOKEN_ID, + &rust_biguint!(boosted_rewards * 2), + ); +} diff --git a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs index a1843a1f6..79d433dfe 100644 --- a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs +++ b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs @@ -1,3 +1,6 @@ +use contexts::storage_cache::StorageCache; +use farm_base_impl::base_traits_impl::FarmContract; + use crate::base_impl_wrapper::FarmStakingWrapper; multiversx_sc::imports!(); @@ -38,10 +41,15 @@ pub trait ClaimOnlyBoostedStakingRewardsModule: ); } + let mut storage_cache = StorageCache::new(self); + FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); + let boosted_rewards = self.claim_only_boosted_payment(user); let boosted_rewards_payment = EsdtTokenPayment::new(self.reward_token_id().get(), 0, boosted_rewards); + self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); + self.send_payment_non_zero(user, &boosted_rewards_payment); boosted_rewards_payment diff --git a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs index 14aa23da7..e2ba49fe4 100644 --- a/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs +++ b/farm-staking/farm-staking/src/claim_stake_farm_rewards.rs @@ -82,10 +82,10 @@ pub trait ClaimStakeFarmRewardsModule: virtual_farm_token.payment.amount = new_amount.clone(); virtual_farm_token.attributes.current_farm_amount = new_amount; - - self.set_farm_supply_for_current_week(&claim_result.storage_cache.farm_token_supply); } + self.set_farm_supply_for_current_week(&claim_result.storage_cache.farm_token_supply); + self.update_energy_and_progress(&original_caller); let new_farm_token_nonce = self.send().esdt_nft_create_compact( From f668405802716a1995882d3fffbf39d175fd24b6 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Thu, 1 Aug 2024 13:52:54 +0300 Subject: [PATCH 085/103] farm supply on claim fix for farm with locked rew --- dex/farm-with-locked-rewards/src/lib.rs | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index 84d7dc7f4..e03cb80fe 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -127,30 +127,19 @@ pub trait Farm: self.migrate_old_farm_positions(&orig_caller); - let payments = self.call_value().all_esdt_transfers().clone_value(); - let base_claim_rewards_result = - self.claim_rewards_base::>(orig_caller.clone(), payments); - let output_farm_token_payment = base_claim_rewards_result.new_farm_token.payment.clone(); - self.send_payment_non_zero(&caller, &output_farm_token_payment); + let claim_rewards_result = self.claim_rewards::>(orig_caller.clone()); - let rewards_payment = base_claim_rewards_result.rewards; + self.send_payment_non_zero(&caller, &claim_rewards_result.new_farm_token); + + let rewards_payment = claim_rewards_result.rewards; let locked_rewards_payment = self.send_to_lock_contract_non_zero( rewards_payment.token_identifier, rewards_payment.amount, caller, - orig_caller.clone(), - ); - - self.emit_claim_rewards_event::<_, FarmTokenAttributes>( - &orig_caller, - base_claim_rewards_result.context, - base_claim_rewards_result.new_farm_token, - locked_rewards_payment.clone(), - base_claim_rewards_result.created_with_merge, - base_claim_rewards_result.storage_cache, + orig_caller, ); - (output_farm_token_payment, locked_rewards_payment).into() + (claim_rewards_result.new_farm_token, locked_rewards_payment).into() } #[payable("*")] From a907b89b64f9efdeebebb8a5144c9a9b5fc4cd0e Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 11:34:22 +0300 Subject: [PATCH 086/103] add rewards aggregation in merge endpoints --- dex/farm-with-locked-rewards/src/lib.rs | 2 ++ dex/farm/src/base_functions.rs | 7 +++++++ dex/farm/src/lib.rs | 2 ++ .../src/claim_only_boosted_staking_rewards.rs | 1 + farm-staking/farm-staking/src/custom_rewards.rs | 4 ++++ farm-staking/farm-staking/src/lib.rs | 8 ++++++++ farm-staking/farm-staking/src/unbond_farm.rs | 8 ++++++-- 7 files changed, 30 insertions(+), 2 deletions(-) diff --git a/dex/farm-with-locked-rewards/src/lib.rs b/dex/farm-with-locked-rewards/src/lib.rs index e03cb80fe..972ddbbd7 100644 --- a/dex/farm-with-locked-rewards/src/lib.rs +++ b/dex/farm-with-locked-rewards/src/lib.rs @@ -227,6 +227,7 @@ pub trait Farm: } let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); NoMintWrapper::::generate_aggregated_rewards(self, &mut storage_cache); let boosted_rewards = self.claim_only_boosted_payment(user); @@ -265,6 +266,7 @@ pub trait Farm: require!(percentage <= MAX_PERCENT, "Invalid percentage"); let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); NoMintWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.boosted_yields_rewards_percentage().set(percentage); diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index d6455a2b7..dad01984e 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -192,6 +192,13 @@ pub trait BaseFunctionsModule: FC::check_and_update_user_farm_position(self, orig_caller, &payments); + let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); + + FC::generate_aggregated_rewards(self, &mut storage_cache); + + self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); + self.merge_from_payments_and_burn(payments, &token_mapper) } diff --git a/dex/farm/src/lib.rs b/dex/farm/src/lib.rs index 211b05e02..aeabcaaa0 100644 --- a/dex/farm/src/lib.rs +++ b/dex/farm/src/lib.rs @@ -229,6 +229,7 @@ pub trait Farm: } let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); Wrapper::::generate_aggregated_rewards(self, &mut storage_cache); let boosted_rewards = self.claim_only_boosted_payment(user); @@ -266,6 +267,7 @@ pub trait Farm: require!(percentage <= MAX_PERCENT, "Invalid percentage"); let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); Wrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.boosted_yields_rewards_percentage().set(percentage); diff --git a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs index 79d433dfe..4969f3ddb 100644 --- a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs +++ b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs @@ -42,6 +42,7 @@ pub trait ClaimOnlyBoostedStakingRewardsModule: } let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); let boosted_rewards = self.claim_only_boosted_payment(user); diff --git a/farm-staking/farm-staking/src/custom_rewards.rs b/farm-staking/farm-staking/src/custom_rewards.rs index 4d07dd5a4..024b8c5e2 100644 --- a/farm-staking/farm-staking/src/custom_rewards.rs +++ b/farm-staking/farm-staking/src/custom_rewards.rs @@ -51,6 +51,7 @@ pub trait CustomRewardsModule: self.require_caller_has_admin_permissions(); let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); let reward_capacity_mapper = self.reward_capacity(); @@ -80,6 +81,7 @@ pub trait CustomRewardsModule: self.require_caller_has_admin_permissions(); let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.produce_rewards_enabled().set(false); } @@ -90,6 +92,7 @@ pub trait CustomRewardsModule: require!(per_block_amount != 0, "Amount cannot be zero"); let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.per_block_reward_amount().set(&per_block_amount); } @@ -100,6 +103,7 @@ pub trait CustomRewardsModule: require!(max_apr != 0, "Max APR cannot be zero"); let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.max_annual_percentage_rewards().set(&max_apr); } diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index f783c7831..9cf4b1228 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -144,6 +144,13 @@ pub trait FarmStaking: FC::check_and_update_user_farm_position(self, orig_caller, &payments); + let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); + + FC::generate_aggregated_rewards(self, &mut storage_cache); + + self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); + self.merge_from_payments_and_burn(payments, &token_mapper) } @@ -153,6 +160,7 @@ pub trait FarmStaking: require!(percentage <= MAX_PERCENT, "Invalid percentage"); let mut storage_cache = StorageCache::new(self); + self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.boosted_yields_rewards_percentage().set(percentage); diff --git a/farm-staking/farm-staking/src/unbond_farm.rs b/farm-staking/farm-staking/src/unbond_farm.rs index 7e85a2a2c..ec2044897 100644 --- a/farm-staking/farm-staking/src/unbond_farm.rs +++ b/farm-staking/farm-staking/src/unbond_farm.rs @@ -1,8 +1,9 @@ multiversx_sc::imports!(); use contexts::storage_cache::StorageCache; +use farm_base_impl::base_traits_impl::FarmContract; -use crate::token_attributes::UnbondSftAttributes; +use crate::{base_impl_wrapper::FarmStakingWrapper, token_attributes::UnbondSftAttributes}; #[multiversx_sc::module] pub trait UnbondFarmModule: @@ -32,7 +33,7 @@ pub trait UnbondFarmModule: #[payable("*")] #[endpoint(unbondFarm)] fn unbond_farm(&self) -> EsdtTokenPayment { - let storage_cache = StorageCache::new(self); + let mut storage_cache = StorageCache::new(self); self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); let farm_token_mapper = self.farm_token(); @@ -48,6 +49,9 @@ pub trait UnbondFarmModule: "Unbond period not over" ); + FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); + self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); + farm_token_mapper.nft_burn(payment.token_nonce, &payment.amount); let caller = self.blockchain().get_caller(); From 3464f856e0ef3cbf573ed71e1848b00fc5245f15 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 12:02:57 +0300 Subject: [PATCH 087/103] remove validation checks from farm staking SC --- .../farm-staking/src/claim_only_boosted_staking_rewards.rs | 1 - farm-staking/farm-staking/src/custom_rewards.rs | 4 ---- 2 files changed, 5 deletions(-) diff --git a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs index 4969f3ddb..79d433dfe 100644 --- a/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs +++ b/farm-staking/farm-staking/src/claim_only_boosted_staking_rewards.rs @@ -42,7 +42,6 @@ pub trait ClaimOnlyBoostedStakingRewardsModule: } let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); let boosted_rewards = self.claim_only_boosted_payment(user); diff --git a/farm-staking/farm-staking/src/custom_rewards.rs b/farm-staking/farm-staking/src/custom_rewards.rs index 024b8c5e2..4d07dd5a4 100644 --- a/farm-staking/farm-staking/src/custom_rewards.rs +++ b/farm-staking/farm-staking/src/custom_rewards.rs @@ -51,7 +51,6 @@ pub trait CustomRewardsModule: self.require_caller_has_admin_permissions(); let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); let reward_capacity_mapper = self.reward_capacity(); @@ -81,7 +80,6 @@ pub trait CustomRewardsModule: self.require_caller_has_admin_permissions(); let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.produce_rewards_enabled().set(false); } @@ -92,7 +90,6 @@ pub trait CustomRewardsModule: require!(per_block_amount != 0, "Amount cannot be zero"); let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.per_block_reward_amount().set(&per_block_amount); } @@ -103,7 +100,6 @@ pub trait CustomRewardsModule: require!(max_apr != 0, "Max APR cannot be zero"); let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.max_annual_percentage_rewards().set(&max_apr); } From 88dd12bb4fe8184729545f95e4659602dc067819 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 14:10:50 +0300 Subject: [PATCH 088/103] farm with locked rewards unit tests --- .../farm_with_locked_rewards_setup/mod.rs | 87 +++++++ .../tests/farm_with_locked_rewards_test.rs | 233 ++++++++++++++++++ dex/farm/tests/total_farm_position_test.rs | 58 ----- 3 files changed, 320 insertions(+), 58 deletions(-) diff --git a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs index 7125f474b..98c8837ee 100644 --- a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs +++ b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs @@ -8,6 +8,7 @@ use multiversx_sc::{ types::{Address, BigInt, EsdtLocalRole, MultiValueEncoded}, }; use multiversx_sc_scenario::{ + imports::TxTokenTransfer, managed_address, managed_biguint, managed_token_id, rust_biguint, whitebox_legacy::{BlockchainStateWrapper, ContractObjWrapper}, DebugApi, @@ -24,6 +25,7 @@ use farm_with_locked_rewards::Farm; use locking_module::lock_with_energy_module::LockWithEnergyModule; use multiversx_sc_modules::pause::PauseModule; use pausable::{PausableModule, State}; +use rewards::RewardsModule; use sc_whitelist_module::SCWhitelistModule; use simple_lock::locked_token::LockedTokenModule; use week_timekeeping::Epoch; @@ -48,6 +50,11 @@ pub const EPOCHS_IN_YEAR: u64 = 360; pub static LOCK_OPTIONS: &[u64] = &[EPOCHS_IN_YEAR, 2 * EPOCHS_IN_YEAR, 4 * EPOCHS_IN_YEAR]; pub static PENALTY_PERCENTAGES: &[u64] = &[4_000, 6_000, 8_000]; +pub struct NonceAmountPair { + pub nonce: u64, + pub amount: u64, +} + pub struct RawFarmTokenAttributes { pub reward_per_share_bytes: Vec, pub entering_epoch: Epoch, @@ -408,6 +415,37 @@ where result } + pub fn merge_farm_tokens(&mut self, user: &Address, farm_tokens: Vec) { + self.last_farm_token_nonce += 1; + let mut expected_farm_token_amount = 0; + let mut payments = Vec::new(); + for farm_token in farm_tokens { + expected_farm_token_amount += farm_token.amount; + payments.push(TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: farm_token.nonce, + value: rust_biguint!(farm_token.amount), + }); + } + + self.b_mock + .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { + let (out_farm_token, _boosted_rewards) = sc + .merge_farm_tokens_endpoint(OptionalValue::None) + .into_tuple(); + assert_eq!( + out_farm_token.token_identifier, + managed_token_id!(FARM_TOKEN_ID) + ); + assert_eq!(out_farm_token.token_nonce, self.last_farm_token_nonce); + assert_eq!( + out_farm_token.amount, + managed_biguint!(expected_farm_token_amount) + ); + }) + .assert_ok(); + } + pub fn exit_farm(&mut self, user: &Address, farm_token_nonce: u64, exit_farm_amount: u64) { self.b_mock .execute_esdt_transfer( @@ -422,4 +460,53 @@ where ) .assert_ok(); } + + pub fn claim_boosted_rewards_for_user( + &mut self, + owner: &Address, + broker: &Address, + locked_reward_nonce: u64, + ) -> u64 { + self.last_farm_token_nonce += 1; + + let mut result = 0; + self.b_mock + .execute_tx(broker, &self.farm_wrapper, &rust_biguint!(0), |sc| { + let reward_payment = + sc.claim_boosted_rewards(OptionalValue::Some(managed_address!(owner))); + assert_eq!( + reward_payment.token_identifier, + managed_token_id!(LOCKED_REWARD_TOKEN_ID) + ); + assert_eq!(reward_payment.token_nonce, locked_reward_nonce); + + result = reward_payment.amount.to_u64().unwrap(); + }) + .assert_ok(); + + result + } + + pub fn check_farm_token_supply(&mut self, expected_farm_token_supply: u64) { + let b_mock = &mut self.b_mock; + b_mock + .execute_query(&self.farm_wrapper, |sc| { + let actual_farm_supply = sc.farm_token_supply().get(); + assert_eq!( + managed_biguint!(expected_farm_token_supply), + actual_farm_supply + ); + }) + .assert_ok(); + } + + pub fn check_farm_rps(&mut self, expected_amount: u64) { + let b_mock = &mut self.b_mock; + b_mock + .execute_query(&self.farm_wrapper, |sc| { + let current_rps = sc.reward_per_share().get(); + assert_eq!(managed_biguint!(expected_amount), current_rps); + }) + .assert_ok(); + } } diff --git a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs index 8a9fb8793..4668665a4 100644 --- a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs +++ b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs @@ -1,6 +1,8 @@ #![allow(deprecated)] use common_structs::FarmTokenAttributes; +use farm_with_locked_rewards_setup::NonceAmountPair; +use multiversx_sc::codec::Empty; use multiversx_sc_scenario::{managed_address, managed_biguint, rust_biguint, DebugApi}; use simple_lock::locked_token::LockedTokenAttributes; @@ -335,3 +337,234 @@ fn total_farm_position_claim_with_locked_rewards_test() { None, ); } + +#[test] +fn claim_only_boosted_rewards_per_week_test() { + DebugApi::dummy(); + let mut farm_setup = FarmSetup::new( + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + let temp_user = farm_setup.third_user.clone(); + + // first user enter farm + let farm_in_amount = 100_000_000; + let first_user = farm_setup.first_user.clone(); + farm_setup.set_user_energy(&first_user, 1_000, 2, 1); + farm_setup.enter_farm(&first_user, farm_in_amount); + + farm_setup.check_farm_token_supply(farm_in_amount); + farm_setup.check_farm_rps(0u64); + + farm_setup.b_mock.set_block_nonce(10); + farm_setup.b_mock.set_block_epoch(6); + farm_setup.set_user_energy(&first_user, 1_000, 6, 1); + farm_setup.set_user_energy(&temp_user, 1, 6, 1); + farm_setup.enter_farm(&temp_user, 1); + farm_setup.exit_farm(&temp_user, 2, 1); + + farm_setup.check_farm_rps(75_000_000u64); + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 13, 1); + farm_setup.b_mock.set_block_nonce(20); + farm_setup.b_mock.set_block_epoch(13); + + let boosted_rewards = 2_500; + let second_week_received_reward_amt = + farm_setup.claim_boosted_rewards_for_user(&first_user, &first_user, 1); + + assert_eq!(second_week_received_reward_amt, boosted_rewards); + farm_setup.check_farm_rps(150_000_000u64); + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 15, 1); + farm_setup.b_mock.set_block_nonce(30); + farm_setup.b_mock.set_block_epoch(15); + let third_week_received_reward_amt = + farm_setup.claim_boosted_rewards_for_user(&first_user, &first_user, 1); + + assert_eq!(third_week_received_reward_amt, boosted_rewards); + farm_setup.check_farm_rps(225_000_000u64); + + farm_setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_REWARD_TOKEN_ID, + 1, + &rust_biguint!(boosted_rewards * 2), + None, + ); +} + +#[test] +fn claim_rewards_per_week_test() { + DebugApi::dummy(); + let mut farm_setup = FarmSetup::new( + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + let temp_user = farm_setup.third_user.clone(); + + // first user enter farm + let farm_in_amount = 100_000_000; + let first_user = farm_setup.first_user.clone(); + farm_setup.set_user_energy(&first_user, 1_000, 2, 1); + farm_setup.enter_farm(&first_user, farm_in_amount); + + farm_setup.check_farm_token_supply(farm_in_amount); + farm_setup.check_farm_rps(0u64); + + farm_setup.b_mock.set_block_nonce(10); + farm_setup.b_mock.set_block_epoch(6); + farm_setup.set_user_energy(&first_user, 1_000, 6, 1); + farm_setup.set_user_energy(&temp_user, 1, 6, 1); + farm_setup.enter_farm(&temp_user, 1); + farm_setup.exit_farm(&temp_user, 2, 1); + + farm_setup.check_farm_rps(75_000_000u64); + let base_rewards_per_week = 7_500; + let boosted_rewards_per_week = 2_500; + let total_rewards_per_week = base_rewards_per_week + boosted_rewards_per_week; + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 13, 1); + farm_setup.b_mock.set_block_nonce(20); + farm_setup.b_mock.set_block_epoch(13); + + let second_week_received_reward_amt = farm_setup.claim_rewards(&first_user, 1, farm_in_amount); + + assert_eq!( + second_week_received_reward_amt, + total_rewards_per_week + base_rewards_per_week + ); + farm_setup.check_farm_rps(150_000_000u64); + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 15, 1); + farm_setup.b_mock.set_block_nonce(30); + farm_setup.b_mock.set_block_epoch(15); + let third_week_received_reward_amt = farm_setup.claim_rewards(&first_user, 3, farm_in_amount); + + assert_eq!(third_week_received_reward_amt, total_rewards_per_week); + farm_setup.check_farm_rps(225_000_000u64); + + farm_setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_REWARD_TOKEN_ID, + 1, + &rust_biguint!(total_rewards_per_week * 2 + base_rewards_per_week), + None, + ); +} + +#[test] +fn merge_farm_position_per_week_test() { + DebugApi::dummy(); + let mut farm_setup = FarmSetup::new( + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + let temp_user = farm_setup.third_user.clone(); + + // first user enter farm + let farm_in_amount = 10_000_000; + let first_user = farm_setup.first_user.clone(); + farm_setup.set_user_energy(&first_user, 1_000, 2, 1); + + // User creates 3 different positions + farm_setup.enter_farm(&first_user, farm_in_amount); + farm_setup.enter_farm(&first_user, farm_in_amount); + farm_setup.enter_farm(&first_user, farm_in_amount); + + farm_setup.check_farm_token_supply(farm_in_amount * 3); + farm_setup.check_farm_rps(0u64); + + farm_setup.b_mock.set_block_nonce(10); + farm_setup.b_mock.set_block_epoch(6); + farm_setup.set_user_energy(&first_user, 1_000, 6, 1); + farm_setup.set_user_energy(&temp_user, 1, 6, 1); + farm_setup.enter_farm(&temp_user, 1); + farm_setup.exit_farm(&temp_user, 4, 1); + + farm_setup.check_farm_rps(250_000_000u64); + let boosted_rewards_per_week = 2_500; + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 13, 1); + farm_setup.b_mock.set_block_nonce(20); + farm_setup.b_mock.set_block_epoch(13); + + let mut payments = vec![ + NonceAmountPair { + nonce: 1, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 2, + amount: farm_in_amount, + }, + ]; + + farm_setup.merge_farm_tokens(&first_user, payments); + + farm_setup.check_farm_token_supply(farm_in_amount * 3); + farm_setup.check_farm_rps(500_000_000u64); + farm_setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_REWARD_TOKEN_ID, + 1, + &rust_biguint!(boosted_rewards_per_week), + None, + ); + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 15, 1); + farm_setup.b_mock.set_block_nonce(30); + farm_setup.b_mock.set_block_epoch(15); + + payments = vec![ + NonceAmountPair { + nonce: 3, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 5, + amount: farm_in_amount * 2, + }, + ]; + + farm_setup.merge_farm_tokens(&first_user, payments); + + farm_setup.check_farm_token_supply(farm_in_amount * 3); + farm_setup.check_farm_rps(750_000_000u64); + + farm_setup.b_mock.check_nft_balance::( + &first_user, + FARM_TOKEN_ID, + 6, + &rust_biguint!(farm_in_amount * 3), + None, + ); + farm_setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_REWARD_TOKEN_ID, + 1, + &rust_biguint!(boosted_rewards_per_week * 2), + None, + ); +} diff --git a/dex/farm/tests/total_farm_position_test.rs b/dex/farm/tests/total_farm_position_test.rs index e0819d411..b7ca1be7b 100644 --- a/dex/farm/tests/total_farm_position_test.rs +++ b/dex/farm/tests/total_farm_position_test.rs @@ -1193,61 +1193,3 @@ fn total_farm_position_through_simple_lock_test() { &rust_biguint!(first_received_reward_amt), ); } - -#[test] -fn claim_only_boosted_rewards_per_week_test() { - DebugApi::dummy(); - let mut farm_setup = MultiUserFarmSetup::new( - farm::contract_obj, - energy_factory_mock::contract_obj, - energy_update::contract_obj, - ); - - farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); - farm_setup.set_boosted_yields_factors(); - farm_setup.b_mock.set_block_epoch(2); - - let temp_user = farm_setup.third_user.clone(); - - // first user enter farm - let farm_in_amount = 100_000_000; - let first_user = farm_setup.first_user.clone(); - farm_setup.set_user_energy(&first_user, 1_000, 2, 1); - farm_setup.enter_farm(&first_user, farm_in_amount); - - farm_setup.check_farm_token_supply(farm_in_amount); - - farm_setup.b_mock.set_block_nonce(10); - farm_setup.b_mock.set_block_epoch(6); - farm_setup.set_user_energy(&first_user, 1_000, 6, 1); - farm_setup.set_user_energy(&temp_user, 1, 6, 1); - farm_setup.enter_farm(&temp_user, 1); - farm_setup.exit_farm(&temp_user, 2, 1); - - // advance 1 week - farm_setup.set_user_energy(&first_user, 1_000, 13, 1); - farm_setup.b_mock.set_block_nonce(20); - farm_setup.b_mock.set_block_epoch(13); - - let boosted_rewards = 2_500; - let second_week_received_reward_amt = - farm_setup.claim_boosted_rewards_for_user(&first_user, &first_user); - - assert_eq!(second_week_received_reward_amt, boosted_rewards); - - // advance 1 week - farm_setup.set_user_energy(&first_user, 1_000, 15, 1); - farm_setup.b_mock.set_block_nonce(30); - farm_setup.b_mock.set_block_epoch(15); - let third_week_received_reward_amt = - farm_setup.claim_boosted_rewards_for_user(&first_user, &first_user); - - // Should be equal to half base generated rewards + full boosted generated rewards - assert_eq!(third_week_received_reward_amt, boosted_rewards); - - farm_setup.b_mock.check_esdt_balance( - &first_user, - REWARD_TOKEN_ID, - &rust_biguint!(boosted_rewards * 2), - ); -} From 602b696735ab9ce1bda52049113e2bced3c94efe Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 16:54:34 +0300 Subject: [PATCH 089/103] farm staking unit tests --- .../tests/farm_staking_energy_test.rs | 303 ++++++++++++++++++ .../tests/farm_staking_setup/mod.rs | 67 ++++ 2 files changed, 370 insertions(+) diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index 1274be166..e71f0db34 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1427,3 +1427,306 @@ fn boosted_rewards_config_change_test() { && first_user_total_rewards == third_user_total_rewards ); } + +#[test] +fn claim_only_boosted_rewards_per_week_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + let first_user = fs_setup.user_address.clone(); + let farm_in_amount = 100_000_000; + + fs_setup.set_user_energy(&first_user, 10_000, 0, 10); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); + + fs_setup.check_farm_token_supply(farm_in_amount); + fs_setup.check_farm_rps(0u64); + + fs_setup.b_mock.set_block_nonce(100); + fs_setup.b_mock.set_block_epoch(6); + fs_setup.set_user_energy(&first_user, 1_000, 6, 1); + + // Reset user balance + fs_setup + .b_mock + .set_esdt_balance(&first_user, FARMING_TOKEN_ID, &rust_biguint!(0)); + + // random user tx to collect rewards + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &rand_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + fs_setup.set_user_energy(&rand_user, 1, 6, 1); + fs_setup.stake_farm(&rand_user, 10, &[], 2, 3_000_000u64, 0); + fs_setup.unstake_farm_no_checks(&rand_user, 10, 2); + + let farm_rps_increase = 3_000_000u64; + let mut current_farm_rps = 0; + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 13, 1); + fs_setup.b_mock.set_block_nonce(200); + fs_setup.b_mock.set_block_epoch(13); + + let boosted_rewards_for_week = 100; + fs_setup.claim_boosted_rewards_for_user( + &first_user, + &first_user, + boosted_rewards_for_week, + &rust_biguint!(boosted_rewards_for_week), + ); + + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 15, 1); + fs_setup.b_mock.set_block_nonce(300); + fs_setup.b_mock.set_block_epoch(15); + fs_setup.claim_boosted_rewards_for_user( + &first_user, + &first_user, + boosted_rewards_for_week, + &rust_biguint!(boosted_rewards_for_week * 2), + ); + + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + fs_setup.b_mock.check_esdt_balance( + &first_user, + REWARD_TOKEN_ID, + &rust_biguint!(boosted_rewards_for_week * 2), + ); + + let expected_attributes = StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(0), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(farm_in_amount), + original_owner: managed_address!(&first_user), + }; + + fs_setup.b_mock.check_nft_balance( + &first_user, + FARM_TOKEN_ID, + 1, + &rust_biguint!(farm_in_amount), + Some(&expected_attributes), + ); +} + +#[test] +fn claim_rewards_per_week_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + let first_user = fs_setup.user_address.clone(); + let farm_in_amount = 100_000_000; + + fs_setup.set_user_energy(&first_user, 10_000, 0, 10); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); + + fs_setup.check_farm_token_supply(farm_in_amount); + fs_setup.check_farm_rps(0u64); + + fs_setup.b_mock.set_block_nonce(100); + fs_setup.b_mock.set_block_epoch(6); + fs_setup.set_user_energy(&first_user, 1_000, 6, 1); + + // Reset user balance + fs_setup + .b_mock + .set_esdt_balance(&first_user, FARMING_TOKEN_ID, &rust_biguint!(0)); + + // random user tx to collect rewards + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &rand_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + fs_setup.set_user_energy(&rand_user, 1, 6, 1); + fs_setup.stake_farm(&rand_user, 10, &[], 2, 3_000_000u64, 0); + fs_setup.unstake_farm_no_checks(&rand_user, 10, 2); + + let farm_rps_increase = 3_000_000u64; + let mut current_farm_rps = 0; + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 13, 1); + fs_setup.b_mock.set_block_nonce(200); + fs_setup.b_mock.set_block_epoch(13); + + let base_rewards_for_week = 300; + let boosted_rewards_for_week = 100; + + current_farm_rps += farm_rps_increase; + let mut user_rewards_balance = base_rewards_for_week * 2 + boosted_rewards_for_week; + fs_setup.claim_rewards( + &first_user, + farm_in_amount, + 1, + base_rewards_for_week * 2 + boosted_rewards_for_week, + &rust_biguint!(user_rewards_balance), + &rust_biguint!(user_rewards_balance), // user balance has bet set to 0 at the start + 4, + current_farm_rps, + ); + + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 15, 1); + fs_setup.b_mock.set_block_nonce(300); + fs_setup.b_mock.set_block_epoch(15); + + current_farm_rps += farm_rps_increase; + user_rewards_balance += base_rewards_for_week + boosted_rewards_for_week; + fs_setup.claim_rewards( + &first_user, + farm_in_amount, + 4, + base_rewards_for_week + boosted_rewards_for_week, + &rust_biguint!(user_rewards_balance), + &rust_biguint!(user_rewards_balance), + 5, + current_farm_rps, + ); + + fs_setup.check_farm_rps(current_farm_rps); + + fs_setup.b_mock.check_esdt_balance( + &first_user, + REWARD_TOKEN_ID, + &rust_biguint!(user_rewards_balance), + ); +} + +#[test] +fn merge_farm_position_per_week_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + let first_user = fs_setup.user_address.clone(); + let farm_in_amount = 100_000_000; + + fs_setup.set_user_energy(&first_user, 10_000, 0, 10); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 2, 0, 0); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 3, 0, 0); + + fs_setup.check_farm_token_supply(farm_in_amount * 3); + fs_setup.check_farm_rps(0u64); + + fs_setup.b_mock.set_block_nonce(100); + fs_setup.b_mock.set_block_epoch(6); + fs_setup.set_user_energy(&first_user, 1_000, 6, 1); + + // Reset user balance + fs_setup + .b_mock + .set_esdt_balance(&first_user, FARMING_TOKEN_ID, &rust_biguint!(0)); + + // random user tx to collect rewards + let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &rand_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + fs_setup.set_user_energy(&rand_user, 1, 6, 1); + fs_setup.stake_farm(&rand_user, 10, &[], 4, 3_500_000u64, 0); + fs_setup.unstake_farm_no_checks(&rand_user, 10, 4); + + let farm_rps_increase = 3_500_000u64; + let mut current_farm_rps = 0; + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 13, 1); + fs_setup.b_mock.set_block_nonce(200); + fs_setup.b_mock.set_block_epoch(13); + + let boosted_rewards_for_week = 350u64; + + current_farm_rps += farm_rps_increase; + let mut user_rewards_balance = boosted_rewards_for_week; + + let mut payments = vec![ + NonceAmountPair { + nonce: 1, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 2, + amount: farm_in_amount, + }, + ]; + fs_setup.merge_farm_tokens(&first_user, payments, 6); + + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 15, 1); + fs_setup.b_mock.set_block_nonce(300); + fs_setup.b_mock.set_block_epoch(15); + + current_farm_rps += farm_rps_increase; + user_rewards_balance += boosted_rewards_for_week; + + payments = vec![ + NonceAmountPair { + nonce: 3, + amount: farm_in_amount, + }, + NonceAmountPair { + nonce: 6, + amount: farm_in_amount * 2, + }, + ]; + fs_setup.merge_farm_tokens(&first_user, payments, 7); + + fs_setup.check_farm_rps(current_farm_rps); + + fs_setup.b_mock.check_esdt_balance( + &first_user, + REWARD_TOKEN_ID, + &rust_biguint!(user_rewards_balance), + ); + + let expected_attributes = StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(0), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(farm_in_amount * 3), + original_owner: managed_address!(&first_user), + }; + + fs_setup.b_mock.check_nft_balance( + &first_user, + FARM_TOKEN_ID, + 7, + &rust_biguint!(farm_in_amount * 3), + Some(&expected_attributes), + ); +} diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index 90513e2d6..45151e926 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -25,6 +25,7 @@ use farm_staking::unstake_farm::UnstakeFarmModule; use farm_staking::*; use farm_token::FarmTokenModule; use pausable::{PausableModule, State}; +use rewards::RewardsModule; pub static REWARD_TOKEN_ID: &[u8] = b"RIDE-abcdef"; // reward token ID pub static FARMING_TOKEN_ID: &[u8] = b"RIDE-abcdef"; // farming token ID @@ -46,6 +47,11 @@ pub const MIN_FARM_AMOUNT_FOR_BOOSTED_YIELDS: u64 = 1; pub const WITHDRAW_AMOUNT_TOO_HIGH: &str = "Withdraw amount is higher than the remaining uncollected rewards!"; +pub struct NonceAmountPair { + pub nonce: u64, + pub amount: u64, +} + pub struct FarmStakingSetup where FarmObjBuilder: 'static + Copy + Fn() -> farm_staking::ContractObj, @@ -509,6 +515,24 @@ where ); } + pub fn unstake_farm_no_checks( + &mut self, + user: &Address, + farm_token_amount: u64, + farm_token_nonce: u64, + ) { + let _ = self.b_mock.execute_esdt_transfer( + user, + &self.farm_wrapper, + FARM_TOKEN_ID, + farm_token_nonce, + &rust_biguint!(farm_token_amount), + |sc| { + sc.unstake_farm(OptionalValue::None); + }, + ); + } + pub fn unbond_farm( &mut self, farm_token_nonce: u64, @@ -542,6 +566,40 @@ where ); } + pub fn merge_farm_tokens( + &mut self, + user: &Address, + farm_tokens: Vec, + expected_farm_token_nonce: u64, + ) { + let mut expected_farm_token_amount = 0; + let mut payments = Vec::new(); + for farm_token in farm_tokens { + expected_farm_token_amount += farm_token.amount; + payments.push(TxTokenTransfer { + token_identifier: FARM_TOKEN_ID.to_vec(), + nonce: farm_token.nonce, + value: rust_biguint!(farm_token.amount), + }); + } + + self.b_mock + .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { + let (out_farm_token, _boosted_rewards) = + sc.merge_farm_tokens_endpoint().into_tuple(); + assert_eq!( + out_farm_token.token_identifier, + managed_token_id!(FARM_TOKEN_ID) + ); + assert_eq!(out_farm_token.token_nonce, expected_farm_token_nonce); + assert_eq!( + out_farm_token.amount, + managed_biguint!(expected_farm_token_amount) + ); + }) + .assert_ok(); + } + pub fn check_farm_token_supply(&mut self, expected_farm_token_supply: u64) { self.b_mock .execute_query(&self.farm_wrapper, |sc| { @@ -554,6 +612,15 @@ where .assert_ok(); } + pub fn check_farm_rps(&mut self, expected_amount: u64) { + self.b_mock + .execute_query(&self.farm_wrapper, |sc| { + let current_rps = sc.reward_per_share().get(); + assert_eq!(managed_biguint!(expected_amount), current_rps); + }) + .assert_ok(); + } + pub fn check_rewards_capacity(&mut self, expected_farm_token_supply: u64) { self.b_mock .execute_query(&self.farm_wrapper, |sc| { From b147571ad81bca791d612fd6247af4c54edb1640 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 18:01:55 +0300 Subject: [PATCH 090/103] farm staking unbond fix + unit test --- farm-staking/farm-staking/src/unbond_farm.rs | 2 + .../tests/farm_staking_energy_test.rs | 92 +++++++++++++++++++ 2 files changed, 94 insertions(+) diff --git a/farm-staking/farm-staking/src/unbond_farm.rs b/farm-staking/farm-staking/src/unbond_farm.rs index ec2044897..de296e4c3 100644 --- a/farm-staking/farm-staking/src/unbond_farm.rs +++ b/farm-staking/farm-staking/src/unbond_farm.rs @@ -49,6 +49,8 @@ pub trait UnbondFarmModule: "Unbond period not over" ); + let current_week = self.get_current_week(); + self.perform_weekly_update(current_week); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index e71f0db34..dee471634 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1730,3 +1730,95 @@ fn merge_farm_position_per_week_test() { Some(&expected_attributes), ); } + +#[test] +fn unbond_farm_position_per_week_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + let first_user = fs_setup.user_address.clone(); + let farm_in_amount = 100_000_000; + + fs_setup.set_user_energy(&first_user, 10_000, 0, 10); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); + fs_setup.check_farm_token_supply(farm_in_amount); + + fs_setup.unstake_farm_no_checks(&first_user, farm_in_amount / 2, 1); + fs_setup.check_farm_token_supply(farm_in_amount / 2); + + fs_setup.check_farm_rps(0u64); + + fs_setup.b_mock.set_block_nonce(100); + fs_setup.b_mock.set_block_epoch(6); + fs_setup.set_user_energy(&first_user, 1_000, 6, 1); + + // Reset user balance + fs_setup + .b_mock + .set_esdt_balance(&first_user, FARMING_TOKEN_ID, &rust_biguint!(0)); + + let mut current_farm_rps = 0; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 13, 1); + fs_setup.b_mock.set_block_nonce(200); + fs_setup.b_mock.set_block_epoch(13); + + fs_setup.unbond_farm( + 2, + farm_in_amount / 2, + farm_in_amount / 2, + farm_in_amount / 2, + ); + + let mut user_balance = farm_in_amount / 2; + fs_setup + .b_mock + .check_esdt_balance(&first_user, REWARD_TOKEN_ID, &rust_biguint!(user_balance)); + + let farm_rps_increase = 6_000_000u64; + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 15, 1); + fs_setup.b_mock.set_block_nonce(300); + fs_setup.b_mock.set_block_epoch(15); + + let boosted_rewards_for_week = 100; + user_balance += boosted_rewards_for_week; + fs_setup.claim_boosted_rewards_for_user( + &first_user, + &first_user, + boosted_rewards_for_week, + &rust_biguint!(user_balance), + ); + + // User should have the following balance: unstake_amount + boosted_rewards_week_2 + fs_setup + .b_mock + .check_esdt_balance(&first_user, REWARD_TOKEN_ID, &rust_biguint!(user_balance)); + + current_farm_rps += farm_rps_increase / 2; //user existed with half position + fs_setup.check_farm_rps(current_farm_rps); + + let expected_attributes = StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(0), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(farm_in_amount), + original_owner: managed_address!(&first_user), + }; + + fs_setup.b_mock.check_nft_balance( + &first_user, + FARM_TOKEN_ID, + 1, + &rust_biguint!(farm_in_amount / 2), + Some(&expected_attributes), + ); +} From a28f0a4381bdaf82ae58c3c759a2ff09e39c7bdb Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 18:12:39 +0300 Subject: [PATCH 091/103] revert farm staking unbond changes --- farm-staking/farm-staking/src/unbond_farm.rs | 11 +-- .../tests/farm_staking_energy_test.rs | 92 ------------------- 2 files changed, 2 insertions(+), 101 deletions(-) diff --git a/farm-staking/farm-staking/src/unbond_farm.rs b/farm-staking/farm-staking/src/unbond_farm.rs index de296e4c3..0e661616e 100644 --- a/farm-staking/farm-staking/src/unbond_farm.rs +++ b/farm-staking/farm-staking/src/unbond_farm.rs @@ -1,9 +1,8 @@ multiversx_sc::imports!(); use contexts::storage_cache::StorageCache; -use farm_base_impl::base_traits_impl::FarmContract; -use crate::{base_impl_wrapper::FarmStakingWrapper, token_attributes::UnbondSftAttributes}; +use crate::token_attributes::UnbondSftAttributes; #[multiversx_sc::module] pub trait UnbondFarmModule: @@ -17,7 +16,6 @@ pub trait UnbondFarmModule: + pausable::PausableModule + permissions_module::PermissionsModule + multiversx_sc_modules::default_issue_callbacks::DefaultIssueCallbacksModule - + farm_base_impl::base_farm_init::BaseFarmInitModule + farm_base_impl::base_farm_validation::BaseFarmValidationModule + utils::UtilsModule + farm_boosted_yields::FarmBoostedYieldsModule @@ -33,7 +31,7 @@ pub trait UnbondFarmModule: #[payable("*")] #[endpoint(unbondFarm)] fn unbond_farm(&self) -> EsdtTokenPayment { - let mut storage_cache = StorageCache::new(self); + let storage_cache = StorageCache::new(self); self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); let farm_token_mapper = self.farm_token(); @@ -49,11 +47,6 @@ pub trait UnbondFarmModule: "Unbond period not over" ); - let current_week = self.get_current_week(); - self.perform_weekly_update(current_week); - FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); - self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); - farm_token_mapper.nft_burn(payment.token_nonce, &payment.amount); let caller = self.blockchain().get_caller(); diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index dee471634..e71f0db34 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1730,95 +1730,3 @@ fn merge_farm_position_per_week_test() { Some(&expected_attributes), ); } - -#[test] -fn unbond_farm_position_per_week_test() { - DebugApi::dummy(); - let mut fs_setup = - FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); - - fs_setup.set_boosted_yields_factors(); - fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); - - let first_user = fs_setup.user_address.clone(); - let farm_in_amount = 100_000_000; - - fs_setup.set_user_energy(&first_user, 10_000, 0, 10); - fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); - fs_setup.check_farm_token_supply(farm_in_amount); - - fs_setup.unstake_farm_no_checks(&first_user, farm_in_amount / 2, 1); - fs_setup.check_farm_token_supply(farm_in_amount / 2); - - fs_setup.check_farm_rps(0u64); - - fs_setup.b_mock.set_block_nonce(100); - fs_setup.b_mock.set_block_epoch(6); - fs_setup.set_user_energy(&first_user, 1_000, 6, 1); - - // Reset user balance - fs_setup - .b_mock - .set_esdt_balance(&first_user, FARMING_TOKEN_ID, &rust_biguint!(0)); - - let mut current_farm_rps = 0; - fs_setup.check_farm_rps(current_farm_rps); - - // advance 1 week - fs_setup.set_user_energy(&first_user, 1_000, 13, 1); - fs_setup.b_mock.set_block_nonce(200); - fs_setup.b_mock.set_block_epoch(13); - - fs_setup.unbond_farm( - 2, - farm_in_amount / 2, - farm_in_amount / 2, - farm_in_amount / 2, - ); - - let mut user_balance = farm_in_amount / 2; - fs_setup - .b_mock - .check_esdt_balance(&first_user, REWARD_TOKEN_ID, &rust_biguint!(user_balance)); - - let farm_rps_increase = 6_000_000u64; - current_farm_rps += farm_rps_increase; - fs_setup.check_farm_rps(current_farm_rps); - - // advance 1 week - fs_setup.set_user_energy(&first_user, 1_000, 15, 1); - fs_setup.b_mock.set_block_nonce(300); - fs_setup.b_mock.set_block_epoch(15); - - let boosted_rewards_for_week = 100; - user_balance += boosted_rewards_for_week; - fs_setup.claim_boosted_rewards_for_user( - &first_user, - &first_user, - boosted_rewards_for_week, - &rust_biguint!(user_balance), - ); - - // User should have the following balance: unstake_amount + boosted_rewards_week_2 - fs_setup - .b_mock - .check_esdt_balance(&first_user, REWARD_TOKEN_ID, &rust_biguint!(user_balance)); - - current_farm_rps += farm_rps_increase / 2; //user existed with half position - fs_setup.check_farm_rps(current_farm_rps); - - let expected_attributes = StakingFarmTokenAttributes:: { - reward_per_share: managed_biguint!(0), - compounded_reward: managed_biguint!(0), - current_farm_amount: managed_biguint!(farm_in_amount), - original_owner: managed_address!(&first_user), - }; - - fs_setup.b_mock.check_nft_balance( - &first_user, - FARM_TOKEN_ID, - 1, - &rust_biguint!(farm_in_amount / 2), - Some(&expected_attributes), - ); -} From ba5aec93b500be7c3b03ce6dbc4e41b1625bb428 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 18:32:56 +0300 Subject: [PATCH 092/103] remove supply fix for merge endpoints --- .../farm_with_locked_rewards_setup/mod.rs | 37 ------ .../tests/farm_with_locked_rewards_test.rs | 103 ---------------- farm-staking/farm-staking/src/lib.rs | 8 -- .../tests/farm_staking_energy_test.rs | 114 ------------------ 4 files changed, 262 deletions(-) diff --git a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs index 98c8837ee..5f6015658 100644 --- a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs +++ b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_setup/mod.rs @@ -8,7 +8,6 @@ use multiversx_sc::{ types::{Address, BigInt, EsdtLocalRole, MultiValueEncoded}, }; use multiversx_sc_scenario::{ - imports::TxTokenTransfer, managed_address, managed_biguint, managed_token_id, rust_biguint, whitebox_legacy::{BlockchainStateWrapper, ContractObjWrapper}, DebugApi, @@ -50,11 +49,6 @@ pub const EPOCHS_IN_YEAR: u64 = 360; pub static LOCK_OPTIONS: &[u64] = &[EPOCHS_IN_YEAR, 2 * EPOCHS_IN_YEAR, 4 * EPOCHS_IN_YEAR]; pub static PENALTY_PERCENTAGES: &[u64] = &[4_000, 6_000, 8_000]; -pub struct NonceAmountPair { - pub nonce: u64, - pub amount: u64, -} - pub struct RawFarmTokenAttributes { pub reward_per_share_bytes: Vec, pub entering_epoch: Epoch, @@ -415,37 +409,6 @@ where result } - pub fn merge_farm_tokens(&mut self, user: &Address, farm_tokens: Vec) { - self.last_farm_token_nonce += 1; - let mut expected_farm_token_amount = 0; - let mut payments = Vec::new(); - for farm_token in farm_tokens { - expected_farm_token_amount += farm_token.amount; - payments.push(TxTokenTransfer { - token_identifier: FARM_TOKEN_ID.to_vec(), - nonce: farm_token.nonce, - value: rust_biguint!(farm_token.amount), - }); - } - - self.b_mock - .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { - let (out_farm_token, _boosted_rewards) = sc - .merge_farm_tokens_endpoint(OptionalValue::None) - .into_tuple(); - assert_eq!( - out_farm_token.token_identifier, - managed_token_id!(FARM_TOKEN_ID) - ); - assert_eq!(out_farm_token.token_nonce, self.last_farm_token_nonce); - assert_eq!( - out_farm_token.amount, - managed_biguint!(expected_farm_token_amount) - ); - }) - .assert_ok(); - } - pub fn exit_farm(&mut self, user: &Address, farm_token_nonce: u64, exit_farm_amount: u64) { self.b_mock .execute_esdt_transfer( diff --git a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs index 4668665a4..d313c3b6b 100644 --- a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs +++ b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs @@ -1,7 +1,6 @@ #![allow(deprecated)] use common_structs::FarmTokenAttributes; -use farm_with_locked_rewards_setup::NonceAmountPair; use multiversx_sc::codec::Empty; use multiversx_sc_scenario::{managed_address, managed_biguint, rust_biguint, DebugApi}; use simple_lock::locked_token::LockedTokenAttributes; @@ -466,105 +465,3 @@ fn claim_rewards_per_week_test() { None, ); } - -#[test] -fn merge_farm_position_per_week_test() { - DebugApi::dummy(); - let mut farm_setup = FarmSetup::new( - farm_with_locked_rewards::contract_obj, - energy_factory::contract_obj, - ); - - farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); - farm_setup.set_boosted_yields_factors(); - farm_setup.b_mock.set_block_epoch(2); - - let temp_user = farm_setup.third_user.clone(); - - // first user enter farm - let farm_in_amount = 10_000_000; - let first_user = farm_setup.first_user.clone(); - farm_setup.set_user_energy(&first_user, 1_000, 2, 1); - - // User creates 3 different positions - farm_setup.enter_farm(&first_user, farm_in_amount); - farm_setup.enter_farm(&first_user, farm_in_amount); - farm_setup.enter_farm(&first_user, farm_in_amount); - - farm_setup.check_farm_token_supply(farm_in_amount * 3); - farm_setup.check_farm_rps(0u64); - - farm_setup.b_mock.set_block_nonce(10); - farm_setup.b_mock.set_block_epoch(6); - farm_setup.set_user_energy(&first_user, 1_000, 6, 1); - farm_setup.set_user_energy(&temp_user, 1, 6, 1); - farm_setup.enter_farm(&temp_user, 1); - farm_setup.exit_farm(&temp_user, 4, 1); - - farm_setup.check_farm_rps(250_000_000u64); - let boosted_rewards_per_week = 2_500; - - // advance 1 week - farm_setup.set_user_energy(&first_user, 1_000, 13, 1); - farm_setup.b_mock.set_block_nonce(20); - farm_setup.b_mock.set_block_epoch(13); - - let mut payments = vec![ - NonceAmountPair { - nonce: 1, - amount: farm_in_amount, - }, - NonceAmountPair { - nonce: 2, - amount: farm_in_amount, - }, - ]; - - farm_setup.merge_farm_tokens(&first_user, payments); - - farm_setup.check_farm_token_supply(farm_in_amount * 3); - farm_setup.check_farm_rps(500_000_000u64); - farm_setup.b_mock.check_nft_balance::( - &first_user, - LOCKED_REWARD_TOKEN_ID, - 1, - &rust_biguint!(boosted_rewards_per_week), - None, - ); - - // advance 1 week - farm_setup.set_user_energy(&first_user, 1_000, 15, 1); - farm_setup.b_mock.set_block_nonce(30); - farm_setup.b_mock.set_block_epoch(15); - - payments = vec![ - NonceAmountPair { - nonce: 3, - amount: farm_in_amount, - }, - NonceAmountPair { - nonce: 5, - amount: farm_in_amount * 2, - }, - ]; - - farm_setup.merge_farm_tokens(&first_user, payments); - - farm_setup.check_farm_token_supply(farm_in_amount * 3); - farm_setup.check_farm_rps(750_000_000u64); - - farm_setup.b_mock.check_nft_balance::( - &first_user, - FARM_TOKEN_ID, - 6, - &rust_biguint!(farm_in_amount * 3), - None, - ); - farm_setup.b_mock.check_nft_balance::( - &first_user, - LOCKED_REWARD_TOKEN_ID, - 1, - &rust_biguint!(boosted_rewards_per_week * 2), - None, - ); -} diff --git a/farm-staking/farm-staking/src/lib.rs b/farm-staking/farm-staking/src/lib.rs index 9cf4b1228..f783c7831 100644 --- a/farm-staking/farm-staking/src/lib.rs +++ b/farm-staking/farm-staking/src/lib.rs @@ -144,13 +144,6 @@ pub trait FarmStaking: FC::check_and_update_user_farm_position(self, orig_caller, &payments); - let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); - - FC::generate_aggregated_rewards(self, &mut storage_cache); - - self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); - self.merge_from_payments_and_burn(payments, &token_mapper) } @@ -160,7 +153,6 @@ pub trait FarmStaking: require!(percentage <= MAX_PERCENT, "Invalid percentage"); let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); FarmStakingWrapper::::generate_aggregated_rewards(self, &mut storage_cache); self.boosted_yields_rewards_percentage().set(percentage); diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index e71f0db34..050a4e968 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1616,117 +1616,3 @@ fn claim_rewards_per_week_test() { &rust_biguint!(user_rewards_balance), ); } - -#[test] -fn merge_farm_position_per_week_test() { - DebugApi::dummy(); - let mut fs_setup = - FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); - - fs_setup.set_boosted_yields_factors(); - fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); - - let first_user = fs_setup.user_address.clone(); - let farm_in_amount = 100_000_000; - - fs_setup.set_user_energy(&first_user, 10_000, 0, 10); - fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); - fs_setup.stake_farm(&first_user, farm_in_amount, &[], 2, 0, 0); - fs_setup.stake_farm(&first_user, farm_in_amount, &[], 3, 0, 0); - - fs_setup.check_farm_token_supply(farm_in_amount * 3); - fs_setup.check_farm_rps(0u64); - - fs_setup.b_mock.set_block_nonce(100); - fs_setup.b_mock.set_block_epoch(6); - fs_setup.set_user_energy(&first_user, 1_000, 6, 1); - - // Reset user balance - fs_setup - .b_mock - .set_esdt_balance(&first_user, FARMING_TOKEN_ID, &rust_biguint!(0)); - - // random user tx to collect rewards - let rand_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); - fs_setup.b_mock.set_esdt_balance( - &rand_user, - FARMING_TOKEN_ID, - &rust_biguint!(USER_TOTAL_RIDE_TOKENS), - ); - - fs_setup.set_user_energy(&rand_user, 1, 6, 1); - fs_setup.stake_farm(&rand_user, 10, &[], 4, 3_500_000u64, 0); - fs_setup.unstake_farm_no_checks(&rand_user, 10, 4); - - let farm_rps_increase = 3_500_000u64; - let mut current_farm_rps = 0; - current_farm_rps += farm_rps_increase; - fs_setup.check_farm_rps(current_farm_rps); - - // advance 1 week - fs_setup.set_user_energy(&first_user, 1_000, 13, 1); - fs_setup.b_mock.set_block_nonce(200); - fs_setup.b_mock.set_block_epoch(13); - - let boosted_rewards_for_week = 350u64; - - current_farm_rps += farm_rps_increase; - let mut user_rewards_balance = boosted_rewards_for_week; - - let mut payments = vec![ - NonceAmountPair { - nonce: 1, - amount: farm_in_amount, - }, - NonceAmountPair { - nonce: 2, - amount: farm_in_amount, - }, - ]; - fs_setup.merge_farm_tokens(&first_user, payments, 6); - - fs_setup.check_farm_rps(current_farm_rps); - - // advance 1 week - fs_setup.set_user_energy(&first_user, 1_000, 15, 1); - fs_setup.b_mock.set_block_nonce(300); - fs_setup.b_mock.set_block_epoch(15); - - current_farm_rps += farm_rps_increase; - user_rewards_balance += boosted_rewards_for_week; - - payments = vec![ - NonceAmountPair { - nonce: 3, - amount: farm_in_amount, - }, - NonceAmountPair { - nonce: 6, - amount: farm_in_amount * 2, - }, - ]; - fs_setup.merge_farm_tokens(&first_user, payments, 7); - - fs_setup.check_farm_rps(current_farm_rps); - - fs_setup.b_mock.check_esdt_balance( - &first_user, - REWARD_TOKEN_ID, - &rust_biguint!(user_rewards_balance), - ); - - let expected_attributes = StakingFarmTokenAttributes:: { - reward_per_share: managed_biguint!(0), - compounded_reward: managed_biguint!(0), - current_farm_amount: managed_biguint!(farm_in_amount * 3), - original_owner: managed_address!(&first_user), - }; - - fs_setup.b_mock.check_nft_balance( - &first_user, - FARM_TOKEN_ID, - 7, - &rust_biguint!(farm_in_amount * 3), - Some(&expected_attributes), - ); -} From c957df6c74648ca49c06b3f7ba3d40ebef5b0bf2 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 22:23:47 +0300 Subject: [PATCH 093/103] remove rewards aggregation from merge farm --- dex/farm/src/base_functions.rs | 7 ------- 1 file changed, 7 deletions(-) diff --git a/dex/farm/src/base_functions.rs b/dex/farm/src/base_functions.rs index dad01984e..d6455a2b7 100644 --- a/dex/farm/src/base_functions.rs +++ b/dex/farm/src/base_functions.rs @@ -192,13 +192,6 @@ pub trait BaseFunctionsModule: FC::check_and_update_user_farm_position(self, orig_caller, &payments); - let mut storage_cache = StorageCache::new(self); - self.validate_contract_state(storage_cache.contract_state, &storage_cache.farm_token_id); - - FC::generate_aggregated_rewards(self, &mut storage_cache); - - self.set_farm_supply_for_current_week(&storage_cache.farm_token_supply); - self.merge_from_payments_and_burn(payments, &token_mapper) } From 6c0d6b6542d433cfb12a20a691e648da117da794 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 22:27:24 +0300 Subject: [PATCH 094/103] farm staking unit tests cleanup --- .../tests/farm_staking_setup/mod.rs | 34 ------------------- 1 file changed, 34 deletions(-) diff --git a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs index 45151e926..a27b2d0d0 100644 --- a/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs +++ b/farm-staking/farm-staking/tests/farm_staking_setup/mod.rs @@ -566,40 +566,6 @@ where ); } - pub fn merge_farm_tokens( - &mut self, - user: &Address, - farm_tokens: Vec, - expected_farm_token_nonce: u64, - ) { - let mut expected_farm_token_amount = 0; - let mut payments = Vec::new(); - for farm_token in farm_tokens { - expected_farm_token_amount += farm_token.amount; - payments.push(TxTokenTransfer { - token_identifier: FARM_TOKEN_ID.to_vec(), - nonce: farm_token.nonce, - value: rust_biguint!(farm_token.amount), - }); - } - - self.b_mock - .execute_esdt_multi_transfer(user, &self.farm_wrapper, &payments, |sc| { - let (out_farm_token, _boosted_rewards) = - sc.merge_farm_tokens_endpoint().into_tuple(); - assert_eq!( - out_farm_token.token_identifier, - managed_token_id!(FARM_TOKEN_ID) - ); - assert_eq!(out_farm_token.token_nonce, expected_farm_token_nonce); - assert_eq!( - out_farm_token.amount, - managed_biguint!(expected_farm_token_amount) - ); - }) - .assert_ok(); - } - pub fn check_farm_token_supply(&mut self, expected_farm_token_supply: u64) { self.b_mock .execute_query(&self.farm_wrapper, |sc| { From f5d259305957026045faf2679a3c697444f66d3b Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Fri, 2 Aug 2024 23:16:25 +0300 Subject: [PATCH 095/103] zero position claim farm staking farm supply fix --- .../tests/farm_with_locked_rewards_test.rs | 63 +++++++++++++ .../farm-staking/src/base_impl_wrapper.rs | 7 +- .../tests/farm_staking_energy_test.rs | 90 +++++++++++++++++++ 3 files changed, 154 insertions(+), 6 deletions(-) diff --git a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs index d313c3b6b..6fbeb9cc6 100644 --- a/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs +++ b/dex/farm-with-locked-rewards/tests/farm_with_locked_rewards_test.rs @@ -465,3 +465,66 @@ fn claim_rewards_per_week_test() { None, ); } + +#[test] +fn claim_boosted_rewards_with_zero_position_test() { + DebugApi::dummy(); + let mut farm_setup = FarmSetup::new( + farm_with_locked_rewards::contract_obj, + energy_factory::contract_obj, + ); + + farm_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + farm_setup.set_boosted_yields_factors(); + farm_setup.b_mock.set_block_epoch(2); + + let temp_user = farm_setup.third_user.clone(); + + // first user enter farm + let farm_in_amount = 100_000_000; + let first_user = farm_setup.first_user.clone(); + farm_setup.set_user_energy(&first_user, 1_000, 2, 1); + farm_setup.enter_farm(&first_user, farm_in_amount); + + farm_setup.check_farm_token_supply(farm_in_amount); + farm_setup.check_farm_rps(0u64); + + farm_setup.b_mock.set_block_nonce(10); + farm_setup.b_mock.set_block_epoch(6); + farm_setup.set_user_energy(&first_user, 1_000, 6, 1); + farm_setup.set_user_energy(&temp_user, 1, 6, 1); + farm_setup.enter_farm(&temp_user, 1); + farm_setup.exit_farm(&temp_user, 2, 1); + + farm_setup.check_farm_rps(75_000_000u64); + + // advance 1 week + farm_setup.set_user_energy(&first_user, 1_000, 13, 1); + farm_setup.b_mock.set_block_nonce(20); + farm_setup.b_mock.set_block_epoch(13); + + let second_week_received_reward_amt = + farm_setup.claim_boosted_rewards_for_user(&temp_user, &temp_user, 0); + + assert_eq!(second_week_received_reward_amt, 0); + farm_setup.check_farm_rps(150_000_000u64); + + // advance 1 week + let boosted_rewards = 2_500; + farm_setup.set_user_energy(&first_user, 1_000, 15, 1); + farm_setup.b_mock.set_block_nonce(30); + farm_setup.b_mock.set_block_epoch(15); + let third_week_received_reward_amt = + farm_setup.claim_boosted_rewards_for_user(&first_user, &first_user, 1); + + assert_eq!(third_week_received_reward_amt, boosted_rewards * 2); // user receives rewards for weeks 1 and 2) + farm_setup.check_farm_rps(225_000_000u64); + + farm_setup.b_mock.check_nft_balance::( + &first_user, + LOCKED_REWARD_TOKEN_ID, + 1, + &rust_biguint!(boosted_rewards * 2), + None, + ); +} diff --git a/farm-staking/farm-staking/src/base_impl_wrapper.rs b/farm-staking/farm-staking/src/base_impl_wrapper.rs index f2208cfde..21d98f5bc 100644 --- a/farm-staking/farm-staking/src/base_impl_wrapper.rs +++ b/farm-staking/farm-staking/src/base_impl_wrapper.rs @@ -63,13 +63,8 @@ where caller: &ManagedAddress<<::FarmSc as ContractBase>::Api>, ) -> BigUint<<::FarmSc as ContractBase>::Api> { let user_total_farm_position = sc.user_total_farm_position(caller).get(); - let mut boosted_rewards = BigUint::zero(); - if user_total_farm_position > 0 { - boosted_rewards = sc.claim_boosted_yields_rewards(caller, user_total_farm_position); - } - - boosted_rewards + sc.claim_boosted_yields_rewards(caller, user_total_farm_position) } } diff --git a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs index 050a4e968..f22555545 100644 --- a/farm-staking/farm-staking/tests/farm_staking_energy_test.rs +++ b/farm-staking/farm-staking/tests/farm_staking_energy_test.rs @@ -1616,3 +1616,93 @@ fn claim_rewards_per_week_test() { &rust_biguint!(user_rewards_balance), ); } + +#[test] +fn claim_boosted_rewards_with_zero_position_test() { + DebugApi::dummy(); + let mut fs_setup = + FarmStakingSetup::new(farm_staking::contract_obj, energy_factory::contract_obj); + + fs_setup.set_boosted_yields_factors(); + fs_setup.set_boosted_yields_rewards_percentage(BOOSTED_YIELDS_PERCENTAGE); + + let first_user = fs_setup.user_address.clone(); + let farm_in_amount = 100_000_000; + + fs_setup.set_user_energy(&first_user, 10_000, 0, 10); + fs_setup.stake_farm(&first_user, farm_in_amount, &[], 1, 0, 0); + + fs_setup.check_farm_token_supply(farm_in_amount); + fs_setup.check_farm_rps(0u64); + + fs_setup.b_mock.set_block_nonce(100); + fs_setup.b_mock.set_block_epoch(6); + fs_setup.set_user_energy(&first_user, 1_000, 6, 1); + + // Reset user balance + fs_setup + .b_mock + .set_esdt_balance(&first_user, FARMING_TOKEN_ID, &rust_biguint!(0)); + + // tx to collect rewards + let second_user = fs_setup.b_mock.create_user_account(&rust_biguint!(0)); + fs_setup.b_mock.set_esdt_balance( + &second_user, + FARMING_TOKEN_ID, + &rust_biguint!(USER_TOTAL_RIDE_TOKENS), + ); + + fs_setup.set_user_energy(&second_user, 1, 6, 1); + fs_setup.stake_farm(&second_user, 10, &[], 2, 3_000_000u64, 0); + fs_setup.unstake_farm_no_checks(&second_user, 10, 2); + + let farm_rps_increase = 3_000_000u64; + let mut current_farm_rps = 0; + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 13, 1); + fs_setup.b_mock.set_block_nonce(200); + fs_setup.b_mock.set_block_epoch(13); + + let boosted_rewards_for_week = 100; + fs_setup.claim_boosted_rewards_for_user(&second_user, &second_user, 0, &rust_biguint!(0)); + + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + + // advance 1 week + fs_setup.set_user_energy(&first_user, 1_000, 15, 1); + fs_setup.b_mock.set_block_nonce(300); + fs_setup.b_mock.set_block_epoch(15); + fs_setup.claim_boosted_rewards_for_user( + &first_user, + &first_user, + boosted_rewards_for_week * 2, + &rust_biguint!(boosted_rewards_for_week * 2), + ); + + current_farm_rps += farm_rps_increase; + fs_setup.check_farm_rps(current_farm_rps); + fs_setup.b_mock.check_esdt_balance( + &first_user, + REWARD_TOKEN_ID, + &rust_biguint!(boosted_rewards_for_week * 2), + ); + + let expected_attributes = StakingFarmTokenAttributes:: { + reward_per_share: managed_biguint!(0), + compounded_reward: managed_biguint!(0), + current_farm_amount: managed_biguint!(farm_in_amount), + original_owner: managed_address!(&first_user), + }; + + fs_setup.b_mock.check_nft_balance( + &first_user, + FARM_TOKEN_ID, + 1, + &rust_biguint!(farm_in_amount), + Some(&expected_attributes), + ); +} From 57c06a5e3d5d30fa43d21bc013a4d9ddfc6c83bc Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Sat, 3 Aug 2024 12:43:49 +0300 Subject: [PATCH 096/103] restore energy factory proxy in query module --- energy-integration/common-modules/energy-query/src/lib.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/energy-integration/common-modules/energy-query/src/lib.rs b/energy-integration/common-modules/energy-query/src/lib.rs index 00ee89507..4f4e2e7af 100644 --- a/energy-integration/common-modules/energy-query/src/lib.rs +++ b/energy-integration/common-modules/energy-query/src/lib.rs @@ -77,6 +77,9 @@ pub trait EnergyQueryModule { .read_from_address(&energy_factory_address, key) } + #[proxy] + fn energy_factory_proxy(&self, sc_address: ManagedAddress) -> energy_factory::Proxy; + #[view(getEnergyFactoryAddress)] #[storage_mapper("energyFactoryAddress")] fn energy_factory_address(&self) -> SingleValueMapper; From 984f596252e81687e6167c6ab39b1123f7a60914 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Sat, 3 Aug 2024 12:49:40 +0300 Subject: [PATCH 097/103] proxy dex legacy reference fix --- legacy-contracts/proxy-dex-legacy/src/energy_update.rs | 3 --- 1 file changed, 3 deletions(-) diff --git a/legacy-contracts/proxy-dex-legacy/src/energy_update.rs b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs index 880cce46b..b4e30f9bf 100644 --- a/legacy-contracts/proxy-dex-legacy/src/energy_update.rs +++ b/legacy-contracts/proxy-dex-legacy/src/energy_update.rs @@ -70,7 +70,4 @@ pub trait EnergyUpdateModule: ManagedBuffer::new_from_bytes(EXTENDED_ATTRIBUTES_ACTIVATION_NONCE_KEY), ) } - - #[proxy] - fn energy_factory_proxy(&self, sc_address: ManagedAddress) -> energy_factory::Proxy; } From afdccc1ff45a97a89afef2e686c418779b5dc5e6 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Sat, 3 Aug 2024 12:53:44 +0300 Subject: [PATCH 098/103] github actions update --- .../workflows/on_pull_request_build_contracts.yml | 14 -------------- 1 file changed, 14 deletions(-) delete mode 100644 .github/workflows/on_pull_request_build_contracts.yml diff --git a/.github/workflows/on_pull_request_build_contracts.yml b/.github/workflows/on_pull_request_build_contracts.yml deleted file mode 100644 index dd4b3713c..000000000 --- a/.github/workflows/on_pull_request_build_contracts.yml +++ /dev/null @@ -1,14 +0,0 @@ -name: On pull request, build contracts - -on: - pull_request: - -permissions: - contents: write - -jobs: - build: - uses: multiversx/mx-sc-actions/.github/workflows/reproducible-build.yml@v3.2.0 - with: - image_tag: v7.0.0 - package_whole_project_src: true \ No newline at end of file From b05f46e08cc69165fb53a40fca6e5fb74e97d121 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Mon, 12 Aug 2024 23:59:01 +0300 Subject: [PATCH 099/103] audit updates --- legacy-contracts/factory-legacy/src/lib.rs | 3 +++ .../factory-legacy/wasm/src/lib.rs | 4 ++- legacy-contracts/farm-v12/src/lib.rs | 25 ++++++++++--------- .../farm-v13-custom-rewards/src/lib.rs | 25 +++++++++++-------- .../farm-v13-locked-rewards/src/lib.rs | 3 --- .../farm-v13-locked-rewards/wasm/src/lib.rs | 4 +-- legacy-contracts/farm-v13/src/lib.rs | 5 +--- legacy-contracts/farm-v13/wasm/src/lib.rs | 4 +-- .../price-discovery-v1/src/lib.rs | 20 +++++++++++++++ .../price-discovery-v1/wasm/src/lib.rs | 8 ++++-- .../price-discovery-v2/src/lib.rs | 20 +++++++++++++++ .../price-discovery-v2/wasm/src/lib.rs | 8 ++++-- legacy-contracts/proxy-dex-legacy/src/lib.rs | 3 +++ .../proxy-dex-legacy/wasm/src/lib.rs | 4 ++- 14 files changed, 94 insertions(+), 42 deletions(-) diff --git a/legacy-contracts/factory-legacy/src/lib.rs b/legacy-contracts/factory-legacy/src/lib.rs index 56449f8d1..1a5f01ad3 100644 --- a/legacy-contracts/factory-legacy/src/lib.rs +++ b/legacy-contracts/factory-legacy/src/lib.rs @@ -49,6 +49,9 @@ pub trait LockedAssetFactory: self.set_paused(true); } + #[upgrade] + fn upgrade(&self) {} + #[only_owner] #[endpoint] fn whitelist(&self, address: ManagedAddress) { diff --git a/legacy-contracts/factory-legacy/wasm/src/lib.rs b/legacy-contracts/factory-legacy/wasm/src/lib.rs index 1ddbeb62c..80a5bf559 100644 --- a/legacy-contracts/factory-legacy/wasm/src/lib.rs +++ b/legacy-contracts/factory-legacy/wasm/src/lib.rs @@ -5,9 +5,10 @@ //////////////////////////////////////////////////// // Init: 1 +// Upgrade: 1 // Endpoints: 21 // Async Callback (empty): 1 -// Total number of exported functions: 23 +// Total number of exported functions: 24 #![no_std] @@ -18,6 +19,7 @@ multiversx_sc_wasm_adapter::endpoints! { factory_legacy ( init => init + upgrade => upgrade whitelist => whitelist removeWhitelist => remove_whitelist createAndForwardCustomPeriod => create_and_forward_custom_period diff --git a/legacy-contracts/farm-v12/src/lib.rs b/legacy-contracts/farm-v12/src/lib.rs index c126c2135..806ae3bcf 100644 --- a/legacy-contracts/farm-v12/src/lib.rs +++ b/legacy-contracts/farm-v12/src/lib.rs @@ -1,4 +1,5 @@ #![no_std] +#![allow(deprecated)] use multiversx_sc::derive_imports::*; use multiversx_sc::imports::*; @@ -21,7 +22,7 @@ pub trait FarmV12 { #[payable("*")] #[endpoint(acceptFee)] - fn accept_fee(&self, _token_in: TokenIdentifier, _amount: BigUint) { + fn accept_fee(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -30,12 +31,12 @@ pub trait FarmV12 { &self, _amount: BigUint, _attributes_raw: ManagedBuffer, - ) -> BigUint { + ) -> SCResult { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(end_produce_rewards_as_owner)] - fn end_produce_rewards_as_owner(&self) { + fn end_produce_rewards_as_owner(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -44,7 +45,7 @@ pub trait FarmV12 { fn exit_farm( &self, _opt_accept_funds_func: OptionalValue, - ) -> ExitFarmResultType { + ) -> SCResult> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -164,17 +165,17 @@ pub trait FarmV12 { } #[endpoint(pause)] - fn pause(&self) { + fn pause(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(resume)] - fn resume(&self) { + fn resume(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(setPerBlockRewardAmount)] - fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) { + fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -185,27 +186,27 @@ pub trait FarmV12 { } #[endpoint(set_locked_rewards_apr_multiplier)] - fn set_locked_rewards_apr_multiplier(&self, _muliplier: u8) { + fn set_locked_rewards_apr_multiplier(&self, _muliplier: u8) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_minimum_farming_epochs)] - fn set_minimum_farming_epochs(&self, _epochs: u8) { + fn set_minimum_farming_epochs(&self, _epochs: u8) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_penalty_percent)] - fn set_penalty_percent(&self, _percent: u64) { + fn set_penalty_percent(&self, _percent: u64) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_transfer_exec_gas_limit)] - fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { + fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(start_produce_rewards)] - fn start_produce_rewards(&self) { + fn start_produce_rewards(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } } diff --git a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs index 4708be991..40607fba0 100644 --- a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs @@ -1,4 +1,5 @@ #![no_std] +#![allow(deprecated)] use multiversx_sc::derive_imports::*; use multiversx_sc::imports::*; @@ -27,9 +28,11 @@ pub struct FarmTokenAttributes { } #[multiversx_sc::contract] -pub trait FarmV13LockedRewards { +pub trait FarmV13CustomRewards { #[init] - fn init(&self) {} + fn init(&self) -> SCResult<()> { + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); + } #[only_owner] #[endpoint(addAddressToWhitelist)] @@ -42,7 +45,7 @@ pub trait FarmV13LockedRewards { &self, _amount: BigUint, _attributes: FarmTokenAttributes, - ) -> BigUint { + ) -> SCResult { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -51,19 +54,19 @@ pub trait FarmV13LockedRewards { fn claim_rewards( &self, _opt_accept_funds_func: OptionalValue, - ) -> ClaimRewardsResultType { + ) -> SCResult> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[only_owner] #[payable("*")] #[endpoint(depositRewards)] - fn deposit_rewards(&self) { + fn deposit_rewards(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(end_produce_rewards)] - fn end_produce_rewards(&self) { + fn end_produce_rewards(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -72,7 +75,7 @@ pub trait FarmV13LockedRewards { fn enter_farm( &self, _opt_accept_funds_func: OptionalValue, - ) -> EnterFarmResultType { + ) -> SCResult> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -81,7 +84,7 @@ pub trait FarmV13LockedRewards { fn exit_farm( &self, _opt_accept_funds_func: OptionalValue, - ) -> ExitFarmResultType { + ) -> SCResult> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -180,7 +183,7 @@ pub trait FarmV13LockedRewards { fn merge_farm_tokens( &self, _opt_accept_funds_func: OptionalValue, - ) -> EsdtTokenPayment { + ) -> SCResult> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -213,7 +216,7 @@ pub trait FarmV13LockedRewards { #[only_owner] #[endpoint(setBlockForEndRewards)] - fn set_block_for_end_rewards(&self, _block_end: u64) { + fn set_block_for_end_rewards(&self, _block_end: u64) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -223,7 +226,7 @@ pub trait FarmV13LockedRewards { } #[endpoint(setPerBlockRewardAmount)] - fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) { + fn set_per_block_reward_amount(&self, _per_block_amount: BigUint) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } diff --git a/legacy-contracts/farm-v13-locked-rewards/src/lib.rs b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs index abd6f7bb8..1ab7cba04 100644 --- a/legacy-contracts/farm-v13-locked-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-locked-rewards/src/lib.rs @@ -64,9 +64,6 @@ pub trait FarmV13LockedRewards { #[init] fn init(&self) {} - #[upgrade] - fn upgrade(&self) {} - #[payable("*")] #[endpoint(exitFarm)] fn exit_farm( diff --git a/legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs b/legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs index c51ed969b..f45431ebf 100644 --- a/legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs +++ b/legacy-contracts/farm-v13-locked-rewards/wasm/src/lib.rs @@ -5,10 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Upgrade: 1 // Endpoints: 36 // Async Callback (empty): 1 -// Total number of exported functions: 39 +// Total number of exported functions: 38 #![no_std] @@ -19,7 +18,6 @@ multiversx_sc_wasm_adapter::endpoints! { farm_v13_locked_rewards ( init => init - upgrade => upgrade exitFarm => exit_farm mergeFarmTokens => merge_farm_tokens calculateRewardsForGivenPosition => calculate_rewards_for_given_position diff --git a/legacy-contracts/farm-v13/src/lib.rs b/legacy-contracts/farm-v13/src/lib.rs index 047d6923a..9d877876f 100644 --- a/legacy-contracts/farm-v13/src/lib.rs +++ b/legacy-contracts/farm-v13/src/lib.rs @@ -64,13 +64,10 @@ pub struct FarmMigrationConfig { } #[multiversx_sc::contract] -pub trait FarmV13LockedRewards { +pub trait FarmV13 { #[init] fn init(&self) {} - #[upgrade] - fn upgrade(&self) {} - #[payable("*")] #[endpoint(enterFarm)] fn enter_farm( diff --git a/legacy-contracts/farm-v13/wasm/src/lib.rs b/legacy-contracts/farm-v13/wasm/src/lib.rs index d589b7dbf..2fef50415 100644 --- a/legacy-contracts/farm-v13/wasm/src/lib.rs +++ b/legacy-contracts/farm-v13/wasm/src/lib.rs @@ -5,10 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Upgrade: 1 // Endpoints: 39 // Async Callback (empty): 1 -// Total number of exported functions: 42 +// Total number of exported functions: 41 #![no_std] @@ -19,7 +18,6 @@ multiversx_sc_wasm_adapter::endpoints! { farm_v13 ( init => init - upgrade => upgrade enterFarm => enter_farm exitFarm => exit_farm claimRewards => claim_rewards diff --git a/legacy-contracts/price-discovery-v1/src/lib.rs b/legacy-contracts/price-discovery-v1/src/lib.rs index 065cfecec..4ac38f975 100644 --- a/legacy-contracts/price-discovery-v1/src/lib.rs +++ b/legacy-contracts/price-discovery-v1/src/lib.rs @@ -63,6 +63,18 @@ pub trait PriceDiscoveryV1 { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } + #[only_owner] + #[endpoint(setLockingScAddress)] + fn set_locking_sc_address(&self, _new_address: ManagedAddress) { + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); + } + + #[only_owner] + #[endpoint(setUnlockEpoch)] + fn set_unlock_epoch(&self, _new_epoch: u64) { + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); + } + #[view(getLaunchedTokenId)] #[storage_mapper("launchedTokenId")] fn launched_token_id(&self) -> SingleValueMapper; @@ -127,4 +139,12 @@ pub trait PriceDiscoveryV1 { #[view(getFixedPenaltyPercentage)] #[storage_mapper("fixedPenaltyPercentage")] fn fixed_penalty_percentage(&self) -> SingleValueMapper; + + #[view(getLockingScAddress)] + #[storage_mapper("lockingScAddress")] + fn locking_sc_address(&self) -> SingleValueMapper; + + #[view(getUnlockEpoch)] + #[storage_mapper("unlockEpoch")] + fn unlock_epoch(&self) -> SingleValueMapper; } diff --git a/legacy-contracts/price-discovery-v1/wasm/src/lib.rs b/legacy-contracts/price-discovery-v1/wasm/src/lib.rs index 638f4282c..b056de3a2 100644 --- a/legacy-contracts/price-discovery-v1/wasm/src/lib.rs +++ b/legacy-contracts/price-discovery-v1/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 23 +// Endpoints: 27 // Async Callback (empty): 1 -// Total number of exported functions: 25 +// Total number of exported functions: 29 #![no_std] @@ -25,6 +25,8 @@ multiversx_sc_wasm_adapter::endpoints! { getCurrentPhase => get_current_phase issueRedeemToken => issue_redeem_token createInitialRedeemTokens => create_initial_redeem_tokens + setLockingScAddress => set_locking_sc_address + setUnlockEpoch => set_unlock_epoch getLaunchedTokenId => launched_token_id getAcceptedTokenId => accepted_token_id getLaunchedTokenBalance => launched_token_balance @@ -41,6 +43,8 @@ multiversx_sc_wasm_adapter::endpoints! { getPenaltyMinPercentage => penalty_min_percentage getPenaltyMaxPercentage => penalty_max_percentage getFixedPenaltyPercentage => fixed_penalty_percentage + getLockingScAddress => locking_sc_address + getUnlockEpoch => unlock_epoch ) } diff --git a/legacy-contracts/price-discovery-v2/src/lib.rs b/legacy-contracts/price-discovery-v2/src/lib.rs index cf63515a3..34de9499b 100644 --- a/legacy-contracts/price-discovery-v2/src/lib.rs +++ b/legacy-contracts/price-discovery-v2/src/lib.rs @@ -63,6 +63,18 @@ pub trait PriceDiscoveryV2 { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } + #[only_owner] + #[endpoint(setLockingScAddress)] + fn set_locking_sc_address(&self, _new_address: ManagedAddress) { + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); + } + + #[only_owner] + #[endpoint(setUnlockEpoch)] + fn set_unlock_epoch(&self, _new_epoch: u64) { + sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); + } + #[view(getLaunchedTokenId)] #[storage_mapper("launchedTokenId")] fn launched_token_id(&self) -> SingleValueMapper; @@ -127,4 +139,12 @@ pub trait PriceDiscoveryV2 { #[storage_mapper("totalCirculatingSupply")] fn redeem_token_total_circulating_supply(&self, token_nonce: u64) -> SingleValueMapper; + + #[view(getLockingScAddress)] + #[storage_mapper("lockingScAddress")] + fn locking_sc_address(&self) -> SingleValueMapper; + + #[view(getUnlockEpoch)] + #[storage_mapper("unlockEpoch")] + fn unlock_epoch(&self) -> SingleValueMapper; } diff --git a/legacy-contracts/price-discovery-v2/wasm/src/lib.rs b/legacy-contracts/price-discovery-v2/wasm/src/lib.rs index 30ec83460..e4ac1662c 100644 --- a/legacy-contracts/price-discovery-v2/wasm/src/lib.rs +++ b/legacy-contracts/price-discovery-v2/wasm/src/lib.rs @@ -5,9 +5,9 @@ //////////////////////////////////////////////////// // Init: 1 -// Endpoints: 23 +// Endpoints: 27 // Async Callback (empty): 1 -// Total number of exported functions: 25 +// Total number of exported functions: 29 #![no_std] @@ -25,6 +25,8 @@ multiversx_sc_wasm_adapter::endpoints! { getCurrentPhase => get_current_phase issueRedeemToken => issue_redeem_token createInitialRedeemTokens => create_initial_redeem_tokens + setLockingScAddress => set_locking_sc_address + setUnlockEpoch => set_unlock_epoch getLaunchedTokenId => launched_token_id getAcceptedTokenId => accepted_token_id getLaunchedTokenBalance => launched_token_balance @@ -41,6 +43,8 @@ multiversx_sc_wasm_adapter::endpoints! { getFixedPenaltyPercentage => fixed_penalty_percentage getRedeemTokenId => redeem_token getRedeemTokenTotalCirculatingSupply => redeem_token_total_circulating_supply + getLockingScAddress => locking_sc_address + getUnlockEpoch => unlock_epoch ) } diff --git a/legacy-contracts/proxy-dex-legacy/src/lib.rs b/legacy-contracts/proxy-dex-legacy/src/lib.rs index d5034c31d..a93923c71 100644 --- a/legacy-contracts/proxy-dex-legacy/src/lib.rs +++ b/legacy-contracts/proxy-dex-legacy/src/lib.rs @@ -26,4 +26,7 @@ pub trait ProxyDexImpl: { #[init] fn init(&self) {} + + #[upgrade] + fn upgrade(&self) {} } diff --git a/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs b/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs index bc4c8d085..4711ddb98 100644 --- a/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs +++ b/legacy-contracts/proxy-dex-legacy/wasm/src/lib.rs @@ -5,9 +5,10 @@ //////////////////////////////////////////////////// // Init: 1 +// Upgrade: 1 // Endpoints: 19 // Async Callback (empty): 1 -// Total number of exported functions: 21 +// Total number of exported functions: 22 #![no_std] @@ -18,6 +19,7 @@ multiversx_sc_wasm_adapter::endpoints! { proxy_dex_legacy ( init => init + upgrade => upgrade getAssetTokenId => asset_token_id getLockedAssetTokenId => locked_asset_token_id getWrappedLpTokenId => wrapped_lp_token_id From 343a9edc5432aedac9b7cce714bd0a83f6ddd0de Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 13 Aug 2024 11:05:07 +0300 Subject: [PATCH 100/103] further audit fixes --- .../farm-v13-custom-rewards/src/lib.rs | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs index 40607fba0..55292216f 100644 --- a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs @@ -188,7 +188,7 @@ pub trait FarmV13CustomRewards { } #[endpoint(pause)] - fn pause(&self) { + fn pause(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -199,7 +199,7 @@ pub trait FarmV13CustomRewards { _token_display_name: ManagedBuffer, _token_ticker: ManagedBuffer, _num_decimals: usize, - ) { + ) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -210,7 +210,7 @@ pub trait FarmV13CustomRewards { } #[endpoint(resume)] - fn resume(&self) { + fn resume(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -221,7 +221,7 @@ pub trait FarmV13CustomRewards { } #[endpoint(setLocalRolesFarmToken)] - fn set_local_roles_farm_token(&self) { + fn set_local_roles_farm_token(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -231,27 +231,27 @@ pub trait FarmV13CustomRewards { } #[endpoint(set_burn_gas_limit)] - fn set_burn_gas_limit(&self, _gas_limit: u64) { + fn set_burn_gas_limit(&self, _gas_limit: u64) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_minimum_farming_epochs)] - fn set_minimum_farming_epochs(&self, _epochs: u8) { + fn set_minimum_farming_epochs(&self, _epochs: u8) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_penalty_percent)] - fn set_penalty_percent(&self, _percent: u64) { + fn set_penalty_percent(&self, _percent: u64) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(set_transfer_exec_gas_limit)] - fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) { + fn set_transfer_exec_gas_limit(&self, _gas_limit: u64) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } #[endpoint(startProduceRewards)] - fn start_produce_rewards(&self) { + fn start_produce_rewards(&self) -> SCResult<()> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } } From d7463a0a0f77782e44865a1722ca9f95b05d58fc Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Tue, 13 Aug 2024 16:13:05 +0300 Subject: [PATCH 101/103] add INCORRECTReturnType in legacy contracts --- legacy-contracts/farm-v12/src/lib.rs | 6 +++++- legacy-contracts/farm-v13-custom-rewards/src/lib.rs | 5 +++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/legacy-contracts/farm-v12/src/lib.rs b/legacy-contracts/farm-v12/src/lib.rs index 806ae3bcf..8c0d9a9d1 100644 --- a/legacy-contracts/farm-v12/src/lib.rs +++ b/legacy-contracts/farm-v12/src/lib.rs @@ -7,6 +7,7 @@ use multiversx_sc::imports::*; type Nonce = u64; type ExitFarmResultType = MultiValue2, EsdtTokenPayment>; +type INCORRECTReturnType = ManagedBuffer; #[derive(TopEncode, TopDecode, PartialEq, TypeAbi)] pub enum State { @@ -181,7 +182,10 @@ pub trait FarmV12 { #[only_owner] #[endpoint(setTransferRoleFarmToken)] - fn set_transfer_role_farm_token(&self, _opt_address: OptionalValue) { + fn set_transfer_role_farm_token( + &self, + _opt_address: OptionalValue, + ) -> INCORRECTReturnType { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } diff --git a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs index 55292216f..c1217bb56 100644 --- a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs @@ -10,6 +10,7 @@ type ClaimRewardsResultType = MultiValue2, EsdtTokenPayment>; type ExitFarmResultType = MultiValue2, EsdtTokenPayment>; +type INCORRECTReturnType = ManagedBuffer; #[derive(TopEncode, TopDecode, PartialEq, TypeAbi)] pub enum State { @@ -199,7 +200,7 @@ pub trait FarmV13CustomRewards { _token_display_name: ManagedBuffer, _token_ticker: ManagedBuffer, _num_decimals: usize, - ) -> SCResult<()> { + ) -> SCResult> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -221,7 +222,7 @@ pub trait FarmV13CustomRewards { } #[endpoint(setLocalRolesFarmToken)] - fn set_local_roles_farm_token(&self) -> SCResult<()> { + fn set_local_roles_farm_token(&self) -> SCResult> { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } From 57d14d98fa2a47fc46464c1a81f57908612409c6 Mon Sep 17 00:00:00 2001 From: Sorin Petreasca Date: Wed, 14 Aug 2024 10:19:33 +0300 Subject: [PATCH 102/103] small fix --- legacy-contracts/farm-v13-custom-rewards/src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs index c1217bb56..71cf8cf0d 100644 --- a/legacy-contracts/farm-v13-custom-rewards/src/lib.rs +++ b/legacy-contracts/farm-v13-custom-rewards/src/lib.rs @@ -200,7 +200,7 @@ pub trait FarmV13CustomRewards { _token_display_name: ManagedBuffer, _token_ticker: ManagedBuffer, _num_decimals: usize, - ) -> SCResult> { + ) -> INCORRECTReturnType { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } @@ -222,7 +222,7 @@ pub trait FarmV13CustomRewards { } #[endpoint(setLocalRolesFarmToken)] - fn set_local_roles_farm_token(&self) -> SCResult> { + fn set_local_roles_farm_token(&self) -> INCORRECTReturnType { sc_panic!("This is a no-code version of a legacy contract. The logic of the endpoints has not been implemented."); } From 5712bb35961351d9ad03f339d9b48bc626670637 Mon Sep 17 00:00:00 2001 From: Mihai Calin Luca Date: Wed, 4 Sep 2024 10:45:53 +0200 Subject: [PATCH 103/103] upgrade to 0.52.3 --- Cargo.lock | 955 +++--- common/common_errors/Cargo.toml | 2 +- common/common_structs/Cargo.toml | 2 +- common/modules/farm/config/Cargo.toml | 2 +- common/modules/farm/contexts/Cargo.toml | 4 +- common/modules/farm/events/Cargo.toml | 2 +- common/modules/farm/farm_base_impl/Cargo.toml | 6 +- common/modules/farm/farm_token/Cargo.toml | 4 +- .../modules/farm/farm_token_merge/Cargo.toml | 4 +- common/modules/farm/rewards/Cargo.toml | 4 +- .../legacy_token_decode_module/Cargo.toml | 2 +- common/modules/locking_module/Cargo.toml | 2 +- common/modules/math/Cargo.toml | 2 +- common/modules/pausable/Cargo.toml | 2 +- common/modules/permissions_module/Cargo.toml | 2 +- common/modules/sc_whitelist_module/Cargo.toml | 2 +- common/modules/token_merge_helper/Cargo.toml | 2 +- common/modules/token_send/Cargo.toml | 2 +- common/modules/utils/Cargo.toml | 2 +- common/traits/fixed-supply-token/Cargo.toml | 2 +- common/traits/mergeable/Cargo.toml | 2 +- common/traits/unwrappable/Cargo.toml | 2 +- dex/Cargo.toml | 6 +- dex/farm-with-locked-rewards/Cargo.toml | 6 +- dex/farm-with-locked-rewards/meta/Cargo.toml | 2 +- dex/farm-with-locked-rewards/wasm/Cargo.lock | 48 +- dex/farm-with-locked-rewards/wasm/Cargo.toml | 2 +- dex/farm/Cargo.toml | 6 +- dex/farm/meta/Cargo.toml | 2 +- dex/farm/wasm/Cargo.lock | 48 +- dex/farm/wasm/Cargo.toml | 2 +- dex/fuzz/Cargo.toml | 4 +- dex/governance/Cargo.toml | 4 +- dex/governance/meta/Cargo.toml | 2 +- dex/governance/wasm/Cargo.lock | 40 +- dex/governance/wasm/Cargo.toml | 2 +- dex/pair-mock/Cargo.toml | 4 +- dex/pair-mock/meta/Cargo.toml | 2 +- dex/pair-mock/wasm/Cargo.lock | 44 +- dex/pair-mock/wasm/Cargo.toml | 2 +- dex/pair/Cargo.toml | 4 +- dex/pair/meta/Cargo.toml | 2 +- dex/pair/wasm-pair-full/Cargo.lock | 48 +- dex/pair/wasm-pair-full/Cargo.toml | 2 +- dex/pair/wasm-safe-price-view/Cargo.lock | 48 +- dex/pair/wasm-safe-price-view/Cargo.toml | 2 +- dex/pair/wasm/Cargo.lock | 48 +- dex/pair/wasm/Cargo.toml | 2 +- dex/price-discovery/Cargo.toml | 6 +- dex/price-discovery/meta/Cargo.toml | 2 +- dex/price-discovery/wasm/Cargo.lock | 44 +- dex/price-discovery/wasm/Cargo.toml | 2 +- dex/proxy-deployer/Cargo.toml | 4 +- dex/proxy-deployer/meta/Cargo.toml | 2 +- dex/proxy-deployer/wasm/Cargo.lock | 48 +- dex/proxy-deployer/wasm/Cargo.toml | 2 +- dex/router/Cargo.toml | 4 +- dex/router/meta/Cargo.toml | 2 +- dex/router/wasm/Cargo.lock | 48 +- dex/router/wasm/Cargo.toml | 2 +- .../common-modules/energy-query/Cargo.toml | 2 +- .../week-timekeeping/Cargo.toml | 2 +- .../weekly-rewards-splitting/Cargo.toml | 2 +- energy-integration/common-types/Cargo.toml | 2 +- .../energy-factory-mock/Cargo.toml | 4 +- .../energy-factory-mock/meta/Cargo.toml | 2 +- .../energy-factory-mock/wasm/Cargo.lock | 44 +- .../energy-factory-mock/wasm/Cargo.toml | 2 +- energy-integration/energy-update/Cargo.toml | 6 +- .../energy-update/meta/Cargo.toml | 2 +- .../energy-update/wasm/Cargo.lock | 48 +- .../energy-update/wasm/Cargo.toml | 2 +- .../farm-boosted-yields/Cargo.toml | 2 +- energy-integration/fees-collector/Cargo.toml | 6 +- .../fees-collector/meta/Cargo.toml | 2 +- .../fees-collector/wasm/Cargo.lock | 44 +- .../fees-collector/wasm/Cargo.toml | 2 +- energy-integration/governance-v2/Cargo.toml | 4 +- .../governance-v2/meta/Cargo.toml | 2 +- .../governance-v2/wasm/Cargo.lock | 44 +- .../governance-v2/wasm/Cargo.toml | 2 +- farm-staking/farm-staking-proxy/Cargo.toml | 6 +- .../farm-staking-proxy/meta/Cargo.toml | 2 +- .../farm-staking-proxy/wasm/Cargo.lock | 48 +- .../farm-staking-proxy/wasm/Cargo.toml | 2 +- farm-staking/farm-staking/Cargo.toml | 6 +- farm-staking/farm-staking/meta/Cargo.toml | 2 +- farm-staking/farm-staking/wasm/Cargo.lock | 48 +- farm-staking/farm-staking/wasm/Cargo.toml | 2 +- farm-staking/metabonding-staking/Cargo.toml | 6 +- .../metabonding-staking/meta/Cargo.toml | 2 +- .../metabonding-staking/wasm/Cargo.lock | 52 +- .../metabonding-staking/wasm/Cargo.toml | 2 +- legacy-contracts/factory-legacy/Cargo.toml | 6 +- .../factory-legacy/meta/Cargo.toml | 2 +- .../factory-legacy/wasm/Cargo.lock | 40 +- .../factory-legacy/wasm/Cargo.toml | 2 +- .../farm-staking-proxy-v13/Cargo.toml | 6 +- .../farm-staking-proxy-v13/meta/Cargo.toml | 2 +- .../farm-staking-proxy-v13/wasm/Cargo.lock | 44 +- .../farm-staking-proxy-v13/wasm/Cargo.toml | 2 +- legacy-contracts/farm-v12/Cargo.lock | 2593 ----------------- legacy-contracts/farm-v12/Cargo.toml | 4 +- legacy-contracts/farm-v12/meta/Cargo.toml | 2 +- legacy-contracts/farm-v12/wasm/Cargo.lock | 32 +- legacy-contracts/farm-v12/wasm/Cargo.toml | 2 +- .../farm-v13-custom-rewards/Cargo.lock | 2593 ----------------- .../farm-v13-custom-rewards/Cargo.toml | 4 +- .../farm-v13-custom-rewards/meta/Cargo.toml | 2 +- .../farm-v13-custom-rewards/wasm/Cargo.lock | 32 +- .../farm-v13-custom-rewards/wasm/Cargo.toml | 2 +- .../farm-v13-locked-rewards/Cargo.lock | 2593 ----------------- .../farm-v13-locked-rewards/Cargo.toml | 4 +- .../farm-v13-locked-rewards/meta/Cargo.toml | 2 +- .../farm-v13-locked-rewards/wasm/Cargo.lock | 32 +- .../farm-v13-locked-rewards/wasm/Cargo.toml | 2 +- legacy-contracts/farm-v13/Cargo.lock | 2593 ----------------- legacy-contracts/farm-v13/Cargo.toml | 4 +- legacy-contracts/farm-v13/meta/Cargo.toml | 2 +- legacy-contracts/farm-v13/wasm/Cargo.lock | 32 +- legacy-contracts/farm-v13/wasm/Cargo.toml | 2 +- .../price-discovery-v1/Cargo.lock | 2593 ----------------- .../price-discovery-v1/Cargo.toml | 4 +- .../price-discovery-v1/meta/Cargo.toml | 2 +- .../price-discovery-v1/wasm/Cargo.lock | 32 +- .../price-discovery-v1/wasm/Cargo.toml | 2 +- .../price-discovery-v2/Cargo.lock | 2593 ----------------- .../price-discovery-v2/Cargo.toml | 4 +- .../price-discovery-v2/meta/Cargo.toml | 2 +- .../price-discovery-v2/wasm/Cargo.lock | 32 +- .../price-discovery-v2/wasm/Cargo.toml | 2 +- legacy-contracts/proxy-dex-legacy/Cargo.toml | 4 +- .../proxy-dex-legacy/meta/Cargo.toml | 2 +- .../proxy-dex-legacy/wasm/Cargo.lock | 40 +- .../proxy-dex-legacy/wasm/Cargo.toml | 2 +- .../simple-lock-legacy/Cargo.toml | 6 +- .../simple-lock-legacy/meta/Cargo.toml | 2 +- .../simple-lock-legacy/wasm/Cargo.lock | 44 +- .../simple-lock-legacy/wasm/Cargo.toml | 2 +- locked-asset/Cargo.toml | 6 +- locked-asset/distribution/Cargo.toml | 4 +- locked-asset/distribution/meta/Cargo.toml | 2 +- locked-asset/distribution/wasm/Cargo.lock | 52 +- locked-asset/distribution/wasm/Cargo.toml | 2 +- locked-asset/energy-factory/Cargo.toml | 6 +- locked-asset/energy-factory/meta/Cargo.toml | 2 +- locked-asset/energy-factory/wasm/Cargo.lock | 44 +- locked-asset/energy-factory/wasm/Cargo.toml | 2 +- locked-asset/factory/Cargo.toml | 6 +- locked-asset/factory/meta/Cargo.toml | 2 +- locked-asset/factory/wasm/Cargo.lock | 52 +- locked-asset/factory/wasm/Cargo.toml | 2 +- locked-asset/lkmex-transfer/Cargo.toml | 6 +- locked-asset/lkmex-transfer/meta/Cargo.toml | 2 +- locked-asset/lkmex-transfer/wasm/Cargo.lock | 44 +- locked-asset/lkmex-transfer/wasm/Cargo.toml | 2 +- locked-asset/locked-token-wrapper/Cargo.toml | 6 +- .../locked-token-wrapper/meta/Cargo.toml | 2 +- .../locked-token-wrapper/wasm/Cargo.lock | 44 +- .../locked-token-wrapper/wasm/Cargo.toml | 2 +- locked-asset/proxy_dex/Cargo.toml | 6 +- locked-asset/proxy_dex/meta/Cargo.toml | 2 +- locked-asset/proxy_dex/wasm/Cargo.lock | 48 +- locked-asset/proxy_dex/wasm/Cargo.toml | 2 +- locked-asset/simple-lock/Cargo.toml | 6 +- locked-asset/simple-lock/meta/Cargo.toml | 2 +- locked-asset/simple-lock/wasm/Cargo.lock | 44 +- locked-asset/simple-lock/wasm/Cargo.toml | 2 +- locked-asset/token-unstake/Cargo.toml | 6 +- locked-asset/token-unstake/meta/Cargo.toml | 2 +- locked-asset/token-unstake/wasm/Cargo.lock | 44 +- locked-asset/token-unstake/wasm/Cargo.toml | 2 +- pause-all/Cargo.toml | 6 +- pause-all/meta/Cargo.toml | 2 +- pause-all/wasm/Cargo.lock | 44 +- pause-all/wasm/Cargo.toml | 2 +- 176 files changed, 1579 insertions(+), 16896 deletions(-) delete mode 100644 legacy-contracts/farm-v12/Cargo.lock delete mode 100644 legacy-contracts/farm-v13-custom-rewards/Cargo.lock delete mode 100644 legacy-contracts/farm-v13-locked-rewards/Cargo.lock delete mode 100644 legacy-contracts/farm-v13/Cargo.lock delete mode 100644 legacy-contracts/price-discovery-v1/Cargo.lock delete mode 100644 legacy-contracts/price-discovery-v2/Cargo.lock diff --git a/Cargo.lock b/Cargo.lock index 3b7a33332..d5983c1c7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -14,9 +14,9 @@ dependencies = [ [[package]] name = "addr2line" -version = "0.21.0" +version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" dependencies = [ "gimli", ] @@ -27,6 +27,12 @@ version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" +[[package]] +name = "adler2" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627" + [[package]] name = "ahash" version = "0.8.11" @@ -41,56 +47,57 @@ dependencies = [ [[package]] name = "aho-corasick" -version = "1.1.2" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" dependencies = [ "memchr", ] [[package]] name = "anstream" -version = "0.6.11" +version = "0.6.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e2e1ebcb11de5c03c67de28a7df593d32191b44939c482e97702baaaa6ab6a5" +checksum = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" dependencies = [ "anstyle", "anstyle-parse", "anstyle-query", "anstyle-wincon", "colorchoice", + "is_terminal_polyfill", "utf8parse", ] [[package]] name = "anstyle" -version = "1.0.4" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7079075b41f533b8c61d2a4d073c4676e1f8b249ff94a393b0595db304e0dd87" +checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" [[package]] name = "anstyle-parse" -version = "0.2.3" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c75ac65da39e5fe5ab759307499ddad880d724eed2f6ce5b5e8a26f4f387928c" +checksum = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.2" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e28923312444cdd728e4738b3f9c9cac739500909bb3d3c94b43551b16517648" +checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" dependencies = [ "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.2" +version = "3.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cd54b81ec8d6180e24654d0b371ad22fc3dd083b6ff8ba325b72e00c87660a7" +checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" dependencies = [ "anstyle", "windows-sys 0.52.0", @@ -98,9 +105,9 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.79" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "080e9890a082662b09c1ad45f567faeeb47f22b5fb23895fbe1e651e718e25ca" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" [[package]] name = "arbitrary" @@ -125,31 +132,25 @@ checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "backtrace" -version = "0.3.69" +version = "0.3.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2089b7e3f35b9dd2d0ed921ead4f6d318c27680d4a5bd167b3ee120edb105837" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" dependencies = [ "addr2line", "cc", "cfg-if 1.0.0", "libc", - "miniz_oxide", + "miniz_oxide 0.7.4", "object", "rustc-demangle", ] -[[package]] -name = "base64" -version = "0.21.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" - [[package]] name = "base64" version = "0.22.1" @@ -183,15 +184,9 @@ checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" [[package]] name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "block-buffer" @@ -213,9 +208,9 @@ dependencies = [ [[package]] name = "bstr" -version = "1.9.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c48f0051a4b4c5e0b6d365cd04af53aeaa209e3cc15ec2cdb69e73cc87fbd0dc" +checksum = "40723b8fb387abc38f4f4a37c09073622e41dd12327033091ef8950659e6dc0c" dependencies = [ "memchr", "serde", @@ -235,17 +230,17 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.5.0" +version = "1.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" +checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" [[package]] name = "cc" -version = "1.0.83" +version = "1.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1174fb0b6ec23863f8b971027804a42614e347eafb0a95bf0b12cdae21fc4d0" +checksum = "57b6a275aa2903740dc87da01c62040406b8812552e97129a63ea8850a17c6e6" dependencies = [ - "libc", + "shlex", ] [[package]] @@ -262,9 +257,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "clap" -version = "4.4.18" +version = "4.5.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e578d6ec4194633722ccf9544794b71b1385c3c027efe0c55db226fc880865c" +checksum = "ed6719fffa43d0d87e5fd8caeab59be1554fb028cd30edc88fc4369b17971019" dependencies = [ "clap_builder", "clap_derive", @@ -272,9 +267,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.4.18" +version = "4.5.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4df4df40ec50c46000231c914968278b1eb05098cf8f1b3a518a95030e71d1c7" +checksum = "216aec2b177652e3846684cbfe25c9964d18ec45234f0f5da5157b207ed1aab6" dependencies = [ "anstream", "anstyle", @@ -284,9 +279,9 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.4.7" +version = "4.5.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf9804afaaf59a91e75b022a30fb7229a7901f60c755489cc61c9b423b836442" +checksum = "501d359d5f3dcaf6ecdeee48833ae73ec6e42723a1e52419c79abf9507eec0a0" dependencies = [ "heck", "proc-macro2", @@ -296,15 +291,15 @@ dependencies = [ [[package]] name = "clap_lex" -version = "0.6.0" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "702fc72eb24e5a1e48ce58027a675bc24edd52096d5397d4aea7c6dd9eca0bd1" +checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" [[package]] name = "colorchoice" -version = "1.0.0" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" +checksum = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" [[package]] name = "colored" @@ -406,15 +401,15 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.6" +version = "0.8.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" +checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" [[package]] name = "cpufeatures" -version = "0.2.12" +version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" +checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" dependencies = [ "libc", ] @@ -535,9 +530,9 @@ dependencies = [ [[package]] name = "displaydoc" -version = "0.2.4" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" +checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" dependencies = [ "proc-macro2", "quote", @@ -611,15 +606,15 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "encoding_rs" -version = "0.8.33" +version = "0.8.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7268b386296a025e474d5140678f75d6de9493ae55a5d709eeb9dd08149945e1" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" dependencies = [ "cfg-if 1.0.0", ] @@ -703,6 +698,29 @@ dependencies = [ "multiversx-sc-meta", ] +[[package]] +name = "env_filter" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f2c92ceda6ceec50f43169f9ee8424fe2db276791afde7b2cd8bc084cb376ab" +dependencies = [ + "log", + "regex", +] + +[[package]] +name = "env_logger" +version = "0.11.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13fa619b91fb2381732789fc5de83b45675e882f66623b7d8cb4f643017018d" +dependencies = [ + "anstream", + "anstyle", + "env_filter", + "humantime", + "log", +] + [[package]] name = "equivalent" version = "1.0.1" @@ -711,9 +729,9 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" dependencies = [ "libc", "windows-sys 0.52.0", @@ -1093,9 +1111,9 @@ dependencies = [ [[package]] name = "fastrand" -version = "2.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" +checksum = "e8c02a5121d4ea3eb16a80748c74f5549a5665e4c21333c6098f283870fbdea6" [[package]] name = "fees-collector" @@ -1134,12 +1152,12 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.30" +version = "1.0.33" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" +checksum = "324a1be68054ef05ad64b861cc9eaf1d623d2d8cb25b4bf2cb9cdd902b4bf253" dependencies = [ "crc32fast", - "miniz_oxide", + "miniz_oxide 0.8.0", ] [[package]] @@ -1172,6 +1190,21 @@ dependencies = [ "percent-encoding", ] +[[package]] +name = "futures" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "645c6916888f6cb6350d2550b80fb63e734897a8498abe35cfb732b6487804b0" +dependencies = [ + "futures-channel", + "futures-core", + "futures-executor", + "futures-io", + "futures-sink", + "futures-task", + "futures-util", +] + [[package]] name = "futures-channel" version = "0.3.30" @@ -1188,12 +1221,34 @@ version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" +[[package]] +name = "futures-executor" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a576fc72ae164fca6b9db127eaa9a9dda0d61316034f33a0a0d4eda41f02b01d" +dependencies = [ + "futures-core", + "futures-task", + "futures-util", +] + [[package]] name = "futures-io" version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" +[[package]] +name = "futures-macro" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "futures-sink" version = "0.3.30" @@ -1212,8 +1267,10 @@ version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" dependencies = [ + "futures-channel", "futures-core", "futures-io", + "futures-macro", "futures-sink", "futures-task", "memchr", @@ -1268,9 +1325,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.12" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "190092ea657667030ac6a35e305e62fc4dd69fd98ac98631e5d3a2b1575a12b5" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if 1.0.0", "libc", @@ -1279,9 +1336,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.28.1" +version = "0.29.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4271d37baee1b8c7e4b708028c57d816cf9d2434acb33a549475f78c181f6253" +checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" [[package]] name = "globset" @@ -1338,9 +1395,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" +checksum = "524e8ac6999421f49a846c2d4411f337e53497d8ec55d67753beffa43c5d9205" dependencies = [ "atomic-waker", "bytes", @@ -1357,9 +1414,9 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.3" +version = "0.14.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" dependencies = [ "ahash", "serde", @@ -1367,15 +1424,15 @@ dependencies = [ [[package]] name = "heck" -version = "0.4.1" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" [[package]] name = "hermit-abi" -version = "0.3.4" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d3d0e0f38255e7fa3cf31335b3a56f05febd18025f4db5ef7a0cfb4f8da651f" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "hex" @@ -1417,9 +1474,9 @@ dependencies = [ [[package]] name = "http-body" -version = "1.0.0" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" +checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" dependencies = [ "bytes", "http", @@ -1440,15 +1497,21 @@ dependencies = [ [[package]] name = "httparse" -version = "1.8.0" +version = "1.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" + +[[package]] +name = "humantime" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "hyper" -version = "1.3.1" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe575dd17d0862a9a33781c8c4696a55c320909004a67a00fb286ba8b1bc496d" +checksum = "50dfd22e0e76d0f662d429a5f80fcaf3855009297eab6a0a9f8543834744ba05" dependencies = [ "bytes", "futures-channel", @@ -1464,6 +1527,23 @@ dependencies = [ "want", ] +[[package]] +name = "hyper-rustls" +version = "0.27.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" +dependencies = [ + "futures-util", + "http", + "hyper", + "hyper-util", + "rustls", + "rustls-pki-types", + "tokio", + "tokio-rustls", + "tower-service", +] + [[package]] name = "hyper-tls" version = "0.6.0" @@ -1482,9 +1562,9 @@ dependencies = [ [[package]] name = "hyper-util" -version = "0.1.5" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b875924a60b96e5d7b9ae7b066540b1dd1cbd90d1828f54c92e02a283351c56" +checksum = "cde7055719c54e36e95e8719f95883f22072a48ede39db7fc17a4e1d5281e9b9" dependencies = [ "bytes", "futures-channel", @@ -1528,9 +1608,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.1.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d530e1a18b1cb4c484e6e34556a0d948706958449fca0cab753d649f2bce3d1f" +checksum = "68b900aa2f7301e21c36462b170ee99994de34dff39a4a6a528e80e7376d07e5" dependencies = [ "equivalent", "hashbrown", @@ -1543,6 +1623,12 @@ version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" +[[package]] +name = "is_terminal_polyfill" +version = "1.70.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" + [[package]] name = "itertools" version = "0.10.5" @@ -1554,24 +1640,24 @@ dependencies = [ [[package]] name = "itertools" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25db6b064527c5d482d0423354fcd07a89a2dfe07b67892e62411946db7f07b0" +checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186" dependencies = [ "either", ] [[package]] name = "itoa" -version = "1.0.10" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] name = "js-sys" -version = "0.3.67" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a1d36f1235bc969acba30b7f5990b864423a6068a10f7c90ae8f0112e3a59d1" +checksum = "1868808506b929d7b0cfa8f75951347aa71bb21144b7791bae35d9bccfcfe37a" dependencies = [ "wasm-bindgen", ] @@ -1587,9 +1673,9 @@ dependencies = [ [[package]] name = "lazy_static" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "legacy_token_decode_module" @@ -1602,15 +1688,15 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.152" +version = "0.2.158" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13e3bf6590cbc649f4d1a3eefc9d5d6eb746f5200ffb04e5e142700b8faa56e7" +checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" [[package]] name = "linux-raw-sys" -version = "0.4.13" +version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" [[package]] name = "lkmex-transfer" @@ -1639,9 +1725,9 @@ dependencies = [ [[package]] name = "lock_api" -version = "0.4.11" +version = "0.4.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c168f8615b12bc01f9c17e2eb0cc07dcae1940121185446edc3744920e8ef45" +checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" dependencies = [ "autocfg", "scopeguard", @@ -1692,9 +1778,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.21" +version = "0.4.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" [[package]] name = "math" @@ -1705,9 +1791,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.7.2" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "memory_units" @@ -1750,29 +1836,39 @@ checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" [[package]] name = "miniz_oxide" -version = "0.7.1" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" dependencies = [ "adler", ] +[[package]] +name = "miniz_oxide" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2d80299ef12ff69b16a84bb182e3b9df68b5a91574d3d4fa6e41b65deec4df1" +dependencies = [ + "adler2", +] + [[package]] name = "mio" -version = "0.8.10" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" +checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" dependencies = [ + "hermit-abi", "libc", "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "multiversx-chain-scenario-format" -version = "0.22.2" +version = "0.22.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" +checksum = "921a66f6db5ffff311e355d42a49fd49baf72d7a6a6215b0484dcd9d8dd512a3" dependencies = [ "bech32", "hex", @@ -1785,16 +1881,16 @@ dependencies = [ [[package]] name = "multiversx-chain-vm" -version = "0.8.4" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" +checksum = "a8d91b6ce610a3ac1272f0813284a3f03a34d55db2f86cddaff357bf651074ee" dependencies = [ - "bitflags 2.5.0", + "bitflags", "colored", "ed25519-dalek", "hex", "hex-literal 0.4.1", - "itertools 0.12.0", + "itertools 0.13.0", "multiversx-chain-vm-executor", "num-bigint", "num-traits", @@ -1812,11 +1908,11 @@ checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ - "bitflags 2.5.0", + "bitflags", "hex-literal 0.4.1", "multiversx-sc-codec", "multiversx-sc-derive", @@ -1826,9 +1922,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -1838,9 +1934,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -1850,9 +1946,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -1863,21 +1959,41 @@ dependencies = [ [[package]] name = "multiversx-sc-meta" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" +checksum = "df1e5defa15d0195cb93f12b0a09220d9e94fe4fd86f2657c19272402c4083ac" dependencies = [ "clap", "colored", "common-path", "convert_case", "copy_dir", - "hex", - "lazy_static", "multiversx-sc", + "multiversx-sc-meta-lib", + "multiversx-sc-snippets", "pathdiff", "reqwest", "ruplacer", + "semver", + "serde", + "serde_json", + "tokio", + "toml", + "zip", +] + +[[package]] +name = "multiversx-sc-meta-lib" +version = "0.52.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8deccfcc760b8fd281e2603268fa1a453ed65e4caac7a51a2d71c40cec37ae3" +dependencies = [ + "clap", + "colored", + "convert_case", + "hex", + "lazy_static", + "multiversx-sc", "rustc_version", "semver", "serde", @@ -1885,60 +2001,74 @@ dependencies = [ "toml", "wasmparser", "wasmprinter", - "zip", ] [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-scenario" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" +checksum = "5d3024d52e2cb7d455f5a560218be8968e446eabc7c31dc9fc479c329f45e05e" dependencies = [ - "base64 0.22.1", + "base64", "bech32", - "clap", "colored", "hex", - "itertools 0.12.0", + "itertools 0.13.0", "log", "multiversx-chain-scenario-format", "multiversx-chain-vm", "multiversx-chain-vm-executor", "multiversx-sc", - "multiversx-sc-meta", - "multiversx-sdk", + "multiversx-sc-meta-lib", "num-bigint", "num-traits", "pathdiff", "serde", "serde_json", "sha2 0.10.8", - "tokio", "unwrap-infallible", ] +[[package]] +name = "multiversx-sc-snippets" +version = "0.52.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94bbd06d14e07875e92453bfe19557e1b3f2239af18b9cd3a8f05a19f4111df3" +dependencies = [ + "base64", + "env_logger", + "futures", + "hex", + "log", + "multiversx-chain-scenario-format", + "multiversx-sc-scenario", + "multiversx-sdk", + "tokio", +] + [[package]] name = "multiversx-sdk" -version = "0.4.1" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" +checksum = "139f1ac6d82e743dd3ae303e47134ab17b7c3e3c4306f09bed11a6054822596c" dependencies = [ "anyhow", - "base64 0.22.1", + "base64", "bech32", "bip39", "hex", "hmac", - "itertools 0.12.0", + "itertools 0.13.0", + "log", "pbkdf2", "pem", "rand 0.8.5", @@ -1954,11 +2084,10 @@ dependencies = [ [[package]] name = "native-tls" -version = "0.2.11" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07226173c32f2926027b63cce4bcd8076c3552846cbe7925f3aaffeac0a3b92e" +checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" dependencies = [ - "lazy_static", "libc", "log", "openssl", @@ -1981,9 +2110,9 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ "num-integer", "num-traits", @@ -2007,21 +2136,11 @@ dependencies = [ "autocfg", ] -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - [[package]] name = "object" -version = "0.32.2" +version = "0.36.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6a622008b6e321afc04970976f62ee297fdbaa6f95318ca343e3eebb9648441" +checksum = "084f1a5821ac4c651660a94a7153d27ac9d8a53736203f58b31945ded098070a" dependencies = [ "memchr", ] @@ -2040,11 +2159,11 @@ checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" [[package]] name = "openssl" -version = "0.10.62" +version = "0.10.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cde4d2d9200ad5909f8dac647e29482e07c3a35de8a13fce7c9c7747ad9f671" +checksum = "9529f4786b70a3e8c61e11179af17ab6188ad8d0ded78c5529441ed39d4bd9c1" dependencies = [ - "bitflags 2.5.0", + "bitflags", "cfg-if 1.0.0", "foreign-types", "libc", @@ -2072,9 +2191,9 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-sys" -version = "0.9.98" +version = "0.9.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1665caf8ab2dc9aef43d1c0023bd904633a6a05cb30b0ad59bec2ae986e57a7" +checksum = "7f9e8deee91df40a943c71b917e5874b951d32a802526c85721ce3b776c929d6" dependencies = [ "cc", "libc", @@ -2128,9 +2247,9 @@ dependencies = [ [[package]] name = "parking_lot" -version = "0.12.1" +version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" +checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" dependencies = [ "lock_api", "parking_lot_core", @@ -2138,15 +2257,15 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.9" +version = "0.9.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c42a9226546d68acdd9c0a280d17ce19bfe27a46bf68784e4066115788d008e" +checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" dependencies = [ "cfg-if 1.0.0", "libc", "redox_syscall", "smallvec", - "windows-targets 0.48.5", + "windows-targets 0.52.6", ] [[package]] @@ -2194,11 +2313,11 @@ dependencies = [ [[package]] name = "pem" -version = "3.0.3" +version = "3.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b8fcc794035347fb64beda2d3b462595dd2753e3f268d89c5aae77e8cf2c310" +checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" dependencies = [ - "base64 0.21.7", + "base64", "serde", ] @@ -2212,7 +2331,7 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" name = "permissions_module" version = "0.0.0" dependencies = [ - "bitflags 2.5.0", + "bitflags", "common_errors", "multiversx-sc", ] @@ -2239,9 +2358,9 @@ dependencies = [ [[package]] name = "pin-project-lite" -version = "0.2.13" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" [[package]] name = "pin-utils" @@ -2251,15 +2370,18 @@ checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" [[package]] name = "pkg-config" -version = "0.3.29" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2900ede94e305130c13ddd391e0ab7cbaeb783945ae07a279c268cb05109c6cb" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" [[package]] name = "ppv-lite86" -version = "0.2.17" +version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" +dependencies = [ + "zerocopy", +] [[package]] name = "price-discovery" @@ -2320,9 +2442,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -2491,7 +2613,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.12", + "getrandom 0.2.15", ] [[package]] @@ -2514,18 +2636,18 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.4.1" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" +checksum = "2a908a6e00f1fdd0dfd9c0eb08ce85126f6d8bbda50017e74bc4a4b7d4a926a4" dependencies = [ - "bitflags 1.3.2", + "bitflags", ] [[package]] name = "regex" -version = "1.10.2" +version = "1.10.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "380b951a9c5e80ddfd6136919eef32310721aa4aacd4889a8d39124b026ab343" +checksum = "4219d74c6b67a3654a9fbebc4b419e22126d13d2f3c4a07ee0cb61ff79a79619" dependencies = [ "aho-corasick", "memchr", @@ -2535,9 +2657,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.3" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f804c7828047e88b2d32e2d7fe5a105da8ee3264f01902f796c8e067dc2483f" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" dependencies = [ "aho-corasick", "memchr", @@ -2546,17 +2668,17 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.8.2" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" [[package]] name = "reqwest" -version = "0.12.4" +version = "0.12.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "566cafdd92868e0939d3fb961bd0dc25fcfaaed179291093b3d43e6b3150ea10" +checksum = "f8f4955649ef5c38cc7f9e8aa41761d48fb9677197daea9984dc54f56aad5e63" dependencies = [ - "base64 0.22.1", + "base64", "bytes", "encoding_rs", "futures-channel", @@ -2567,6 +2689,7 @@ dependencies = [ "http-body", "http-body-util", "hyper", + "hyper-rustls", "hyper-tls", "hyper-util", "ipnet", @@ -2590,7 +2713,7 @@ dependencies = [ "wasm-bindgen", "wasm-bindgen-futures", "web-sys", - "winreg", + "windows-registry", ] [[package]] @@ -2608,6 +2731,21 @@ dependencies = [ "token_send", ] +[[package]] +name = "ring" +version = "0.17.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" +dependencies = [ + "cc", + "cfg-if 1.0.0", + "getrandom 0.2.15", + "libc", + "spin", + "untrusted", + "windows-sys 0.52.0", +] + [[package]] name = "router" version = "0.0.0" @@ -2645,53 +2783,77 @@ dependencies = [ [[package]] name = "rustc-demangle" -version = "0.1.23" +version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" [[package]] name = "rustc_version" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" dependencies = [ "semver", ] [[package]] name = "rustix" -version = "0.38.30" +version = "0.38.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "322394588aaf33c24007e8bb3238ee3e4c5c09c084ab32bc73890b99ff326bca" +checksum = "a85d50532239da68e9addb745ba38ff4612a242c1c7ceea689c4bc7c2f43c36f" dependencies = [ - "bitflags 2.5.0", + "bitflags", "errno", "libc", "linux-raw-sys", "windows-sys 0.52.0", ] +[[package]] +name = "rustls" +version = "0.23.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c58f8c84392efc0a126acce10fa59ff7b3d2ac06ab451a33f2741989b806b044" +dependencies = [ + "once_cell", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + [[package]] name = "rustls-pemfile" -version = "2.1.2" +version = "2.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" +checksum = "196fe16b00e106300d3e45ecfcb764fa292a535d7326a29a5875c579c7417425" dependencies = [ - "base64 0.22.1", + "base64", "rustls-pki-types", ] [[package]] name = "rustls-pki-types" -version = "1.7.0" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc0a2ce646f8655401bb81e7927b812614bd5d91dbc968696be50603510fcaf0" + +[[package]] +name = "rustls-webpki" +version = "0.102.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" +checksum = "84678086bd54edf2b415183ed7a94d0efb049f1b646a33e22a36f3794be6ae56" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] [[package]] name = "ryu" -version = "1.0.16" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f98d2aa92eebf49b69786be48e4477826b256916e84a57ff2a4f21923b48eb4c" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" [[package]] name = "same-file" @@ -2727,11 +2889,11 @@ checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" [[package]] name = "security-framework" -version = "2.9.2" +version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05b64fb303737d99b81884b2c63433e9ae28abebe5eb5045dcdd175dc2ecf4de" +checksum = "897b2245f0b511c87893af39b033e5ca9cce68824c4d7e7630b5a1d339658d02" dependencies = [ - "bitflags 1.3.2", + "bitflags", "core-foundation", "core-foundation-sys", "libc", @@ -2740,9 +2902,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.9.1" +version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e932934257d3b408ed8f30db49d85ea163bfe74961f017f405b025af298f0c7a" +checksum = "75da29fe9b9b08fe9d6b22b5b4bcbc75d8db3aa31e639aa56bb62e9d46bfceaf" dependencies = [ "core-foundation-sys", "libc", @@ -2750,24 +2912,24 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.21" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b97ed7a9823b74f99c7742f5336af7be5ecd3eeafcb1507d1fa93347b1d589b0" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" [[package]] name = "serde" -version = "1.0.195" +version = "1.0.209" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63261df402c67811e9ac6def069e4786148c4563f4b50fd4bf30aa370d626b02" +checksum = "99fce0ffe7310761ca6bf9faf5115afbc19688edd00171d81b1bb1b116c63e09" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.195" +version = "1.0.209" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46fe8f8603d81ba86327b23a2e9cdf49e1255fb94a4c5f297f6ee0547178ea2c" +checksum = "a5831b979fd7b5439637af1752d535ff49f4860c0f341d1baeb6faf0f4242170" dependencies = [ "proc-macro2", "quote", @@ -2776,21 +2938,22 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.111" +version = "1.0.127" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "176e46fa42316f18edd598015a5166857fc835ec732f5215eac6b7bdbf0a84f4" +checksum = "8043c06d9f82bd7271361ed64f415fe5e12a77fdb52e573e7f06a516dea329ad" dependencies = [ "indexmap", "itoa", + "memchr", "ryu", "serde", ] [[package]] name = "serde_repr" -version = "0.1.18" +version = "0.1.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b2e6b945e9d3df726b65d6ee24060aff8e3533d431f677a9695db04eff9dfdb" +checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" dependencies = [ "proc-macro2", "quote", @@ -2799,9 +2962,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.5" +version = "0.6.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb3622f419d1296904700073ea6cc23ad690adbd66f13ea683df73298736f0c1" +checksum = "eb5b1b31579f3811bf615c144393417496f152e12ac8b7663bf664f4a815306d" dependencies = [ "serde", ] @@ -2852,11 +3015,17 @@ dependencies = [ "keccak", ] +[[package]] +name = "shlex" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" + [[package]] name = "signal-hook-registry" -version = "1.4.1" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" +checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" dependencies = [ "libc", ] @@ -2926,37 +3095,43 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.13.0" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b187f0231d56fe41bfb12034819dd2bf336422a5866de41bc3fec4b2e3883e8" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "socket2" -version = "0.5.5" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b5fac59a5cb5dd637972e5fca70daf0523c9067fcdc4842f053dae04a18f8e9" +checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" dependencies = [ "libc", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" + [[package]] name = "strsim" -version = "0.10.0" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" +checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "subtle" -version = "2.5.0" +version = "2.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", @@ -2965,26 +3140,29 @@ dependencies = [ [[package]] name = "sync_wrapper" -version = "0.1.2" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2047c6ded9c721764247e62cd3b03c09ffc529b2ba5b10ec482ae507a4a70160" +checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" +dependencies = [ + "futures-core", +] [[package]] name = "system-configuration" -version = "0.5.1" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b" dependencies = [ - "bitflags 1.3.2", + "bitflags", "core-foundation", "system-configuration-sys", ] [[package]] name = "system-configuration-sys" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4" dependencies = [ "core-foundation-sys", "libc", @@ -2992,31 +3170,40 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.9.0" +version = "3.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01ce4141aa927a6d1bd34a041795abd0db1cccba5d5f24b009f694bdf3a1f3fa" +checksum = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64" dependencies = [ "cfg-if 1.0.0", "fastrand", - "redox_syscall", + "once_cell", "rustix", - "windows-sys 0.52.0", + "windows-sys 0.59.0", +] + +[[package]] +name = "termcolor" +version = "1.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755" +dependencies = [ + "winapi-util", ] [[package]] name = "thiserror" -version = "1.0.61" +version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" +checksum = "c0342370b38b6a11b6cc11d6a805569958d54cfa061a29969c3b5ce2ea405724" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.61" +version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" +checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" dependencies = [ "proc-macro2", "quote", @@ -3025,9 +3212,9 @@ dependencies = [ [[package]] name = "tinyvec" -version = "1.6.0" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" +checksum = "445e881f4f6d382d5f27c034e25eb92edd7c784ceab92a0937db7f2e9471b938" dependencies = [ "tinyvec_macros", ] @@ -3084,28 +3271,27 @@ dependencies = [ [[package]] name = "tokio" -version = "1.35.1" +version = "1.40.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c89b4efa943be685f629b149f53829423f8f5531ea21249408e8e2f8671ec104" +checksum = "e2b070231665d27ad9ec9b8df639893f46727666c6767db40317fbe920a5d998" dependencies = [ "backtrace", "bytes", "libc", "mio", - "num_cpus", "parking_lot", "pin-project-lite", "signal-hook-registry", "socket2", "tokio-macros", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] name = "tokio-macros" -version = "2.2.0" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" +checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", @@ -3122,25 +3308,35 @@ dependencies = [ "tokio", ] +[[package]] +name = "tokio-rustls" +version = "0.26.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" +dependencies = [ + "rustls", + "rustls-pki-types", + "tokio", +] + [[package]] name = "tokio-util" -version = "0.7.10" +version = "0.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5419f34732d9eb6ee4c3578b7989078579b7f039cbbb9ca2c4da015749371e15" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" dependencies = [ "bytes", "futures-core", "futures-sink", "pin-project-lite", "tokio", - "tracing", ] [[package]] name = "toml" -version = "0.8.8" +version = "0.8.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1a195ec8c9da26928f773888e0742ca3ca1040c6cd859c919c9f59c1954ab35" +checksum = "a1ed1f98e3fdc28d6d910e6737ae6ab1a93bf1985935a1193e68f93eeb68d24e" dependencies = [ "indexmap", "serde", @@ -3151,18 +3347,18 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "0.6.5" +version = "0.6.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" +checksum = "0dd7358ecb8fc2f8d014bf86f6f638ce72ba252a2c3a2572f2a795f1d23efb41" dependencies = [ "serde", ] [[package]] name = "toml_edit" -version = "0.21.0" +version = "0.22.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d34d383cd00a163b4a5b85053df514d45bc330f6de7737edfe0a93311d1eaa03" +checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" dependencies = [ "indexmap", "serde", @@ -3188,15 +3384,15 @@ dependencies = [ [[package]] name = "tower-layer" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" +checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" [[package]] name = "tower-service" -version = "0.3.2" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" +checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" [[package]] name = "tracing" @@ -3252,9 +3448,15 @@ dependencies = [ [[package]] name = "unicode-segmentation" -version = "1.10.1" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" + +[[package]] +name = "untrusted" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "unwrap-infallible" @@ -3271,9 +3473,9 @@ dependencies = [ [[package]] name = "url" -version = "2.5.0" +version = "2.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31e6302e3bb753d46e83516cae55ae196fc0c309407cf11ab35cc51a4c2a4633" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" dependencies = [ "form_urlencoded", "idna", @@ -3282,9 +3484,9 @@ dependencies = [ [[package]] name = "utf8parse" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "utils" @@ -3304,15 +3506,15 @@ checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" [[package]] name = "version_check" -version = "0.9.4" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" [[package]] name = "walkdir" -version = "2.4.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d71d857dc86794ca4c280d616f7da00d2dbfd8cd788846559a6813e6aa4b54ee" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" dependencies = [ "same-file", "winapi-util", @@ -3341,19 +3543,20 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.90" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1223296a201415c7fad14792dbefaace9bd52b62d33453ade1c5b5f07555406" +checksum = "a82edfc16a6c469f5f44dc7b571814045d60404b55a0ee849f9bcfa2e63dd9b5" dependencies = [ "cfg-if 1.0.0", + "once_cell", "wasm-bindgen-macro", ] [[package]] name = "wasm-bindgen-backend" -version = "0.2.90" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcdc935b63408d58a32f8cc9738a0bffd8f05cc7c002086c6ef20b7312ad9dcd" +checksum = "9de396da306523044d3302746f1208fa71d7532227f15e347e2d93e4145dd77b" dependencies = [ "bumpalo", "log", @@ -3366,9 +3569,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-futures" -version = "0.4.40" +version = "0.4.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bde2032aeb86bdfaecc8b261eef3cba735cc426c1f3a3416d1e0791be95fc461" +checksum = "61e9300f63a621e96ed275155c108eb6f843b6a26d053f122ab69724559dc8ed" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -3378,9 +3581,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.90" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e4c238561b2d428924c49815533a8b9121c664599558a5d9ec51f8a1740a999" +checksum = "585c4c91a46b072c92e908d99cb1dcdf95c5218eeb6f3bf1efa991ee7a68cccf" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -3388,9 +3591,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.90" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bae1abb6806dc1ad9e560ed242107c0f6c84335f1749dd4e8ddb012ebd5e25a7" +checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" dependencies = [ "proc-macro2", "quote", @@ -3401,18 +3604,18 @@ dependencies = [ [[package]] name = "wasm-bindgen-shared" -version = "0.2.90" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d91413b1c31d7539ba5ef2451af3f0b833a005eb27a631cec32bc0635a8602b" +checksum = "c62a0a307cb4a311d3a07867860911ca130c3494e8c2719593806c08bc5d0484" [[package]] name = "wasmparser" -version = "0.208.1" +version = "0.214.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" +checksum = "5309c1090e3e84dad0d382f42064e9933fdaedb87e468cc239f0eabea73ddcb6" dependencies = [ "ahash", - "bitflags 2.5.0", + "bitflags", "hashbrown", "indexmap", "semver", @@ -3421,19 +3624,20 @@ dependencies = [ [[package]] name = "wasmprinter" -version = "0.208.1" +version = "0.214.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" +checksum = "58d4f2b3f7bd2ba10f99e03f885ff90d5db3455e163bccecebbbf60406bd8980" dependencies = [ "anyhow", + "termcolor", "wasmparser", ] [[package]] name = "web-sys" -version = "0.3.67" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58cd2333b6e0be7a39605f0e255892fd7418a682d8da8fe042fe25128794d2ed" +checksum = "26fdeaafd9bd129f65e7c031593c24d62186301e0c72c8978fa1678be7d532c0" dependencies = [ "js-sys", "wasm-bindgen", @@ -3489,11 +3693,11 @@ checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" [[package]] name = "winapi-util" -version = "0.1.6" +version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f29e6f9198ba0d26b4c9f07dbe6f9ed633e1f3d5b8b414090084349e46a52596" +checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" dependencies = [ - "winapi", + "windows-sys 0.59.0", ] [[package]] @@ -3502,6 +3706,36 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" +[[package]] +name = "windows-registry" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e400001bb720a623c1c69032f8e3e4cf09984deec740f007dd2b03ec864804b0" +dependencies = [ + "windows-result", + "windows-strings", + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-result" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d1043d8214f791817bab27572aaa8af63732e11bf84aa21a45a78d6c317ae0e" +dependencies = [ + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-strings" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4cd9b125c486025df0eabcb585e62173c6c9eddcec5d117d3b6e8c30e2ee4d10" +dependencies = [ + "windows-result", + "windows-targets 0.52.6", +] + [[package]] name = "windows-sys" version = "0.48.0" @@ -3517,7 +3751,16 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" dependencies = [ - "windows-targets 0.52.0", + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets 0.52.6", ] [[package]] @@ -3537,17 +3780,18 @@ dependencies = [ [[package]] name = "windows-targets" -version = "0.52.0" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a18201040b24831fbb9e4eb208f8892e1f50a37feb53cc7ff887feb8f50e7cd" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" dependencies = [ - "windows_aarch64_gnullvm 0.52.0", - "windows_aarch64_msvc 0.52.0", - "windows_i686_gnu 0.52.0", - "windows_i686_msvc 0.52.0", - "windows_x86_64_gnu 0.52.0", - "windows_x86_64_gnullvm 0.52.0", - "windows_x86_64_msvc 0.52.0", + "windows_aarch64_gnullvm 0.52.6", + "windows_aarch64_msvc 0.52.6", + "windows_i686_gnu 0.52.6", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.6", + "windows_x86_64_gnu 0.52.6", + "windows_x86_64_gnullvm 0.52.6", + "windows_x86_64_msvc 0.52.6", ] [[package]] @@ -3558,9 +3802,9 @@ checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.0" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb7764e35d4db8a7921e09562a0304bf2f93e0a51bfccee0bd0bb0b666b015ea" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" [[package]] name = "windows_aarch64_msvc" @@ -3570,9 +3814,9 @@ checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" [[package]] name = "windows_aarch64_msvc" -version = "0.52.0" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbaa0368d4f1d2aaefc55b6fcfee13f41544ddf36801e793edbbfd7d7df075ef" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" [[package]] name = "windows_i686_gnu" @@ -3582,9 +3826,15 @@ checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" [[package]] name = "windows_i686_gnu" -version = "0.52.0" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a28637cb1fa3560a16915793afb20081aba2c92ee8af57b4d5f28e4b3e7df313" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" [[package]] name = "windows_i686_msvc" @@ -3594,9 +3844,9 @@ checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" [[package]] name = "windows_i686_msvc" -version = "0.52.0" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffe5e8e31046ce6230cc7215707b816e339ff4d4d67c65dffa206fd0f7aa7b9a" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" [[package]] name = "windows_x86_64_gnu" @@ -3606,9 +3856,9 @@ checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" [[package]] name = "windows_x86_64_gnu" -version = "0.52.0" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6fa32db2bc4a2f5abeacf2b69f7992cd09dca97498da74a151a3132c26befd" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" [[package]] name = "windows_x86_64_gnullvm" @@ -3618,9 +3868,9 @@ checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.0" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a657e1e9d3f514745a572a6846d3c7aa7dbe1658c056ed9c3344c4109a6949e" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" [[package]] name = "windows_x86_64_msvc" @@ -3630,43 +3880,34 @@ checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" [[package]] name = "windows_x86_64_msvc" -version = "0.52.0" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.5.34" +version = "0.6.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7cf47b659b318dccbd69cc4797a39ae128f533dce7902a1096044d1967b9c16" +checksum = "68a9bda4691f099d435ad181000724da8e5899daa10713c2d432552b9ccd3a6f" dependencies = [ "memchr", ] -[[package]] -name = "winreg" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" -dependencies = [ - "cfg-if 1.0.0", - "windows-sys 0.48.0", -] - [[package]] name = "zerocopy" -version = "0.7.34" +version = "0.7.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" dependencies = [ + "byteorder", "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.7.34" +version = "0.7.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ "proc-macro2", "quote", @@ -3675,9 +3916,9 @@ dependencies = [ [[package]] name = "zeroize" -version = "1.7.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" +checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" dependencies = [ "zeroize_derive", ] @@ -3695,9 +3936,9 @@ dependencies = [ [[package]] name = "zip" -version = "2.1.3" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" +checksum = "dc5e4288ea4057ae23afc69a4472434a87a2495cafce6632fd1c4ec9f5cf3494" dependencies = [ "arbitrary", "crc32fast", diff --git a/common/common_errors/Cargo.toml b/common/common_errors/Cargo.toml index cd386f750..6fee8d60d 100644 --- a/common/common_errors/Cargo.toml +++ b/common/common_errors/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/common_structs/Cargo.toml b/common/common_structs/Cargo.toml index 983e946a4..e16ae99a1 100644 --- a/common/common_structs/Cargo.toml +++ b/common/common_structs/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] diff --git a/common/modules/farm/config/Cargo.toml b/common/modules/farm/config/Cargo.toml index 18e114c64..a23429f55 100644 --- a/common/modules/farm/config/Cargo.toml +++ b/common/modules/farm/config/Cargo.toml @@ -23,5 +23,5 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/contexts/Cargo.toml b/common/modules/farm/contexts/Cargo.toml index 97de2f04f..759895606 100644 --- a/common/modules/farm/contexts/Cargo.toml +++ b/common/modules/farm/contexts/Cargo.toml @@ -35,8 +35,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" diff --git a/common/modules/farm/events/Cargo.toml b/common/modules/farm/events/Cargo.toml index 5bd8b9e4a..4da2574ee 100644 --- a/common/modules/farm/events/Cargo.toml +++ b/common/modules/farm/events/Cargo.toml @@ -14,5 +14,5 @@ path = "../../../common_structs" path = "../contexts" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/farm/farm_base_impl/Cargo.toml b/common/modules/farm/farm_base_impl/Cargo.toml index 43d755b75..67bae38bd 100644 --- a/common/modules/farm/farm_base_impl/Cargo.toml +++ b/common/modules/farm/farm_base_impl/Cargo.toml @@ -50,11 +50,11 @@ path = "../../../traits/mergeable" path = "../../../traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/common/modules/farm/farm_token/Cargo.toml b/common/modules/farm/farm_token/Cargo.toml index ede42b094..7b8c589a6 100644 --- a/common/modules/farm/farm_token/Cargo.toml +++ b/common/modules/farm/farm_token/Cargo.toml @@ -26,8 +26,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" diff --git a/common/modules/farm/farm_token_merge/Cargo.toml b/common/modules/farm/farm_token_merge/Cargo.toml index 58df12194..5c3396d85 100644 --- a/common/modules/farm/farm_token_merge/Cargo.toml +++ b/common/modules/farm/farm_token_merge/Cargo.toml @@ -23,11 +23,11 @@ path = "../../token_merge_helper" path = "../farm_token" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/common/modules/farm/rewards/Cargo.toml b/common/modules/farm/rewards/Cargo.toml index 77d5391c6..224f8f83d 100644 --- a/common/modules/farm/rewards/Cargo.toml +++ b/common/modules/farm/rewards/Cargo.toml @@ -29,8 +29,8 @@ path = "../../pausable" path = "../../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" diff --git a/common/modules/legacy_token_decode_module/Cargo.toml b/common/modules/legacy_token_decode_module/Cargo.toml index 1eb14224a..92ac7fccf 100644 --- a/common/modules/legacy_token_decode_module/Cargo.toml +++ b/common/modules/legacy_token_decode_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2018" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/modules/locking_module/Cargo.toml b/common/modules/locking_module/Cargo.toml index afa7961a2..78cc80724 100644 --- a/common/modules/locking_module/Cargo.toml +++ b/common/modules/locking_module/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.simple-lock] diff --git a/common/modules/math/Cargo.toml b/common/modules/math/Cargo.toml index b78acbbc4..df63fe034 100644 --- a/common/modules/math/Cargo.toml +++ b/common/modules/math/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/pausable/Cargo.toml b/common/modules/pausable/Cargo.toml index fa9fe8d01..840683ef3 100644 --- a/common/modules/pausable/Cargo.toml +++ b/common/modules/pausable/Cargo.toml @@ -11,5 +11,5 @@ path = "src/pausable.rs" path = "../permissions_module" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/permissions_module/Cargo.toml b/common/modules/permissions_module/Cargo.toml index b16125e14..a64b00a6f 100644 --- a/common/modules/permissions_module/Cargo.toml +++ b/common/modules/permissions_module/Cargo.toml @@ -17,5 +17,5 @@ bitflags = "2.4.1" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/sc_whitelist_module/Cargo.toml b/common/modules/sc_whitelist_module/Cargo.toml index d1394b2b6..3aa5b143c 100644 --- a/common/modules/sc_whitelist_module/Cargo.toml +++ b/common/modules/sc_whitelist_module/Cargo.toml @@ -11,5 +11,5 @@ path = "src/sc_whitelist_module.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_merge_helper/Cargo.toml b/common/modules/token_merge_helper/Cargo.toml index 775755d2b..92a71b34d 100644 --- a/common/modules/token_merge_helper/Cargo.toml +++ b/common/modules/token_merge_helper/Cargo.toml @@ -11,5 +11,5 @@ path = "src/lib.rs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/token_send/Cargo.toml b/common/modules/token_send/Cargo.toml index ffd8c110e..30ccb3efa 100644 --- a/common/modules/token_send/Cargo.toml +++ b/common/modules/token_send/Cargo.toml @@ -14,5 +14,5 @@ path = "../../common_structs" path = "../../common_errors" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/modules/utils/Cargo.toml b/common/modules/utils/Cargo.toml index 97c4d8469..e38f8fe90 100644 --- a/common/modules/utils/Cargo.toml +++ b/common/modules/utils/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.common_structs] diff --git a/common/traits/fixed-supply-token/Cargo.toml b/common/traits/fixed-supply-token/Cargo.toml index f77040cb7..6e733792a 100644 --- a/common/traits/fixed-supply-token/Cargo.toml +++ b/common/traits/fixed-supply-token/Cargo.toml @@ -8,4 +8,4 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" diff --git a/common/traits/mergeable/Cargo.toml b/common/traits/mergeable/Cargo.toml index ffcd7d4aa..f5ee4681a 100644 --- a/common/traits/mergeable/Cargo.toml +++ b/common/traits/mergeable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/common/traits/unwrappable/Cargo.toml b/common/traits/unwrappable/Cargo.toml index 61f703d49..f4697c4b7 100644 --- a/common/traits/unwrappable/Cargo.toml +++ b/common/traits/unwrappable/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/dex/Cargo.toml b/dex/Cargo.toml index f7092b937..df2fd1e57 100644 --- a/dex/Cargo.toml +++ b/dex/Cargo.toml @@ -5,17 +5,17 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.config] path = "../common/modules/farm/config" diff --git a/dex/farm-with-locked-rewards/Cargo.toml b/dex/farm-with-locked-rewards/Cargo.toml index 2c82821ac..02e2190bb 100644 --- a/dex/farm-with-locked-rewards/Cargo.toml +++ b/dex/farm-with-locked-rewards/Cargo.toml @@ -75,17 +75,17 @@ path = "../../locked-asset/energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.simple-lock] path = "../../locked-asset/simple-lock" diff --git a/dex/farm-with-locked-rewards/meta/Cargo.toml b/dex/farm-with-locked-rewards/meta/Cargo.toml index 759756a2d..a273b797a 100644 --- a/dex/farm-with-locked-rewards/meta/Cargo.toml +++ b/dex/farm-with-locked-rewards/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.lock b/dex/farm-with-locked-rewards/wasm/Cargo.lock index d1031c945..81b781351 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.lock +++ b/dex/farm-with-locked-rewards/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -315,9 +315,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -329,9 +329,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -340,9 +340,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -352,9 +352,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -365,18 +365,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -434,9 +434,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -494,15 +494,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/farm-with-locked-rewards/wasm/Cargo.toml b/dex/farm-with-locked-rewards/wasm/Cargo.toml index 2ef56b51f..5e02cdde1 100644 --- a/dex/farm-with-locked-rewards/wasm/Cargo.toml +++ b/dex/farm-with-locked-rewards/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/farm/Cargo.toml b/dex/farm/Cargo.toml index ba4b12b2c..34af0d038 100644 --- a/dex/farm/Cargo.toml +++ b/dex/farm/Cargo.toml @@ -69,11 +69,11 @@ path = "../../energy-integration/common-modules/weekly-rewards-splitting" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies] num-bigint = "0.4.2" @@ -82,7 +82,7 @@ num-bigint = "0.4.2" path = "../../energy-integration/energy-update" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.energy-factory-mock] path = "../../energy-integration/energy-factory-mock" diff --git a/dex/farm/meta/Cargo.toml b/dex/farm/meta/Cargo.toml index 47b03082d..932e0ad31 100644 --- a/dex/farm/meta/Cargo.toml +++ b/dex/farm/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/farm/wasm/Cargo.lock b/dex/farm/wasm/Cargo.lock index 8ea1ffb97..9cb7e7e72 100644 --- a/dex/farm/wasm/Cargo.lock +++ b/dex/farm/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -285,9 +285,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -299,9 +299,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -310,9 +310,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -322,9 +322,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -335,18 +335,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -404,9 +404,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -464,15 +464,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/farm/wasm/Cargo.toml b/dex/farm/wasm/Cargo.toml index 4ece2ffba..5283ecab3 100644 --- a/dex/farm/wasm/Cargo.toml +++ b/dex/farm/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/fuzz/Cargo.toml b/dex/fuzz/Cargo.toml index 31b25d4f2..cd7c3fa7c 100644 --- a/dex/fuzz/Cargo.toml +++ b/dex/fuzz/Cargo.toml @@ -12,11 +12,11 @@ num-bigint = "0.4.2" rand = "0.8.4" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dependencies.pausable] path = "../../common/modules/pausable" diff --git a/dex/governance/Cargo.toml b/dex/governance/Cargo.toml index 559dcd8b0..6ef3a8084 100644 --- a/dex/governance/Cargo.toml +++ b/dex/governance/Cargo.toml @@ -9,14 +9,14 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.pair-mock] path = "../pair-mock" diff --git a/dex/governance/meta/Cargo.toml b/dex/governance/meta/Cargo.toml index 0edbcfa91..b6328ceaf 100644 --- a/dex/governance/meta/Cargo.toml +++ b/dex/governance/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/governance/wasm/Cargo.lock b/dex/governance/wasm/Cargo.lock index 2c838bb95..1bcfc827a 100644 --- a/dex/governance/wasm/Cargo.lock +++ b/dex/governance/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "endian-type" @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -69,9 +69,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -80,9 +80,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -92,9 +92,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -105,9 +105,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -160,15 +160,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/governance/wasm/Cargo.toml b/dex/governance/wasm/Cargo.toml index 3fa482747..22307fd20 100644 --- a/dex/governance/wasm/Cargo.toml +++ b/dex/governance/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/pair-mock/Cargo.toml b/dex/pair-mock/Cargo.toml index c5b9546ea..8d6627ce9 100644 --- a/dex/pair-mock/Cargo.toml +++ b/dex/pair-mock/Cargo.toml @@ -12,7 +12,7 @@ path = "src/pair.rs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.itertools] @@ -20,4 +20,4 @@ version = "0.10.1" default-features = false [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/dex/pair-mock/meta/Cargo.toml b/dex/pair-mock/meta/Cargo.toml index e9b89883e..245b01fb9 100644 --- a/dex/pair-mock/meta/Cargo.toml +++ b/dex/pair-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/pair-mock/wasm/Cargo.lock b/dex/pair-mock/wasm/Cargo.lock index 178e0ae80..890c8b7c3 100644 --- a/dex/pair-mock/wasm/Cargo.lock +++ b/dex/pair-mock/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -29,9 +29,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -62,9 +62,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -87,9 +87,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -99,9 +99,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -112,9 +112,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -156,9 +156,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -184,15 +184,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/pair-mock/wasm/Cargo.toml b/dex/pair-mock/wasm/Cargo.toml index 2b0db710c..3fcbc95bf 100644 --- a/dex/pair-mock/wasm/Cargo.toml +++ b/dex/pair-mock/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/pair/Cargo.toml b/dex/pair/Cargo.toml index ee9c89796..a183ce778 100644 --- a/dex/pair/Cargo.toml +++ b/dex/pair/Cargo.toml @@ -37,11 +37,11 @@ version = "0.10.1" default-features = false [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/dex/pair/meta/Cargo.toml b/dex/pair/meta/Cargo.toml index 4047753d0..377f6daf7 100644 --- a/dex/pair/meta/Cargo.toml +++ b/dex/pair/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/pair/wasm-pair-full/Cargo.lock b/dex/pair/wasm-pair-full/Cargo.lock index 14e0fcb89..3afa89c6d 100644 --- a/dex/pair/wasm-pair-full/Cargo.lock +++ b/dex/pair/wasm-pair-full/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -47,9 +47,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -175,9 +175,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -186,9 +186,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -288,9 +288,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -333,15 +333,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/pair/wasm-pair-full/Cargo.toml b/dex/pair/wasm-pair-full/Cargo.toml index cb7e86119..20504704c 100644 --- a/dex/pair/wasm-pair-full/Cargo.toml +++ b/dex/pair/wasm-pair-full/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/pair/wasm-safe-price-view/Cargo.lock b/dex/pair/wasm-safe-price-view/Cargo.lock index d3d33acec..130405e72 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.lock +++ b/dex/pair/wasm-safe-price-view/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -47,9 +47,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -175,9 +175,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -186,9 +186,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -280,9 +280,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -333,15 +333,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/pair/wasm-safe-price-view/Cargo.toml b/dex/pair/wasm-safe-price-view/Cargo.toml index 017e0d8e7..1c372b740 100644 --- a/dex/pair/wasm-safe-price-view/Cargo.toml +++ b/dex/pair/wasm-safe-price-view/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/pair/wasm/Cargo.lock b/dex/pair/wasm/Cargo.lock index 1ed40bfb6..a429c153e 100644 --- a/dex/pair/wasm/Cargo.lock +++ b/dex/pair/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -47,9 +47,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -175,9 +175,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -186,9 +186,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -288,9 +288,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -333,15 +333,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/pair/wasm/Cargo.toml b/dex/pair/wasm/Cargo.toml index 763f76956..0aba20357 100644 --- a/dex/pair/wasm/Cargo.toml +++ b/dex/pair/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/price-discovery/Cargo.toml b/dex/price-discovery/Cargo.toml index c8ef79f7b..6425eedbc 100644 --- a/dex/price-discovery/Cargo.toml +++ b/dex/price-discovery/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.locking_module] path = "../../common/modules/locking_module" @@ -30,4 +30,4 @@ hex = "0.4" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/dex/price-discovery/meta/Cargo.toml b/dex/price-discovery/meta/Cargo.toml index db083f12c..c8330479e 100644 --- a/dex/price-discovery/meta/Cargo.toml +++ b/dex/price-discovery/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/price-discovery/wasm/Cargo.lock b/dex/price-discovery/wasm/Cargo.lock index 04a98edc4..49b291715 100644 --- a/dex/price-discovery/wasm/Cargo.lock +++ b/dex/price-discovery/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -133,9 +133,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -144,9 +144,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -156,9 +156,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -169,18 +169,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -223,9 +223,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -268,15 +268,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/price-discovery/wasm/Cargo.toml b/dex/price-discovery/wasm/Cargo.toml index 74978fb3e..1dcb092a2 100644 --- a/dex/price-discovery/wasm/Cargo.toml +++ b/dex/price-discovery/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/proxy-deployer/Cargo.toml b/dex/proxy-deployer/Cargo.toml index 488949062..1cdb05f73 100644 --- a/dex/proxy-deployer/Cargo.toml +++ b/dex/proxy-deployer/Cargo.toml @@ -21,11 +21,11 @@ path = "../../common/modules/farm/config" path = "../../common/modules/farm/farm_token" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/dex/proxy-deployer/meta/Cargo.toml b/dex/proxy-deployer/meta/Cargo.toml index 8f99d0558..dc7a4d09f 100644 --- a/dex/proxy-deployer/meta/Cargo.toml +++ b/dex/proxy-deployer/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/proxy-deployer/wasm/Cargo.lock b/dex/proxy-deployer/wasm/Cargo.lock index bef49309c..d6e8501f7 100644 --- a/dex/proxy-deployer/wasm/Cargo.lock +++ b/dex/proxy-deployer/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -277,9 +277,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -291,9 +291,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -302,9 +302,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -314,9 +314,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -327,18 +327,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -396,9 +396,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -475,15 +475,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/proxy-deployer/wasm/Cargo.toml b/dex/proxy-deployer/wasm/Cargo.toml index 26a1eca02..a91353591 100644 --- a/dex/proxy-deployer/wasm/Cargo.toml +++ b/dex/proxy-deployer/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/dex/router/Cargo.toml b/dex/router/Cargo.toml index b653e13d0..b542e4196 100644 --- a/dex/router/Cargo.toml +++ b/dex/router/Cargo.toml @@ -15,7 +15,7 @@ path = "../../common/modules/token_send" path = "../../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.pair] @@ -28,4 +28,4 @@ path = "../../common/modules/locking_module" path = "../../locked-asset/simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/dex/router/meta/Cargo.toml b/dex/router/meta/Cargo.toml index 6333e29d5..48160d8b0 100644 --- a/dex/router/meta/Cargo.toml +++ b/dex/router/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/dex/router/wasm/Cargo.lock b/dex/router/wasm/Cargo.lock index 44918dd26..7fb52d1e3 100644 --- a/dex/router/wasm/Cargo.lock +++ b/dex/router/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -47,9 +47,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -175,9 +175,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -186,9 +186,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -280,9 +280,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -345,15 +345,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/dex/router/wasm/Cargo.toml b/dex/router/wasm/Cargo.toml index 25449bdd1..5f51baac3 100644 --- a/dex/router/wasm/Cargo.toml +++ b/dex/router/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/energy-integration/common-modules/energy-query/Cargo.toml b/energy-integration/common-modules/energy-query/Cargo.toml index ad8bd57cf..f6cddc324 100644 --- a/energy-integration/common-modules/energy-query/Cargo.toml +++ b/energy-integration/common-modules/energy-query/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-factory] diff --git a/energy-integration/common-modules/week-timekeeping/Cargo.toml b/energy-integration/common-modules/week-timekeeping/Cargo.toml index 06c500490..ca761a0ac 100644 --- a/energy-integration/common-modules/week-timekeeping/Cargo.toml +++ b/energy-integration/common-modules/week-timekeeping/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.common-types] diff --git a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml index 4b83416ac..769bf1a02 100644 --- a/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml +++ b/energy-integration/common-modules/weekly-rewards-splitting/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.energy-query] diff --git a/energy-integration/common-types/Cargo.toml b/energy-integration/common-types/Cargo.toml index 394f09b1b..204f503ed 100644 --- a/energy-integration/common-types/Cargo.toml +++ b/energy-integration/common-types/Cargo.toml @@ -8,5 +8,5 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] diff --git a/energy-integration/energy-factory-mock/Cargo.toml b/energy-integration/energy-factory-mock/Cargo.toml index 4a494ca9c..a1786f9f7 100644 --- a/energy-integration/energy-factory-mock/Cargo.toml +++ b/energy-integration/energy-factory-mock/Cargo.toml @@ -12,8 +12,8 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/energy-integration/energy-factory-mock/meta/Cargo.toml b/energy-integration/energy-factory-mock/meta/Cargo.toml index 68abe9e93..4dd743ee5 100644 --- a/energy-integration/energy-factory-mock/meta/Cargo.toml +++ b/energy-integration/energy-factory-mock/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.lock b/energy-integration/energy-factory-mock/wasm/Cargo.lock index 30564520b..90e2d715e 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.lock +++ b/energy-integration/energy-factory-mock/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -128,9 +128,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -142,9 +142,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -153,9 +153,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -178,18 +178,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -214,9 +214,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -259,15 +259,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/energy-integration/energy-factory-mock/wasm/Cargo.toml b/energy-integration/energy-factory-mock/wasm/Cargo.toml index 40d83dc16..c27927d62 100644 --- a/energy-integration/energy-factory-mock/wasm/Cargo.toml +++ b/energy-integration/energy-factory-mock/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/energy-integration/energy-update/Cargo.toml b/energy-integration/energy-update/Cargo.toml index bd8ced5d5..cece1badc 100644 --- a/energy-integration/energy-update/Cargo.toml +++ b/energy-integration/energy-update/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.farm] path = "../../dex/farm" @@ -25,4 +25,4 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/energy-integration/energy-update/meta/Cargo.toml b/energy-integration/energy-update/meta/Cargo.toml index 306816956..17921bd41 100644 --- a/energy-integration/energy-update/meta/Cargo.toml +++ b/energy-integration/energy-update/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/energy-integration/energy-update/wasm/Cargo.lock b/energy-integration/energy-update/wasm/Cargo.lock index 6741f94e8..d589409c8 100644 --- a/energy-integration/energy-update/wasm/Cargo.lock +++ b/energy-integration/energy-update/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -295,9 +295,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -309,9 +309,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -320,9 +320,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -332,9 +332,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -345,18 +345,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -414,9 +414,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -474,15 +474,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/energy-integration/energy-update/wasm/Cargo.toml b/energy-integration/energy-update/wasm/Cargo.toml index 39a04fe5a..3046000d8 100644 --- a/energy-integration/energy-update/wasm/Cargo.toml +++ b/energy-integration/energy-update/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/energy-integration/farm-boosted-yields/Cargo.toml b/energy-integration/farm-boosted-yields/Cargo.toml index 1ec5d2a22..635f6f12e 100644 --- a/energy-integration/farm-boosted-yields/Cargo.toml +++ b/energy-integration/farm-boosted-yields/Cargo.toml @@ -8,7 +8,7 @@ edition = "2021" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.config] diff --git a/energy-integration/fees-collector/Cargo.toml b/energy-integration/fees-collector/Cargo.toml index d357714f3..71246ad74 100644 --- a/energy-integration/fees-collector/Cargo.toml +++ b/energy-integration/fees-collector/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.energy-query] path = "../common-modules/energy-query" @@ -49,7 +49,7 @@ path = "../../common/common_errors" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.sc_whitelist_module] path = "../../common/modules/sc_whitelist_module" diff --git a/energy-integration/fees-collector/meta/Cargo.toml b/energy-integration/fees-collector/meta/Cargo.toml index 24f69c8f0..fdf9fb2d1 100644 --- a/energy-integration/fees-collector/meta/Cargo.toml +++ b/energy-integration/fees-collector/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/energy-integration/fees-collector/wasm/Cargo.lock b/energy-integration/fees-collector/wasm/Cargo.lock index 8ac282906..aefa2da06 100644 --- a/energy-integration/fees-collector/wasm/Cargo.lock +++ b/energy-integration/fees-collector/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -168,9 +168,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -179,9 +179,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -191,9 +191,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -204,18 +204,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -240,9 +240,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -285,15 +285,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/energy-integration/fees-collector/wasm/Cargo.toml b/energy-integration/fees-collector/wasm/Cargo.toml index c631daf5b..7fd11ead7 100644 --- a/energy-integration/fees-collector/wasm/Cargo.toml +++ b/energy-integration/fees-collector/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/energy-integration/governance-v2/Cargo.toml b/energy-integration/governance-v2/Cargo.toml index ee51183a3..ea148f4ba 100644 --- a/energy-integration/governance-v2/Cargo.toml +++ b/energy-integration/governance-v2/Cargo.toml @@ -12,7 +12,7 @@ path = "src/lib.rs" path = "../common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.permissions_module] @@ -28,7 +28,7 @@ path = "../common-modules/weekly-rewards-splitting" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.energy-factory-mock] path = "../energy-factory-mock" diff --git a/energy-integration/governance-v2/meta/Cargo.toml b/energy-integration/governance-v2/meta/Cargo.toml index 54f7de3d2..a4d6830a6 100644 --- a/energy-integration/governance-v2/meta/Cargo.toml +++ b/energy-integration/governance-v2/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/energy-integration/governance-v2/wasm/Cargo.lock b/energy-integration/governance-v2/wasm/Cargo.lock index 872bda3b7..822c38060 100644 --- a/energy-integration/governance-v2/wasm/Cargo.lock +++ b/energy-integration/governance-v2/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -179,9 +179,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -190,9 +190,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -202,9 +202,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -215,18 +215,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -260,9 +260,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -305,15 +305,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/energy-integration/governance-v2/wasm/Cargo.toml b/energy-integration/governance-v2/wasm/Cargo.toml index c57b86b9b..ba31902a3 100644 --- a/energy-integration/governance-v2/wasm/Cargo.toml +++ b/energy-integration/governance-v2/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/farm-staking/farm-staking-proxy/Cargo.toml b/farm-staking/farm-staking-proxy/Cargo.toml index 4e6aeea05..74ee9fdca 100644 --- a/farm-staking/farm-staking-proxy/Cargo.toml +++ b/farm-staking/farm-staking-proxy/Cargo.toml @@ -12,11 +12,11 @@ path = "src/lib.rs" hex-literal = "0.3.1" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.farm] path = "../../dex/farm" @@ -67,7 +67,7 @@ path = "../../energy-integration/common-modules/energy-query" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.farm_token] path = "../../common/modules/farm/farm_token" diff --git a/farm-staking/farm-staking-proxy/meta/Cargo.toml b/farm-staking/farm-staking-proxy/meta/Cargo.toml index 95fefa3c4..c1419832e 100644 --- a/farm-staking/farm-staking-proxy/meta/Cargo.toml +++ b/farm-staking/farm-staking-proxy/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.lock b/farm-staking/farm-staking-proxy/wasm/Cargo.lock index 54852f7e5..4944a7735 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.lock +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -376,9 +376,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal 0.4.1", @@ -390,9 +390,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -401,9 +401,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -413,9 +413,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -426,18 +426,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -495,9 +495,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -555,15 +555,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/farm-staking/farm-staking-proxy/wasm/Cargo.toml b/farm-staking/farm-staking-proxy/wasm/Cargo.toml index bd620ca6b..e10369847 100644 --- a/farm-staking/farm-staking-proxy/wasm/Cargo.toml +++ b/farm-staking/farm-staking-proxy/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/farm-staking/farm-staking/Cargo.toml b/farm-staking/farm-staking/Cargo.toml index bbe389e85..15e0e15ac 100644 --- a/farm-staking/farm-staking/Cargo.toml +++ b/farm-staking/farm-staking/Cargo.toml @@ -78,14 +78,14 @@ path = "../../common/common_structs" path = "../../common/common_errors" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/farm-staking/farm-staking/meta/Cargo.toml b/farm-staking/farm-staking/meta/Cargo.toml index f36d834e2..78643b777 100644 --- a/farm-staking/farm-staking/meta/Cargo.toml +++ b/farm-staking/farm-staking/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/farm-staking/farm-staking/wasm/Cargo.lock b/farm-staking/farm-staking/wasm/Cargo.lock index a0b69f4ee..d4cfdd73e 100644 --- a/farm-staking/farm-staking/wasm/Cargo.lock +++ b/farm-staking/farm-staking/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -316,9 +316,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -330,9 +330,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -341,9 +341,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -353,9 +353,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -366,18 +366,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -435,9 +435,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -495,15 +495,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/farm-staking/farm-staking/wasm/Cargo.toml b/farm-staking/farm-staking/wasm/Cargo.toml index 3f5313c18..5b206bdfc 100644 --- a/farm-staking/farm-staking/wasm/Cargo.toml +++ b/farm-staking/farm-staking/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/farm-staking/metabonding-staking/Cargo.toml b/farm-staking/metabonding-staking/Cargo.toml index 05cf87564..a9678d893 100644 --- a/farm-staking/metabonding-staking/Cargo.toml +++ b/farm-staking/metabonding-staking/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.factory] path = "../../locked-asset/factory" @@ -22,7 +22,7 @@ path = "../../locked-asset/factory" num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.common_structs] path = "../../common/common_structs" diff --git a/farm-staking/metabonding-staking/meta/Cargo.toml b/farm-staking/metabonding-staking/meta/Cargo.toml index 7872ee659..32bf213be 100644 --- a/farm-staking/metabonding-staking/meta/Cargo.toml +++ b/farm-staking/metabonding-staking/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/farm-staking/metabonding-staking/wasm/Cargo.lock b/farm-staking/metabonding-staking/wasm/Cargo.lock index e4b8627cd..a8675928b 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.lock +++ b/farm-staking/metabonding-staking/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "cfg-if" @@ -46,9 +46,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -127,9 +127,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.151" +version = "0.2.158" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" +checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" [[package]] name = "math" @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -195,9 +195,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -207,9 +207,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -220,18 +220,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -256,9 +256,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -301,15 +301,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/farm-staking/metabonding-staking/wasm/Cargo.toml b/farm-staking/metabonding-staking/wasm/Cargo.toml index a8a2a7a7c..1853ff22d 100644 --- a/farm-staking/metabonding-staking/wasm/Cargo.toml +++ b/farm-staking/metabonding-staking/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/factory-legacy/Cargo.toml b/legacy-contracts/factory-legacy/Cargo.toml index f1dee1bb8..1f17baf8e 100644 --- a/legacy-contracts/factory-legacy/Cargo.toml +++ b/legacy-contracts/factory-legacy/Cargo.toml @@ -8,14 +8,14 @@ edition = "2018" path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dependencies.common_structs] path = "../../common/common_structs" diff --git a/legacy-contracts/factory-legacy/meta/Cargo.toml b/legacy-contracts/factory-legacy/meta/Cargo.toml index 01027f67e..99df379a1 100644 --- a/legacy-contracts/factory-legacy/meta/Cargo.toml +++ b/legacy-contracts/factory-legacy/meta/Cargo.toml @@ -10,5 +10,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false \ No newline at end of file diff --git a/legacy-contracts/factory-legacy/wasm/Cargo.lock b/legacy-contracts/factory-legacy/wasm/Cargo.lock index 84827ca96..4437e0091 100644 --- a/legacy-contracts/factory-legacy/wasm/Cargo.lock +++ b/legacy-contracts/factory-legacy/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -124,9 +124,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -138,9 +138,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -149,9 +149,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -174,18 +174,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -210,9 +210,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -261,9 +261,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/factory-legacy/wasm/Cargo.toml b/legacy-contracts/factory-legacy/wasm/Cargo.toml index bd05eac77..e147feb21 100644 --- a/legacy-contracts/factory-legacy/wasm/Cargo.toml +++ b/legacy-contracts/factory-legacy/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/farm-staking-proxy-v13/Cargo.toml b/legacy-contracts/farm-staking-proxy-v13/Cargo.toml index f530c7e09..4284d329e 100644 --- a/legacy-contracts/farm-staking-proxy-v13/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v13/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.token_merge_helper] path = "../../common/modules/token_merge_helper" @@ -57,4 +57,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/legacy-contracts/farm-staking-proxy-v13/meta/Cargo.toml b/legacy-contracts/farm-staking-proxy-v13/meta/Cargo.toml index bd22d73c1..e23e8edf5 100644 --- a/legacy-contracts/farm-staking-proxy-v13/meta/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v13/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.lock b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.lock index 0b23c164b..edad582f7 100644 --- a/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.lock +++ b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -336,9 +336,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -350,9 +350,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -361,9 +361,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -373,9 +373,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -386,18 +386,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -455,9 +455,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -515,15 +515,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.toml b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.toml index 8f9b2ad96..71837f035 100644 --- a/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.toml +++ b/legacy-contracts/farm-staking-proxy-v13/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/farm-v12/Cargo.lock b/legacy-contracts/farm-v12/Cargo.lock deleted file mode 100644 index 07b1eab79..000000000 --- a/legacy-contracts/farm-v12/Cargo.lock +++ /dev/null @@ -1,2593 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "aho-corasick" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" -dependencies = [ - "memchr", -] - -[[package]] -name = "anstream" -version = "0.6.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "is_terminal_polyfill", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" - -[[package]] -name = "anstyle-parse" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "anstyle-wincon" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" -dependencies = [ - "anstyle", - "windows-sys 0.52.0", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" -dependencies = [ - "derive_arbitrary", -] - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "backtrace" -version = "0.3.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base64" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" - -[[package]] -name = "bech32" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" - -[[package]] -name = "bip39" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" -dependencies = [ - "bitcoin_hashes", - "rand 0.8.5", - "rand_core 0.6.4", - "serde", - "unicode-normalization", -] - -[[package]] -name = "bitcoin_hashes" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "bstr" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" - -[[package]] -name = "cc" -version = "1.0.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "clap" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" -dependencies = [ - "clap_builder", - "clap_derive", -] - -[[package]] -name = "clap_builder" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" -dependencies = [ - "anstream", - "anstyle", - "clap_lex", - "strsim", -] - -[[package]] -name = "clap_derive" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "clap_lex" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" - -[[package]] -name = "colorchoice" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" - -[[package]] -name = "colored" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" -dependencies = [ - "lazy_static", - "windows-sys 0.48.0", -] - -[[package]] -name = "common-path" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" - -[[package]] -name = "convert_case" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "copy_dir" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" -dependencies = [ - "walkdir", -] - -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" -dependencies = [ - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "derive_arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "displaydoc" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - -[[package]] -name = "encoding_rs" -version = "0.8.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "endian-type" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "farm-v-13" -version = "0.0.0" -dependencies = [ - "multiversx-sc", - "multiversx-sc-scenario", - "num-bigint", -] - -[[package]] -name = "farm-v-13-meta" -version = "0.0.0" -dependencies = [ - "farm-v-13", - "multiversx-sc-meta", -] - -[[package]] -name = "fastrand" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" - -[[package]] -name = "flate2" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futures-channel" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" - -[[package]] -name = "futures-io" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" - -[[package]] -name = "futures-sink" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" - -[[package]] -name = "futures-task" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" - -[[package]] -name = "futures-util" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" -dependencies = [ - "futures-core", - "futures-io", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gimli" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" - -[[package]] -name = "globset" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" -dependencies = [ - "aho-corasick", - "bstr", - "log", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "h2" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" -dependencies = [ - "atomic-waker", - "bytes", - "fnv", - "futures-core", - "futures-sink", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "http" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" -dependencies = [ - "bytes", - "http", -] - -[[package]] -name = "http-body-util" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" -dependencies = [ - "bytes", - "futures-util", - "http", - "http-body", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" - -[[package]] -name = "hyper" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "itoa", - "pin-project-lite", - "smallvec", - "tokio", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" -dependencies = [ - "futures-util", - "http", - "hyper", - "hyper-util", - "rustls", - "rustls-pki-types", - "tokio", - "tokio-rustls", - "tower-service", -] - -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - -[[package]] -name = "hyper-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "http", - "http-body", - "hyper", - "pin-project-lite", - "socket2", - "tokio", - "tower", - "tower-service", - "tracing", -] - -[[package]] -name = "idna" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" -dependencies = [ - "crossbeam-deque", - "globset", - "log", - "memchr", - "regex-automata", - "same-file", - "walkdir", - "winapi-util", -] - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", - "serde", -] - -[[package]] -name = "ipnet" -version = "2.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" - -[[package]] -name = "is_terminal_polyfill" -version = "1.70.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" - -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "js-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "keccak" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "linux-raw-sys" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" - -[[package]] -name = "lock_api" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "lockfree-object-pool" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" - -[[package]] -name = "log" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", -] - -[[package]] -name = "multiversx-chain-scenario-format" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" -dependencies = [ - "bech32", - "hex", - "num-bigint", - "num-traits", - "serde", - "serde_json", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" -dependencies = [ - "bitflags 2.5.0", - "colored", - "ed25519-dalek", - "hex", - "hex-literal", - "itertools", - "multiversx-chain-vm-executor", - "num-bigint", - "num-traits", - "rand 0.8.5", - "rand_seeder", - "sha2 0.10.8", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm-executor" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" - -[[package]] -name = "multiversx-sc" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" -dependencies = [ - "bitflags 2.5.0", - "hex-literal", - "multiversx-sc-codec", - "multiversx-sc-derive", - "num-traits", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" -dependencies = [ - "arrayvec", - "multiversx-sc-codec-derive", - "num-bigint", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec-derive" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "multiversx-sc-derive" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "radix_trie", - "syn", -] - -[[package]] -name = "multiversx-sc-meta" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" -dependencies = [ - "clap", - "colored", - "common-path", - "convert_case", - "copy_dir", - "hex", - "lazy_static", - "multiversx-sc", - "pathdiff", - "reqwest", - "ruplacer", - "rustc_version", - "semver", - "serde", - "serde_json", - "toml", - "wasmparser", - "wasmprinter", - "zip", -] - -[[package]] -name = "multiversx-sc-scenario" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" -dependencies = [ - "base64", - "bech32", - "clap", - "colored", - "hex", - "itertools", - "log", - "multiversx-chain-scenario-format", - "multiversx-chain-vm", - "multiversx-chain-vm-executor", - "multiversx-sc", - "multiversx-sc-meta", - "multiversx-sdk", - "num-bigint", - "num-traits", - "pathdiff", - "serde", - "serde_json", - "sha2 0.10.8", - "tokio", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sdk" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" -dependencies = [ - "anyhow", - "base64", - "bech32", - "bip39", - "hex", - "hmac", - "itertools", - "pbkdf2", - "pem", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "sha2 0.10.8", - "sha3", - "tokio", - "zeroize", -] - -[[package]] -name = "native-tls" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" -dependencies = [ - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nibble_vec" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" -dependencies = [ - "smallvec", -] - -[[package]] -name = "num-bigint" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" -dependencies = [ - "num-integer", - "num-traits", -] - -[[package]] -name = "num-integer" -version = "0.1.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" -dependencies = [ - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "object" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "opaque-debug" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" - -[[package]] -name = "openssl" -version = "0.10.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" -dependencies = [ - "bitflags 2.5.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.102" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "parking_lot" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-targets 0.52.5", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "pbkdf2" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pem" -version = "3.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" -dependencies = [ - "base64", - "serde", -] - -[[package]] -name = "percent-encoding" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" - -[[package]] -name = "pin-project" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro2" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radix_trie" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" -dependencies = [ - "endian-type", - "nibble_vec", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.15", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_seeder" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "redox_syscall" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" -dependencies = [ - "bitflags 2.5.0", -] - -[[package]] -name = "regex" -version = "1.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" - -[[package]] -name = "reqwest" -version = "0.12.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" -dependencies = [ - "base64", - "bytes", - "encoding_rs", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "http-body-util", - "hyper", - "hyper-rustls", - "hyper-tls", - "hyper-util", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper", - "system-configuration", - "tokio", - "tokio-native-tls", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "winreg", -] - -[[package]] -name = "ring" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" -dependencies = [ - "cc", - "cfg-if", - "getrandom 0.2.15", - "libc", - "spin", - "untrusted", - "windows-sys 0.52.0", -] - -[[package]] -name = "ruplacer" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" -dependencies = [ - "Inflector", - "anyhow", - "clap", - "colored", - "ignore", - "regex", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.38.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" -dependencies = [ - "bitflags 2.5.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustls" -version = "0.23.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" -dependencies = [ - "once_cell", - "rustls-pki-types", - "rustls-webpki", - "subtle", - "zeroize", -] - -[[package]] -name = "rustls-pemfile" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" -dependencies = [ - "base64", - "rustls-pki-types", -] - -[[package]] -name = "rustls-pki-types" -version = "1.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" - -[[package]] -name = "rustls-webpki" -version = "0.102.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" -dependencies = [ - "ring", - "rustls-pki-types", - "untrusted", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "schannel" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "security-framework" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" -dependencies = [ - "bitflags 2.5.0", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.119" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" -dependencies = [ - "indexmap", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_spanned" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simd-adler32" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" - -[[package]] -name = "socket2" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "syn" -version = "2.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "sync_wrapper" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tempfile" -version = "3.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" -dependencies = [ - "cfg-if", - "fastrand", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "thiserror" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tinyvec" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot", - "pin-project-lite", - "signal-hook-registry", - "socket2", - "tokio-macros", - "windows-sys 0.48.0", -] - -[[package]] -name = "tokio-macros" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" -dependencies = [ - "rustls", - "rustls-pki-types", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "toml" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "pin-project", - "pin-project-lite", - "tokio", - "tower-layer", - "tower-service", -] - -[[package]] -name = "tower-layer" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" -dependencies = [ - "pin-project-lite", - "tracing-core", -] - -[[package]] -name = "tracing-core" -version = "0.1.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" -dependencies = [ - "once_cell", -] - -[[package]] -name = "try-lock" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unicode-bidi" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "unwrap-infallible" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" - -[[package]] -name = "url" -version = "2.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "utf8parse" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" - -[[package]] -name = "wasmparser" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" -dependencies = [ - "ahash", - "bitflags 2.5.0", - "hashbrown", - "indexmap", - "semver", - "serde", -] - -[[package]] -name = "wasmprinter" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" -dependencies = [ - "anyhow", - "wasmparser", -] - -[[package]] -name = "web-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "winapi-util" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.5", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.5", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm 0.48.5", - "windows_aarch64_msvc 0.48.5", - "windows_i686_gnu 0.48.5", - "windows_i686_msvc 0.48.5", - "windows_x86_64_gnu 0.48.5", - "windows_x86_64_gnullvm 0.48.5", - "windows_x86_64_msvc 0.48.5", -] - -[[package]] -name = "windows-targets" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" -dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", - "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" - -[[package]] -name = "winnow" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - -[[package]] -name = "zerocopy" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" -dependencies = [ - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zip" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" -dependencies = [ - "arbitrary", - "crc32fast", - "crossbeam-utils", - "displaydoc", - "flate2", - "indexmap", - "memchr", - "thiserror", - "zopfli", -] - -[[package]] -name = "zopfli" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" -dependencies = [ - "bumpalo", - "crc32fast", - "lockfree-object-pool", - "log", - "once_cell", - "simd-adler32", -] diff --git a/legacy-contracts/farm-v12/Cargo.toml b/legacy-contracts/farm-v12/Cargo.toml index 3aa922b85..1c5b00b29 100644 --- a/legacy-contracts/farm-v12/Cargo.toml +++ b/legacy-contracts/farm-v12/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "0.50.5" +version = "0.52.3" [dev-dependencies] num-bigint = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "0.50.5" +version = "0.52.3" diff --git a/legacy-contracts/farm-v12/meta/Cargo.toml b/legacy-contracts/farm-v12/meta/Cargo.toml index 3a195e0ed..a2f55541d 100644 --- a/legacy-contracts/farm-v12/meta/Cargo.toml +++ b/legacy-contracts/farm-v12/meta/Cargo.toml @@ -8,5 +8,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/farm-v12/wasm/Cargo.lock b/legacy-contracts/farm-v12/wasm/Cargo.lock index aedadbc26..3223f31f4 100644 --- a/legacy-contracts/farm-v12/wasm/Cargo.lock +++ b/legacy-contracts/farm-v12/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "endian-type" @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -69,9 +69,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -80,9 +80,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -92,9 +92,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -105,9 +105,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -166,9 +166,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/farm-v12/wasm/Cargo.toml b/legacy-contracts/farm-v12/wasm/Cargo.toml index 00f6566ac..a2e35227c 100644 --- a/legacy-contracts/farm-v12/wasm/Cargo.toml +++ b/legacy-contracts/farm-v12/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "0.50.5" +version = "0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/farm-v13-custom-rewards/Cargo.lock b/legacy-contracts/farm-v13-custom-rewards/Cargo.lock deleted file mode 100644 index 07b1eab79..000000000 --- a/legacy-contracts/farm-v13-custom-rewards/Cargo.lock +++ /dev/null @@ -1,2593 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "aho-corasick" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" -dependencies = [ - "memchr", -] - -[[package]] -name = "anstream" -version = "0.6.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "is_terminal_polyfill", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" - -[[package]] -name = "anstyle-parse" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "anstyle-wincon" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" -dependencies = [ - "anstyle", - "windows-sys 0.52.0", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" -dependencies = [ - "derive_arbitrary", -] - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "backtrace" -version = "0.3.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base64" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" - -[[package]] -name = "bech32" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" - -[[package]] -name = "bip39" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" -dependencies = [ - "bitcoin_hashes", - "rand 0.8.5", - "rand_core 0.6.4", - "serde", - "unicode-normalization", -] - -[[package]] -name = "bitcoin_hashes" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "bstr" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" - -[[package]] -name = "cc" -version = "1.0.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "clap" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" -dependencies = [ - "clap_builder", - "clap_derive", -] - -[[package]] -name = "clap_builder" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" -dependencies = [ - "anstream", - "anstyle", - "clap_lex", - "strsim", -] - -[[package]] -name = "clap_derive" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "clap_lex" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" - -[[package]] -name = "colorchoice" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" - -[[package]] -name = "colored" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" -dependencies = [ - "lazy_static", - "windows-sys 0.48.0", -] - -[[package]] -name = "common-path" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" - -[[package]] -name = "convert_case" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "copy_dir" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" -dependencies = [ - "walkdir", -] - -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" -dependencies = [ - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "derive_arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "displaydoc" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - -[[package]] -name = "encoding_rs" -version = "0.8.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "endian-type" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "farm-v-13" -version = "0.0.0" -dependencies = [ - "multiversx-sc", - "multiversx-sc-scenario", - "num-bigint", -] - -[[package]] -name = "farm-v-13-meta" -version = "0.0.0" -dependencies = [ - "farm-v-13", - "multiversx-sc-meta", -] - -[[package]] -name = "fastrand" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" - -[[package]] -name = "flate2" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futures-channel" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" - -[[package]] -name = "futures-io" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" - -[[package]] -name = "futures-sink" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" - -[[package]] -name = "futures-task" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" - -[[package]] -name = "futures-util" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" -dependencies = [ - "futures-core", - "futures-io", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gimli" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" - -[[package]] -name = "globset" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" -dependencies = [ - "aho-corasick", - "bstr", - "log", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "h2" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" -dependencies = [ - "atomic-waker", - "bytes", - "fnv", - "futures-core", - "futures-sink", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "http" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" -dependencies = [ - "bytes", - "http", -] - -[[package]] -name = "http-body-util" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" -dependencies = [ - "bytes", - "futures-util", - "http", - "http-body", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" - -[[package]] -name = "hyper" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "itoa", - "pin-project-lite", - "smallvec", - "tokio", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" -dependencies = [ - "futures-util", - "http", - "hyper", - "hyper-util", - "rustls", - "rustls-pki-types", - "tokio", - "tokio-rustls", - "tower-service", -] - -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - -[[package]] -name = "hyper-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "http", - "http-body", - "hyper", - "pin-project-lite", - "socket2", - "tokio", - "tower", - "tower-service", - "tracing", -] - -[[package]] -name = "idna" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" -dependencies = [ - "crossbeam-deque", - "globset", - "log", - "memchr", - "regex-automata", - "same-file", - "walkdir", - "winapi-util", -] - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", - "serde", -] - -[[package]] -name = "ipnet" -version = "2.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" - -[[package]] -name = "is_terminal_polyfill" -version = "1.70.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" - -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "js-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "keccak" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "linux-raw-sys" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" - -[[package]] -name = "lock_api" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "lockfree-object-pool" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" - -[[package]] -name = "log" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", -] - -[[package]] -name = "multiversx-chain-scenario-format" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" -dependencies = [ - "bech32", - "hex", - "num-bigint", - "num-traits", - "serde", - "serde_json", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" -dependencies = [ - "bitflags 2.5.0", - "colored", - "ed25519-dalek", - "hex", - "hex-literal", - "itertools", - "multiversx-chain-vm-executor", - "num-bigint", - "num-traits", - "rand 0.8.5", - "rand_seeder", - "sha2 0.10.8", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm-executor" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" - -[[package]] -name = "multiversx-sc" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" -dependencies = [ - "bitflags 2.5.0", - "hex-literal", - "multiversx-sc-codec", - "multiversx-sc-derive", - "num-traits", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" -dependencies = [ - "arrayvec", - "multiversx-sc-codec-derive", - "num-bigint", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec-derive" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "multiversx-sc-derive" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "radix_trie", - "syn", -] - -[[package]] -name = "multiversx-sc-meta" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" -dependencies = [ - "clap", - "colored", - "common-path", - "convert_case", - "copy_dir", - "hex", - "lazy_static", - "multiversx-sc", - "pathdiff", - "reqwest", - "ruplacer", - "rustc_version", - "semver", - "serde", - "serde_json", - "toml", - "wasmparser", - "wasmprinter", - "zip", -] - -[[package]] -name = "multiversx-sc-scenario" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" -dependencies = [ - "base64", - "bech32", - "clap", - "colored", - "hex", - "itertools", - "log", - "multiversx-chain-scenario-format", - "multiversx-chain-vm", - "multiversx-chain-vm-executor", - "multiversx-sc", - "multiversx-sc-meta", - "multiversx-sdk", - "num-bigint", - "num-traits", - "pathdiff", - "serde", - "serde_json", - "sha2 0.10.8", - "tokio", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sdk" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" -dependencies = [ - "anyhow", - "base64", - "bech32", - "bip39", - "hex", - "hmac", - "itertools", - "pbkdf2", - "pem", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "sha2 0.10.8", - "sha3", - "tokio", - "zeroize", -] - -[[package]] -name = "native-tls" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" -dependencies = [ - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nibble_vec" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" -dependencies = [ - "smallvec", -] - -[[package]] -name = "num-bigint" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" -dependencies = [ - "num-integer", - "num-traits", -] - -[[package]] -name = "num-integer" -version = "0.1.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" -dependencies = [ - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "object" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "opaque-debug" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" - -[[package]] -name = "openssl" -version = "0.10.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" -dependencies = [ - "bitflags 2.5.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.102" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "parking_lot" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-targets 0.52.5", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "pbkdf2" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pem" -version = "3.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" -dependencies = [ - "base64", - "serde", -] - -[[package]] -name = "percent-encoding" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" - -[[package]] -name = "pin-project" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro2" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radix_trie" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" -dependencies = [ - "endian-type", - "nibble_vec", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.15", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_seeder" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "redox_syscall" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" -dependencies = [ - "bitflags 2.5.0", -] - -[[package]] -name = "regex" -version = "1.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" - -[[package]] -name = "reqwest" -version = "0.12.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" -dependencies = [ - "base64", - "bytes", - "encoding_rs", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "http-body-util", - "hyper", - "hyper-rustls", - "hyper-tls", - "hyper-util", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper", - "system-configuration", - "tokio", - "tokio-native-tls", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "winreg", -] - -[[package]] -name = "ring" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" -dependencies = [ - "cc", - "cfg-if", - "getrandom 0.2.15", - "libc", - "spin", - "untrusted", - "windows-sys 0.52.0", -] - -[[package]] -name = "ruplacer" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" -dependencies = [ - "Inflector", - "anyhow", - "clap", - "colored", - "ignore", - "regex", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.38.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" -dependencies = [ - "bitflags 2.5.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustls" -version = "0.23.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" -dependencies = [ - "once_cell", - "rustls-pki-types", - "rustls-webpki", - "subtle", - "zeroize", -] - -[[package]] -name = "rustls-pemfile" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" -dependencies = [ - "base64", - "rustls-pki-types", -] - -[[package]] -name = "rustls-pki-types" -version = "1.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" - -[[package]] -name = "rustls-webpki" -version = "0.102.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" -dependencies = [ - "ring", - "rustls-pki-types", - "untrusted", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "schannel" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "security-framework" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" -dependencies = [ - "bitflags 2.5.0", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.119" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" -dependencies = [ - "indexmap", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_spanned" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simd-adler32" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" - -[[package]] -name = "socket2" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "syn" -version = "2.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "sync_wrapper" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tempfile" -version = "3.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" -dependencies = [ - "cfg-if", - "fastrand", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "thiserror" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tinyvec" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot", - "pin-project-lite", - "signal-hook-registry", - "socket2", - "tokio-macros", - "windows-sys 0.48.0", -] - -[[package]] -name = "tokio-macros" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" -dependencies = [ - "rustls", - "rustls-pki-types", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "toml" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "pin-project", - "pin-project-lite", - "tokio", - "tower-layer", - "tower-service", -] - -[[package]] -name = "tower-layer" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" -dependencies = [ - "pin-project-lite", - "tracing-core", -] - -[[package]] -name = "tracing-core" -version = "0.1.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" -dependencies = [ - "once_cell", -] - -[[package]] -name = "try-lock" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unicode-bidi" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "unwrap-infallible" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" - -[[package]] -name = "url" -version = "2.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "utf8parse" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" - -[[package]] -name = "wasmparser" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" -dependencies = [ - "ahash", - "bitflags 2.5.0", - "hashbrown", - "indexmap", - "semver", - "serde", -] - -[[package]] -name = "wasmprinter" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" -dependencies = [ - "anyhow", - "wasmparser", -] - -[[package]] -name = "web-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "winapi-util" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.5", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.5", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm 0.48.5", - "windows_aarch64_msvc 0.48.5", - "windows_i686_gnu 0.48.5", - "windows_i686_msvc 0.48.5", - "windows_x86_64_gnu 0.48.5", - "windows_x86_64_gnullvm 0.48.5", - "windows_x86_64_msvc 0.48.5", -] - -[[package]] -name = "windows-targets" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" -dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", - "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" - -[[package]] -name = "winnow" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - -[[package]] -name = "zerocopy" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" -dependencies = [ - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zip" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" -dependencies = [ - "arbitrary", - "crc32fast", - "crossbeam-utils", - "displaydoc", - "flate2", - "indexmap", - "memchr", - "thiserror", - "zopfli", -] - -[[package]] -name = "zopfli" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" -dependencies = [ - "bumpalo", - "crc32fast", - "lockfree-object-pool", - "log", - "once_cell", - "simd-adler32", -] diff --git a/legacy-contracts/farm-v13-custom-rewards/Cargo.toml b/legacy-contracts/farm-v13-custom-rewards/Cargo.toml index c0a35e39c..11ee0c4a1 100644 --- a/legacy-contracts/farm-v13-custom-rewards/Cargo.toml +++ b/legacy-contracts/farm-v13-custom-rewards/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "0.50.5" +version = "0.52.3" [dev-dependencies] num-bigint = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "0.50.5" +version = "0.52.3" diff --git a/legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml b/legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml index a5038c44a..19cc6160c 100644 --- a/legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml +++ b/legacy-contracts/farm-v13-custom-rewards/meta/Cargo.toml @@ -8,5 +8,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock index fd532c2d9..72579ae25 100644 --- a/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock +++ b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "endian-type" @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -69,9 +69,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -80,9 +80,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -92,9 +92,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -105,9 +105,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -166,9 +166,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml index 2a05d93a7..6eaa243e8 100644 --- a/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml +++ b/legacy-contracts/farm-v13-custom-rewards/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "0.50.5" +version = "0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/farm-v13-locked-rewards/Cargo.lock b/legacy-contracts/farm-v13-locked-rewards/Cargo.lock deleted file mode 100644 index 07b1eab79..000000000 --- a/legacy-contracts/farm-v13-locked-rewards/Cargo.lock +++ /dev/null @@ -1,2593 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "aho-corasick" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" -dependencies = [ - "memchr", -] - -[[package]] -name = "anstream" -version = "0.6.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "is_terminal_polyfill", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" - -[[package]] -name = "anstyle-parse" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "anstyle-wincon" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" -dependencies = [ - "anstyle", - "windows-sys 0.52.0", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" -dependencies = [ - "derive_arbitrary", -] - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "backtrace" -version = "0.3.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base64" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" - -[[package]] -name = "bech32" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" - -[[package]] -name = "bip39" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" -dependencies = [ - "bitcoin_hashes", - "rand 0.8.5", - "rand_core 0.6.4", - "serde", - "unicode-normalization", -] - -[[package]] -name = "bitcoin_hashes" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "bstr" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" - -[[package]] -name = "cc" -version = "1.0.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "clap" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" -dependencies = [ - "clap_builder", - "clap_derive", -] - -[[package]] -name = "clap_builder" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" -dependencies = [ - "anstream", - "anstyle", - "clap_lex", - "strsim", -] - -[[package]] -name = "clap_derive" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "clap_lex" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" - -[[package]] -name = "colorchoice" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" - -[[package]] -name = "colored" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" -dependencies = [ - "lazy_static", - "windows-sys 0.48.0", -] - -[[package]] -name = "common-path" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" - -[[package]] -name = "convert_case" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "copy_dir" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" -dependencies = [ - "walkdir", -] - -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" -dependencies = [ - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "derive_arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "displaydoc" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - -[[package]] -name = "encoding_rs" -version = "0.8.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "endian-type" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "farm-v-13" -version = "0.0.0" -dependencies = [ - "multiversx-sc", - "multiversx-sc-scenario", - "num-bigint", -] - -[[package]] -name = "farm-v-13-meta" -version = "0.0.0" -dependencies = [ - "farm-v-13", - "multiversx-sc-meta", -] - -[[package]] -name = "fastrand" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" - -[[package]] -name = "flate2" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futures-channel" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" - -[[package]] -name = "futures-io" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" - -[[package]] -name = "futures-sink" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" - -[[package]] -name = "futures-task" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" - -[[package]] -name = "futures-util" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" -dependencies = [ - "futures-core", - "futures-io", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gimli" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" - -[[package]] -name = "globset" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" -dependencies = [ - "aho-corasick", - "bstr", - "log", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "h2" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" -dependencies = [ - "atomic-waker", - "bytes", - "fnv", - "futures-core", - "futures-sink", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "http" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" -dependencies = [ - "bytes", - "http", -] - -[[package]] -name = "http-body-util" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" -dependencies = [ - "bytes", - "futures-util", - "http", - "http-body", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" - -[[package]] -name = "hyper" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "itoa", - "pin-project-lite", - "smallvec", - "tokio", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" -dependencies = [ - "futures-util", - "http", - "hyper", - "hyper-util", - "rustls", - "rustls-pki-types", - "tokio", - "tokio-rustls", - "tower-service", -] - -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - -[[package]] -name = "hyper-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "http", - "http-body", - "hyper", - "pin-project-lite", - "socket2", - "tokio", - "tower", - "tower-service", - "tracing", -] - -[[package]] -name = "idna" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" -dependencies = [ - "crossbeam-deque", - "globset", - "log", - "memchr", - "regex-automata", - "same-file", - "walkdir", - "winapi-util", -] - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", - "serde", -] - -[[package]] -name = "ipnet" -version = "2.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" - -[[package]] -name = "is_terminal_polyfill" -version = "1.70.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" - -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "js-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "keccak" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "linux-raw-sys" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" - -[[package]] -name = "lock_api" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "lockfree-object-pool" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" - -[[package]] -name = "log" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", -] - -[[package]] -name = "multiversx-chain-scenario-format" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" -dependencies = [ - "bech32", - "hex", - "num-bigint", - "num-traits", - "serde", - "serde_json", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" -dependencies = [ - "bitflags 2.5.0", - "colored", - "ed25519-dalek", - "hex", - "hex-literal", - "itertools", - "multiversx-chain-vm-executor", - "num-bigint", - "num-traits", - "rand 0.8.5", - "rand_seeder", - "sha2 0.10.8", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm-executor" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" - -[[package]] -name = "multiversx-sc" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" -dependencies = [ - "bitflags 2.5.0", - "hex-literal", - "multiversx-sc-codec", - "multiversx-sc-derive", - "num-traits", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" -dependencies = [ - "arrayvec", - "multiversx-sc-codec-derive", - "num-bigint", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec-derive" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "multiversx-sc-derive" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "radix_trie", - "syn", -] - -[[package]] -name = "multiversx-sc-meta" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" -dependencies = [ - "clap", - "colored", - "common-path", - "convert_case", - "copy_dir", - "hex", - "lazy_static", - "multiversx-sc", - "pathdiff", - "reqwest", - "ruplacer", - "rustc_version", - "semver", - "serde", - "serde_json", - "toml", - "wasmparser", - "wasmprinter", - "zip", -] - -[[package]] -name = "multiversx-sc-scenario" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" -dependencies = [ - "base64", - "bech32", - "clap", - "colored", - "hex", - "itertools", - "log", - "multiversx-chain-scenario-format", - "multiversx-chain-vm", - "multiversx-chain-vm-executor", - "multiversx-sc", - "multiversx-sc-meta", - "multiversx-sdk", - "num-bigint", - "num-traits", - "pathdiff", - "serde", - "serde_json", - "sha2 0.10.8", - "tokio", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sdk" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" -dependencies = [ - "anyhow", - "base64", - "bech32", - "bip39", - "hex", - "hmac", - "itertools", - "pbkdf2", - "pem", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "sha2 0.10.8", - "sha3", - "tokio", - "zeroize", -] - -[[package]] -name = "native-tls" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" -dependencies = [ - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nibble_vec" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" -dependencies = [ - "smallvec", -] - -[[package]] -name = "num-bigint" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" -dependencies = [ - "num-integer", - "num-traits", -] - -[[package]] -name = "num-integer" -version = "0.1.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" -dependencies = [ - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "object" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "opaque-debug" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" - -[[package]] -name = "openssl" -version = "0.10.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" -dependencies = [ - "bitflags 2.5.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.102" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "parking_lot" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-targets 0.52.5", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "pbkdf2" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pem" -version = "3.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" -dependencies = [ - "base64", - "serde", -] - -[[package]] -name = "percent-encoding" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" - -[[package]] -name = "pin-project" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro2" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radix_trie" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" -dependencies = [ - "endian-type", - "nibble_vec", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.15", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_seeder" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "redox_syscall" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" -dependencies = [ - "bitflags 2.5.0", -] - -[[package]] -name = "regex" -version = "1.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" - -[[package]] -name = "reqwest" -version = "0.12.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" -dependencies = [ - "base64", - "bytes", - "encoding_rs", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "http-body-util", - "hyper", - "hyper-rustls", - "hyper-tls", - "hyper-util", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper", - "system-configuration", - "tokio", - "tokio-native-tls", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "winreg", -] - -[[package]] -name = "ring" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" -dependencies = [ - "cc", - "cfg-if", - "getrandom 0.2.15", - "libc", - "spin", - "untrusted", - "windows-sys 0.52.0", -] - -[[package]] -name = "ruplacer" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" -dependencies = [ - "Inflector", - "anyhow", - "clap", - "colored", - "ignore", - "regex", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.38.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" -dependencies = [ - "bitflags 2.5.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustls" -version = "0.23.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" -dependencies = [ - "once_cell", - "rustls-pki-types", - "rustls-webpki", - "subtle", - "zeroize", -] - -[[package]] -name = "rustls-pemfile" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" -dependencies = [ - "base64", - "rustls-pki-types", -] - -[[package]] -name = "rustls-pki-types" -version = "1.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" - -[[package]] -name = "rustls-webpki" -version = "0.102.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" -dependencies = [ - "ring", - "rustls-pki-types", - "untrusted", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "schannel" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "security-framework" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" -dependencies = [ - "bitflags 2.5.0", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.119" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" -dependencies = [ - "indexmap", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_spanned" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simd-adler32" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" - -[[package]] -name = "socket2" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "syn" -version = "2.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "sync_wrapper" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tempfile" -version = "3.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" -dependencies = [ - "cfg-if", - "fastrand", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "thiserror" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tinyvec" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot", - "pin-project-lite", - "signal-hook-registry", - "socket2", - "tokio-macros", - "windows-sys 0.48.0", -] - -[[package]] -name = "tokio-macros" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" -dependencies = [ - "rustls", - "rustls-pki-types", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "toml" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "pin-project", - "pin-project-lite", - "tokio", - "tower-layer", - "tower-service", -] - -[[package]] -name = "tower-layer" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" -dependencies = [ - "pin-project-lite", - "tracing-core", -] - -[[package]] -name = "tracing-core" -version = "0.1.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" -dependencies = [ - "once_cell", -] - -[[package]] -name = "try-lock" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unicode-bidi" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "unwrap-infallible" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" - -[[package]] -name = "url" -version = "2.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "utf8parse" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" - -[[package]] -name = "wasmparser" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" -dependencies = [ - "ahash", - "bitflags 2.5.0", - "hashbrown", - "indexmap", - "semver", - "serde", -] - -[[package]] -name = "wasmprinter" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" -dependencies = [ - "anyhow", - "wasmparser", -] - -[[package]] -name = "web-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "winapi-util" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.5", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.5", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm 0.48.5", - "windows_aarch64_msvc 0.48.5", - "windows_i686_gnu 0.48.5", - "windows_i686_msvc 0.48.5", - "windows_x86_64_gnu 0.48.5", - "windows_x86_64_gnullvm 0.48.5", - "windows_x86_64_msvc 0.48.5", -] - -[[package]] -name = "windows-targets" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" -dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", - "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" - -[[package]] -name = "winnow" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - -[[package]] -name = "zerocopy" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" -dependencies = [ - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zip" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" -dependencies = [ - "arbitrary", - "crc32fast", - "crossbeam-utils", - "displaydoc", - "flate2", - "indexmap", - "memchr", - "thiserror", - "zopfli", -] - -[[package]] -name = "zopfli" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" -dependencies = [ - "bumpalo", - "crc32fast", - "lockfree-object-pool", - "log", - "once_cell", - "simd-adler32", -] diff --git a/legacy-contracts/farm-v13-locked-rewards/Cargo.toml b/legacy-contracts/farm-v13-locked-rewards/Cargo.toml index 315ac407f..31a1cf1fa 100644 --- a/legacy-contracts/farm-v13-locked-rewards/Cargo.toml +++ b/legacy-contracts/farm-v13-locked-rewards/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "0.50.5" +version = "0.52.3" [dev-dependencies] num-bigint = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "0.50.5" +version = "0.52.3" diff --git a/legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml b/legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml index 2fe5738aa..f4fc5fdb2 100644 --- a/legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml +++ b/legacy-contracts/farm-v13-locked-rewards/meta/Cargo.toml @@ -8,5 +8,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock index 32f373d1c..648687653 100644 --- a/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock +++ b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "endian-type" @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -69,9 +69,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -80,9 +80,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -92,9 +92,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -105,9 +105,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -166,9 +166,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml index 83789310d..6c8dfa0f3 100644 --- a/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml +++ b/legacy-contracts/farm-v13-locked-rewards/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "0.50.5" +version = "0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/farm-v13/Cargo.lock b/legacy-contracts/farm-v13/Cargo.lock deleted file mode 100644 index 07b1eab79..000000000 --- a/legacy-contracts/farm-v13/Cargo.lock +++ /dev/null @@ -1,2593 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "aho-corasick" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" -dependencies = [ - "memchr", -] - -[[package]] -name = "anstream" -version = "0.6.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "is_terminal_polyfill", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" - -[[package]] -name = "anstyle-parse" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "anstyle-wincon" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" -dependencies = [ - "anstyle", - "windows-sys 0.52.0", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" -dependencies = [ - "derive_arbitrary", -] - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "backtrace" -version = "0.3.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base64" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" - -[[package]] -name = "bech32" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" - -[[package]] -name = "bip39" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" -dependencies = [ - "bitcoin_hashes", - "rand 0.8.5", - "rand_core 0.6.4", - "serde", - "unicode-normalization", -] - -[[package]] -name = "bitcoin_hashes" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "bstr" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" - -[[package]] -name = "cc" -version = "1.0.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "clap" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" -dependencies = [ - "clap_builder", - "clap_derive", -] - -[[package]] -name = "clap_builder" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" -dependencies = [ - "anstream", - "anstyle", - "clap_lex", - "strsim", -] - -[[package]] -name = "clap_derive" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "clap_lex" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" - -[[package]] -name = "colorchoice" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" - -[[package]] -name = "colored" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" -dependencies = [ - "lazy_static", - "windows-sys 0.48.0", -] - -[[package]] -name = "common-path" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" - -[[package]] -name = "convert_case" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "copy_dir" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" -dependencies = [ - "walkdir", -] - -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" -dependencies = [ - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "derive_arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "displaydoc" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - -[[package]] -name = "encoding_rs" -version = "0.8.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "endian-type" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "farm-v-13" -version = "0.0.0" -dependencies = [ - "multiversx-sc", - "multiversx-sc-scenario", - "num-bigint", -] - -[[package]] -name = "farm-v-13-meta" -version = "0.0.0" -dependencies = [ - "farm-v-13", - "multiversx-sc-meta", -] - -[[package]] -name = "fastrand" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" - -[[package]] -name = "flate2" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futures-channel" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" - -[[package]] -name = "futures-io" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" - -[[package]] -name = "futures-sink" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" - -[[package]] -name = "futures-task" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" - -[[package]] -name = "futures-util" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" -dependencies = [ - "futures-core", - "futures-io", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gimli" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" - -[[package]] -name = "globset" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" -dependencies = [ - "aho-corasick", - "bstr", - "log", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "h2" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" -dependencies = [ - "atomic-waker", - "bytes", - "fnv", - "futures-core", - "futures-sink", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "http" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" -dependencies = [ - "bytes", - "http", -] - -[[package]] -name = "http-body-util" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" -dependencies = [ - "bytes", - "futures-util", - "http", - "http-body", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" - -[[package]] -name = "hyper" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "itoa", - "pin-project-lite", - "smallvec", - "tokio", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" -dependencies = [ - "futures-util", - "http", - "hyper", - "hyper-util", - "rustls", - "rustls-pki-types", - "tokio", - "tokio-rustls", - "tower-service", -] - -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - -[[package]] -name = "hyper-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "http", - "http-body", - "hyper", - "pin-project-lite", - "socket2", - "tokio", - "tower", - "tower-service", - "tracing", -] - -[[package]] -name = "idna" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" -dependencies = [ - "crossbeam-deque", - "globset", - "log", - "memchr", - "regex-automata", - "same-file", - "walkdir", - "winapi-util", -] - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", - "serde", -] - -[[package]] -name = "ipnet" -version = "2.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" - -[[package]] -name = "is_terminal_polyfill" -version = "1.70.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" - -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "js-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "keccak" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "linux-raw-sys" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" - -[[package]] -name = "lock_api" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "lockfree-object-pool" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" - -[[package]] -name = "log" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", -] - -[[package]] -name = "multiversx-chain-scenario-format" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" -dependencies = [ - "bech32", - "hex", - "num-bigint", - "num-traits", - "serde", - "serde_json", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" -dependencies = [ - "bitflags 2.5.0", - "colored", - "ed25519-dalek", - "hex", - "hex-literal", - "itertools", - "multiversx-chain-vm-executor", - "num-bigint", - "num-traits", - "rand 0.8.5", - "rand_seeder", - "sha2 0.10.8", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm-executor" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" - -[[package]] -name = "multiversx-sc" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" -dependencies = [ - "bitflags 2.5.0", - "hex-literal", - "multiversx-sc-codec", - "multiversx-sc-derive", - "num-traits", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" -dependencies = [ - "arrayvec", - "multiversx-sc-codec-derive", - "num-bigint", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec-derive" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "multiversx-sc-derive" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "radix_trie", - "syn", -] - -[[package]] -name = "multiversx-sc-meta" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" -dependencies = [ - "clap", - "colored", - "common-path", - "convert_case", - "copy_dir", - "hex", - "lazy_static", - "multiversx-sc", - "pathdiff", - "reqwest", - "ruplacer", - "rustc_version", - "semver", - "serde", - "serde_json", - "toml", - "wasmparser", - "wasmprinter", - "zip", -] - -[[package]] -name = "multiversx-sc-scenario" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" -dependencies = [ - "base64", - "bech32", - "clap", - "colored", - "hex", - "itertools", - "log", - "multiversx-chain-scenario-format", - "multiversx-chain-vm", - "multiversx-chain-vm-executor", - "multiversx-sc", - "multiversx-sc-meta", - "multiversx-sdk", - "num-bigint", - "num-traits", - "pathdiff", - "serde", - "serde_json", - "sha2 0.10.8", - "tokio", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sdk" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" -dependencies = [ - "anyhow", - "base64", - "bech32", - "bip39", - "hex", - "hmac", - "itertools", - "pbkdf2", - "pem", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "sha2 0.10.8", - "sha3", - "tokio", - "zeroize", -] - -[[package]] -name = "native-tls" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" -dependencies = [ - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nibble_vec" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" -dependencies = [ - "smallvec", -] - -[[package]] -name = "num-bigint" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" -dependencies = [ - "num-integer", - "num-traits", -] - -[[package]] -name = "num-integer" -version = "0.1.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" -dependencies = [ - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "object" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "opaque-debug" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" - -[[package]] -name = "openssl" -version = "0.10.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" -dependencies = [ - "bitflags 2.5.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.102" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "parking_lot" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-targets 0.52.5", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "pbkdf2" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pem" -version = "3.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" -dependencies = [ - "base64", - "serde", -] - -[[package]] -name = "percent-encoding" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" - -[[package]] -name = "pin-project" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro2" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radix_trie" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" -dependencies = [ - "endian-type", - "nibble_vec", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.15", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_seeder" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "redox_syscall" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" -dependencies = [ - "bitflags 2.5.0", -] - -[[package]] -name = "regex" -version = "1.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" - -[[package]] -name = "reqwest" -version = "0.12.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" -dependencies = [ - "base64", - "bytes", - "encoding_rs", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "http-body-util", - "hyper", - "hyper-rustls", - "hyper-tls", - "hyper-util", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper", - "system-configuration", - "tokio", - "tokio-native-tls", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "winreg", -] - -[[package]] -name = "ring" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" -dependencies = [ - "cc", - "cfg-if", - "getrandom 0.2.15", - "libc", - "spin", - "untrusted", - "windows-sys 0.52.0", -] - -[[package]] -name = "ruplacer" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" -dependencies = [ - "Inflector", - "anyhow", - "clap", - "colored", - "ignore", - "regex", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.38.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" -dependencies = [ - "bitflags 2.5.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustls" -version = "0.23.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" -dependencies = [ - "once_cell", - "rustls-pki-types", - "rustls-webpki", - "subtle", - "zeroize", -] - -[[package]] -name = "rustls-pemfile" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" -dependencies = [ - "base64", - "rustls-pki-types", -] - -[[package]] -name = "rustls-pki-types" -version = "1.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" - -[[package]] -name = "rustls-webpki" -version = "0.102.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" -dependencies = [ - "ring", - "rustls-pki-types", - "untrusted", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "schannel" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "security-framework" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" -dependencies = [ - "bitflags 2.5.0", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.119" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" -dependencies = [ - "indexmap", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_spanned" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simd-adler32" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" - -[[package]] -name = "socket2" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "syn" -version = "2.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "sync_wrapper" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tempfile" -version = "3.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" -dependencies = [ - "cfg-if", - "fastrand", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "thiserror" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tinyvec" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot", - "pin-project-lite", - "signal-hook-registry", - "socket2", - "tokio-macros", - "windows-sys 0.48.0", -] - -[[package]] -name = "tokio-macros" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" -dependencies = [ - "rustls", - "rustls-pki-types", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "toml" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "pin-project", - "pin-project-lite", - "tokio", - "tower-layer", - "tower-service", -] - -[[package]] -name = "tower-layer" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" -dependencies = [ - "pin-project-lite", - "tracing-core", -] - -[[package]] -name = "tracing-core" -version = "0.1.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" -dependencies = [ - "once_cell", -] - -[[package]] -name = "try-lock" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unicode-bidi" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "unwrap-infallible" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" - -[[package]] -name = "url" -version = "2.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "utf8parse" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" - -[[package]] -name = "wasmparser" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" -dependencies = [ - "ahash", - "bitflags 2.5.0", - "hashbrown", - "indexmap", - "semver", - "serde", -] - -[[package]] -name = "wasmprinter" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" -dependencies = [ - "anyhow", - "wasmparser", -] - -[[package]] -name = "web-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "winapi-util" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.5", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.5", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm 0.48.5", - "windows_aarch64_msvc 0.48.5", - "windows_i686_gnu 0.48.5", - "windows_i686_msvc 0.48.5", - "windows_x86_64_gnu 0.48.5", - "windows_x86_64_gnullvm 0.48.5", - "windows_x86_64_msvc 0.48.5", -] - -[[package]] -name = "windows-targets" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" -dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", - "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" - -[[package]] -name = "winnow" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - -[[package]] -name = "zerocopy" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" -dependencies = [ - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zip" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" -dependencies = [ - "arbitrary", - "crc32fast", - "crossbeam-utils", - "displaydoc", - "flate2", - "indexmap", - "memchr", - "thiserror", - "zopfli", -] - -[[package]] -name = "zopfli" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" -dependencies = [ - "bumpalo", - "crc32fast", - "lockfree-object-pool", - "log", - "once_cell", - "simd-adler32", -] diff --git a/legacy-contracts/farm-v13/Cargo.toml b/legacy-contracts/farm-v13/Cargo.toml index a72ce8f75..196c8b313 100644 --- a/legacy-contracts/farm-v13/Cargo.toml +++ b/legacy-contracts/farm-v13/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "0.50.5" +version = "0.52.3" [dev-dependencies] num-bigint = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "0.50.5" +version = "0.52.3" diff --git a/legacy-contracts/farm-v13/meta/Cargo.toml b/legacy-contracts/farm-v13/meta/Cargo.toml index c1db07489..ae52d18fb 100644 --- a/legacy-contracts/farm-v13/meta/Cargo.toml +++ b/legacy-contracts/farm-v13/meta/Cargo.toml @@ -8,5 +8,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/farm-v13/wasm/Cargo.lock b/legacy-contracts/farm-v13/wasm/Cargo.lock index a294288ec..2f99076f5 100644 --- a/legacy-contracts/farm-v13/wasm/Cargo.lock +++ b/legacy-contracts/farm-v13/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "endian-type" @@ -55,9 +55,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -69,9 +69,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -80,9 +80,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -92,9 +92,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -105,9 +105,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -166,9 +166,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/farm-v13/wasm/Cargo.toml b/legacy-contracts/farm-v13/wasm/Cargo.toml index a334d9dbc..12487fd26 100644 --- a/legacy-contracts/farm-v13/wasm/Cargo.toml +++ b/legacy-contracts/farm-v13/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "0.50.5" +version = "0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/price-discovery-v1/Cargo.lock b/legacy-contracts/price-discovery-v1/Cargo.lock deleted file mode 100644 index 07b1eab79..000000000 --- a/legacy-contracts/price-discovery-v1/Cargo.lock +++ /dev/null @@ -1,2593 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "aho-corasick" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" -dependencies = [ - "memchr", -] - -[[package]] -name = "anstream" -version = "0.6.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "is_terminal_polyfill", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" - -[[package]] -name = "anstyle-parse" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "anstyle-wincon" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" -dependencies = [ - "anstyle", - "windows-sys 0.52.0", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" -dependencies = [ - "derive_arbitrary", -] - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "backtrace" -version = "0.3.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base64" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" - -[[package]] -name = "bech32" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" - -[[package]] -name = "bip39" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" -dependencies = [ - "bitcoin_hashes", - "rand 0.8.5", - "rand_core 0.6.4", - "serde", - "unicode-normalization", -] - -[[package]] -name = "bitcoin_hashes" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "bstr" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" - -[[package]] -name = "cc" -version = "1.0.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "clap" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" -dependencies = [ - "clap_builder", - "clap_derive", -] - -[[package]] -name = "clap_builder" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" -dependencies = [ - "anstream", - "anstyle", - "clap_lex", - "strsim", -] - -[[package]] -name = "clap_derive" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "clap_lex" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" - -[[package]] -name = "colorchoice" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" - -[[package]] -name = "colored" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" -dependencies = [ - "lazy_static", - "windows-sys 0.48.0", -] - -[[package]] -name = "common-path" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" - -[[package]] -name = "convert_case" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "copy_dir" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" -dependencies = [ - "walkdir", -] - -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" -dependencies = [ - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "derive_arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "displaydoc" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - -[[package]] -name = "encoding_rs" -version = "0.8.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "endian-type" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "farm-v-13" -version = "0.0.0" -dependencies = [ - "multiversx-sc", - "multiversx-sc-scenario", - "num-bigint", -] - -[[package]] -name = "farm-v-13-meta" -version = "0.0.0" -dependencies = [ - "farm-v-13", - "multiversx-sc-meta", -] - -[[package]] -name = "fastrand" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" - -[[package]] -name = "flate2" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futures-channel" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" - -[[package]] -name = "futures-io" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" - -[[package]] -name = "futures-sink" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" - -[[package]] -name = "futures-task" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" - -[[package]] -name = "futures-util" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" -dependencies = [ - "futures-core", - "futures-io", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gimli" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" - -[[package]] -name = "globset" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" -dependencies = [ - "aho-corasick", - "bstr", - "log", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "h2" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" -dependencies = [ - "atomic-waker", - "bytes", - "fnv", - "futures-core", - "futures-sink", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "http" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" -dependencies = [ - "bytes", - "http", -] - -[[package]] -name = "http-body-util" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" -dependencies = [ - "bytes", - "futures-util", - "http", - "http-body", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" - -[[package]] -name = "hyper" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "itoa", - "pin-project-lite", - "smallvec", - "tokio", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" -dependencies = [ - "futures-util", - "http", - "hyper", - "hyper-util", - "rustls", - "rustls-pki-types", - "tokio", - "tokio-rustls", - "tower-service", -] - -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - -[[package]] -name = "hyper-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "http", - "http-body", - "hyper", - "pin-project-lite", - "socket2", - "tokio", - "tower", - "tower-service", - "tracing", -] - -[[package]] -name = "idna" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" -dependencies = [ - "crossbeam-deque", - "globset", - "log", - "memchr", - "regex-automata", - "same-file", - "walkdir", - "winapi-util", -] - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", - "serde", -] - -[[package]] -name = "ipnet" -version = "2.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" - -[[package]] -name = "is_terminal_polyfill" -version = "1.70.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" - -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "js-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "keccak" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "linux-raw-sys" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" - -[[package]] -name = "lock_api" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "lockfree-object-pool" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" - -[[package]] -name = "log" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", -] - -[[package]] -name = "multiversx-chain-scenario-format" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" -dependencies = [ - "bech32", - "hex", - "num-bigint", - "num-traits", - "serde", - "serde_json", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" -dependencies = [ - "bitflags 2.5.0", - "colored", - "ed25519-dalek", - "hex", - "hex-literal", - "itertools", - "multiversx-chain-vm-executor", - "num-bigint", - "num-traits", - "rand 0.8.5", - "rand_seeder", - "sha2 0.10.8", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm-executor" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" - -[[package]] -name = "multiversx-sc" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" -dependencies = [ - "bitflags 2.5.0", - "hex-literal", - "multiversx-sc-codec", - "multiversx-sc-derive", - "num-traits", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" -dependencies = [ - "arrayvec", - "multiversx-sc-codec-derive", - "num-bigint", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec-derive" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "multiversx-sc-derive" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "radix_trie", - "syn", -] - -[[package]] -name = "multiversx-sc-meta" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" -dependencies = [ - "clap", - "colored", - "common-path", - "convert_case", - "copy_dir", - "hex", - "lazy_static", - "multiversx-sc", - "pathdiff", - "reqwest", - "ruplacer", - "rustc_version", - "semver", - "serde", - "serde_json", - "toml", - "wasmparser", - "wasmprinter", - "zip", -] - -[[package]] -name = "multiversx-sc-scenario" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" -dependencies = [ - "base64", - "bech32", - "clap", - "colored", - "hex", - "itertools", - "log", - "multiversx-chain-scenario-format", - "multiversx-chain-vm", - "multiversx-chain-vm-executor", - "multiversx-sc", - "multiversx-sc-meta", - "multiversx-sdk", - "num-bigint", - "num-traits", - "pathdiff", - "serde", - "serde_json", - "sha2 0.10.8", - "tokio", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sdk" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" -dependencies = [ - "anyhow", - "base64", - "bech32", - "bip39", - "hex", - "hmac", - "itertools", - "pbkdf2", - "pem", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "sha2 0.10.8", - "sha3", - "tokio", - "zeroize", -] - -[[package]] -name = "native-tls" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" -dependencies = [ - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nibble_vec" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" -dependencies = [ - "smallvec", -] - -[[package]] -name = "num-bigint" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" -dependencies = [ - "num-integer", - "num-traits", -] - -[[package]] -name = "num-integer" -version = "0.1.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" -dependencies = [ - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "object" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "opaque-debug" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" - -[[package]] -name = "openssl" -version = "0.10.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" -dependencies = [ - "bitflags 2.5.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.102" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "parking_lot" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-targets 0.52.5", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "pbkdf2" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pem" -version = "3.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" -dependencies = [ - "base64", - "serde", -] - -[[package]] -name = "percent-encoding" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" - -[[package]] -name = "pin-project" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro2" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radix_trie" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" -dependencies = [ - "endian-type", - "nibble_vec", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.15", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_seeder" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "redox_syscall" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" -dependencies = [ - "bitflags 2.5.0", -] - -[[package]] -name = "regex" -version = "1.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" - -[[package]] -name = "reqwest" -version = "0.12.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" -dependencies = [ - "base64", - "bytes", - "encoding_rs", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "http-body-util", - "hyper", - "hyper-rustls", - "hyper-tls", - "hyper-util", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper", - "system-configuration", - "tokio", - "tokio-native-tls", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "winreg", -] - -[[package]] -name = "ring" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" -dependencies = [ - "cc", - "cfg-if", - "getrandom 0.2.15", - "libc", - "spin", - "untrusted", - "windows-sys 0.52.0", -] - -[[package]] -name = "ruplacer" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" -dependencies = [ - "Inflector", - "anyhow", - "clap", - "colored", - "ignore", - "regex", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.38.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" -dependencies = [ - "bitflags 2.5.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustls" -version = "0.23.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" -dependencies = [ - "once_cell", - "rustls-pki-types", - "rustls-webpki", - "subtle", - "zeroize", -] - -[[package]] -name = "rustls-pemfile" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" -dependencies = [ - "base64", - "rustls-pki-types", -] - -[[package]] -name = "rustls-pki-types" -version = "1.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" - -[[package]] -name = "rustls-webpki" -version = "0.102.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" -dependencies = [ - "ring", - "rustls-pki-types", - "untrusted", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "schannel" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "security-framework" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" -dependencies = [ - "bitflags 2.5.0", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.119" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" -dependencies = [ - "indexmap", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_spanned" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simd-adler32" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" - -[[package]] -name = "socket2" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "syn" -version = "2.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "sync_wrapper" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tempfile" -version = "3.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" -dependencies = [ - "cfg-if", - "fastrand", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "thiserror" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tinyvec" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot", - "pin-project-lite", - "signal-hook-registry", - "socket2", - "tokio-macros", - "windows-sys 0.48.0", -] - -[[package]] -name = "tokio-macros" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" -dependencies = [ - "rustls", - "rustls-pki-types", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "toml" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "pin-project", - "pin-project-lite", - "tokio", - "tower-layer", - "tower-service", -] - -[[package]] -name = "tower-layer" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" -dependencies = [ - "pin-project-lite", - "tracing-core", -] - -[[package]] -name = "tracing-core" -version = "0.1.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" -dependencies = [ - "once_cell", -] - -[[package]] -name = "try-lock" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unicode-bidi" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "unwrap-infallible" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" - -[[package]] -name = "url" -version = "2.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "utf8parse" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" - -[[package]] -name = "wasmparser" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" -dependencies = [ - "ahash", - "bitflags 2.5.0", - "hashbrown", - "indexmap", - "semver", - "serde", -] - -[[package]] -name = "wasmprinter" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" -dependencies = [ - "anyhow", - "wasmparser", -] - -[[package]] -name = "web-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "winapi-util" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.5", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.5", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm 0.48.5", - "windows_aarch64_msvc 0.48.5", - "windows_i686_gnu 0.48.5", - "windows_i686_msvc 0.48.5", - "windows_x86_64_gnu 0.48.5", - "windows_x86_64_gnullvm 0.48.5", - "windows_x86_64_msvc 0.48.5", -] - -[[package]] -name = "windows-targets" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" -dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", - "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" - -[[package]] -name = "winnow" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - -[[package]] -name = "zerocopy" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" -dependencies = [ - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zip" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" -dependencies = [ - "arbitrary", - "crc32fast", - "crossbeam-utils", - "displaydoc", - "flate2", - "indexmap", - "memchr", - "thiserror", - "zopfli", -] - -[[package]] -name = "zopfli" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" -dependencies = [ - "bumpalo", - "crc32fast", - "lockfree-object-pool", - "log", - "once_cell", - "simd-adler32", -] diff --git a/legacy-contracts/price-discovery-v1/Cargo.toml b/legacy-contracts/price-discovery-v1/Cargo.toml index 48a77d04f..d00d06b39 100644 --- a/legacy-contracts/price-discovery-v1/Cargo.toml +++ b/legacy-contracts/price-discovery-v1/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "0.50.5" +version = "0.52.3" [dev-dependencies] num-bigint = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "0.50.5" +version = "0.52.3" diff --git a/legacy-contracts/price-discovery-v1/meta/Cargo.toml b/legacy-contracts/price-discovery-v1/meta/Cargo.toml index 1c78eb1f1..8a10570f7 100644 --- a/legacy-contracts/price-discovery-v1/meta/Cargo.toml +++ b/legacy-contracts/price-discovery-v1/meta/Cargo.toml @@ -8,5 +8,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/price-discovery-v1/wasm/Cargo.lock b/legacy-contracts/price-discovery-v1/wasm/Cargo.lock index 82df55d0c..a1b884dc9 100644 --- a/legacy-contracts/price-discovery-v1/wasm/Cargo.lock +++ b/legacy-contracts/price-discovery-v1/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "endian-type" @@ -40,9 +40,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -54,9 +54,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -65,9 +65,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -77,9 +77,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -90,9 +90,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -166,9 +166,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/price-discovery-v1/wasm/Cargo.toml b/legacy-contracts/price-discovery-v1/wasm/Cargo.toml index 458d208f7..52fee981c 100644 --- a/legacy-contracts/price-discovery-v1/wasm/Cargo.toml +++ b/legacy-contracts/price-discovery-v1/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "0.50.5" +version = "0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/price-discovery-v2/Cargo.lock b/legacy-contracts/price-discovery-v2/Cargo.lock deleted file mode 100644 index 07b1eab79..000000000 --- a/legacy-contracts/price-discovery-v2/Cargo.lock +++ /dev/null @@ -1,2593 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.22.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "ahash" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" -dependencies = [ - "cfg-if", - "once_cell", - "version_check", - "zerocopy", -] - -[[package]] -name = "aho-corasick" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" -dependencies = [ - "memchr", -] - -[[package]] -name = "anstream" -version = "0.6.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "418c75fa768af9c03be99d17643f93f79bbba589895012a80e3452a19ddda15b" -dependencies = [ - "anstyle", - "anstyle-parse", - "anstyle-query", - "anstyle-wincon", - "colorchoice", - "is_terminal_polyfill", - "utf8parse", -] - -[[package]] -name = "anstyle" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" - -[[package]] -name = "anstyle-parse" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c03a11a9034d92058ceb6ee011ce58af4a9bf61491aa7e1e59ecd24bd40d22d4" -dependencies = [ - "utf8parse", -] - -[[package]] -name = "anstyle-query" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad186efb764318d35165f1758e7dcef3b10628e26d41a44bc5550652e6804391" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "anstyle-wincon" -version = "3.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a38449feb7068f52bb06c12759005cf459ee52bb4adc1d5a7c4322d716fb19" -dependencies = [ - "anstyle", - "windows-sys 0.52.0", -] - -[[package]] -name = "anyhow" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" - -[[package]] -name = "arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d5a26814d8dcb93b0e5a0ff3c6d80a8843bafb21b39e8e18a6f05471870e110" -dependencies = [ - "derive_arbitrary", -] - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "autocfg" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" - -[[package]] -name = "backtrace" -version = "0.3.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "base64" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" - -[[package]] -name = "bech32" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d86b93f97252c47b41663388e6d155714a9d0c398b99f1005cbc5f978b29f445" - -[[package]] -name = "bip39" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f2635620bf0b9d4576eb7bb9a38a55df78bd1205d26fa994b25911a69f212f" -dependencies = [ - "bitcoin_hashes", - "rand 0.8.5", - "rand_core 0.6.4", - "serde", - "unicode-normalization", -] - -[[package]] -name = "bitcoin_hashes" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90064b8dee6815a6470d60bad07bbbaee885c0e12d04177138fa3291a01b7bc4" - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "bstr" -version = "1.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05efc5cfd9110c8416e471df0e96702d58690178e206e61b7173706673c93706" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9" - -[[package]] -name = "cc" -version = "1.0.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74b6a57f98764a267ff415d50a25e6e166f3831a5071af4995296ea97d210490" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "clap" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84b3edb18336f4df585bc9aa31dd99c036dfa5dc5e9a2939a722a188f3a8970d" -dependencies = [ - "clap_builder", - "clap_derive", -] - -[[package]] -name = "clap_builder" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1c09dd5ada6c6c78075d6fd0da3f90d8080651e2d6cc8eb2f1aaa4034ced708" -dependencies = [ - "anstream", - "anstyle", - "clap_lex", - "strsim", -] - -[[package]] -name = "clap_derive" -version = "4.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bac35c6dafb060fd4d275d9a4ffae97917c13a6327903a8be2153cd964f7085" -dependencies = [ - "heck", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "clap_lex" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" - -[[package]] -name = "colorchoice" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" - -[[package]] -name = "colored" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cbf2150cce219b664a8a70df7a1f933836724b503f8a413af9365b4dcc4d90b8" -dependencies = [ - "lazy_static", - "windows-sys 0.48.0", -] - -[[package]] -name = "common-path" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2382f75942f4b3be3690fe4f86365e9c853c1587d6ee58212cebf6e2a9ccd101" - -[[package]] -name = "convert_case" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec182b0ca2f35d8fc196cf3404988fd8b8c739a4d270ff118a398feb0cbec1ca" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "copy_dir" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "543d1dd138ef086e2ff05e3a48cf9da045da2033d16f8538fd76b86cd49b2ca3" -dependencies = [ - "walkdir", -] - -[[package]] -name = "core-foundation" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" - -[[package]] -name = "cpufeatures" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53fe5e26ff1b7aef8bca9c6080520cfb8d9333c7568e1829cef191a9723e5504" -dependencies = [ - "libc", -] - -[[package]] -name = "crc32fast" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" -dependencies = [ - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b9fdf9972b2bd6af2d913799d9ebc165ea4d2e65878e329d9c6b372c4491b61" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "subtle", - "zeroize", -] - -[[package]] -name = "derive_arbitrary" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "displaydoc" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "either" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" - -[[package]] -name = "encoding_rs" -version = "0.8.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "endian-type" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c34f04666d835ff5d62e058c3995147c06f42fe86ff053337632bca83e42702d" - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "farm-v-13" -version = "0.0.0" -dependencies = [ - "multiversx-sc", - "multiversx-sc-scenario", - "num-bigint", -] - -[[package]] -name = "farm-v-13-meta" -version = "0.0.0" -dependencies = [ - "farm-v-13", - "multiversx-sc-meta", -] - -[[package]] -name = "fastrand" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" - -[[package]] -name = "flate2" -version = "1.0.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f54427cfd1c7829e2a139fcefea601bf088ebca651d2bf53ebc600eac295dae" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e13624c2627564efccf4934284bdd98cbaa14e79b0b5a141218e507b3a823456" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "futures-channel" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" - -[[package]] -name = "futures-io" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" - -[[package]] -name = "futures-sink" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" - -[[package]] -name = "futures-task" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" - -[[package]] -name = "futures-util" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" -dependencies = [ - "futures-core", - "futures-io", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "typenum", - "version_check", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", -] - -[[package]] -name = "getrandom" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "gimli" -version = "0.29.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ecd4077b5ae9fd2e9e169b102c6c330d0605168eb0e8bf79952b256dbefffd" - -[[package]] -name = "globset" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57da3b9b5b85bd66f31093f8c408b90a74431672542466497dcbdfdc02034be1" -dependencies = [ - "aho-corasick", - "bstr", - "log", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "h2" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" -dependencies = [ - "atomic-waker", - "bytes", - "fnv", - "futures-core", - "futures-sink", - "http", - "indexmap", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hashbrown" -version = "0.14.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" -dependencies = [ - "ahash", - "serde", -] - -[[package]] -name = "heck" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" - -[[package]] -name = "hermit-abi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hex-literal" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "http" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cac85db508abc24a2e48553ba12a996e87244a0395ce011e62b37158745d643" -dependencies = [ - "bytes", - "http", -] - -[[package]] -name = "http-body-util" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793429d76616a256bcb62c2a2ec2bed781c8307e797e2598c50010f2bee2544f" -dependencies = [ - "bytes", - "futures-util", - "http", - "http-body", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" - -[[package]] -name = "hyper" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c4fe55fb7a772d59a5ff1dfbff4fe0258d19b89fec4b233e75d35d5d2316badc" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "itoa", - "pin-project-lite", - "smallvec", - "tokio", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" -dependencies = [ - "futures-util", - "http", - "hyper", - "hyper-util", - "rustls", - "rustls-pki-types", - "tokio", - "tokio-rustls", - "tower-service", -] - -[[package]] -name = "hyper-tls" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" -dependencies = [ - "bytes", - "http-body-util", - "hyper", - "hyper-util", - "native-tls", - "tokio", - "tokio-native-tls", - "tower-service", -] - -[[package]] -name = "hyper-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ab92f4f49ee4fb4f997c784b7a2e0fa70050211e0b6a287f898c3c9785ca956" -dependencies = [ - "bytes", - "futures-channel", - "futures-util", - "http", - "http-body", - "hyper", - "pin-project-lite", - "socket2", - "tokio", - "tower", - "tower-service", - "tracing", -] - -[[package]] -name = "idna" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "ignore" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b46810df39e66e925525d6e38ce1e7f6e1d208f72dc39757880fcb66e2c58af1" -dependencies = [ - "crossbeam-deque", - "globset", - "log", - "memchr", - "regex-automata", - "same-file", - "walkdir", - "winapi-util", -] - -[[package]] -name = "indexmap" -version = "2.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "168fb715dda47215e360912c096649d23d58bf392ac62f73919e831745e40f26" -dependencies = [ - "equivalent", - "hashbrown", - "serde", -] - -[[package]] -name = "ipnet" -version = "2.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" - -[[package]] -name = "is_terminal_polyfill" -version = "1.70.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8478577c03552c21db0e2724ffb8986a5ce7af88107e6be5d2ee6e158c12800" - -[[package]] -name = "itertools" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba291022dbbd398a455acf126c1e341954079855bc60dfdda641363bd6922569" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" - -[[package]] -name = "js-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "keccak" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecc2af9a1119c51f12a14607e783cb977bde58bc069ff0c3da1095e635d70654" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "lazy_static" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" - -[[package]] -name = "libc" -version = "0.2.155" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" - -[[package]] -name = "linux-raw-sys" -version = "0.4.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" - -[[package]] -name = "lock_api" -version = "0.4.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07af8b9cdd281b7915f413fa73f29ebd5d55d0d3f0155584dade1ff18cea1b17" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "lockfree-object-pool" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e" - -[[package]] -name = "log" -version = "0.4.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" - -[[package]] -name = "memchr" -version = "2.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "miniz_oxide" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.48.0", -] - -[[package]] -name = "multiversx-chain-scenario-format" -version = "0.22.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a9190bdd56300e801e7793fc4ee7dc0c76c1149aac019da8c71cc58254966fe" -dependencies = [ - "bech32", - "hex", - "num-bigint", - "num-traits", - "serde", - "serde_json", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f69520691466bc184475320c27db21137e68be5e959df25c1a14b09e055d0d58" -dependencies = [ - "bitflags 2.5.0", - "colored", - "ed25519-dalek", - "hex", - "hex-literal", - "itertools", - "multiversx-chain-vm-executor", - "num-bigint", - "num-traits", - "rand 0.8.5", - "rand_seeder", - "sha2 0.10.8", - "sha3", -] - -[[package]] -name = "multiversx-chain-vm-executor" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b59072fa0624b55ae5ae3fa6bfa91515bbeb4ac440214bc4a509e2c8806d6e9f" - -[[package]] -name = "multiversx-sc" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" -dependencies = [ - "bitflags 2.5.0", - "hex-literal", - "multiversx-sc-codec", - "multiversx-sc-derive", - "num-traits", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" -dependencies = [ - "arrayvec", - "multiversx-sc-codec-derive", - "num-bigint", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sc-codec-derive" -version = "0.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "multiversx-sc-derive" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" -dependencies = [ - "hex", - "proc-macro2", - "quote", - "radix_trie", - "syn", -] - -[[package]] -name = "multiversx-sc-meta" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca792ba887b76270d5d6c975e349f2e7e037af2db25a78fe855ceb70eed473dd" -dependencies = [ - "clap", - "colored", - "common-path", - "convert_case", - "copy_dir", - "hex", - "lazy_static", - "multiversx-sc", - "pathdiff", - "reqwest", - "ruplacer", - "rustc_version", - "semver", - "serde", - "serde_json", - "toml", - "wasmparser", - "wasmprinter", - "zip", -] - -[[package]] -name = "multiversx-sc-scenario" -version = "0.50.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9916e196bbe87d5d46e4c9fd8ea00283660a97be44e6628c2cfbc9df5f8befcb" -dependencies = [ - "base64", - "bech32", - "clap", - "colored", - "hex", - "itertools", - "log", - "multiversx-chain-scenario-format", - "multiversx-chain-vm", - "multiversx-chain-vm-executor", - "multiversx-sc", - "multiversx-sc-meta", - "multiversx-sdk", - "num-bigint", - "num-traits", - "pathdiff", - "serde", - "serde_json", - "sha2 0.10.8", - "tokio", - "unwrap-infallible", -] - -[[package]] -name = "multiversx-sdk" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cb2f8dd4a17ce9c9fa1ab3d80152929702968be6536499f32bd7e2278c2e0fb" -dependencies = [ - "anyhow", - "base64", - "bech32", - "bip39", - "hex", - "hmac", - "itertools", - "pbkdf2", - "pem", - "rand 0.8.5", - "reqwest", - "serde", - "serde_json", - "serde_repr", - "sha2 0.10.8", - "sha3", - "tokio", - "zeroize", -] - -[[package]] -name = "native-tls" -version = "0.2.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8614eb2c83d59d1c8cc974dd3f920198647674a0a035e1af1fa58707e317466" -dependencies = [ - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nibble_vec" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a5d83df9f36fe23f0c3648c6bbb8b0298bb5f1939c8f2704431371f4b84d43" -dependencies = [ - "smallvec", -] - -[[package]] -name = "num-bigint" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c165a9ab64cf766f73521c0dd2cfdff64f488b8f0b3e621face3462d3db536d7" -dependencies = [ - "num-integer", - "num-traits", -] - -[[package]] -name = "num-integer" -version = "0.1.46" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" -dependencies = [ - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi", - "libc", -] - -[[package]] -name = "object" -version = "0.36.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "081b846d1d56ddfc18fdf1a922e4f6e07a11768ea1b92dec44e42b72712ccfce" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.19.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" - -[[package]] -name = "opaque-debug" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" - -[[package]] -name = "openssl" -version = "0.10.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a0481286a310808298130d22dd1fef0fa571e05a8f44ec801801e84b216b1f" -dependencies = [ - "bitflags 2.5.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.102" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c597637d56fbc83893a35eb0dd04b2b8e7a50c91e64e9493e398b5df4fb45fa2" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "parking_lot" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1bf18183cf54e8d6059647fc3063646a1801cf30896933ec2311622cc4b9a27" -dependencies = [ - "lock_api", - "parking_lot_core", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall", - "smallvec", - "windows-targets 0.52.5", -] - -[[package]] -name = "pathdiff" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" - -[[package]] -name = "pbkdf2" -version = "0.12.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pem" -version = "3.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e459365e590736a54c3fa561947c84837534b8e9af6fc5bf781307e82658fae" -dependencies = [ - "base64", - "serde", -] - -[[package]] -name = "percent-encoding" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" - -[[package]] -name = "pin-project" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.30" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro2" -version = "1.0.82" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "quote" -version = "1.0.36" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radix_trie" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c069c179fcdc6a2fe24d8d18305cf085fdbd4f922c041943e203685d6a1c58fd" -dependencies = [ - "endian-type", - "nibble_vec", -] - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.15", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_seeder" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf2890aaef0aa82719a50e808de264f9484b74b442e1a3a0e5ee38243ac40bdb" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "redox_syscall" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c82cf8cff14456045f55ec4241383baeff27af886adb72ffb2162f99911de0fd" -dependencies = [ - "bitflags 2.5.0", -] - -[[package]] -name = "regex" -version = "1.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.4.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" - -[[package]] -name = "reqwest" -version = "0.12.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" -dependencies = [ - "base64", - "bytes", - "encoding_rs", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "http-body-util", - "hyper", - "hyper-rustls", - "hyper-tls", - "hyper-util", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "sync_wrapper", - "system-configuration", - "tokio", - "tokio-native-tls", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "winreg", -] - -[[package]] -name = "ring" -version = "0.17.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" -dependencies = [ - "cc", - "cfg-if", - "getrandom 0.2.15", - "libc", - "spin", - "untrusted", - "windows-sys 0.52.0", -] - -[[package]] -name = "ruplacer" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58a26a1b15ff113d31d139357f7422708312978ed69cd5dd47e36d1b80b7eaf3" -dependencies = [ - "Inflector", - "anyhow", - "clap", - "colored", - "ignore", - "regex", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.38.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" -dependencies = [ - "bitflags 2.5.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.52.0", -] - -[[package]] -name = "rustls" -version = "0.23.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05cff451f60db80f490f3c182b77c35260baace73209e9cdbbe526bfe3a4d402" -dependencies = [ - "once_cell", - "rustls-pki-types", - "rustls-webpki", - "subtle", - "zeroize", -] - -[[package]] -name = "rustls-pemfile" -version = "2.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29993a25686778eb88d4189742cd713c9bce943bc54251a33509dc63cbacf73d" -dependencies = [ - "base64", - "rustls-pki-types", -] - -[[package]] -name = "rustls-pki-types" -version = "1.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" - -[[package]] -name = "rustls-webpki" -version = "0.102.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff448f7e92e913c4b7d4c6d8e4540a1724b319b4152b8aef6d4cf8339712b33e" -dependencies = [ - "ring", - "rustls-pki-types", - "untrusted", -] - -[[package]] -name = "ryu" -version = "1.0.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" - -[[package]] -name = "same-file" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "schannel" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "security-framework" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c627723fd09706bacdb5cf41499e95098555af3c3c29d014dc3c458ef6be11c0" -dependencies = [ - "bitflags 2.5.0", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "317936bbbd05227752583946b9e66d7ce3b489f84e11a94a510b4437fef407d7" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" - -[[package]] -name = "serde" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_derive" -version = "1.0.203" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_json" -version = "1.0.119" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8eddb61f0697cc3989c5d64b452f5488e2b8a60fd7d5076a3045076ffef8cb0" -dependencies = [ - "indexmap", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_repr" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "serde_spanned" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79e674e01f999af37c49f70a6ede167a8a60b2503e56c5599532a65baa5969a0" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simd-adler32" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" - -[[package]] -name = "socket2" -version = "0.5.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" -dependencies = [ - "libc", - "windows-sys 0.52.0", -] - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "strsim" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" - -[[package]] -name = "subtle" -version = "2.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" - -[[package]] -name = "syn" -version = "2.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "sync_wrapper" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tempfile" -version = "3.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" -dependencies = [ - "cfg-if", - "fastrand", - "rustix", - "windows-sys 0.52.0", -] - -[[package]] -name = "thiserror" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.61" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tinyvec" -version = "1.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c55115c6fbe2d2bef26eb09ad74bde02d8255476fc0c7b515ef09fbb35742d82" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.38.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba4f4a02a7a80d6f274636f0aa95c7e383b912d41fe721a31f29e29698585a4a" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot", - "pin-project-lite", - "signal-hook-registry", - "socket2", - "tokio-macros", - "windows-sys 0.48.0", -] - -[[package]] -name = "tokio-macros" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f5ae998a069d4b5aba8ee9dad856af7d520c3699e6159b185c2acd48155d39a" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" -dependencies = [ - "rustls", - "rustls-pki-types", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "toml" -version = "0.8.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f49eb2ab21d2f26bd6db7bf383edc527a7ebaee412d17af4d40fdccd442f335" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "toml_edit", -] - -[[package]] -name = "toml_datetime" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4badfd56924ae69bcc9039335b2e017639ce3f9b001c393c1b2d1ef846ce2cbf" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_edit" -version = "0.22.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f21c7aaf97f1bd9ca9d4f9e73b0a6c74bd5afef56f2bc931943a6e1c37e04e38" -dependencies = [ - "indexmap", - "serde", - "serde_spanned", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "pin-project", - "pin-project-lite", - "tokio", - "tower-layer", - "tower-service", -] - -[[package]] -name = "tower-layer" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.40" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" -dependencies = [ - "pin-project-lite", - "tracing-core", -] - -[[package]] -name = "tracing-core" -version = "0.1.32" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" -dependencies = [ - "once_cell", -] - -[[package]] -name = "try-lock" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unicode-bidi" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "unwrap-infallible" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "151ac09978d3c2862c4e39b557f4eceee2cc72150bc4cb4f16abf061b6e381fb" - -[[package]] -name = "url" -version = "2.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "utf8parse" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "walkdir" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" -dependencies = [ - "same-file", - "winapi-util", -] - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.92" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" - -[[package]] -name = "wasmparser" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd921789c9dcc495f589cb37d200155dee65b4a4beeb853323b5e24e0a5f9c58" -dependencies = [ - "ahash", - "bitflags 2.5.0", - "hashbrown", - "indexmap", - "semver", - "serde", -] - -[[package]] -name = "wasmprinter" -version = "0.208.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0700bdace4821e6c694617938500ae9999946df464bb13219c16570f8b6f202f" -dependencies = [ - "anyhow", - "wasmparser", -] - -[[package]] -name = "web-sys" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "winapi-util" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d4cc384e1e73b93bafa6fb4f1df8c41695c8a91cf9c4c64358067d15a7b6c6b" -dependencies = [ - "windows-sys 0.52.0", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets 0.48.5", -] - -[[package]] -name = "windows-sys" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" -dependencies = [ - "windows-targets 0.52.5", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm 0.48.5", - "windows_aarch64_msvc 0.48.5", - "windows_i686_gnu 0.48.5", - "windows_i686_msvc 0.48.5", - "windows_x86_64_gnu 0.48.5", - "windows_x86_64_gnullvm 0.48.5", - "windows_x86_64_msvc 0.48.5", -] - -[[package]] -name = "windows-targets" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f0713a46559409d202e70e28227288446bf7841d3211583a4b53e3f6d96e7eb" -dependencies = [ - "windows_aarch64_gnullvm 0.52.5", - "windows_aarch64_msvc 0.52.5", - "windows_i686_gnu 0.52.5", - "windows_i686_gnullvm", - "windows_i686_msvc 0.52.5", - "windows_x86_64_gnu 0.52.5", - "windows_x86_64_gnullvm 0.52.5", - "windows_x86_64_msvc 0.52.5", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7088eed71e8b8dda258ecc8bac5fb1153c5cffaf2578fc8ff5d61e23578d3263" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9985fd1504e250c615ca5f281c3f7a6da76213ebd5ccc9561496568a2752afb6" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88ba073cf16d5372720ec942a8ccbf61626074c6d4dd2e745299726ce8b89670" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87f4261229030a858f36b459e748ae97545d6f1ec60e5e0d6a3d32e0dc232ee9" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db3c2bf3d13d5b658be73463284eaf12830ac9a26a90c717b7f771dfe97487bf" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4e4246f76bdeff09eb48875a0fd3e2af6aada79d409d33011886d3e1581517d9" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "852298e482cd67c356ddd9570386e2862b5673c85bd5f88df9ab6802b334c596" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bec47e5bfd1bff0eeaf6d8b485cc1074891a197ab4225d504cb7a1ab88b02bf0" - -[[package]] -name = "winnow" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b5e5f6c299a3c7890b876a2a587f3115162487e704907d9b6cd29473052ba1" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.52.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" -dependencies = [ - "cfg-if", - "windows-sys 0.48.0", -] - -[[package]] -name = "zerocopy" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae87e3fcd617500e5d106f0380cf7b77f3c6092aae37191433159dda23cfb087" -dependencies = [ - "zerocopy-derive", -] - -[[package]] -name = "zerocopy-derive" -version = "0.7.34" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15e934569e47891f7d9411f1a451d947a60e000ab3bd24fbb970f000387d1b3b" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zeroize" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced3678a2879b30306d323f4542626697a464a97c0a07c9aebf7ebca65cd4dde" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "zip" -version = "2.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "775a2b471036342aa69bc5a602bc889cb0a06cda00477d0c69566757d5553d39" -dependencies = [ - "arbitrary", - "crc32fast", - "crossbeam-utils", - "displaydoc", - "flate2", - "indexmap", - "memchr", - "thiserror", - "zopfli", -] - -[[package]] -name = "zopfli" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" -dependencies = [ - "bumpalo", - "crc32fast", - "lockfree-object-pool", - "log", - "once_cell", - "simd-adler32", -] diff --git a/legacy-contracts/price-discovery-v2/Cargo.toml b/legacy-contracts/price-discovery-v2/Cargo.toml index ab0dddc4b..e2f00ec89 100644 --- a/legacy-contracts/price-discovery-v2/Cargo.toml +++ b/legacy-contracts/price-discovery-v2/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "0.50.5" +version = "0.52.3" [dev-dependencies] num-bigint = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "0.50.5" +version = "0.52.3" diff --git a/legacy-contracts/price-discovery-v2/meta/Cargo.toml b/legacy-contracts/price-discovery-v2/meta/Cargo.toml index bb8a32afb..66b16ff3d 100644 --- a/legacy-contracts/price-discovery-v2/meta/Cargo.toml +++ b/legacy-contracts/price-discovery-v2/meta/Cargo.toml @@ -8,5 +8,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/price-discovery-v2/wasm/Cargo.lock b/legacy-contracts/price-discovery-v2/wasm/Cargo.lock index 635dbdb44..f1bdaed4b 100644 --- a/legacy-contracts/price-discovery-v2/wasm/Cargo.lock +++ b/legacy-contracts/price-discovery-v2/wasm/Cargo.lock @@ -16,9 +16,9 @@ checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "endian-type" @@ -40,9 +40,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -54,9 +54,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -65,9 +65,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -77,9 +77,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -90,9 +90,9 @@ dependencies = [ [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -166,9 +166,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/price-discovery-v2/wasm/Cargo.toml b/legacy-contracts/price-discovery-v2/wasm/Cargo.toml index 0ca10975d..c5a34afb0 100644 --- a/legacy-contracts/price-discovery-v2/wasm/Cargo.toml +++ b/legacy-contracts/price-discovery-v2/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "0.50.5" +version = "0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/proxy-dex-legacy/Cargo.toml b/legacy-contracts/proxy-dex-legacy/Cargo.toml index 0443092ed..2567e0195 100644 --- a/legacy-contracts/proxy-dex-legacy/Cargo.toml +++ b/legacy-contracts/proxy-dex-legacy/Cargo.toml @@ -8,11 +8,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dependencies.common_structs] path = "../../common/common_structs" diff --git a/legacy-contracts/proxy-dex-legacy/meta/Cargo.toml b/legacy-contracts/proxy-dex-legacy/meta/Cargo.toml index 38efa5f0d..7b04c9d2c 100644 --- a/legacy-contracts/proxy-dex-legacy/meta/Cargo.toml +++ b/legacy-contracts/proxy-dex-legacy/meta/Cargo.toml @@ -10,5 +10,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock index 063bdc08a..830467f4b 100644 --- a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock +++ b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -180,9 +180,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -194,9 +194,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -205,9 +205,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -217,9 +217,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -230,18 +230,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -299,9 +299,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -372,9 +372,9 @@ checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml index fa6f756fe..28c7bfe76 100644 --- a/legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml +++ b/legacy-contracts/proxy-dex-legacy/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/legacy-contracts/simple-lock-legacy/Cargo.toml b/legacy-contracts/simple-lock-legacy/Cargo.toml index d3e866d66..465b3372e 100644 --- a/legacy-contracts/simple-lock-legacy/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/legacy-contracts/simple-lock-legacy/meta/Cargo.toml b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml index e00582e08..f561fae63 100644 --- a/legacy-contracts/simple-lock-legacy/meta/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock index c6dc70fac..0ce02d62b 100644 --- a/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_structs" @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -86,9 +86,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -97,9 +97,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -109,9 +109,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -122,18 +122,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -158,9 +158,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -203,15 +203,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml index 0c6712178..208b10e76 100644 --- a/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml +++ b/legacy-contracts/simple-lock-legacy/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/Cargo.toml b/locked-asset/Cargo.toml index 02b69159a..664556963 100644 --- a/locked-asset/Cargo.toml +++ b/locked-asset/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" publish = false [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.farm] @@ -50,7 +50,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/distribution/Cargo.toml b/locked-asset/distribution/Cargo.toml index 11d2ba1c3..94a6783ee 100644 --- a/locked-asset/distribution/Cargo.toml +++ b/locked-asset/distribution/Cargo.toml @@ -14,8 +14,8 @@ path = "../../common/common_structs" path = "../factory" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/distribution/meta/Cargo.toml b/locked-asset/distribution/meta/Cargo.toml index 4c62fffbf..532a034b9 100644 --- a/locked-asset/distribution/meta/Cargo.toml +++ b/locked-asset/distribution/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/distribution/wasm/Cargo.lock b/locked-asset/distribution/wasm/Cargo.lock index 30b240495..ff20f5e5a 100644 --- a/locked-asset/distribution/wasm/Cargo.lock +++ b/locked-asset/distribution/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "cfg-if" @@ -63,9 +63,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -144,9 +144,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.151" +version = "0.2.158" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" +checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" [[package]] name = "math" @@ -170,9 +170,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -184,9 +184,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -195,9 +195,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -207,9 +207,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -220,18 +220,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -256,9 +256,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -301,15 +301,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/distribution/wasm/Cargo.toml b/locked-asset/distribution/wasm/Cargo.toml index 9c8780552..5c94e6ebb 100644 --- a/locked-asset/distribution/wasm/Cargo.toml +++ b/locked-asset/distribution/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/energy-factory/Cargo.toml b/locked-asset/energy-factory/Cargo.toml index bd4e5c0b6..c41abf0f6 100644 --- a/locked-asset/energy-factory/Cargo.toml +++ b/locked-asset/energy-factory/Cargo.toml @@ -33,11 +33,11 @@ path = "../../common/traits/unwrappable" path = "../../common/modules/legacy_token_decode_module" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies] num-bigint = "0.4.2" @@ -45,4 +45,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/energy-factory/meta/Cargo.toml b/locked-asset/energy-factory/meta/Cargo.toml index e3773e413..f85c5b818 100644 --- a/locked-asset/energy-factory/meta/Cargo.toml +++ b/locked-asset/energy-factory/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/energy-factory/wasm/Cargo.lock b/locked-asset/energy-factory/wasm/Cargo.lock index 692139886..f1b55e72c 100644 --- a/locked-asset/energy-factory/wasm/Cargo.lock +++ b/locked-asset/energy-factory/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -112,9 +112,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -126,9 +126,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -137,9 +137,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -149,9 +149,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -162,18 +162,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -243,15 +243,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/energy-factory/wasm/Cargo.toml b/locked-asset/energy-factory/wasm/Cargo.toml index f03bc747f..13119f8cd 100644 --- a/locked-asset/energy-factory/wasm/Cargo.toml +++ b/locked-asset/energy-factory/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/factory/Cargo.toml b/locked-asset/factory/Cargo.toml index fdf9e4909..72efa530a 100644 --- a/locked-asset/factory/Cargo.toml +++ b/locked-asset/factory/Cargo.toml @@ -26,11 +26,11 @@ path = "../../common/modules/token_merge_helper" path = "../energy-factory" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.arrayvec] version = "0.7.1" @@ -49,4 +49,4 @@ hex = "0.4" path = "../simple-lock" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/factory/meta/Cargo.toml b/locked-asset/factory/meta/Cargo.toml index cb31d100a..9c2bc7b20 100644 --- a/locked-asset/factory/meta/Cargo.toml +++ b/locked-asset/factory/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/factory/wasm/Cargo.lock b/locked-asset/factory/wasm/Cargo.lock index 809943091..0464466be 100644 --- a/locked-asset/factory/wasm/Cargo.lock +++ b/locked-asset/factory/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "cfg-if" @@ -46,9 +46,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -135,9 +135,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.151" +version = "0.2.158" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" +checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" [[package]] name = "math" @@ -161,9 +161,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -175,9 +175,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -186,9 +186,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -198,9 +198,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -211,18 +211,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -247,9 +247,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -292,15 +292,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/factory/wasm/Cargo.toml b/locked-asset/factory/wasm/Cargo.toml index f42916ed8..4fdf6de1c 100644 --- a/locked-asset/factory/wasm/Cargo.toml +++ b/locked-asset/factory/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/lkmex-transfer/Cargo.toml b/locked-asset/lkmex-transfer/Cargo.toml index 8f3a10373..c08031b0e 100644 --- a/locked-asset/lkmex-transfer/Cargo.toml +++ b/locked-asset/lkmex-transfer/Cargo.toml @@ -30,14 +30,14 @@ path = "../energy-factory" path = "../../energy-integration/common-modules/energy-query" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dev-dependencies] num-bigint = "0.4.2" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/lkmex-transfer/meta/Cargo.toml b/locked-asset/lkmex-transfer/meta/Cargo.toml index e355d4140..e63c0888a 100644 --- a/locked-asset/lkmex-transfer/meta/Cargo.toml +++ b/locked-asset/lkmex-transfer/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.lock b/locked-asset/lkmex-transfer/wasm/Cargo.lock index 5ec5b0139..6e4c444f9 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.lock +++ b/locked-asset/lkmex-transfer/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -134,9 +134,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -148,9 +148,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -159,9 +159,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -171,9 +171,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -184,18 +184,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -229,9 +229,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -274,15 +274,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/lkmex-transfer/wasm/Cargo.toml b/locked-asset/lkmex-transfer/wasm/Cargo.toml index c91df3b30..2ac287015 100644 --- a/locked-asset/lkmex-transfer/wasm/Cargo.toml +++ b/locked-asset/lkmex-transfer/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/locked-token-wrapper/Cargo.toml b/locked-asset/locked-token-wrapper/Cargo.toml index 79ca7517d..f4794c746 100644 --- a/locked-asset/locked-token-wrapper/Cargo.toml +++ b/locked-asset/locked-token-wrapper/Cargo.toml @@ -9,10 +9,10 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.utils] path = "../../common/modules/utils" @@ -44,4 +44,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/locked-token-wrapper/meta/Cargo.toml b/locked-asset/locked-token-wrapper/meta/Cargo.toml index cbafdc722..6e95f2dcf 100644 --- a/locked-asset/locked-token-wrapper/meta/Cargo.toml +++ b/locked-asset/locked-token-wrapper/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.lock b/locked-asset/locked-token-wrapper/wasm/Cargo.lock index 45d646f00..e5c97d121 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.lock +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -158,9 +158,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -172,9 +172,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -183,9 +183,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -195,9 +195,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -208,18 +208,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -253,9 +253,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -298,15 +298,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/locked-token-wrapper/wasm/Cargo.toml b/locked-asset/locked-token-wrapper/wasm/Cargo.toml index 88b2fcef5..e89aace72 100644 --- a/locked-asset/locked-token-wrapper/wasm/Cargo.toml +++ b/locked-asset/locked-token-wrapper/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/proxy_dex/Cargo.toml b/locked-asset/proxy_dex/Cargo.toml index 6cd60b67d..1e4675ccb 100644 --- a/locked-asset/proxy_dex/Cargo.toml +++ b/locked-asset/proxy_dex/Cargo.toml @@ -45,11 +45,11 @@ path = "../../common/traits/mergeable" path = "../../common/traits/fixed-supply-token" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.energy-factory] path = "../energy-factory" @@ -69,7 +69,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.pausable] path = "../../common/modules/pausable" diff --git a/locked-asset/proxy_dex/meta/Cargo.toml b/locked-asset/proxy_dex/meta/Cargo.toml index 81d2922ca..c1298c9c8 100644 --- a/locked-asset/proxy_dex/meta/Cargo.toml +++ b/locked-asset/proxy_dex/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/proxy_dex/wasm/Cargo.lock b/locked-asset/proxy_dex/wasm/Cargo.lock index bad19c9c7..8bdd9ad2b 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.lock +++ b/locked-asset/proxy_dex/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.9.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "endian-type" @@ -307,9 +307,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -321,9 +321,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -332,9 +332,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -344,9 +344,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -357,18 +357,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -426,9 +426,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -518,15 +518,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/proxy_dex/wasm/Cargo.toml b/locked-asset/proxy_dex/wasm/Cargo.toml index dfccc666f..bab8859ab 100644 --- a/locked-asset/proxy_dex/wasm/Cargo.toml +++ b/locked-asset/proxy_dex/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/simple-lock/Cargo.toml b/locked-asset/simple-lock/Cargo.toml index 51a984cef..7781b5929 100644 --- a/locked-asset/simple-lock/Cargo.toml +++ b/locked-asset/simple-lock/Cargo.toml @@ -9,11 +9,11 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dependencies.common_structs] path = "../../common/common_structs" @@ -24,4 +24,4 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/simple-lock/meta/Cargo.toml b/locked-asset/simple-lock/meta/Cargo.toml index 7e88ea4e3..e7a939a39 100644 --- a/locked-asset/simple-lock/meta/Cargo.toml +++ b/locked-asset/simple-lock/meta/Cargo.toml @@ -9,5 +9,5 @@ authors = ["Dorin Iancu "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/simple-lock/wasm/Cargo.lock b/locked-asset/simple-lock/wasm/Cargo.lock index 7251fe292..439762d95 100644 --- a/locked-asset/simple-lock/wasm/Cargo.lock +++ b/locked-asset/simple-lock/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_structs" @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -86,9 +86,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -97,9 +97,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -109,9 +109,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -122,18 +122,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -158,9 +158,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -203,15 +203,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/simple-lock/wasm/Cargo.toml b/locked-asset/simple-lock/wasm/Cargo.toml index fb6783b82..b749b73db 100644 --- a/locked-asset/simple-lock/wasm/Cargo.toml +++ b/locked-asset/simple-lock/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/locked-asset/token-unstake/Cargo.toml b/locked-asset/token-unstake/Cargo.toml index 18eb2701d..fbcf1e07c 100644 --- a/locked-asset/token-unstake/Cargo.toml +++ b/locked-asset/token-unstake/Cargo.toml @@ -9,7 +9,7 @@ publish = false path = "src/lib.rs" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.mergeable] @@ -39,7 +39,7 @@ num-traits = "0.2" hex = "0.4" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" diff --git a/locked-asset/token-unstake/meta/Cargo.toml b/locked-asset/token-unstake/meta/Cargo.toml index 3cd65b028..f3552ba6d 100644 --- a/locked-asset/token-unstake/meta/Cargo.toml +++ b/locked-asset/token-unstake/meta/Cargo.toml @@ -9,5 +9,5 @@ publish = false path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/locked-asset/token-unstake/wasm/Cargo.lock b/locked-asset/token-unstake/wasm/Cargo.lock index 79e063007..74fdec9ce 100644 --- a/locked-asset/token-unstake/wasm/Cargo.lock +++ b/locked-asset/token-unstake/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common-types" @@ -119,9 +119,9 @@ dependencies = [ [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -133,9 +133,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -144,9 +144,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -156,9 +156,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -169,18 +169,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -205,9 +205,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -250,15 +250,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/locked-asset/token-unstake/wasm/Cargo.toml b/locked-asset/token-unstake/wasm/Cargo.toml index c06b0843f..378cdd817 100644 --- a/locked-asset/token-unstake/wasm/Cargo.toml +++ b/locked-asset/token-unstake/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."] diff --git a/pause-all/Cargo.toml b/pause-all/Cargo.toml index ba3f18d7a..7d9df52ad 100644 --- a/pause-all/Cargo.toml +++ b/pause-all/Cargo.toml @@ -12,14 +12,14 @@ path = "src/lib.rs" path = "../common/modules/pausable" [dependencies.multiversx-sc] -version = "=0.50.5" +version = "=0.52.3" features = ["esdt-token-payment-legacy-decode"] [dependencies.multiversx-sc-modules] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.multiversx-sc-scenario] -version = "=0.50.5" +version = "=0.52.3" [dev-dependencies.farm] path = "../dex/farm" diff --git a/pause-all/meta/Cargo.toml b/pause-all/meta/Cargo.toml index ed3c087ed..67f00b69e 100644 --- a/pause-all/meta/Cargo.toml +++ b/pause-all/meta/Cargo.toml @@ -11,5 +11,5 @@ authors = ["MultiversX "] path = ".." [dependencies.multiversx-sc-meta] -version = "0.50.5" +version = "0.52.3" default-features = false diff --git a/pause-all/wasm/Cargo.lock b/pause-all/wasm/Cargo.lock index d23e605c4..483da2b83 100644 --- a/pause-all/wasm/Cargo.lock +++ b/pause-all/wasm/Cargo.lock @@ -10,15 +10,15 @@ checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "autocfg" -version = "1.1.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "common_errors" @@ -47,9 +47,9 @@ checksum = "6fe2267d4ed49bc07b63801559be28c718ea06c4738b7a03c94df7386d2cde46" [[package]] name = "multiversx-sc" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a38a802d6cfa67748145a9e729336f4e6390eba702b5f14360ed01fcff14faa4" +checksum = "526760b1d6236c011285b264a70a0a9dd3b3dbc53c3b5f76932f4bcfd3a8910c" dependencies = [ "bitflags", "hex-literal", @@ -61,9 +61,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c94397b2fba14e40edfa55905b3f453ed57aa06c9b1960ad6a0ca6bfb7a236" +checksum = "ad4f318427761faecf26c1f3115a3beeb5f61858845a60547d9763aa981ddd2d" dependencies = [ "arrayvec", "multiversx-sc-codec-derive", @@ -72,9 +72,9 @@ dependencies = [ [[package]] name = "multiversx-sc-codec-derive" -version = "0.19.0" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf72a8042da0bc19da0b8f0d4f61b4c66ae853560fefc69cd8fea87bf1aa8c14" +checksum = "476501462b0c2654b64f9dec6f2c480e24b4e9b7133ec10b7167e64acda35d04" dependencies = [ "hex", "proc-macro2", @@ -84,9 +84,9 @@ dependencies = [ [[package]] name = "multiversx-sc-derive" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dc53ddcbd71948d2e8d3d6b814da866e2920b24e6c0cbfa643922f781897476" +checksum = "3557f2f12640a8a07fa6af66cc2a13b188c5b61bed72db22fe631fb3a60c3e96" dependencies = [ "hex", "proc-macro2", @@ -97,18 +97,18 @@ dependencies = [ [[package]] name = "multiversx-sc-modules" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea1ae09db9cac18669b85d50932410df6082e1a575975ba5224e3b7ae33cbe7d" +checksum = "61f5c29c6044f3dc9e866858feee625d7fae5604a68ac7bd66dec683eee97563" dependencies = [ "multiversx-sc", ] [[package]] name = "multiversx-sc-wasm-adapter" -version = "0.50.5" +version = "0.52.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99a090365b4483b4ea955ba1322f986f6821be88144291f0013c03f59b4de753" +checksum = "ed13aaca9cbdbc6911174cd3029e750a7563d85dd3daaa1107b1fd31c7f17245" dependencies = [ "multiversx-sc", ] @@ -167,9 +167,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -195,15 +195,15 @@ dependencies = [ [[package]] name = "smallvec" -version = "1.11.2" +version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dccd0940a2dcdf68d092b8cbab7dc0ad8fa938bf95787e1b916b0e3d0e8e970" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" [[package]] name = "syn" -version = "2.0.61" +version = "2.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c993ed8ccba56ae856363b1845da7266a7cb78e1d146c8a32d54b45a8b831fc9" +checksum = "dc4b9b9bf2add8093d3f2c0204471e951b2285580335de42f9d2534f3ae7a8af" dependencies = [ "proc-macro2", "quote", diff --git a/pause-all/wasm/Cargo.toml b/pause-all/wasm/Cargo.toml index 02be3f8ff..019f093a5 100644 --- a/pause-all/wasm/Cargo.toml +++ b/pause-all/wasm/Cargo.toml @@ -28,7 +28,7 @@ panic = "abort" path = ".." [dependencies.multiversx-sc-wasm-adapter] -version = "=0.50.5" +version = "=0.52.3" [workspace] members = ["."]