diff --git a/Cargo.lock b/Cargo.lock index d3c21b0d08b..b795da04e19 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -14,18 +14,18 @@ dependencies = [ [[package]] name = "addr2line" -version = "0.24.2" +version = "0.22.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfbe277e56a376000877090da837660b4427aad530e3028d44e0bffe4f89a1c1" +checksum = "6e4503c46a5c0c7844e948c9a4d6acd9f50cccb4de1c48eb9e291ea17470c678" dependencies = [ - "gimli", + "gimli 0.29.0", ] [[package]] -name = "adler2" -version = "2.0.0" +name = "adler" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627" +checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" [[package]] name = "aes" @@ -44,7 +44,7 @@ version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "891477e0c6a8957309ee5c45a6368af3ae14bb510732d2684ffa19af310920f9" dependencies = [ - "getrandom", + "getrandom 0.2.15", "once_cell", "version_check", ] @@ -56,7 +56,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if 1.0.0", - "getrandom", + "getrandom 0.2.15", "once_cell", "version_check", "zerocopy", @@ -73,9 +73,9 @@ dependencies = [ [[package]] name = "allocator-api2" -version = "0.2.20" +version = "0.2.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45862d1c77f2228b9e10bc609d5bc203d86ebc9b87ad8d5d5167a6c9abf739d9" +checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f" [[package]] name = "alloy-eip2930" @@ -120,7 +120,7 @@ dependencies = [ "keccak-asm", "paste", "proptest", - "rand", + "rand 0.8.5", "ruint", "rustc-hash 2.0.0", "serde", @@ -147,7 +147,7 @@ checksum = "2b09cae092c27b6f1bde952653a22708691802e57bfef4a2973b80bea21efd3f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -201,9 +201,9 @@ dependencies = [ [[package]] name = "anstream" -version = "0.6.18" +version = "0.6.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8acc5369981196006228e28809f761875c0327210a891e941f4c683b3a99529b" +checksum = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" dependencies = [ "anstyle", "anstyle-parse", @@ -216,43 +216,43 @@ dependencies = [ [[package]] name = "anstyle" -version = "1.0.10" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55cc3b69f167a1ef2e161439aa98aed94e6028e5f9a59be9a6ffb47aef1651f9" +checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" [[package]] name = "anstyle-parse" -version = "0.2.6" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3b2d16507662817a6a20a9ea92df6652ee4f94f914589377d69f3b21bc5798a9" +checksum = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.1.2" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79947af37f4177cfead1110013d678905c37501914fba0efea834c3fe9a8d60c" +checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" dependencies = [ - "windows-sys 0.59.0", + "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.6" +version = "3.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2109dbce0e72be3ec00bed26e6a7479ca384ad226efdd66db8fa2e3a38c83125" +checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" dependencies = [ "anstyle", - "windows-sys 0.59.0", + "windows-sys 0.52.0", ] [[package]] name = "anyhow" -version = "1.0.93" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c95c10ba0b00a02636238b814946408b1322d5ac4760326e6fb8ec956d85775" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" [[package]] name = "arc-swap" @@ -294,7 +294,7 @@ dependencies = [ "num-bigint", "num-traits", "paste", - "rustc_version 0.4.1", + "rustc_version 0.4.0", "zeroize", ] @@ -371,7 +371,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1df2c09229cbc5a028b1d70e00fdb2acee28b1055dfb5ca73eea49c5a25c4e7c" dependencies = [ "num-traits", - "rand", + "rand 0.8.5", ] [[package]] @@ -381,20 +381,20 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" dependencies = [ "num-traits", - "rand", + "rand 0.8.5", ] [[package]] name = "arrayref" -version = "0.3.9" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76a2e8124351fda1ef8aaaa3bbd7ebbcb486bbcd4225aca0aa0d84bb2db8fecb" +checksum = "9d151e35f61089500b617991b791fc8bfd237ae50cd5950803758a179b41e67a" [[package]] name = "arrayvec" -version = "0.7.6" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c02d123df017efcdfbd739ef81735b36c5ba83ec3c59c80a9d7ecc718f92e50" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "ascii" @@ -424,15 +424,26 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9b34d609dfbaf33d6889b2b7106d3ca345eacad44200913df5ba02bfd31d2ba9" +[[package]] +name = "async-channel" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" +dependencies = [ + "concurrent-queue", + "event-listener", + "futures-core", +] + [[package]] name = "async-trait" -version = "0.1.83" +version = "0.1.81" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "721cae7de5c34fbb2acd27e21e6d2cf7b886dce0c27388d46c4e6c47ea4318dd" +checksum = "6e0c28dcc82d7c8ead5cb13beb15405b57b8546e93215673ff8ca0349a028107" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -468,14 +479,14 @@ checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] name = "autocfg" -version = "1.4.0" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ace50bade8e6234aa140d9a2f552bbee1db4d353f69b8217bc503490fc1a9f26" +checksum = "0c4b4d0bd25bd0b74681c0ad21497610ce1b7c91b1022cd21c80c6fbdd9476b0" [[package]] name = "aws-config" @@ -496,7 +507,7 @@ dependencies = [ "aws-smithy-types", "aws-types", "bytes", - "fastrand", + "fastrand 2.1.0", "hex", "http 0.2.12", "ring", @@ -534,14 +545,14 @@ dependencies = [ "aws-smithy-types", "aws-types", "bytes", - "fastrand", + "fastrand 2.1.0", "http 0.2.12", "http-body 0.4.6", "once_cell", "percent-encoding", "pin-project-lite", "tracing", - "uuid 1.11.0", + "uuid 1.10.0", ] [[package]] @@ -717,13 +728,13 @@ dependencies = [ "aws-smithy-runtime-api", "aws-smithy-types", "bytes", - "fastrand", + "fastrand 2.1.0", "h2 0.3.26", "http 0.2.12", "http-body 0.4.6", "http-body 1.0.1", "httparse", - "hyper 0.14.31", + "hyper 0.14.30", "hyper-rustls 0.24.2", "once_cell", "pin-project-lite", @@ -795,24 +806,24 @@ dependencies = [ "aws-smithy-async", "aws-smithy-runtime-api", "aws-smithy-types", - "rustc_version 0.4.1", + "rustc_version 0.4.0", "tracing", ] [[package]] name = "backtrace" -version = "0.3.74" +version = "0.3.73" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a" +checksum = "5cc23269a4f8976d0a4d2e7109211a419fe30e8d88d677cd60b6bc79c5732e0a" dependencies = [ "addr2line", + "cc", "cfg-if 1.0.0", "libc", "miniz_oxide", "object", "rustc-demangle", "serde", - "windows-targets 0.52.6", ] [[package]] @@ -965,9 +976,9 @@ dependencies = [ [[package]] name = "borsh" -version = "1.5.3" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2506947f73ad44e344215ccd6403ac2ae18cd8e046e581a441bf8d199f257f03" +checksum = "a6362ed55def622cddc70a4746a68554d7b687713770de539e59a739b249f8ed" dependencies = [ "borsh-derive", "cfg_aliases", @@ -975,15 +986,16 @@ dependencies = [ [[package]] name = "borsh-derive" -version = "1.5.3" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2593a3b8b938bd68373196c9832f516be11fa487ef4ae745eb282e6a56a7244" +checksum = "c3ef8005764f53cd4dca619f5bf64cafd4664dada50ece25e4d81de54c80cc0b" dependencies = [ "once_cell", - "proc-macro-crate 3.2.0", + "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", + "syn_derive", ] [[package]] @@ -998,12 +1010,12 @@ dependencies = [ [[package]] name = "bstr" -version = "1.11.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a68f1f47cdf0ec8ee4b941b2eee2a80cb796db73118c0dd09ac63fbe405be22" +checksum = "40723b8fb387abc38f4f4a37c09073622e41dd12327033091ef8950659e6dc0c" dependencies = [ "memchr", - "regex-automata 0.4.9", + "regex-automata 0.4.7", "serde", ] @@ -1021,9 +1033,9 @@ checksum = "c3ac9f8b63eca6fd385229b3675f6cc0dc5c8a5c8a54a59d4f52ffd670d87b0c" [[package]] name = "byte-unit" -version = "5.1.6" +version = "5.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1cd29c3c585209b0cbc7309bfe3ed7efd8c84c21b7af29c8bfae908f8777174" +checksum = "33ac19bdf0b2665407c39d82dbc937e951e7e2001609f0fb32edd0af45a2d63e" dependencies = [ "rust_decimal", "serde", @@ -1066,9 +1078,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.8.0" +version = "1.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ac0150caa2ae65ca5bd83f25c7de183dea78d4d366469f148435e2acfbad0da" +checksum = "8318a53db07bb3f8dca91a600466bdb3f2eaadeedfdbcf02e1accbad9271ba50" [[package]] name = "bytes-utils" @@ -1113,9 +1125,9 @@ checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5" [[package]] name = "cc" -version = "1.2.1" +version = "1.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd9de9f2205d5ef3fd67e685b0df337994ddd4495e2a28d185500d0e1edfea47" +checksum = "68064e60dbf1f17005c2fde4d07c16d8baa506fd7ffed8ccab702d93617975c7" dependencies = [ "jobserver", "libc", @@ -1190,7 +1202,7 @@ checksum = "3147d8272e8fa0ccd29ce51194dd98f79ddfb8191ba9e3409884e751798acf3a" dependencies = [ "core2", "multibase", - "multihash 0.19.2", + "multihash 0.19.1", "unsigned-varint 0.8.0", ] @@ -1206,9 +1218,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.21" +version = "4.5.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb3b4b9e5a7c7514dfa52869339ee98b3156b0bfb4e8a77c4ff4babb64b1604f" +checksum = "ed6719fffa43d0d87e5fd8caeab59be1554fb028cd30edc88fc4369b17971019" dependencies = [ "clap_builder", "clap_derive", @@ -1216,9 +1228,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.21" +version = "4.5.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b17a95aa67cc7b5ebd32aa5370189aa0d79069ef1c64ce893bd30fb24bff20ec" +checksum = "216aec2b177652e3846684cbfe25c9964d18ec45234f0f5da5157b207ed1aab6" dependencies = [ "anstream", "anstyle", @@ -1229,9 +1241,9 @@ dependencies = [ [[package]] name = "clap_complete" -version = "4.5.38" +version = "4.5.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9647a559c112175f17cf724dc72d3645680a883c58481332779192b0d8e7a01" +checksum = "9c677cd0126f3026d8b093fa29eae5d812fde5c05bc66dbb29d0374eea95113a" dependencies = [ "clap", ] @@ -1248,21 +1260,21 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.18" +version = "4.5.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ac6a0c7b1a9e9a5186361f67dfa1b88213572f427fb9ab038efb2bd8c582dab" +checksum = "501d359d5f3dcaf6ecdeee48833ae73ec6e42723a1e52419c79abf9507eec0a0" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] name = "clap_lex" -version = "0.7.3" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "afb84c814227b90d6895e01398aee0d8033c00e7466aca416fb6a8e0eb19d8a7" +checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" [[package]] name = "clipboard-win" @@ -1328,7 +1340,7 @@ dependencies = [ "hmac 0.12.1", "once_cell", "pbkdf2 0.12.2", - "rand", + "rand 0.8.5", "sha2 0.10.8", "thiserror", ] @@ -1355,9 +1367,9 @@ dependencies = [ [[package]] name = "colorchoice" -version = "1.0.3" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b63caa9aa9397e2d9480a9b13673856c78d8ac123288526c37d7839f2a86990" +checksum = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" [[package]] name = "colored" @@ -1400,7 +1412,7 @@ dependencies = [ "http 0.2.12", "mime", "mime_guess", - "rand", + "rand 0.8.5", "thiserror", ] @@ -1412,9 +1424,9 @@ checksum = "410de1ffe61368aa040f599747584e9e3d19235cf4045be6159edb167ef45ddb" [[package]] name = "completest-pty" -version = "0.5.5" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fbd2f22a999db122bd2861c504aa363bbacaa32ebea29edf6924ee6cfe044313" +checksum = "3635aa91b48c47ea30fe12fe7c04efbbf17dade642d4dbaa1e9cfbf3593eed4a" dependencies = [ "completest", "ptyprocess", @@ -1442,6 +1454,15 @@ dependencies = [ "xdg", ] +[[package]] +name = "concurrent-queue" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" +dependencies = [ + "crossbeam-utils", +] + [[package]] name = "console" version = "0.15.8" @@ -1457,9 +1478,9 @@ dependencies = [ [[package]] name = "const-hex" -version = "1.13.1" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0121754e84117e65f9d90648ee6aa4882a6e63110307ab73967a4c5e7e69e586" +checksum = "94fb8a24a26d37e1ffd45343323dc9fe6654ceea44c12f2fcb3d7ac29e610bc6" dependencies = [ "cfg-if 1.0.0", "cpufeatures", @@ -1550,9 +1571,9 @@ checksum = "7704b5fdd17b18ae31c4c1da5a2e0305a2bf17b5249300a9ee9ed7b72114c636" [[package]] name = "cpufeatures" -version = "0.2.15" +version = "0.2.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ca741a962e1b0bff6d724a1a0958b686406e853bb14061f218562e1896f95e6" +checksum = "51e852e6dc9a5bed1fae92dd2375037bf2b768725bf3be87811edee3249d09ad" dependencies = [ "libc", ] @@ -1604,9 +1625,9 @@ dependencies = [ [[package]] name = "critical-section" -version = "1.2.0" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "790eea4361631c5e7d22598ecd5723ff611904e3344ce8720784c93e3d83d40b" +checksum = "7059fff8937831a9ae6f0fe4d658ffabf58f2ca96aa9dec1c889f936f705f216" [[package]] name = "crossbeam-channel" @@ -1655,7 +1676,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0dc92fb57ca44df6db8059111ab3af99a63d5d0f8375d9972e319a379c6bab76" dependencies = [ "generic-array", - "rand_core", + "rand_core 0.6.4", "subtle", "zeroize", ] @@ -1682,9 +1703,9 @@ dependencies = [ [[package]] name = "csv" -version = "1.3.1" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acdc4883a9c96732e4733212c01447ebd805833b7275a73ca3ee080fd77afdaf" +checksum = "ac574ff4d437a7b5ad237ef331c17ccca63c46479e5b5453eb8e10bb99a759fe" dependencies = [ "csv-core", "itoa", @@ -1721,7 +1742,7 @@ dependencies = [ "curve25519-dalek-derive", "digest 0.10.7", "fiat-crypto", - "rustc_version 0.4.1", + "rustc_version 0.4.0", "subtle", ] @@ -1733,7 +1754,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -1832,7 +1853,7 @@ dependencies = [ "proc-macro2", "quote", "strsim 0.11.1", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -1854,7 +1875,7 @@ checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806" dependencies = [ "darling_core 0.20.10", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -1921,6 +1942,25 @@ dependencies = [ "winapi", ] +[[package]] +name = "deadpool" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "421fe0f90f2ab22016f32a9881be5134fdd71c65298917084b0c7477cbc3856e" +dependencies = [ + "async-trait", + "deadpool-runtime", + "num_cpus", + "retain_mut", + "tokio", +] + +[[package]] +name = "deadpool-runtime" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "092966b41edc516079bdf31ec78a2e0588d1d0c08f78b91d8307215928642b2b" + [[package]] name = "der" version = "0.7.9" @@ -1970,7 +2010,7 @@ dependencies = [ "darling 0.20.10", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -1980,7 +2020,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ab63b0e2bf4d5928aff72e83a7dace85d7bba5fe12dcc3c5a572d78caffd3f3c" dependencies = [ "derive_builder_core", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -1992,8 +2032,8 @@ dependencies = [ "convert_case", "proc-macro2", "quote", - "rustc_version 0.4.1", - "syn 2.0.87", + "rustc_version 0.4.0", + "syn 2.0.76", ] [[package]] @@ -2013,7 +2053,7 @@ checksum = "cb7330aeadfbe296029522e6c40f315320aba36fc43a5b3632f3795348f3bd22" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", "unicode-xid", ] @@ -2142,17 +2182,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "displaydoc" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.87", -] - [[package]] name = "dissimilar" version = "1.0.9" @@ -2261,7 +2290,7 @@ dependencies = [ "generic-array", "group", "pkcs8", - "rand_core", + "rand_core 0.6.4", "sec1", "subtle", "zeroize", @@ -2273,12 +2302,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ef1a6892d9eef45c8fa6b9e0086428a2cca8491aca8f787c534a3d6d0bcb3ced" -[[package]] -name = "embedded-io" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edd0f118536f44f5ccd48bcb8b111bdc3de888b58c74639dfb034a357d0f206d" - [[package]] name = "encode_unicode" version = "0.3.6" @@ -2293,9 +2316,9 @@ checksum = "34aa73646ffb006b8f5147f3dc182bd4bcb190227ce861fc4a4844bf8e3cb2c0" [[package]] name = "encoding_rs" -version = "0.8.35" +version = "0.8.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75030f3c4f45dafd7586dd6780965a8c7e8e285a5ecb86713e63a79c5b2766f3" +checksum = "b45de904aa0b010bce2ab45264d0631681847fa7b6f2eaa7dab7619943bc4f59" dependencies = [ "cfg-if 1.0.0", ] @@ -2329,7 +2352,7 @@ checksum = "a1ab991c1362ac86c61ab6f556cff143daa22e5a15e4e189df818b2fd19fe65b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -2342,7 +2365,7 @@ dependencies = [ "num-traits", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -2353,7 +2376,7 @@ checksum = "2f9ed6b3789237c8a0c1c505af1c7eb2c560df6186f01b098c3a1064ea532f38" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -2419,9 +2442,9 @@ checksum = "5692dd7b5a1978a5aeb0ce83b7655c58ca8efdcb79d21036ea249da95afec2c6" [[package]] name = "escargot" -version = "0.5.13" +version = "0.5.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05a3ac187a16b5382fef8c69fd1bad123c67b7cf3932240a2d43dcdd32cded88" +checksum = "c000f23e9d459aef148b7267e02b03b94a0aaacf4ec64c65612f67e02f525fb6" dependencies = [ "log", "once_cell", @@ -2441,7 +2464,7 @@ dependencies = [ "hex", "hmac 0.12.1", "pbkdf2 0.11.0", - "rand", + "rand 0.8.5", "scrypt", "serde", "serde_json", @@ -2484,6 +2507,12 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b90ca2580b73ab6a1f724b76ca11ab632df820fd6040c336200d2c1df7b3c82c" +[[package]] +name = "event-listener" +version = "2.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" + [[package]] name = "eventsource-client" version = "0.13.0" @@ -2491,12 +2520,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "43ddc25e1ad2cc0106d5e2d967397b4fb2068a66677ee9b0eea4600e5cfe8fb4" dependencies = [ "futures", - "hyper 0.14.31", + "hyper 0.14.30", "hyper-rustls 0.24.2", "hyper-timeout", "log", "pin-project", - "rand", + "rand 0.8.5", "tokio", ] @@ -2518,7 +2547,7 @@ checksum = "dd65f1b59dd22d680c7a626cc4a000c1e03d241c51c3e034d2bc9f1e90734f9b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -2545,9 +2574,18 @@ checksum = "a2a2b11eda1d40935b26cf18f6833c526845ae8c41e58d09af6adeb6f0269183" [[package]] name = "fastrand" -version = "2.2.0" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" +dependencies = [ + "instant", +] + +[[package]] +name = "fastrand" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "486f806e73c5707928240ddc295403b1b93c96a02038563881c4a2fd84b81ac4" +checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" [[package]] name = "fastrlp" @@ -2577,7 +2615,7 @@ version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ded41244b729663b1e574f1b4fb731469f69f79c17667b5d776b16cda0479449" dependencies = [ - "rand_core", + "rand_core 0.6.4", "subtle", ] @@ -2610,9 +2648,9 @@ dependencies = [ [[package]] name = "filetime" -version = "0.2.25" +version = "0.2.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35c0522e981e68cbfa8c3f978441a5f34b30b96e146b33cd3359176b50fe8586" +checksum = "bf401df4a4e3872c4fe8151134cf483738e74b67fc934d6532c882b3d24a4550" dependencies = [ "cfg-if 1.0.0", "libc", @@ -2627,7 +2665,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "835c052cb0c08c1acf6ffd71c022172e18723949c8282f2b9f27efbc51e64534" dependencies = [ "byteorder", - "rand", + "rand 0.8.5", "rustc-hex", "static_assertions", ] @@ -2640,9 +2678,9 @@ checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" [[package]] name = "flate2" -version = "1.0.35" +version = "1.0.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c936bfdafb507ebbf50b8074c54fa31c5be9a1e7e5f467dd659697041407d07c" +checksum = "7f211bbe8e69bbd0cfdea405084f128ae8b4aaa6b0b522fc8f2b009084797920" dependencies = [ "crc32fast", "miniz_oxide", @@ -2690,7 +2728,7 @@ dependencies = [ "term-table", "tokio", "toml 0.8.19", - "toml_edit", + "toml_edit 0.22.20", "tracing", "url", "walkdir", @@ -2729,7 +2767,7 @@ dependencies = [ "k256", "portpicker", "pretty_assertions", - "rand", + "rand 0.8.5", "regex", "rexpect 0.5.0", "rpassword", @@ -2741,7 +2779,7 @@ dependencies = [ "sway-utils", "tempfile", "tokio", - "toml_edit", + "toml_edit 0.22.20", "tracing", ] @@ -2762,7 +2800,7 @@ dependencies = [ "futures", "hex", "libp2p-identity", - "rand", + "rand 0.8.5", "rayon", "regex", "serde", @@ -2856,6 +2894,26 @@ dependencies = [ "tokio", ] +[[package]] +name = "forc-node" +version = "0.66.4" +dependencies = [ + "anyhow", + "clap", + "dialoguer", + "forc-tracing 0.66.5", + "forc-util", + "include_dir", + "reqwest 0.12.5", + "semver 1.0.23", + "serde", + "serde_json", + "sha1", + "tempfile", + "tokio", + "wiremock", +] + [[package]] name = "forc-pkg" version = "0.66.5" @@ -2874,7 +2932,7 @@ dependencies = [ "ipfs-api-backend-hyper", "petgraph", "regex", - "reqwest 0.12.9", + "reqwest 0.12.5", "semver 1.0.23", "serde", "serde_ignored", @@ -2904,7 +2962,7 @@ dependencies = [ "fuel-tx", "fuel-vm", "fuels-core", - "rand", + "rand 0.8.5", "rayon", "sway-core", "sway-features", @@ -2993,7 +3051,7 @@ dependencies = [ "futures", "hex", "home", - "rand", + "rand 0.8.5", "rpassword", "serde_json", "termion 2.0.3", @@ -3054,7 +3112,7 @@ dependencies = [ "regex", "serde", "serde_json", - "syn 2.0.87", + "syn 2.0.76", "thiserror", ] @@ -3083,7 +3141,7 @@ dependencies = [ "fuel-core-types", "itertools 0.12.1", "postcard", - "rand", + "rand 0.8.5", "serde", "serde_json", "serde_with", @@ -3199,7 +3257,7 @@ dependencies = [ "derivative", "derive_more 0.99.18", "fuel-vm", - "rand", + "rand 0.8.5", "secrecy", "serde", "tai64", @@ -3220,7 +3278,7 @@ dependencies = [ "k256", "lazy_static", "p256", - "rand", + "rand 0.8.5", "secp256k1", "serde", "sha2 0.10.8", @@ -3235,7 +3293,7 @@ checksum = "ab0bc46a3552964bae5169e79b383761a54bd115ea66951a1a7a229edcefa55a" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", "synstructure 0.13.1", ] @@ -3267,7 +3325,7 @@ dependencies = [ "num-bigint", "pest", "pest_derive", - "rand", + "rand 0.8.5", "sha3", "snafu", ] @@ -3323,7 +3381,7 @@ dependencies = [ "hashbrown 0.14.5", "itertools 0.10.5", "postcard", - "rand", + "rand 0.8.5", "serde", "strum 0.24.1", "strum_macros 0.24.3", @@ -3337,7 +3395,7 @@ checksum = "982265415a99b5bd6277bc24194a233bb2e18764df11c937b3dbb11a02c9e545" dependencies = [ "fuel-derive", "hex", - "rand", + "rand 0.8.5", "serde", ] @@ -3366,7 +3424,7 @@ dependencies = [ "paste", "percent-encoding", "primitive-types", - "rand", + "rand 0.8.5", "serde", "serde_with", "sha3", @@ -3409,7 +3467,7 @@ dependencies = [ "fuel-types", "fuels-core", "itertools 0.12.1", - "rand", + "rand 0.8.5", "semver 1.0.23", "tai64", "thiserror", @@ -3430,7 +3488,7 @@ dependencies = [ "quote", "regex", "serde_json", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -3472,7 +3530,7 @@ dependencies = [ "itertools 0.12.1", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -3489,7 +3547,7 @@ dependencies = [ "fuels-accounts", "fuels-core", "itertools 0.12.1", - "rand", + "rand 0.8.5", "serde_json", "tokio", ] @@ -3512,7 +3570,7 @@ dependencies = [ "fuels-core", "futures", "portpicker", - "rand", + "rand 0.8.5", "tempfile", "tokio", "which", @@ -3526,9 +3584,9 @@ checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" [[package]] name = "futures" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65bc07b1a8bc7c85c5f2e110c476c7389b4554ba72af57d8445ea63a576b0876" +checksum = "645c6916888f6cb6350d2550b80fb63e734897a8498abe35cfb732b6487804b0" dependencies = [ "futures-channel", "futures-core", @@ -3541,9 +3599,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dff15bf788c671c1934e366d07e30c1814a8ef514e1af724a602e8a2fbe1b10" +checksum = "eac8f7d7865dcb88bd4373ab671c8cf4508703796caa2b1985a9ca867b3fcb78" dependencies = [ "futures-core", "futures-sink", @@ -3551,15 +3609,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05f29059c0c2090612e8d742178b0580d2dc940c837851ad723096f87af6663e" +checksum = "dfc6580bb841c5a68e9ef15c77ccc837b40a7504914d52e47b8b0e9bbda25a1d" [[package]] name = "futures-executor" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e28d1d997f585e54aebc3f97d39e72338912123a67330d723fdbb564d646c9f" +checksum = "a576fc72ae164fca6b9db127eaa9a9dda0d61316034f33a0a0d4eda41f02b01d" dependencies = [ "futures-core", "futures-task", @@ -3568,38 +3626,59 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.31" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a44623e20b9681a318efdd71c299b6b222ed6f231972bfe2f224ebad6311f0c1" + +[[package]] +name = "futures-lite" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e5c1b78ca4aae1ac06c48a526a655760685149f0d465d21f37abfe57ce075c6" +checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce" +dependencies = [ + "fastrand 1.9.0", + "futures-core", + "futures-io", + "memchr", + "parking", + "pin-project-lite", + "waker-fn", +] [[package]] name = "futures-macro" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" +checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] name = "futures-sink" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e575fab7d1e0dcb8d0c7bcf9a63ee213816ab51902e6d244a95819acacf1d4f7" +checksum = "9fb8e00e87438d937621c1c6269e53f536c14d3fbd6a042bb24879e57d474fb5" [[package]] name = "futures-task" -version = "0.3.31" +version = "0.3.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d84fa142264698cdce1a9f9172cf383a0c82de1bddcf3092901442c4097004" + +[[package]] +name = "futures-timer" +version = "3.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f90f7dce0722e95104fcb095585910c0977252f286e354b5e3bd38902cd99988" +checksum = "f288b0a4f20f9a56b5d1da57e2227c661b7b16168e2f72365f57b63326e29b24" [[package]] name = "futures-util" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fa08315bb612088cc391249efdc3bc77536f16c91f6cf495e6fbe85b20a4a81" +checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" dependencies = [ "futures-channel", "futures-core", @@ -3634,6 +3713,17 @@ dependencies = [ "zeroize", ] +[[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.15" @@ -3642,9 +3732,15 @@ checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if 1.0.0", "libc", - "wasi", + "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 = "gimli" version = "0.31.1" @@ -3694,9 +3790,9 @@ dependencies = [ [[package]] name = "gix-path" -version = "0.10.12" +version = "0.10.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c04e5a94fdb56b1e91eb7df2658ad16832428b8eeda24ff1a0f0288de2bce554" +checksum = "8d23d5bbda31344d8abc8de7c075b3cf26e5873feba7c4a15d916bce67382bd9" dependencies = [ "bstr", "gix-trace", @@ -3707,15 +3803,15 @@ dependencies = [ [[package]] name = "gix-trace" -version = "0.1.11" +version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04bdde120c29f1fc23a24d3e115aeeea3d60d8e65bab92cc5f9d90d9302eb952" +checksum = "f924267408915fddcd558e3f37295cc7d6a3e50f8bd8b606cee0808c3915157e" [[package]] name = "gix-url" -version = "0.27.5" +version = "0.27.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd280c5e84fb22e128ed2a053a0daeacb6379469be6a85e3d518a0636e160c89" +checksum = "e2eb9b35bba92ea8f0b5ab406fad3cf6b87f7929aa677ff10aa042c6da621156" dependencies = [ "bstr", "gix-features", @@ -3741,8 +3837,8 @@ dependencies = [ "aho-corasick", "bstr", "log", - "regex-automata 0.4.9", - "regex-syntax 0.8.5", + "regex-automata 0.4.7", + "regex-syntax 0.8.4", ] [[package]] @@ -3773,7 +3869,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f0f9ef7462f7c099f518d754361858f86d8a07af53ba9af0fe635bbccb151a63" dependencies = [ "ff", - "rand_core", + "rand_core 0.6.4", "subtle", ] @@ -3798,9 +3894,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.4.7" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccae279728d634d083c00f6099cb58f01cc99c145b84b8be2f6c74618d79922e" +checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" dependencies = [ "atomic-waker", "bytes", @@ -3827,12 +3923,11 @@ dependencies = [ [[package]] name = "handlebars" -version = "6.2.0" +version = "5.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd4ccde012831f9a071a637b0d4e31df31c0f6c525784b35ae76a9ac6bc1e315" +checksum = "d08485b96a0e6393e9e4d1b8d48cf74ad6c063cd905eb33f42c1ce3f0377539b" dependencies = [ "log", - "num-order", "pest", "pest_derive", "serde", @@ -3895,7 +3990,7 @@ checksum = "cdc6457c0eb62c71aac4bc17216026d8410337c4126773b9c5daba343f17964f" dependencies = [ "atomic-polyfill", "hash32", - "rustc_version 0.4.1", + "rustc_version 0.4.0", "serde", "spin", "stable_deref_trait", @@ -4050,11 +4145,32 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "http-types" +version = "2.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e9b187a72d63adbfba487f48095306ac823049cb504ee195541e91c7775f5ad" +dependencies = [ + "anyhow", + "async-channel", + "base64 0.13.1", + "futures-lite", + "http 0.2.12", + "infer", + "pin-project-lite", + "rand 0.7.3", + "serde", + "serde_json", + "serde_qs", + "serde_urlencoded", + "url", +] + [[package]] name = "httparse" -version = "1.9.5" +version = "1.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d71d3574edd2771538b901e6549113b4006ece66150fb69c0fb6d9a2adae946" +checksum = "0fcc0b4a115bf80b728eb8ea024ad5bd707b615bfed49e0665b6e0f86fd082d9" [[package]] name = "httpdate" @@ -4070,9 +4186,9 @@ checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "hyper" -version = "0.14.31" +version = "0.14.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c08302e8fa335b151b788c775ff56e7a03ae64ff85c548ee820fecb70356e85" +checksum = "a152ddd61dfaec7273fe8419ab357f33aee0d914c5f4efbf0d96fa749eea5ec9" dependencies = [ "bytes", "futures-channel", @@ -4094,14 +4210,14 @@ dependencies = [ [[package]] name = "hyper" -version = "1.5.1" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97818827ef4f364230e16705d4706e2897df2bb60617d6ca15d598025a3c481f" +checksum = "50dfd22e0e76d0f662d429a5f80fcaf3855009297eab6a0a9f8543834744ba05" dependencies = [ "bytes", "futures-channel", "futures-util", - "h2 0.4.7", + "h2 0.4.5", "http 1.1.0", "http-body 1.0.1", "httparse", @@ -4122,7 +4238,7 @@ dependencies = [ "common-multipart-rfc7578", "futures-core", "http 0.2.12", - "hyper 0.14.31", + "hyper 0.14.30", ] [[package]] @@ -4133,7 +4249,7 @@ checksum = "ec3efd23720e2049821a693cbc7e65ea87c72f1c58ff2f9522ff332b1491e590" dependencies = [ "futures-util", "http 0.2.12", - "hyper 0.14.31", + "hyper 0.14.30", "log", "rustls 0.21.12", "rustls-native-certs", @@ -4144,15 +4260,15 @@ dependencies = [ [[package]] name = "hyper-rustls" -version = "0.27.3" +version = "0.27.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08afdbb5c31130e3034af566421053ab03787c640246a446327f550d11bcb333" +checksum = "5ee4be2c948921a1a5320b629c4193916ed787a7f7f293fd3f7f5a6c9de74155" dependencies = [ "futures-util", "http 1.1.0", - "hyper 1.5.1", + "hyper 1.4.1", "hyper-util", - "rustls 0.23.17", + "rustls 0.23.12", "rustls-pki-types", "tokio", "tokio-rustls 0.26.0", @@ -4165,7 +4281,7 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bbb958482e8c7be4bc3cf272a766a2b0bf1a6755e7a6ae777f017a31d11b13b1" dependencies = [ - "hyper 0.14.31", + "hyper 0.14.30", "pin-project-lite", "tokio", "tokio-io-timeout", @@ -4179,7 +4295,7 @@ checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" dependencies = [ "bytes", "http-body-util", - "hyper 1.5.1", + "hyper 1.4.1", "hyper-util", "native-tls", "tokio", @@ -4189,28 +4305,29 @@ dependencies = [ [[package]] name = "hyper-util" -version = "0.1.10" +version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df2dcfbe0677734ab2f3ffa7fa7bfd4706bfdc1ef393f2ee30184aed67e631b4" +checksum = "cde7055719c54e36e95e8719f95883f22072a48ede39db7fc17a4e1d5281e9b9" dependencies = [ "bytes", "futures-channel", "futures-util", "http 1.1.0", "http-body 1.0.1", - "hyper 1.5.1", + "hyper 1.4.1", "pin-project-lite", "socket2", "tokio", + "tower 0.4.13", "tower-service", "tracing", ] [[package]] name = "iana-time-zone" -version = "0.1.61" +version = "0.1.60" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "235e081f3925a06703c2d0117ea8b91f042756fd6e7a6e5d901e8ca1a996b220" +checksum = "e7ffbb5a1b541ea2561f8c41c087286cc091e21e556a4f09a8f6cbf17b69b141" dependencies = [ "android_system_properties", "core-foundation-sys", @@ -4229,124 +4346,6 @@ dependencies = [ "cc", ] -[[package]] -name = "icu_collections" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db2fa452206ebee18c4b5c2274dbf1de17008e874b4dc4f0aea9d01ca79e4526" -dependencies = [ - "displaydoc", - "yoke", - "zerofrom", - "zerovec", -] - -[[package]] -name = "icu_locid" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13acbb8371917fc971be86fc8057c41a64b521c184808a698c02acc242dbf637" -dependencies = [ - "displaydoc", - "litemap", - "tinystr", - "writeable", - "zerovec", -] - -[[package]] -name = "icu_locid_transform" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01d11ac35de8e40fdeda00d9e1e9d92525f3f9d887cdd7aa81d727596788b54e" -dependencies = [ - "displaydoc", - "icu_locid", - "icu_locid_transform_data", - "icu_provider", - "tinystr", - "zerovec", -] - -[[package]] -name = "icu_locid_transform_data" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdc8ff3388f852bede6b579ad4e978ab004f139284d7b28715f773507b946f6e" - -[[package]] -name = "icu_normalizer" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19ce3e0da2ec68599d193c93d088142efd7f9c5d6fc9b803774855747dc6a84f" -dependencies = [ - "displaydoc", - "icu_collections", - "icu_normalizer_data", - "icu_properties", - "icu_provider", - "smallvec", - "utf16_iter", - "utf8_iter", - "write16", - "zerovec", -] - -[[package]] -name = "icu_normalizer_data" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8cafbf7aa791e9b22bec55a167906f9e1215fd475cd22adfcf660e03e989516" - -[[package]] -name = "icu_properties" -version = "1.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93d6020766cfc6302c15dbbc9c8778c37e62c14427cb7f6e601d849e092aeef5" -dependencies = [ - "displaydoc", - "icu_collections", - "icu_locid_transform", - "icu_properties_data", - "icu_provider", - "tinystr", - "zerovec", -] - -[[package]] -name = "icu_properties_data" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67a8effbc3dd3e4ba1afa8ad918d5684b8868b3b26500753effea8d2eed19569" - -[[package]] -name = "icu_provider" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ed421c8a8ef78d3e2dbc98a973be2f3770cb42b606e3ab18d6237c4dfde68d9" -dependencies = [ - "displaydoc", - "icu_locid", - "icu_provider_macros", - "stable_deref_trait", - "tinystr", - "writeable", - "yoke", - "zerofrom", - "zerovec", -] - -[[package]] -name = "icu_provider_macros" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.87", -] - [[package]] name = "ident_case" version = "1.0.1" @@ -4365,23 +4364,12 @@ dependencies = [ [[package]] name = "idna" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "686f825264d630750a544639377bae737628043f20d38bbc029e8f29ea968a7e" -dependencies = [ - "idna_adapter", - "smallvec", - "utf8_iter", -] - -[[package]] -name = "idna_adapter" -version = "1.2.0" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "daca1df1c957320b2cf139ac61e7bd64fed304c5040df000a745aa1de3b4ef71" +checksum = "634d9b1461af396cad843f47fdba5597a4f9e6ddd4bfb6ff5d85028c25cb12f6" dependencies = [ - "icu_normalizer", - "icu_properties", + "unicode-bidi", + "unicode-normalization", ] [[package]] @@ -4391,7 +4379,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d0acd33ff0285af998aaf9b57342af478078f53492322fafc47450e09397e0e9" dependencies = [ "bitmaps", - "rand_core", + "rand_core 0.6.4", "rand_xoshiro", "sized-chunks", "typenum", @@ -4427,26 +4415,26 @@ dependencies = [ [[package]] name = "impl-tools" -version = "0.10.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a84bc8d2baf8da56e93b4247067d918e1a44829bbbe3e4b875aaf8d7d3c7bc9" +checksum = "d82c305b1081f1a99fda262883c788e50ab57d36c00830bdd7e0a82894ad965c" dependencies = [ "autocfg", "impl-tools-lib", - "proc-macro-error2", - "syn 2.0.87", + "proc-macro-error", + "syn 2.0.76", ] [[package]] name = "impl-tools-lib" -version = "0.10.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a795a1e201125947a063b967c79de6ae152143ab522f481d4f493c44835ba37a" +checksum = "85d3946d886eaab0702fa0c6585adcced581513223fa9df7ccfabbd9fa331a88" dependencies = [ - "proc-macro-error2", + "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -4514,6 +4502,12 @@ version = "2.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b248f5224d1d606005e02c97f5aa4e88eeb230488bcc03bc9ca4d7991399f2b5" +[[package]] +name = "infer" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64e9829a50b42bb782c1df523f78d332fe371b10c661e78b7a3c34b0198e9fac" + [[package]] name = "inotify" version = "0.9.6" @@ -4557,6 +4551,15 @@ dependencies = [ "similar", ] +[[package]] +name = "instant" +version = "0.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e0242819d153cba4b4b05a5a8f2a7e9bbf97b6055b2a002b395c96b5ff3c0222" +dependencies = [ + "cfg-if 1.0.0", +] + [[package]] name = "ipfs-api-backend-hyper" version = "0.6.0" @@ -4568,7 +4571,7 @@ dependencies = [ "bytes", "futures", "http 0.2.12", - "hyper 0.14.31", + "hyper 0.14.30", "hyper-multipart-rfc7578", "ipfs-api-prelude", "thiserror", @@ -4602,9 +4605,9 @@ dependencies = [ [[package]] name = "ipnet" -version = "2.10.1" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddc24109865250148c2e0f3d25d4f0f479571723792d3802153c60922a4fb708" +checksum = "8f518f335dce6725a761382244631d86cf0ccb2863413590b31338feb467f9c3" [[package]] name = "is-terminal" @@ -4661,9 +4664,9 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.12" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a73e9fe3c49d7afb2ace819fa181a287ce54a0983eda4e0eb05c22f82ffe534" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] name = "jobserver" @@ -4676,18 +4679,18 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.72" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a88f1bda2bd75b0452a14784937d796722fdebfe50df998aeb3f0b7603019a9" +checksum = "1868808506b929d7b0cfa8f75951347aa71bb21144b7791bae35d9bccfcfe37a" dependencies = [ "wasm-bindgen", ] [[package]] name = "k256" -version = "0.13.4" +version = "0.13.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6e3919bbaa2945715f0bb6d3934a173d1e9a59ac23767fbaaef277265a7411b" +checksum = "956ff9b67e26e1a6a866cb758f12c6f8746208489e3e4a4b5580802f2f0a587b" dependencies = [ "cfg-if 1.0.0", "ecdsa", @@ -4747,9 +4750,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.164" +version = "0.2.156" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "433bfe06b8c75da9b2e3fbea6e5329ff87748f0b144ef75306e674c3f6f7c13f" +checksum = "a5f43f184355eefb8d17fc948dbecf6c13be3c141f20d834ae842193a448c72a" [[package]] name = "libdbus-sys" @@ -4777,9 +4780,9 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.11" +version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8355be11b20d696c8f18f6cc018c4e372165b1fa8126cef092399c9951984ffa" +checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" [[package]] name = "libp2p-identity" @@ -4791,7 +4794,7 @@ dependencies = [ "bs58", "hkdf", "libsecp256k1", - "multihash 0.19.2", + "multihash 0.19.1", "quick-protobuf", "sha2 0.10.8", "thiserror", @@ -4818,7 +4821,7 @@ checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" dependencies = [ "bitflags 2.6.0", "libc", - "redox_syscall 0.5.7", + "redox_syscall 0.5.3", ] [[package]] @@ -4834,7 +4837,7 @@ dependencies = [ "libsecp256k1-core", "libsecp256k1-gen-ecmult", "libsecp256k1-gen-genmult", - "rand", + "rand 0.8.5", "serde", "sha2 0.9.9", "typenum", @@ -4897,9 +4900,9 @@ dependencies = [ [[package]] name = "libz-sys" -version = "1.1.20" +version = "1.1.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2d16453e800a8cf6dd2fc3eb4bc99b786a9b90c663b8559a5b1a041bf89e472" +checksum = "fdc53a7799a7496ebc9fd29f31f7df80e83c9bda5299768af5f9e59eeea74647" dependencies = [ "cc", "libc", @@ -4919,12 +4922,6 @@ version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" -[[package]] -name = "litemap" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "643cb0b8d4fcc284004d5fd0d67ccf61dfffadb7f75e1e71bc420f4688a3a704" - [[package]] name = "lock_api" version = "0.4.12" @@ -4988,9 +4985,9 @@ dependencies = [ [[package]] name = "mdbook" -version = "0.4.42" +version = "0.4.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7624879735513024d323e7267a0b3a7176aceb0db537939beb4ee31d9e8945e3" +checksum = "b45a38e19bd200220ef07c892b0157ad3d2365e5b5a267ca01ad12182491eea5" dependencies = [ "anyhow", "chrono", @@ -5066,20 +5063,17 @@ dependencies = [ [[package]] name = "minifier" -version = "0.3.2" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd559bbf5d350ac7f2c1cf92ed71a869b847a92bce0c1318b47932a5b5f65cdd" -dependencies = [ - "clap", -] +checksum = "95bbbf96b9ac3482c2a25450b67a15ed851319bc5fabf3b40742ea9066e84282" [[package]] name = "miniz_oxide" -version = "0.8.0" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2d80299ef12ff69b16a84bb182e3b9df68b5a91574d3d4fa6e41b65deec4df1" +checksum = "b8a240ddb74feaf34a79a7add65a741f3167852fba007066dcac1ca548d89c08" dependencies = [ - "adler2", + "adler", ] [[package]] @@ -5090,7 +5084,7 @@ checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" dependencies = [ "libc", "log", - "wasi", + "wasi 0.11.0+wasi-snapshot-preview1", "windows-sys 0.48.0", ] @@ -5102,7 +5096,7 @@ checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" dependencies = [ "hermit-abi 0.3.9", "libc", - "wasi", + "wasi 0.11.0+wasi-snapshot-preview1", "windows-sys 0.52.0", ] @@ -5149,12 +5143,12 @@ dependencies = [ [[package]] name = "multihash" -version = "0.19.2" +version = "0.19.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc41f430805af9d1cf4adae4ed2149c759b877b01d909a1f40256188d09345d2" +checksum = "076d548d76a0e2a0d4ab471d0b1c36c577786dfc4471242035d97a12a735c492" dependencies = [ "core2", - "unsigned-varint 0.8.0", + "unsigned-varint 0.7.2", ] [[package]] @@ -5372,21 +5366,6 @@ dependencies = [ "num-traits", ] -[[package]] -name = "num-modular" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17bb261bf36fa7d83f4c294f834e91256769097b3cb505d44831e0a179ac647f" - -[[package]] -name = "num-order" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "537b596b97c40fcf8056d153049eb22f481c17ebce72a513ec9286e4986d1bb6" -dependencies = [ - "num-modular", -] - [[package]] name = "num-rational" version = "0.4.2" @@ -5433,10 +5412,10 @@ version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "af1844ef2428cc3e1cb900be36181049ef3d3193c63e43026cfe202983b27a56" dependencies = [ - "proc-macro-crate 3.2.0", + "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -5453,13 +5432,13 @@ checksum = "6aa2c4e539b869820a2b82e1aef6ff40aa85e65decdd5185e83fb4b1249cd00f" [[package]] name = "object" -version = "0.36.5" +version = "0.36.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aedf0a2d09c573ed1d8d85b30c119153926a2b36dce0ab28322c09a117a4683e" +checksum = "27b64972346851a39438c60b341ebc01bba47464ae329e55cf343eb93964efd9" dependencies = [ "crc32fast", "flate2", - "hashbrown 0.15.1", + "hashbrown 0.14.5", "indexmap 2.6.0", "memchr", "ruzstd", @@ -5467,19 +5446,19 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.20.2" +version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" [[package]] name = "onig" -version = "6.4.0" +version = "6.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c4b31c8722ad9171c6d77d3557db078cab2bd50afcc9d09c8b315c59df8ca4f" +checksum = "67ddfe2c93bb389eea6e6d713306880c7f6dcc99a75b659ce145d962c861b225" dependencies = [ "bitflags 1.3.2", + "lazy_static", "libc", - "once_cell", "onig_sys", ] @@ -5519,9 +5498,9 @@ dependencies = [ [[package]] name = "openssl" -version = "0.10.68" +version = "0.10.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6174bc48f102d208783c2c84bf931bb75927a617866870de8a4ea85597f871f5" +checksum = "9529f4786b70a3e8c61e11179af17ab6188ad8d0ded78c5529441ed39d4bd9c1" dependencies = [ "bitflags 2.6.0", "cfg-if 1.0.0", @@ -5540,7 +5519,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -5551,18 +5530,18 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-src" -version = "300.4.1+3.4.0" +version = "300.3.1+3.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "faa4eac4138c62414b5622d1b31c5c304f34b406b013c079c2bbc652fdd6678c" +checksum = "7259953d42a81bf137fbbd73bd30a8e1914d6dce43c2b90ed575783a22608b91" dependencies = [ "cc", ] [[package]] name = "openssl-sys" -version = "0.9.104" +version = "0.9.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45abf306cbf99debc8195b66b7346498d7b10c210de50418b5ccd7ceba08c741" +checksum = "7f9e8deee91df40a943c71b917e5874b951d32a802526c85721ce3b776c929d6" dependencies = [ "cc", "libc", @@ -5628,31 +5607,36 @@ dependencies = [ [[package]] name = "parity-scale-codec" -version = "3.7.0" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8be4817d39f3272f69c59fe05d0535ae6456c2dc2fa1ba02910296c7e0a5c590" +checksum = "306800abfa29c7f16596b5970a588435e3d5b3149683d00c12b699cc19f895ee" dependencies = [ "arrayvec", "bitvec", "byte-slice-cast", "impl-trait-for-tuples", "parity-scale-codec-derive", - "rustversion", "serde", ] [[package]] name = "parity-scale-codec-derive" -version = "3.7.0" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8781a75c6205af67215f382092b6e0a4ff3734798523e69073d4bcd294ec767b" +checksum = "d830939c76d294956402033aee57a6da7b438f2294eb94864c37b0569053a42c" dependencies = [ - "proc-macro-crate 3.2.0", + "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.87", + "syn 1.0.109", ] +[[package]] +name = "parking" +version = "2.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" + [[package]] name = "parking_lot" version = "0.12.3" @@ -5671,7 +5655,7 @@ checksum = "1e401f977ab385c9e4e3ab30627d6f26d00e2c73eef317493c4ec6d468726cf8" dependencies = [ "cfg-if 1.0.0", "libc", - "redox_syscall 0.5.7", + "redox_syscall 0.5.3", "smallvec", "windows-targets 0.52.6", ] @@ -5736,9 +5720,9 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pest" -version = "2.7.14" +version = "2.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "879952a81a83930934cbf1786752d6dedc3b1f29e8f8fb2ad1d0a36f377cf442" +checksum = "cd53dff83f26735fdc1ca837098ccf133605d794cdae66acfc2bfac3ec809d95" dependencies = [ "memchr", "thiserror", @@ -5747,9 +5731,9 @@ dependencies = [ [[package]] name = "pest_derive" -version = "2.7.14" +version = "2.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d214365f632b123a47fd913301e14c946c61d1c183ee245fa76eb752e59a02dd" +checksum = "2a548d2beca6773b1c244554d36fcf8548a8a58e74156968211567250e48e49a" dependencies = [ "pest", "pest_generator", @@ -5757,22 +5741,22 @@ dependencies = [ [[package]] name = "pest_generator" -version = "2.7.14" +version = "2.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb55586734301717aea2ac313f50b2eb8f60d2fc3dc01d190eefa2e625f60c4e" +checksum = "3c93a82e8d145725dcbaf44e5ea887c8a869efdcc28706df2d08c69e17077183" dependencies = [ "pest", "pest_meta", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] name = "pest_meta" -version = "2.7.14" +version = "2.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b75da2a70cf4d9cb76833c990ac9cd3923c9a8905a8929789ce347c84564d03d" +checksum = "a941429fea7e08bedec25e4f6785b6ffaacc6b755da98df5ef3e7dcf4a124c4f" dependencies = [ "once_cell", "pest", @@ -5808,7 +5792,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "48e4cc64c2ad9ebe670cb8fd69dd50ae301650392e81c05f9bfcb2d5bdbc24b0" dependencies = [ "phf_shared", - "rand", + "rand 0.8.5", ] [[package]] @@ -5821,7 +5805,7 @@ dependencies = [ "phf_shared", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -5835,29 +5819,29 @@ dependencies = [ [[package]] name = "pin-project" -version = "1.1.7" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be57f64e946e500c8ee36ef6331845d40a93055567ec57e8fae13efd33759b95" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.7" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c0f5fad0874fc7abcd4d750e76917eaebbecaa2c20bde22e1dbeeba8beb758c" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] name = "pin-project-lite" -version = "0.2.15" +version = "0.2.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "915a1e146535de9163f3987b8944ed8cf49a18bb0056bcebcdcece385cece4ff" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" [[package]] name = "pin-utils" @@ -5877,9 +5861,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.31" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "953ec861398dccce10c670dfeaf3ec4911ca479e9c02154b3a215178c5f566f2" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" [[package]] name = "plist" @@ -5896,9 +5880,9 @@ dependencies = [ [[package]] name = "plotters" -version = "0.3.7" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5aeb6f403d7a4911efb1e33402027fc44f29b5bf6def3effcc22d7bb75f2b747" +checksum = "a15b6eccb8484002195a3e44fe65a4ce8e93a625797a063735536fd59cb01cf3" dependencies = [ "num-traits", "plotters-backend", @@ -5909,15 +5893,15 @@ dependencies = [ [[package]] name = "plotters-backend" -version = "0.3.7" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df42e13c12958a16b3f7f4386b9ab1f3e7933914ecea48da7139435263a4172a" +checksum = "414cec62c6634ae900ea1c56128dfe87cf63e7caece0852ec76aba307cebadb7" [[package]] name = "plotters-svg" -version = "0.3.7" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51bae2ac328883f7acdfea3d66a7c35751187f870bc81f94563733a154d7a670" +checksum = "81b30686a7d9c3e010b84284bdd26a29f2138574f52f5eb6f794fc0ad924e705" dependencies = [ "plotters-backend", ] @@ -5928,18 +5912,17 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "be97d76faf1bfab666e1375477b23fde79eccf0276e9b63b92a39d676a889ba9" dependencies = [ - "rand", + "rand 0.8.5", ] [[package]] name = "postcard" -version = "1.0.10" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f7f0a8d620d71c457dd1d47df76bb18960378da56af4527aaa10f515eee732e" +checksum = "a55c51ee6c0db07e68448e336cf8ea4131a620edefebf9893e759b2d793420f8" dependencies = [ "cobs", - "embedded-io 0.4.0", - "embedded-io 0.6.1", + "embedded-io", "heapless", "serde", ] @@ -6028,11 +6011,11 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "3.2.0" +version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecf48c7ca261d60b74ab1a7b20da18bede46776b2e55535cb958eb595c5fa7b" +checksum = "6d37c51ca738a55da99dc0c4a34860fd675453b8b36209178c2249bb13651284" dependencies = [ - "toml_edit", + "toml_edit 0.21.1", ] [[package]] @@ -6059,32 +6042,11 @@ dependencies = [ "version_check", ] -[[package]] -name = "proc-macro-error-attr2" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96de42df36bb9bba5542fe9f1a054b8cc87e172759a1868aa05c1f3acc89dfc5" -dependencies = [ - "proc-macro2", - "quote", -] - -[[package]] -name = "proc-macro-error2" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11ec05c52be0a07b08061f7dd003e7d7092e0472bc731b4af7bb1ef876109802" -dependencies = [ - "proc-macro-error-attr2", - "proc-macro2", - "quote", -] - [[package]] name = "proc-macro2" -version = "1.0.89" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f139b0662de085916d1fb67d2b4169d1addddda1919e696f3252b740b629986e" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -6109,7 +6071,7 @@ checksum = "440f724eba9f6996b75d63681b0a92b06947f1457076d503a4d2e2c8f56442b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -6123,10 +6085,10 @@ dependencies = [ "bitflags 2.6.0", "lazy_static", "num-traits", - "rand", - "rand_chacha", + "rand 0.8.5", + "rand_chacha 0.3.1", "rand_xorshift", - "regex-syntax 0.8.5", + "regex-syntax 0.8.4", "rusty-fork", "tempfile", "unarray", @@ -6169,11 +6131,11 @@ dependencies = [ [[package]] name = "publicsuffix" -version = "2.3.0" +version = "2.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f42ea446cab60335f76979ec15e12619a2165b5ae2c12166bef27d283a9fadf" +checksum = "96a8c1bda5ae1af7f99a2962e49df150414a43d62404644d98dd5c3a93d07457" dependencies = [ - "idna 1.0.3", + "idna 0.3.0", "psl-types", ] @@ -6221,9 +6183,9 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.37" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ "proc-macro2", ] @@ -6244,6 +6206,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" @@ -6251,8 +6226,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]] @@ -6262,7 +6247,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]] @@ -6271,7 +6265,16 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom", + "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]] @@ -6280,7 +6283,7 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d25bf25ec5ae4a3f1b92f929810509a2f53d7dca2f50b794ff57e3face536c8f" dependencies = [ - "rand_core", + "rand_core 0.6.4", ] [[package]] @@ -6289,7 +6292,7 @@ version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6f97cdb2a36ed4183de61b2f824cc45c9f1037f28afe0a322e9fff4c108b5aaa" dependencies = [ - "rand_core", + "rand_core 0.6.4", ] [[package]] @@ -6334,9 +6337,9 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.5.7" +version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b6dfecf2c74bce2466cabf93f6664d6998a69eb21e39f4207930065b27b771f" +checksum = "2a908a6e00f1fdd0dfd9c0eb08ce85126f6d8bbda50017e74bc4a4b7d4a926a4" dependencies = [ "bitflags 2.6.0", ] @@ -6349,25 +6352,25 @@ checksum = "20145670ba436b55d91fc92d25e71160fbfbdd57831631c8d7d36377a476f1cb" [[package]] name = "redox_users" -version = "0.4.6" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba009ff324d1fc1b900bd1fdb31564febe58a8ccc8a6fdbb93b543d33b13ca43" +checksum = "bd283d9651eeda4b2a83a43c1c91b266c40fd76ecd39a50a8c630ae69dc72891" dependencies = [ - "getrandom", + "getrandom 0.2.15", "libredox 0.1.3", "thiserror", ] [[package]] name = "regex" -version = "1.11.1" +version = "1.10.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191" +checksum = "4219d74c6b67a3654a9fbebc4b419e22126d13d2f3c4a07ee0cb61ff79a79619" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.9", - "regex-syntax 0.8.5", + "regex-automata 0.4.7", + "regex-syntax 0.8.4", ] [[package]] @@ -6381,13 +6384,13 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.9" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "809e8dc61f6de73b46c85f4c96486310fe304c434cfa43669d7b40f711150908" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.8.5", + "regex-syntax 0.8.4", ] [[package]] @@ -6404,9 +6407,9 @@ checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] name = "regex-syntax" -version = "0.8.5" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" [[package]] name = "rend" @@ -6433,7 +6436,7 @@ dependencies = [ "h2 0.3.26", "http 0.2.12", "http-body 0.4.6", - "hyper 0.14.31", + "hyper 0.14.30", "hyper-rustls 0.24.2", "ipnet", "js-sys", @@ -6448,7 +6451,7 @@ dependencies = [ "serde_json", "serde_urlencoded", "sync_wrapper 0.1.2", - "system-configuration 0.5.1", + "system-configuration", "tokio", "tokio-rustls 0.24.1", "tower-service", @@ -6457,26 +6460,26 @@ dependencies = [ "wasm-bindgen-futures", "web-sys", "webpki-roots", - "winreg", + "winreg 0.50.0", ] [[package]] name = "reqwest" -version = "0.12.9" +version = "0.12.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a77c62af46e79de0a562e1a9849205ffcb7fc1238876e9bd743357570e04046f" +checksum = "c7d6d2a27d57148378eb5e111173f4276ad26340ecc5c49a4a2152167a2d6a37" dependencies = [ "base64 0.22.1", "bytes", "encoding_rs", "futures-core", "futures-util", - "h2 0.4.7", + "h2 0.4.5", "http 1.1.0", "http-body 1.0.1", "http-body-util", - "hyper 1.5.1", - "hyper-rustls 0.27.3", + "hyper 1.4.1", + "hyper-rustls 0.27.2", "hyper-tls", "hyper-util", "ipnet", @@ -6487,12 +6490,12 @@ dependencies = [ "once_cell", "percent-encoding", "pin-project-lite", - "rustls-pemfile 2.2.0", + "rustls-pemfile 2.1.3", "serde", "serde_json", "serde_urlencoded", "sync_wrapper 1.0.1", - "system-configuration 0.6.1", + "system-configuration", "tokio", "tokio-native-tls", "tower-service", @@ -6500,9 +6503,15 @@ dependencies = [ "wasm-bindgen", "wasm-bindgen-futures", "web-sys", - "windows-registry", + "winreg 0.52.0", ] +[[package]] +name = "retain_mut" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4389f1d5789befaf6029ebd9f7dac4af7f7e3d61b69d4f30e2ac02b57e7712b0" + [[package]] name = "revm" version = "14.0.3" @@ -6610,7 +6619,7 @@ checksum = "c17fa4cb658e3583423e915b9f3acc01cceaee1860e33d59ebae66adc3a2dc0d" dependencies = [ "cc", "cfg-if 1.0.0", - "getrandom", + "getrandom 0.2.15", "libc", "spin", "untrusted", @@ -6628,9 +6637,9 @@ dependencies = [ [[package]] name = "rkyv" -version = "0.7.45" +version = "0.7.44" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9008cd6385b9e161d8229e1f6549dd23c3d022f132a2ea37ac3a10ac4935779b" +checksum = "5cba464629b3394fc4dbc6f940ff8f5b4ff5c7aef40f29166fd4ad12acbc99c0" dependencies = [ "bitvec", "bytecheck", @@ -6641,14 +6650,14 @@ dependencies = [ "rkyv_derive", "seahash", "tinyvec", - "uuid 1.11.0", + "uuid 1.10.0", ] [[package]] name = "rkyv_derive" -version = "0.7.45" +version = "0.7.44" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "503d1d27590a2b0a3a4ca4c94755aa2875657196ecbf401a42eff41d7de532c0" +checksum = "a7dddfff8de25e6f62b9d64e6e432bf1c6736c57d20323e15ee10435fbda7c65" dependencies = [ "proc-macro2", "quote", @@ -6735,7 +6744,7 @@ dependencies = [ "parity-scale-codec", "primitive-types", "proptest", - "rand", + "rand 0.8.5", "rlp", "ruint-macro", "serde", @@ -6751,15 +6760,15 @@ checksum = "48fd7bd8a6377e15ad9d42a8ec25371b94ddc67abe7c8b9127bec79bebaaae18" [[package]] name = "rust_decimal" -version = "1.36.0" +version = "1.35.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b082d80e3e3cc52b2ed634388d436fe1f4de6af5786cc2de9ba9737527bdf555" +checksum = "1790d1c4c0ca81211399e0e0af16333276f375209e71a37b67698a373db5b47a" dependencies = [ "arrayvec", "borsh", "bytes", "num-traits", - "rand", + "rand 0.8.5", "rkyv", "serde", "serde_json", @@ -6800,18 +6809,18 @@ dependencies = [ [[package]] name = "rustc_version" -version = "0.4.1" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" +checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ "semver 1.0.23", ] [[package]] name = "rustix" -version = "0.38.41" +version = "0.38.34" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7f649912bc1495e167a6edee79151c84b1bad49748cb4f1f1167f459f6224f6" +checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" dependencies = [ "bitflags 2.6.0", "errno", @@ -6834,13 +6843,13 @@ dependencies = [ [[package]] name = "rustls" -version = "0.23.17" +version = "0.23.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f1a745511c54ba6d4465e8d5dfbd81b45791756de28d4981af70d6dca128f1e" +checksum = "c58f8c84392efc0a126acce10fa59ff7b3d2ac06ab451a33f2741989b806b044" dependencies = [ "once_cell", "rustls-pki-types", - "rustls-webpki 0.102.8", + "rustls-webpki 0.102.6", "subtle", "zeroize", ] @@ -6868,18 +6877,19 @@ dependencies = [ [[package]] name = "rustls-pemfile" -version = "2.2.0" +version = "2.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dce314e5fee3f39953d46bb63bb8a46d40c2f8fb7cc5a3b6cab2bde9721d6e50" +checksum = "196fe16b00e106300d3e45ecfcb764fa292a535d7326a29a5875c579c7417425" dependencies = [ + "base64 0.22.1", "rustls-pki-types", ] [[package]] name = "rustls-pki-types" -version = "1.10.0" +version = "1.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16f1201b3c9a7ee8039bcadc17b7e605e2945b27eee7631788c1bd2b0643674b" +checksum = "fc0a2ce646f8655401bb81e7927b812614bd5d91dbc968696be50603510fcaf0" [[package]] name = "rustls-webpki" @@ -6893,9 +6903,9 @@ dependencies = [ [[package]] name = "rustls-webpki" -version = "0.102.8" +version = "0.102.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64ca1bc8749bd4cf37b5ce386cc146580777b4e8572c7b97baf22c83f444bee9" +checksum = "8e6b52d4fda176fd835fdc55a835d4a89b8499cad995885a21149d5ad62f852e" dependencies = [ "ring", "rustls-pki-types", @@ -6904,9 +6914,9 @@ dependencies = [ [[package]] name = "rustversion" -version = "1.0.18" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e819f2bc632f285be6d7cd36e25940d45b2391dd6d9b939e79de557f7014248" +checksum = "955d28af4278de8121b7ebeb796b6a45735dc01436d898801014aced2773a3d6" [[package]] name = "rusty-fork" @@ -6977,20 +6987,20 @@ dependencies = [ [[package]] name = "scc" -version = "2.2.5" +version = "2.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66b202022bb57c049555430e11fc22fea12909276a80a4c3d368da36ac1d88ed" +checksum = "c478f373151538826ed50feaceeef7095ad435065a48153af789005fd5e44c0d" dependencies = [ "sdd", ] [[package]] name = "schannel" -version = "0.1.27" +version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f29ebaa345f945cec9fbbc532eb307f0fdad8161f281b6369539c8d84876b3d" +checksum = "fbc91545643bcf3a0bbb6569265615222618bdf33ce4ffbbd13c4bbd4c093534" dependencies = [ - "windows-sys 0.59.0", + "windows-sys 0.52.0", ] [[package]] @@ -7049,9 +7059,9 @@ dependencies = [ [[package]] name = "sdd" -version = "3.0.4" +version = "3.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49c1eeaf4b6a87c7479688c6d52b9f1153cedd3c489300564f932b065c6eab95" +checksum = "0495e4577c672de8254beb68d01a9b62d0e8a13c099edecdbedccce3223cd29f" [[package]] name = "seahash" @@ -7079,7 +7089,7 @@ version = "0.29.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9465315bc9d4566e1724f0fffcbcc446268cb522e60f9a27bcded6b19c108113" dependencies = [ - "rand", + "rand 0.8.5", "secp256k1-sys", ] @@ -7116,9 +7126,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.12.1" +version = "2.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa39c7303dc58b5543c94d22c1766b0d31f2ee58306363ea622b10bbc075eaa2" +checksum = "75da29fe9b9b08fe9d6b22b5b4bcbc75d8db3aa31e639aa56bb62e9d46bfceaf" dependencies = [ "core-foundation-sys", "libc", @@ -7144,31 +7154,31 @@ dependencies = [ [[package]] name = "semver-parser" -version = "0.10.3" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9900206b54a3527fdc7b8a938bffd94a568bac4f4aa8113b209df75a09c0dec2" +checksum = "00b0bef5b7f9e0df16536d3961cfb6e84331c065b4066afb39768d0e319411f7" dependencies = [ "pest", ] [[package]] name = "serde" -version = "1.0.215" +version = "1.0.209" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6513c1ad0b11a9376da888e3e0baa0077f1aed55c17f50e7b2397136129fb88f" +checksum = "99fce0ffe7310761ca6bf9faf5115afbc19688edd00171d81b1bb1b116c63e09" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.215" +version = "1.0.209" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad1e866f866923f252f05c889987993144fb74e722403468a4ebd70c3cd756c0" +checksum = "a5831b979fd7b5439637af1752d535ff49f4860c0f341d1baeb6faf0f4242170" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -7182,9 +7192,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.133" +version = "1.0.127" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7fceb2473b9166b2294ef05efcb65a3db80803f0b03ef86a5fc88a2b85ee377" +checksum = "8043c06d9f82bd7271361ed64f415fe5e12a77fdb52e573e7f06a516dea329ad" dependencies = [ "indexmap 2.6.0", "itoa", @@ -7193,6 +7203,17 @@ dependencies = [ "serde", ] +[[package]] +name = "serde_qs" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7715380eec75f029a4ef7de39a9200e0a63823176b759d055b613f5a87df6a6" +dependencies = [ + "percent-encoding", + "serde", + "thiserror", +] + [[package]] name = "serde_repr" version = "0.1.19" @@ -7201,14 +7222,14 @@ checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] name = "serde_spanned" -version = "0.6.8" +version = "0.6.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87607cb1398ed59d48732e575a4c28a7a8ebf2454b964fe3f224f2afc07909e1" +checksum = "eb5b1b31579f3811bf615c144393417496f152e12ac8b7663bf664f4a815306d" dependencies = [ "serde", ] @@ -7227,9 +7248,9 @@ dependencies = [ [[package]] name = "serde_with" -version = "3.11.0" +version = "3.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e28bdad6db2b8340e449f7108f020b3b092e8583a9e3fb82713e1d4e71fe817" +checksum = "69cecfa94848272156ea67b2b1a53f20fc7bc638c4a46d2f8abde08f05f4b857" dependencies = [ "base64 0.22.1", "chrono", @@ -7245,14 +7266,14 @@ dependencies = [ [[package]] name = "serde_with_macros" -version = "3.11.0" +version = "3.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d846214a9854ef724f3da161b426242d8de7c1fc7de2f89bb1efcb154dca79d" +checksum = "a8fee4991ef4f274617a51ad4af30519438dacb2f56ac773b08a1922ff743350" dependencies = [ "darling 0.20.10", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -7270,9 +7291,9 @@ dependencies = [ [[package]] name = "serial_test" -version = "3.2.0" +version = "3.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b258109f244e1d6891bf1053a55d63a5cd4f8f4c30cf9a1280989f80e7a1fa9" +checksum = "4b4b487fe2acf240a021cf57c6b2b4903b1e78ca0ecd862a71b71d2a51fed77d" dependencies = [ "futures", "log", @@ -7284,13 +7305,24 @@ dependencies = [ [[package]] name = "serial_test_derive" -version = "3.2.0" +version = "3.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d69265a08751de7844521fd15003ae0a888e035773ba05695c5c759a6f89eef" +checksum = "82fe9db325bcef1fbcde82e078a5cc4efdf787e96b3b9cf45b50b529f2083d67" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", +] + +[[package]] +name = "sha1" +version = "0.10.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" +dependencies = [ + "cfg-if 1.0.0", + "cpufeatures", + "digest 0.10.7", ] [[package]] @@ -7399,14 +7431,14 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" dependencies = [ "digest 0.10.7", - "rand_core", + "rand_core 0.6.4", ] [[package]] name = "simdutf8" -version = "0.1.5" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3a9fe34e3e7a50316060351f37187a3f546bce95496156754b601a5fa71b76e" +checksum = "f27f6278552951f1f2b8cf9da965d10969b2efdea95a6ec47987ab46edfe263a" [[package]] name = "similar" @@ -7536,9 +7568,9 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" [[package]] name = "str_indices" -version = "0.4.4" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d08889ec5408683408db66ad89e0e1f93dff55c73a4ccc71c427d5b277ee47e6" +checksum = "e9557cb6521e8d009c51a8666f09356f4b817ba9ba0981a305bd86aee47bd35c" [[package]] name = "strsim" @@ -7599,7 +7631,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -7612,7 +7644,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -7624,7 +7656,7 @@ dependencies = [ "byteorder", "crunchy", "lazy_static", - "rand", + "rand 0.8.5", "rustc-hex", ] @@ -7659,7 +7691,7 @@ dependencies = [ "fuel-etk-asm", "fuel-etk-ops", "fuel-vm", - "gimli", + "gimli 0.31.1", "graph-cycles", "hashbrown 0.14.5", "hex", @@ -7741,7 +7773,7 @@ dependencies = [ "itertools 0.13.0", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -7768,7 +7800,7 @@ dependencies = [ "pretty_assertions", "proc-macro2", "quote", - "rand", + "rand 0.8.5", "rayon", "rayon-cond", "regex", @@ -7783,12 +7815,12 @@ dependencies = [ "sway-types", "sway-utils", "swayfmt", - "syn 2.0.87", + "syn 2.0.76", "tempfile", "thiserror", "tikv-jemallocator", "tokio", - "toml_edit", + "toml_edit 0.22.20", "tower 0.4.13", "tower-lsp", "tracing", @@ -7802,7 +7834,7 @@ dependencies = [ "assert-json-diff", "futures", "lsp-types", - "rand", + "rand 0.8.5", "serde", "serde_json", "tokio", @@ -7891,15 +7923,27 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.87" +version = "2.0.76" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25aa4ce346d03a6dcd68dd8b4010bcb74e54e62c90c573f394c46eae99aba32d" +checksum = "578e081a14e0cefc3279b0472138c513f37b41a08d5a3cca9b6e4e8ceb6cd525" dependencies = [ "proc-macro2", "quote", "unicode-ident", ] +[[package]] +name = "syn_derive" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1329189c02ff984e9736652b1631330da25eaa6bc639089ed4915d25446cbe7b" +dependencies = [ + "proc-macro-error", + "proc-macro2", + "quote", + "syn 2.0.76", +] + [[package]] name = "sync_wrapper" version = "0.1.2" @@ -7911,9 +7955,6 @@ name = "sync_wrapper" version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a7065abeca94b6a8a577f9bd45aa0867a2238b74e8eb67cf10d492bc39351394" -dependencies = [ - "futures-core", -] [[package]] name = "synstructure" @@ -7935,7 +7976,7 @@ checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -7952,7 +7993,7 @@ dependencies = [ "once_cell", "onig", "plist", - "regex-syntax 0.8.5", + "regex-syntax 0.8.4", "serde", "serde_derive", "serde_json", @@ -7984,18 +8025,7 @@ checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" dependencies = [ "bitflags 1.3.2", "core-foundation", - "system-configuration-sys 0.5.0", -] - -[[package]] -name = "system-configuration" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b" -dependencies = [ - "bitflags 2.6.0", - "core-foundation", - "system-configuration-sys 0.6.0", + "system-configuration-sys", ] [[package]] @@ -8008,21 +8038,11 @@ dependencies = [ "libc", ] -[[package]] -name = "system-configuration-sys" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4" -dependencies = [ - "core-foundation-sys", - "libc", -] - [[package]] name = "tai64" -version = "4.1.0" +version = "4.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "014639506e4f425c78e823eabf56e71c093f940ae55b43e58f682e7bc2f5887a" +checksum = "ed7401421025f4132e6c1f7af5e7f8287383969f36e6628016cd509b8d3da9dc" dependencies = [ "serde", ] @@ -8056,9 +8076,9 @@ dependencies = [ [[package]] name = "tar" -version = "0.4.43" +version = "0.4.41" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c65998313f8e17d0d553d28f91a0df93e4dbbbf770279c7bc21ca0f09ea1a1f6" +checksum = "cb797dad5fb5b76fcf519e702f4a589483b5ef06567f160c392832c1f5e44909" dependencies = [ "filetime", "libc", @@ -8067,12 +8087,12 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.14.0" +version = "3.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28cce251fcbc87fac86a866eeb0d6c2d536fc16d06f184bb61aeae11aa4cee0c" +checksum = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64" dependencies = [ "cfg-if 1.0.0", - "fastrand", + "fastrand 2.1.0", "once_cell", "rustix", "windows-sys 0.59.0", @@ -8111,12 +8131,12 @@ dependencies = [ [[package]] name = "terminal_size" -version = "0.4.0" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f599bd7ca042cfdf8f4512b277c02ba102247820f9d9d4a9f521f496751a6ef" +checksum = "21bebf2b7c9e0a515f6e0f8c51dc0f8e4696391e6f1ff30379559f8365fb0df7" dependencies = [ "rustix", - "windows-sys 0.59.0", + "windows-sys 0.48.0", ] [[package]] @@ -8167,7 +8187,7 @@ dependencies = [ "libtest-mimic", "normalize-path", "prettydiff", - "rand", + "rand 0.8.5", "regex", "revm", "serde_json", @@ -8211,22 +8231,22 @@ dependencies = [ [[package]] name = "thiserror" -version = "1.0.69" +version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52" +checksum = "c0342370b38b6a11b6cc11d6a805569958d54cfa061a29969c3b5ce2ea405724" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.69" +version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" +checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -8309,7 +8329,7 @@ dependencies = [ "hmac 0.12.1", "once_cell", "pbkdf2 0.11.0", - "rand", + "rand 0.8.5", "rustc-hash 1.1.0", "sha2 0.10.8", "thiserror", @@ -8327,16 +8347,6 @@ dependencies = [ "crunchy", ] -[[package]] -name = "tinystr" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9117f5d4db391c1cf6927e7bea3db74b9a1c1add8f7eda9ffd5364f40f57b82f" -dependencies = [ - "displaydoc", - "zerovec", -] - [[package]] name = "tinytemplate" version = "1.2.1" @@ -8364,9 +8374,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.41.1" +version = "1.39.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22cfb5bee7a6a52939ca9224d6ac897bb669134078daa8735560897f69de4d33" +checksum = "daa4fb1bc778bd6f04cbfc4bb2d06a7396a8f299dc33ea1900cedaa316f467b1" dependencies = [ "backtrace", "bytes", @@ -8398,7 +8408,7 @@ checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -8427,16 +8437,16 @@ version = "0.26.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0c7bc40d0e5a97695bb96e27995cd3a08538541b0a846f65bba7a359f36700d4" dependencies = [ - "rustls 0.23.17", + "rustls 0.23.12", "rustls-pki-types", "tokio", ] [[package]] name = "tokio-stream" -version = "0.1.16" +version = "0.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f4e6ce100d0eb49a2734f8c0812bcd324cf357d21810932c5df6b96ef2b86f1" +checksum = "267ac89e0bec6e691e5813911606935d77c476ff49024f98abcea3e7b15e37af" dependencies = [ "futures-core", "pin-project-lite", @@ -8445,9 +8455,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.12" +version = "0.7.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61e7c3654c13bcd040d4a03abee2c75b1d14a37b423cf5a813ceae1cc903ec6a" +checksum = "9cf6b47b3771c49ac75ad09a6162f53ad4b8088b76ac60e8ec1455b31a189fe1" dependencies = [ "bytes", "futures-core", @@ -8474,7 +8484,7 @@ dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit", + "toml_edit 0.22.20", ] [[package]] @@ -8488,15 +8498,26 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.22.22" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1" +dependencies = [ + "indexmap 2.6.0", + "toml_datetime", + "winnow 0.5.40", +] + +[[package]] +name = "toml_edit" +version = "0.22.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ae48d6208a266e853d946088ed816055e556cc6028c5e8e2b84d9fa5dd7c7f5" +checksum = "583c44c02ad26b0c3f3066fe629275e50627026c51ac2e595cca4c230ce1ce1d" dependencies = [ "indexmap 2.6.0", "serde", "serde_spanned", "toml_datetime", - "winnow", + "winnow 0.6.18", ] [[package]] @@ -8515,6 +8536,7 @@ dependencies = [ "futures-util", "pin-project", "pin-project-lite", + "tokio", "tower-layer", "tower-service", ] @@ -8570,7 +8592,7 @@ checksum = "84fd902d4e0b9a4b27f2f440108dc034e1758628a9b702f8ec61ad66355422fa" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -8598,7 +8620,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -8671,7 +8693,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "04659ddb06c87d233c566112c1c9c5b9e98256d9af50ec3bc9c8327f873a7568" dependencies = [ "quote", - "syn 2.0.87", + "syn 2.0.76", ] [[package]] @@ -8715,9 +8737,9 @@ checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" [[package]] name = "ucd-trie" -version = "0.1.7" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2896d95c02a80c6d6a5d6e953d479f5ddf2dfdb6a244441010e373ac0fb88971" +checksum = "ed646292ffc8188ef8ea4d1e0e0150fb15a5c2e12ad9b8fc191ae7a8a7f3c4b9" [[package]] name = "uint" @@ -8739,21 +8761,24 @@ checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" [[package]] name = "unicase" -version = "2.8.0" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7e51b68083f157f853b6379db119d1c1be0e6e4dec98101079dec41f6f5cf6df" +checksum = "f7d2d4dafb69621809a81864c9c1b864479e1235c0dd4e199924b9742439ed89" +dependencies = [ + "version_check", +] [[package]] name = "unicode-bidi" -version = "0.3.17" +version = "0.3.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ab17db44d7388991a428b2ee655ce0c212e862eff1768a455c58f9aad6e7893" +checksum = "08f95100a766bf4f8f28f90d77e0a5461bbdb219042e7679bebe79004fed8d75" [[package]] name = "unicode-ident" -version = "1.0.14" +version = "1.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adb9e6ca4f869e1180728b7950e35922a7fc6397f7b641499e8f3ef06e50dc83" +checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" [[package]] name = "unicode-linebreak" @@ -8763,30 +8788,30 @@ checksum = "3b09c83c3c29d37506a3e260c08c03743a6bb66a9cd432c6934ab501a190571f" [[package]] name = "unicode-normalization" -version = "0.1.24" +version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5033c97c4262335cded6d6fc3e5c18ab755e1a3dc96376350f3d8e9f009ad956" +checksum = "a56d1686db2308d901306f92a263857ef59ea39678a5458e7cb17f01415101f5" dependencies = [ "tinyvec", ] [[package]] name = "unicode-segmentation" -version = "1.12.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6ccf251212114b54433ec949fd6a7841275f9ada20dddd2f29e9ceea4501493" +checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" [[package]] name = "unicode-width" -version = "0.1.14" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dd6e30e90baa6f72411720665d41d89b9a3d039dc45b8faea1ddd07f617f6af" +checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d" [[package]] name = "unicode-xid" -version = "0.2.6" +version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebc1c04c71510c7f702b52b7c350734c9ff1295c464a03335b00bb84fc54f853" +checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" [[package]] name = "unicode_categories" @@ -8829,12 +8854,12 @@ checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" [[package]] name = "url" -version = "2.5.3" +version = "2.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d157f1b96d14500ffdc1f10ba712e780825526c03d9a49b4d0324b0d9113ada" +checksum = "22784dbdf76fdde8af1aeda5622b546b422b6fc585325248a2bf9f5e41e94d6c" dependencies = [ "form_urlencoded", - "idna 1.0.3", + "idna 0.5.0", "percent-encoding", "serde", ] @@ -8845,24 +8870,12 @@ version = "2.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" -[[package]] -name = "utf16_iter" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8232dd3cdaed5356e0f716d285e4b40b932ac434100fe9b7e0e8e935b9e6246" - [[package]] name = "utf8-width" version = "0.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "86bd8d4e895da8537e5315b8254664e6b769c4ff3db18321b297a1e7004392e3" -[[package]] -name = "utf8_iter" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be" - [[package]] name = "utf8parse" version = "0.2.2" @@ -8875,15 +8888,15 @@ version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" dependencies = [ - "getrandom", + "getrandom 0.2.15", "serde", ] [[package]] name = "uuid" -version = "1.11.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8c5f0a0af699448548ad1a2fbf920fb4bee257eae39953ba95cb84891a0446a" +checksum = "81dfa00651efa65069b0b6b651f4aaa31ba9e3c3ce0137aaad053604ee7e0314" [[package]] name = "valuable" @@ -8974,6 +8987,12 @@ dependencies = [ "libc", ] +[[package]] +name = "waker-fn" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "317211a0dc0ceedd78fb2ca9a44aed3d7b9b26f81870d485c07122b4350673b7" + [[package]] name = "walkdir" version = "2.5.0" @@ -8993,6 +9012,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" @@ -9007,9 +9032,9 @@ checksum = "b8dad83b4f25e74f184f64c43b150b91efe7647395b42289f38e50566d82855b" [[package]] name = "wasm-bindgen" -version = "0.2.95" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "128d1e363af62632b8eb57219c8fd7877144af57558fb2ef0368d0087bddeb2e" +checksum = "a82edfc16a6c469f5f44dc7b571814045d60404b55a0ee849f9bcfa2e63dd9b5" dependencies = [ "cfg-if 1.0.0", "once_cell", @@ -9018,24 +9043,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.95" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb6dd4d3ca0ddffd1dd1c9c04f94b868c37ff5fac97c30b97cff2d74fce3a358" +checksum = "9de396da306523044d3302746f1208fa71d7532227f15e347e2d93e4145dd77b" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.45" +version = "0.4.43" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7ec4f8827a71586374db3e87abdb5a2bb3a15afed140221307c3ec06b1f63b" +checksum = "61e9300f63a621e96ed275155c108eb6f843b6a26d053f122ab69724559dc8ed" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -9045,9 +9070,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.95" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e79384be7f8f5a9dd5d7167216f022090cf1f9ec128e6e6a482a2cb5c5422c56" +checksum = "585c4c91a46b072c92e908d99cb1dcdf95c5218eeb6f3bf1efa991ee7a68cccf" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -9055,28 +9080,28 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.95" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26c6ab57572f7a24a4985830b120de1594465e5d500f24afe89e16b4e833ef68" +checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", + "syn 2.0.76", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.95" +version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65fc09f10666a9f147042251e0dda9c18f166ff7de300607007e96bdebc1068d" +checksum = "c62a0a307cb4a311d3a07867860911ca130c3494e8c2719593806c08bc5d0484" [[package]] name = "web-sys" -version = "0.3.72" +version = "0.3.70" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6488b90108c040df0fe62fa815cbdee25124641df01814dd7282749234c6112" +checksum = "26fdeaafd9bd129f65e7c031593c24d62186301e0c72c8978fa1678be7d532c0" dependencies = [ "js-sys", "wasm-bindgen", @@ -9090,9 +9115,9 @@ checksum = "5f20c57d8d7db6d3b86154206ae5d8fba62dd39573114de97c2cb0578251f8e1" [[package]] name = "which" -version = "6.0.3" +version = "6.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4ee928febd44d98f2f459a4a79bd4d928591333a494a10a868418ac1b39cf1f" +checksum = "3d9c5ed668ee1f17edb3b627225343d210006a90bb1e3745ce1f30b1fb115075" dependencies = [ "either", "home", @@ -9102,11 +9127,11 @@ dependencies = [ [[package]] name = "whoami" -version = "1.5.2" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "372d5b87f58ec45c384ba03563b03544dc5fadc3983e434b286913f5b4a9bb6d" +checksum = "a44ab49fad634e88f55bf8f9bb3abd2f27d7204172a112c7c9987e01c1c94ea9" dependencies = [ - "redox_syscall 0.5.7", + "redox_syscall 0.4.1", "wasite", "web-sys", ] @@ -9151,36 +9176,6 @@ dependencies = [ "windows-targets 0.52.6", ] -[[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" @@ -9331,9 +9326,18 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.6.20" +version = "0.5.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +dependencies = [ + "memchr", +] + +[[package]] +name = "winnow" +version = "0.6.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "36c1fec1a2bb5866f07c25f68c26e565c4c200aebb96d7e55710c19d3e8ac49b" +checksum = "68a9bda4691f099d435ad181000724da8e5899daa10713c2d432552b9ccd3a6f" dependencies = [ "memchr", ] @@ -9349,22 +9353,42 @@ dependencies = [ ] [[package]] -name = "winsafe" -version = "0.0.19" +name = "winreg" +version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d135d17ab770252ad95e9a872d365cf3090e3be864a34ab46f48555993efc904" +checksum = "a277a57398d4bfa075df44f501a17cfdf8542d224f0d36095a2adc7aee4ef0a5" +dependencies = [ + "cfg-if 1.0.0", + "windows-sys 0.48.0", +] [[package]] -name = "write16" -version = "1.0.0" +name = "winsafe" +version = "0.0.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1890f4022759daae28ed4fe62859b1236caebfc61ede2f63ed4e695f3f6d936" +checksum = "d135d17ab770252ad95e9a872d365cf3090e3be864a34ab46f48555993efc904" [[package]] -name = "writeable" -version = "0.5.5" +name = "wiremock" +version = "0.5.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e9df38ee2d2c3c5948ea468a8406ff0db0b29ae1ffde1bcf20ef305bcc95c51" +checksum = "13a3a53eaf34f390dd30d7b1b078287dd05df2aa2e21a589ccb80f5c7253c2e9" +dependencies = [ + "assert-json-diff", + "async-trait", + "base64 0.21.7", + "deadpool", + "futures", + "futures-timer", + "http-types", + "hyper 0.14.30", + "log", + "once_cell", + "regex", + "serde", + "serde_json", + "tokio", +] [[package]] name = "wyz" @@ -9419,30 +9443,6 @@ version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cfe53a6657fd280eaa890a3bc59152892ffa3e30101319d168b781ed6529b049" -[[package]] -name = "yoke" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c5b1314b079b0930c31e3af543d8ee1757b1951ae1e1565ec704403a7240ca5" -dependencies = [ - "serde", - "stable_deref_trait", - "yoke-derive", - "zerofrom", -] - -[[package]] -name = "yoke-derive" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28cc31741b18cb6f1d5ff12f5b7523e3d6eb0852bbbad19d73905511d9849b95" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.87", - "synstructure 0.13.1", -] - [[package]] name = "zerocopy" version = "0.7.35" @@ -9461,28 +9461,7 @@ checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", -] - -[[package]] -name = "zerofrom" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91ec111ce797d0e0784a1116d0ddcdbea84322cd79e5d5ad173daeba4f93ab55" -dependencies = [ - "zerofrom-derive", -] - -[[package]] -name = "zerofrom-derive" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ea7b4a3637ea8669cedf0f1fd5c286a17f3de97b8dd5a70a6c167a1730e63a5" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.87", - "synstructure 0.13.1", + "syn 2.0.76", ] [[package]] @@ -9502,27 +9481,5 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.87", -] - -[[package]] -name = "zerovec" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aa2b893d79df23bfb12d5461018d408ea19dfafe76c2c7ef6d4eba614f8ff079" -dependencies = [ - "yoke", - "zerofrom", - "zerovec-derive", -] - -[[package]] -name = "zerovec-derive" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6eafa6dfb17584ea3e2bd6e76e0cc15ad7af12b09abdd1ca55961bed9b1063c6" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.87", + "syn 2.0.76", ] diff --git a/Cargo.toml b/Cargo.toml index 402b7679c42..d185bae3f3b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,6 +9,7 @@ members = [ "forc-plugins/forc-doc", "forc-plugins/forc-fmt", "forc-plugins/forc-lsp", + "forc-plugins/forc-node", "forc-plugins/forc-tx", "forc-test", "forc-tracing", @@ -200,6 +201,7 @@ serde_json = "1.0" serde_with = "3.3" serde_yaml = "0.9" serial_test = "3.0" +sha1 = "0.10" sha2 = "0.10" sha3 = "0.10" shellfish = "0.9" diff --git a/forc-plugins/forc-node/Cargo.toml b/forc-plugins/forc-node/Cargo.toml new file mode 100644 index 00000000000..5f8b6762a45 --- /dev/null +++ b/forc-plugins/forc-node/Cargo.toml @@ -0,0 +1,27 @@ +[package] +name = "forc-node" +version = "0.66.4" +edition.workspace = true +authors.workspace = true +homepage.workspace = true +license.workspace = true +repository.workspace = true + +[dependencies] +anyhow.workspace = true +clap = { workspace = true, features = ["derive", "string"] } +dialoguer.workspace = true +forc-tracing.workspace = true +forc-util.workspace = true +include_dir.workspace = true +reqwest = { workspace = true, features = ["json"] } +semver.workspace = true +serde.workspace = true +serde_json.workspace = true +sha1.workspace = true +tokio = { workspace = true, features = ["macros", "signal", "rt-multi-thread"] } + +[dev-dependencies] +tempfile.workspace = true +tokio = { workspace = true, features = ["full"] } +wiremock = "0.5" diff --git a/forc-plugins/forc-node/src/chain_config.rs b/forc-plugins/forc-node/src/chain_config.rs new file mode 100644 index 00000000000..bfbf91e6927 --- /dev/null +++ b/forc-plugins/forc-node/src/chain_config.rs @@ -0,0 +1,577 @@ +use crate::{ + consts::{ + CHAIN_CONFIG_REPO_NAME, CONFIG_FOLDER, IGNITION_CONFIG_FOLDER_NAME, + LOCAL_CONFIG_FOLDER_NAME, TESTNET_CONFIG_FOLDER_NAME, + }, + util::ask_user_yes_no_question, +}; +use anyhow::{bail, Result}; +use forc_tracing::{println_action_green, println_warning}; +use forc_util::user_forc_directory; +use serde::{Deserialize, Serialize}; +use sha1::{Digest, Sha1}; +use std::{ + collections::{HashMap, HashSet}, + fmt::Display, + fs, + path::PathBuf, +}; + +/// Different chain configuration options. +#[derive(PartialEq, Eq, PartialOrd, Ord, Debug)] +pub enum ChainConfig { + Local, + Testnet, + Ignition, +} + +impl Display for ChainConfig { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + match self { + ChainConfig::Local => write!(f, "local"), + ChainConfig::Testnet => write!(f, "testnet"), + ChainConfig::Ignition => write!(f, "ignition"), + } + } +} + +impl From for PathBuf { + fn from(value: ChainConfig) -> Self { + let folder_name = match value { + ChainConfig::Local => LOCAL_CONFIG_FOLDER_NAME, + ChainConfig::Testnet => TESTNET_CONFIG_FOLDER_NAME, + ChainConfig::Ignition => IGNITION_CONFIG_FOLDER_NAME, + }; + user_forc_directory().join(CONFIG_FOLDER).join(folder_name) + } +} + +/// A github api, content query response. +/// Mainly used for fetching a download url and hash for configuration files. +#[derive(Serialize, Deserialize, Debug)] +struct GithubContentDetails { + name: String, + sha: String, + download_url: Option, + #[serde(rename = "type")] + content_type: String, +} + +/// `ConfigFetcher` is responsible for github api integration related to the +/// configuration operations. +/// Basically checks remote hash of the corresponding chain configuration. +/// If there is a mismatch between local and remote instance, overrides the +/// local instance with remote changes for testnet and mainnet configurations. +/// +/// For local chain configuration, we only check for existence of it locally. +/// If the local chain configuration is missing in user's local, +/// `ConfigFetcher` fetches it but remote updates are not tracked for it. +pub struct ConfigFetcher { + client: reqwest::Client, + base_url: String, + config_vault: PathBuf, +} + +impl ConfigFetcher { + /// Creates a new fetcher to interact with github. + /// By default user's chain configuration vault is at: `~/.forc/chainspecs` + pub fn new() -> Self { + Self { + client: reqwest::Client::new(), + base_url: "https://api.github.com".to_string(), + config_vault: user_forc_directory().join(CONFIG_FOLDER), + } + } + + #[cfg(test)] + /// Override the base url, to be used in tests. + pub fn with_base_url(base_url: String) -> Self { + Self { + client: reqwest::Client::new(), + base_url, + config_vault: user_forc_directory().join(CONFIG_FOLDER), + } + } + + #[cfg(test)] + pub fn with_test_config(base_url: String, config_vault: PathBuf) -> Self { + Self { + client: reqwest::Client::new(), + base_url, + config_vault, + } + } + + fn get_base_url(&self) -> &str { + return &self.base_url; + } + + fn build_api_endpoint(&self, folder_name: &str) -> String { + format!( + "{}/repos/FuelLabs/{}/contents/{}", + self.get_base_url(), + CHAIN_CONFIG_REPO_NAME, + folder_name, + ) + } + + /// Fetches contents from github to get hashes and download urls for + /// contents of the remote configuration repo at: + /// https://github.com/FuelLabs/chain-configuration/ + async fn check_github_files( + &self, + conf: &ChainConfig, + ) -> anyhow::Result> { + let folder_name = match conf { + ChainConfig::Local => LOCAL_CONFIG_FOLDER_NAME, + ChainConfig::Testnet => TESTNET_CONFIG_FOLDER_NAME, + ChainConfig::Ignition => IGNITION_CONFIG_FOLDER_NAME, + }; + let api_endpoint = self.build_api_endpoint(folder_name); + + let response = self + .client + .get(&api_endpoint) + .header("User-Agent", "forc-node") + .send() + .await?; + + if !response.status().is_success() { + bail!("failed to fetch updates from github") + } + + let contents: Vec = response.json().await?; + Ok(contents) + } + + /// Calculates the hash for the local configuration instance. + /// The hash calculation is based on github's hash calculation to match the + /// github api response. + fn check_local_files(&self, conf: &ChainConfig) -> Result>> { + let folder_name = match conf { + ChainConfig::Local => bail!("Local configuration should not be checked"), + ChainConfig::Testnet => TESTNET_CONFIG_FOLDER_NAME, + ChainConfig::Ignition => IGNITION_CONFIG_FOLDER_NAME, + }; + + let folder_path = self.config_vault.join(folder_name); + + if !folder_path.exists() { + return Ok(None); + } + + let mut files = HashMap::new(); + for entry in std::fs::read_dir(&folder_path)? { + let entry = entry?; + if entry.path().is_file() { + let content = std::fs::read(entry.path())?; + // Calculate SHA1 the same way github does + let mut hasher = Sha1::new(); + hasher.update(b"blob "); + hasher.update(content.len().to_string().as_bytes()); + hasher.update([0]); + hasher.update(&content); + let sha = format!("{:x}", hasher.finalize()); + + let name = entry.file_name().into_string().unwrap(); + files.insert(name, sha); + } + } + + Ok(Some(files)) + } + + /// Checks if a fetch is required by comparing the hashes of individual files + /// of the given chain config in the local instance to the one in github by + /// utilizing the github content abi. + pub async fn check_fetch_required(&self, conf: &ChainConfig) -> anyhow::Result { + if *conf == ChainConfig::Local { + return Ok(false); + } + + let local_files = match self.check_local_files(conf)? { + Some(files) => files, + None => return Ok(true), // No local files, need to fetch + }; + + let github_files = self.check_github_files(conf).await?; + + // Compare files + for github_file in &github_files { + if github_file.content_type == "file" { + match local_files.get(&github_file.name) { + Some(local_sha) if local_sha == &github_file.sha => continue, + _ => return Ok(true), // SHA mismatch or file doesn't exist locally + } + } + } + + // Also check if we have any extra files locally that aren't on GitHub + let github_filenames: HashSet<_> = github_files + .iter() + .filter(|f| f.content_type == "file") + .map(|f| &f.name) + .collect(); + + let local_filenames: HashSet<_> = local_files.keys().collect(); + + if local_filenames != github_filenames { + return Ok(true); + } + + Ok(false) + } + + /// Download the chain config for given mode. Fetches the corresponding + /// directory from: https://github.com/FuelLabs/chain-configuration/. + pub async fn download_config(&self, conf: &ChainConfig) -> anyhow::Result<()> { + let folder_name = match conf { + ChainConfig::Local => LOCAL_CONFIG_FOLDER_NAME, + ChainConfig::Testnet => TESTNET_CONFIG_FOLDER_NAME, + ChainConfig::Ignition => IGNITION_CONFIG_FOLDER_NAME, + }; + + let api_endpoint = format!( + "https://api.github.com/repos/FuelLabs/{}/contents/{}", + CHAIN_CONFIG_REPO_NAME, folder_name, + ); + + let contents = self.fetch_folder_contents(&api_endpoint).await?; + + // Create config directory if it doesn't exist + let config_dir = user_forc_directory().join(CONFIG_FOLDER); + let target_dir = config_dir.join(folder_name); + fs::create_dir_all(&target_dir)?; + + // Download each file + for item in contents { + if item.content_type == "file" { + if let Some(download_url) = item.download_url { + let file_path = target_dir.join(&item.name); + + let response = self.client.get(&download_url).send().await?; + + if !response.status().is_success() { + bail!("Failed to download file: {}", item.name); + } + + let content = response.bytes().await?; + fs::write(file_path, content)?; + } + } + } + + Ok(()) + } + + /// Helper function to fetch folder contents from github. + async fn fetch_folder_contents(&self, url: &str) -> anyhow::Result> { + let response = self + .client + .get(url) + .header("User-Agent", "forc-node") + .send() + .await?; + + if !response.status().is_success() { + bail!("failed to fetch contents from github"); + } + + Ok(response.json().await?) + } +} + +/// Local configuration is validated based on its existance. Meaning that if +/// the configuration exists in user's local it is validated. If it is missing +/// the configuration files are fetched from remote. +async fn validate_local_chainconfig(fetcher: &ConfigFetcher) -> anyhow::Result<()> { + let user_conf_dir = user_forc_directory().join(CONFIG_FOLDER); + let local_conf_dir = user_conf_dir.join(LOCAL_CONFIG_FOLDER_NAME); + if !local_conf_dir.exists() { + println_warning(&format!( + "Local node configuration files are missing at {}", + local_conf_dir.display() + )); + // Ask user if they want to update the chain config. + let update = ask_user_yes_no_question("Would you like to download network configuration?")?; + if update { + fetcher.download_config(&ChainConfig::Local).await?; + } else { + bail!( + "Missing local network configuration, create one at {}", + local_conf_dir.display() + ); + } + } + Ok(()) +} + +/// Testnet and mainnet chain configurations are validated against the remote +/// versions from github. If local files exists for these configurations, hash +/// values are collected from remote, and compared to find out if there any +/// changes introduced in remote. If there is the chain configuration is +/// fetched again to ensure, the bootstrapped node can sync with the rest of +/// the network without any issues related to a different chain configuration. +async fn validate_remote_chainconfig( + fetcher: &ConfigFetcher, + conf: &ChainConfig, +) -> anyhow::Result<()> { + // For testnet and mainnet configs, we need to check online. + println_action_green("Checking", "for network configuration updates."); + + if fetcher.check_fetch_required(&conf).await? { + println_warning(&format!( + "A network configuration update detected for {}, this might create problems while syncing with rest of the network", + conf + )); + // Ask user if they want to update the chain config. + let update = ask_user_yes_no_question("Would you like to update network configuration?")?; + if update { + println_action_green("Updating", &format!("configuration files for {conf}",)); + fetcher.download_config(&conf).await?; + println_action_green( + "Finished", + &format!("updating configuration files for {conf}",), + ); + } + } else { + println_action_green(&format!("{conf}"), "is up-to-date."); + } + Ok(()) +} + +/// Check local state of the configuration file in the vault (if they exists) +/// and compare them to the remote one in github. If a change is detected asks +/// user if they want to update, and does the update for them. +pub async fn check_and_update_chain_config(conf: ChainConfig) -> anyhow::Result<()> { + let fetcher = ConfigFetcher::new(); + match conf { + ChainConfig::Local => validate_local_chainconfig(&fetcher).await?, + remote_config => validate_remote_chainconfig(&fetcher, &remote_config).await?, + } + Ok(()) +} + +#[cfg(test)] +mod tests { + use super::*; + use tempfile::TempDir; + use wiremock::{ + matchers::{method, path}, + Mock, MockServer, ResponseTemplate, + }; + + // Helper function to create dummy github response + fn create_github_response(files: &[(&str, &str)]) -> Vec { + files + .iter() + .map(|(name, content)| { + let mut hasher = Sha1::new(); + hasher.update(b"blob "); + hasher.update(content.len().to_string().as_bytes()); + hasher.update([0]); + hasher.update(content.as_bytes()); + let sha = format!("{:x}", hasher.finalize()); + + GithubContentDetails { + name: name.to_string(), + sha, + download_url: Some(format!("https://raw.githubusercontent.com/test/{}", name)), + content_type: "file".to_string(), + } + }) + .collect() + } + + #[tokio::test] + async fn test_fetch_not_required_when_files_match() { + let mock_server = MockServer::start().await; + let test_files = [ + ("config.json", "test config content"), + ("metadata.json", "test metadata content"), + ]; + + // Create test directory and files + let test_dir = TempDir::new().unwrap(); + let config_path = test_dir.path().to_path_buf(); + let test_folder = config_path.join(TESTNET_CONFIG_FOLDER_NAME); + fs::create_dir_all(&test_folder).unwrap(); + + for (name, content) in &test_files { + fs::write(test_folder.join(name), content).unwrap(); + } + + // Setup mock response + let github_response = create_github_response(&test_files); + Mock::given(method("GET")) + .and(path(format!( + "/repos/FuelLabs/{}/contents/{}", + CHAIN_CONFIG_REPO_NAME, TESTNET_CONFIG_FOLDER_NAME + ))) + .respond_with(ResponseTemplate::new(200).set_body_json(&github_response)) + .mount(&mock_server) + .await; + + let fetcher = ConfigFetcher::with_test_config(mock_server.uri(), config_path); + + let needs_fetch = fetcher + .check_fetch_required(&ChainConfig::Testnet) + .await + .unwrap(); + + assert!( + !needs_fetch, + "Fetch should not be required when files match" + ); + } + + #[tokio::test] + async fn test_fetch_required_when_files_differ() { + let mock_server = MockServer::start().await; + + // Create local test files + let test_dir = TempDir::new().unwrap(); + let config_path = test_dir.path().join("fuel").join("configs"); + let test_folder = config_path.join(TESTNET_CONFIG_FOLDER_NAME); + fs::create_dir_all(&test_folder).unwrap(); + + let local_files = [ + ("config.json", "old config content"), + ("metadata.json", "old metadata content"), + ]; + + for (name, content) in &local_files { + fs::write(test_folder.join(name), content).unwrap(); + } + + // Setup mock GitHub response with different content + let github_files = [ + ("config.json", "new config content"), + ("metadata.json", "new metadata content"), + ]; + let github_response = create_github_response(&github_files); + + Mock::given(method("GET")) + .and(path(format!( + "/repos/FuelLabs/{}/contents/{}", + CHAIN_CONFIG_REPO_NAME, TESTNET_CONFIG_FOLDER_NAME + ))) + .respond_with(ResponseTemplate::new(200).set_body_json(&github_response)) + .mount(&mock_server) + .await; + + let fetcher = ConfigFetcher::with_base_url(mock_server.uri()); + + let needs_fetch = fetcher + .check_fetch_required(&ChainConfig::Testnet) + .await + .unwrap(); + + assert!(needs_fetch, "Fetch should be required when files differ"); + } + + #[tokio::test] + async fn test_fetch_required_when_files_missing() { + let mock_server = MockServer::start().await; + + // Create local test files (missing one file) + let test_dir = TempDir::new().unwrap(); + let config_path = test_dir.path().join("fuel").join("configs"); + let test_folder = config_path.join(TESTNET_CONFIG_FOLDER_NAME); + fs::create_dir_all(&test_folder).unwrap(); + + let local_files = [("config.json", "test config content")]; + + for (name, content) in &local_files { + fs::write(test_folder.join(name), content).unwrap(); + } + + // Setup mock GitHub response with extra file + let github_files = [ + ("config.json", "test config content"), + ("metadata.json", "test metadata content"), + ]; + let github_response = create_github_response(&github_files); + + Mock::given(method("GET")) + .and(path(format!( + "/repos/FuelLabs/{}/contents/{}", + CHAIN_CONFIG_REPO_NAME, TESTNET_CONFIG_FOLDER_NAME + ))) + .respond_with(ResponseTemplate::new(200).set_body_json(&github_response)) + .mount(&mock_server) + .await; + + let fetcher = ConfigFetcher::with_base_url(mock_server.uri()); + + let needs_fetch = fetcher + .check_fetch_required(&ChainConfig::Testnet) + .await + .unwrap(); + + assert!( + needs_fetch, + "Fetch should be required when files are missing" + ); + } + + #[tokio::test] + async fn test_local_configuration_never_needs_fetch() { + let fetcher = ConfigFetcher::new(); + let needs_fetch = fetcher + .check_fetch_required(&ChainConfig::Local) + .await + .unwrap(); + + assert!(!needs_fetch, "Local configuration should never need fetch"); + } + + #[tokio::test] + async fn test_fetch_required_when_extra_local_files() { + let mock_server = MockServer::start().await; + + // Create local test files (with extra file) + let test_dir = TempDir::new().unwrap(); + let config_path = test_dir.path().join("fuel").join("configs"); + let test_folder = config_path.join(TESTNET_CONFIG_FOLDER_NAME); + fs::create_dir_all(&test_folder).unwrap(); + + let local_files = [ + ("config.json", "test config content"), + ("metadata.json", "test metadata content"), + ("extra.json", "extra file content"), + ]; + + for (name, content) in &local_files { + fs::write(test_folder.join(name), content).unwrap(); + } + + // Setup mock GitHub response with fewer files + let github_files = [ + ("config.json", "test config content"), + ("metadata.json", "test metadata content"), + ]; + let github_response = create_github_response(&github_files); + + Mock::given(method("GET")) + .and(path(format!( + "/repos/FuelLabs/{}/contents/{}", + CHAIN_CONFIG_REPO_NAME, TESTNET_CONFIG_FOLDER_NAME + ))) + .respond_with(ResponseTemplate::new(200).set_body_json(&github_response)) + .mount(&mock_server) + .await; + + let fetcher = ConfigFetcher::with_base_url(mock_server.uri()); + + let needs_fetch = fetcher + .check_fetch_required(&ChainConfig::Testnet) + .await + .unwrap(); + + assert!( + needs_fetch, + "Fetch should be required when there are extra local files" + ); + } +} diff --git a/forc-plugins/forc-node/src/cmd.rs b/forc-plugins/forc-node/src/cmd.rs new file mode 100644 index 00000000000..22adb59131a --- /dev/null +++ b/forc-plugins/forc-node/src/cmd.rs @@ -0,0 +1,24 @@ +use crate::{ignition::cmd::IgnitionCmd, local::cmd::LocalCmd, testnet::cmd::TestnetCmd}; +use clap::{Parser, Subcommand}; + +#[derive(Debug, Parser)] +#[clap(name = "forc node", version)] +/// Forc node is a wrapper around fuel-core with sensible defaults to provide +/// easy way of bootstrapping a node for local development, testnet or mainnet. +pub struct ForcNodeCmd { + /// Print the fuel-core command without running it. + #[arg(long)] + pub dry_run: bool, + #[command(subcommand)] + pub mode: Mode, +} + +#[derive(Subcommand, Debug)] +pub enum Mode { + /// Starts a local node for development purposes. + Local(LocalCmd), + /// Starts a node that will connect to latest testnet. + Testnet(TestnetCmd), + /// Starts a node that will connect to ignition network. + Ignition(IgnitionCmd), +} diff --git a/forc-plugins/forc-node/src/consts.rs b/forc-plugins/forc-node/src/consts.rs new file mode 100644 index 00000000000..f2efe01f910 --- /dev/null +++ b/forc-plugins/forc-node/src/consts.rs @@ -0,0 +1,34 @@ +/// Minimum fuel-core version supported. +pub const MIN_FUEL_CORE_VERSION: &str = "0.40.0"; + +pub const TESTNET_SERVICE_NAME: &str = "fuel-sepolia-testnet-node"; +pub const TESTNET_SYNC_HEADER_BATCH_SIZE: u32 = 100; +pub const TESTNET_RELAYER_LISTENING_CONTRACT: &str = "0x01855B78C1f8868DE70e84507ec735983bf262dA"; +pub const TESTNET_RELAYER_DA_DEPLOY_HEIGHT: u32 = 5827607; +pub const TESTNET_RELAYER_LOG_PAGE_SIZE: u32 = 500; +pub const TESTNET_SYNC_BLOCK_STREAM_BUFFER_SIZE: u32 = 30; +pub const TESTNET_BOOTSTRAP_NODE: &str = "/dnsaddr/testnet.fuel.network."; + +pub const MAINNET_BOOTSTRAP_NODE: &str = "/dnsaddr/mainnet.fuel.network."; +pub const MAINNET_SERVICE_NAME: &str = "fuel-mainnet-node"; +pub const MAINNET_SYNC_HEADER_BATCH_SIZE: u32 = 30; +pub const MAINNET_RELAYER_LISTENING_CONTRACT: &str = "0xAEB0c00D0125A8a788956ade4f4F12Ead9f65DDf"; +pub const MAINNET_RELAYER_DA_DEPLOY_HEIGHT: u32 = 20620434; +pub const MAINNET_RELAYER_LOG_PAGE_SIZE: u32 = 100; + +/// Name of the folder for testnet at the configuration repo: +/// https://github.com/fuelLabs/chain-configuration/ +pub const TESTNET_CONFIG_FOLDER_NAME: &str = "ignition-test"; +/// Name of the folder for ignition mainnet at the configuration repo: +/// https://github.com/fuelLabs/chain-configuration/ +pub const IGNITION_CONFIG_FOLDER_NAME: &str = "ignition"; +/// Name of the folder for local configuration repo: +pub const LOCAL_CONFIG_FOLDER_NAME: &str = "local"; +/// Name of the github repository that hosts chain-configurations. +pub const CHAIN_CONFIG_REPO_NAME: &str = "chain-configuration"; + +pub const DEFAULT_PORT: u16 = 4000; +pub const DEFAULT_PEERING_PORT: u16 = 30333; + +pub const CONFIG_FOLDER: &str = "chainspecs"; +pub const DB_FOLDER: &str = "db"; diff --git a/forc-plugins/forc-node/src/ignition/cmd.rs b/forc-plugins/forc-node/src/ignition/cmd.rs new file mode 100644 index 00000000000..076589cec67 --- /dev/null +++ b/forc-plugins/forc-node/src/ignition/cmd.rs @@ -0,0 +1,30 @@ +use crate::{ + consts::{DEFAULT_PEERING_PORT, DEFAULT_PORT, MAINNET_BOOTSTRAP_NODE}, + util::DbConfig, +}; +use clap::Parser; +use std::{net::IpAddr, path::PathBuf}; + +#[derive(Parser, Debug, Clone)] +pub struct IgnitionCmd { + #[clap(long)] + pub peer_id: Option, + #[clap(long)] + pub secret: Option, + #[clap(long)] + pub relayer: Option, + #[clap(long, default_value = "0.0.0.0")] + pub ip: IpAddr, + #[clap(long, default_value_t = DEFAULT_PORT)] + pub port: u16, + #[clap(long, default_value_t = DEFAULT_PEERING_PORT)] + pub peering_port: u16, + #[clap(long, default_value = default_ignition_db_path().into_os_string())] + pub db_path: PathBuf, + #[clap(long, default_value_t = MAINNET_BOOTSTRAP_NODE.to_string())] + pub bootstrap_node: String, +} + +fn default_ignition_db_path() -> PathBuf { + DbConfig::Ignition.into() +} diff --git a/forc-plugins/forc-node/src/ignition/mod.rs b/forc-plugins/forc-node/src/ignition/mod.rs new file mode 100644 index 00000000000..8d8565f9f78 --- /dev/null +++ b/forc-plugins/forc-node/src/ignition/mod.rs @@ -0,0 +1,2 @@ +pub mod cmd; +pub mod op; diff --git a/forc-plugins/forc-node/src/ignition/op.rs b/forc-plugins/forc-node/src/ignition/op.rs new file mode 100644 index 00000000000..06002f9310f --- /dev/null +++ b/forc-plugins/forc-node/src/ignition/op.rs @@ -0,0 +1,101 @@ +use super::cmd::IgnitionCmd; +use crate::{ + chain_config::{check_and_update_chain_config, ChainConfig}, + consts::{ + MAINNET_BOOTSTRAP_NODE, MAINNET_RELAYER_DA_DEPLOY_HEIGHT, + MAINNET_RELAYER_LISTENING_CONTRACT, MAINNET_RELAYER_LOG_PAGE_SIZE, MAINNET_SERVICE_NAME, + MAINNET_SYNC_HEADER_BATCH_SIZE, + }, + run_opts::{DbType, RunOpts}, + util::{ask_user_keypair, ask_user_string, HumanReadableCommand, KeyPair}, +}; +use anyhow::Context; +use forc_tracing::println_green; +use std::{ + net::IpAddr, + path::PathBuf, + process::{Child, Command}, +}; +/// Configures the node with testnet configuration to connect the node to latest testnet. +/// Returns `None` if this is a dry_run and no child process created for fuel-core. +pub(crate) async fn run(cmd: IgnitionCmd, dry_run: bool) -> anyhow::Result> { + check_and_update_chain_config(ChainConfig::Testnet).await?; + let keypair = if let (Some(peer_id), Some(secret)) = (&cmd.peer_id, &cmd.secret) { + KeyPair { + peer_id: peer_id.to_string(), + secret: secret.to_string(), + } + } else { + ask_user_keypair()? + }; + + let relayer = if let Some(relayer) = cmd.relayer { + relayer + } else { + ask_user_string("Ethereum RPC (mainnet) Endpoint:")? + }; + + let opts = IgnitionOpts { + keypair, + relayer, + ip: cmd.ip, + port: cmd.port, + peering_port: cmd.peering_port, + db_path: cmd.db_path, + }; + let run_opts = RunOpts::from(opts); + let params = run_opts.generate_params(); + let mut fuel_core_command = Command::new("fuel-core"); + fuel_core_command.arg("run"); + fuel_core_command.args(params.as_slice()); + if dry_run { + println_green(&format!( + "{}", + HumanReadableCommand::from(fuel_core_command) + )); + Ok(None) + } else { + // Spawn the process with proper error handling + let handle = fuel_core_command + .spawn() + .with_context(|| "Failed to spawn fuel-core process:".to_string())?; + Ok(Some(handle)) + } +} + +#[derive(Debug)] +pub struct IgnitionOpts { + keypair: KeyPair, + relayer: String, + ip: IpAddr, + port: u16, + peering_port: u16, + db_path: PathBuf, +} + +impl From for RunOpts { + fn from(value: IgnitionOpts) -> Self { + Self { + service_name: Some(MAINNET_SERVICE_NAME.to_string()), + db_type: DbType::RocksDb, + debug: false, + snapshot: ChainConfig::Testnet.into(), + keypair: Some(value.keypair.secret), + relayer: Some(value.relayer), + ip: Some(value.ip), + port: Some(value.port), + peering_port: Some(value.peering_port), + db_path: Some(value.db_path), + utxo_validation: true, + poa_instant: false, + enable_p2p: true, + sync_header_batch_size: Some(MAINNET_SYNC_HEADER_BATCH_SIZE), + enable_relayer: true, + relayer_listener: Some(MAINNET_RELAYER_LISTENING_CONTRACT.to_string()), + relayer_da_deploy_height: Some(MAINNET_RELAYER_DA_DEPLOY_HEIGHT), + relayer_log_page_size: Some(MAINNET_RELAYER_LOG_PAGE_SIZE), + sync_block_stream_buffer_size: Some(MAINNET_SYNC_HEADER_BATCH_SIZE), + bootstrap_nodes: Some(MAINNET_BOOTSTRAP_NODE.to_string()), + } + } +} diff --git a/forc-plugins/forc-node/src/local/cmd.rs b/forc-plugins/forc-node/src/local/cmd.rs new file mode 100644 index 00000000000..fa0d303e64f --- /dev/null +++ b/forc-plugins/forc-node/src/local/cmd.rs @@ -0,0 +1,10 @@ +use clap::Parser; +use std::path::PathBuf; + +#[derive(Parser, Debug, Clone)] +pub struct LocalCmd { + #[clap(long = "chain-config")] + pub chain_config: Option, + #[clap(long = "port")] + pub port: Option, +} diff --git a/forc-plugins/forc-node/src/local/mod.rs b/forc-plugins/forc-node/src/local/mod.rs new file mode 100644 index 00000000000..8d8565f9f78 --- /dev/null +++ b/forc-plugins/forc-node/src/local/mod.rs @@ -0,0 +1,2 @@ +pub mod cmd; +pub mod op; diff --git a/forc-plugins/forc-node/src/local/op.rs b/forc-plugins/forc-node/src/local/op.rs new file mode 100644 index 00000000000..e7bf9e52197 --- /dev/null +++ b/forc-plugins/forc-node/src/local/op.rs @@ -0,0 +1,53 @@ +use super::cmd::LocalCmd; +use crate::{ + chain_config::{check_and_update_chain_config, ChainConfig}, + run_opts::{DbType, RunOpts}, + util::HumanReadableCommand, +}; +use anyhow::Context; +use forc_tracing::println_green; +use std::process::{Child, Command}; + +/// Local is a local node suited for local development. +/// By default, the node is in `debug` mode and the db used is `in-memory`. +/// Returns `None` if this is a dry_run and no child process created for fuel-core. +pub(crate) async fn run(cmd: LocalCmd, dry_run: bool) -> anyhow::Result> { + check_and_update_chain_config(ChainConfig::Local).await?; + + let run_opts = RunOpts::from(cmd); + let params = run_opts.generate_params(); + + let mut fuel_core_command = Command::new("fuel-core"); + fuel_core_command.arg("run"); + fuel_core_command.args(params.as_slice()); + + if dry_run { + println_green(&format!( + "{}", + HumanReadableCommand::from(fuel_core_command) + )); + Ok(None) + } else { + // Spawn the process with proper error handling + let handle = fuel_core_command + .spawn() + .with_context(|| "Failed to spawn fuel-core process:".to_string())?; + + Ok(Some(handle)) + } +} + +impl From for RunOpts { + fn from(value: LocalCmd) -> Self { + let path = value + .chain_config + .unwrap_or_else(|| ChainConfig::Local.into()); + Self { + db_type: DbType::InMemory, + debug: true, + snapshot: path, + poa_instant: true, + ..Default::default() + } + } +} diff --git a/forc-plugins/forc-node/src/main.rs b/forc-plugins/forc-node/src/main.rs new file mode 100644 index 00000000000..615d4486cd5 --- /dev/null +++ b/forc-plugins/forc-node/src/main.rs @@ -0,0 +1,43 @@ +//! A forc plugin to start a fuel core instance, preconfigured for generic +//! usecases. +mod chain_config; +mod cmd; +mod consts; +mod ignition; +mod local; +mod op; +mod run_opts; +mod testnet; +mod util; + +use anyhow::anyhow; +use clap::Parser; +use forc_tracing::init_tracing_subscriber; +use forc_util::{forc_result_bail, ForcResult}; + +#[tokio::main] +async fn main() -> ForcResult<()> { + init_tracing_subscriber(Default::default()); + + let command = cmd::ForcNodeCmd::parse(); + + let mut handle = match op::run(command).await { + Ok(handler) => handler, + Err(err) => { + forc_result_bail!(err); + } + }; + + // if this is not a dry run we should wait for the kill signal and kill + // fuel-core upon receiving it. + if let Some(handle) = &mut handle { + // Wait for the kill signal, if that comes we should kill child fuel-core + // process. + tokio::signal::ctrl_c() + .await + .map_err(|e| anyhow!("Failed to listen for ctrl-c: {e}"))?; + + handle.kill()?; + } + ForcResult::Ok(()) +} diff --git a/forc-plugins/forc-node/src/op.rs b/forc-plugins/forc-node/src/op.rs new file mode 100644 index 00000000000..a4bdf0cf8e6 --- /dev/null +++ b/forc-plugins/forc-node/src/op.rs @@ -0,0 +1,28 @@ +use crate::{ + cmd::{ForcNodeCmd, Mode}, + consts::MIN_FUEL_CORE_VERSION, + util::get_fuel_core_version, +}; +use forc_util::forc_result_bail; +use semver::Version; +use std::process::Child; + +/// First checks locally installed `forc-node` version and compares it with +/// `consts::MIN_FUEL_CORE_VERSION`. If local version is acceptable, proceeding +/// with the correct mode of operation. +pub(crate) async fn run(cmd: ForcNodeCmd) -> anyhow::Result> { + let current_version = get_fuel_core_version()?; + let supported_min_version = Version::parse(MIN_FUEL_CORE_VERSION)?; + if current_version < supported_min_version { + forc_result_bail!(format!( + "Minimum supported fuel core version is {MIN_FUEL_CORE_VERSION}, system version: {}", + current_version + )); + } + let forc_node_handle = match cmd.mode { + Mode::Local(local) => crate::local::op::run(local, cmd.dry_run).await?, + Mode::Testnet(testnet) => crate::testnet::op::run(testnet, cmd.dry_run).await?, + Mode::Ignition(ignition) => crate::ignition::op::run(ignition, cmd.dry_run).await?, + }; + Ok(forc_node_handle) +} diff --git a/forc-plugins/forc-node/src/run_opts.rs b/forc-plugins/forc-node/src/run_opts.rs new file mode 100644 index 00000000000..ca8158388fb --- /dev/null +++ b/forc-plugins/forc-node/src/run_opts.rs @@ -0,0 +1,155 @@ +use std::{fmt::Display, path::PathBuf}; + +/// Possible parameters to set while integrating with `fuel-core run`. +#[derive(Debug, Default)] +pub struct RunOpts { + pub(crate) service_name: Option, + /// DB type, possible options are: `["in-memory", "rocksdb"]`. + pub(crate) db_type: DbType, + /// Should be used for local development only. Enabling debug mode: + /// - Allows GraphQL Endpoints to arbitrarily advance blocks. + /// - Enables debugger GraphQL Endpoints. + /// - Allows setting `utxo_validation` to `false`. + pub(crate) debug: bool, + /// Snapshot from which to do (re)genesis. + pub(crate) snapshot: PathBuf, + /// Peering private key from generated key-pair. + pub(crate) keypair: Option, + /// Ethereum RPC endpoint. + pub(crate) relayer: Option, + /// The IP address to bind the GraphQL service to. + pub(crate) ip: Option, + /// The port to bind the GraphQL service to. + pub(crate) port: Option, + /// p2p network's TCP port. + pub(crate) peering_port: Option, + /// The path to the database, only releavant if the db type is not + /// "in-memory". + pub(crate) db_path: Option, + /// Enable full utxo stateful validation. + pub(crate) utxo_validation: bool, + /// Use instant block production mode. + /// Newly submitted txs will immediately trigger the production of the next block. + pub(crate) poa_instant: bool, + /// Enable P2P. By default, P2P is disabled. + pub(crate) enable_p2p: bool, + /// Addresses of the bootstrap nodes + /// They should contain PeerId within their `Multiaddr`. + pub(crate) bootstrap_nodes: Option, + /// The maximum number of headers to request in a single batch. + pub(crate) sync_header_batch_size: Option, + /// Enable the Relayer. By default, the Relayer is disabled. + pub(crate) enable_relayer: bool, + /// Ethereum contract address for the relayer. Requires conversion of EthAddress into fuel_types. + pub(crate) relayer_listener: Option, + /// Number of da block that the contract is deployed at. + pub(crate) relayer_da_deploy_height: Option, + /// Number of pages or blocks containing logs that + /// should be downloaded in a single call to the da layer + pub(crate) relayer_log_page_size: Option, + /// The maximum number of get transaction requests to make in a single batch. + pub(crate) sync_block_stream_buffer_size: Option, +} + +#[derive(Debug)] +pub enum DbType { + InMemory, + RocksDb, +} + +impl Default for DbType { + /// By default fuel-core interprets lack of explicit db-type declaration as + /// db-type = rocks-db. + fn default() -> Self { + Self::RocksDb + } +} + +impl Display for DbType { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + match self { + DbType::InMemory => write!(f, "in-memory"), + DbType::RocksDb => write!(f, "rocks-db"), + } + } +} + +impl RunOpts { + pub fn generate_params(self) -> Vec { + let mut params = vec![]; + if let Some(service_name) = self.service_name { + params.push(format!("--service-name {service_name}")); + } + if self.debug { + params.push("--debug".to_string()); + } + if let Some(keypair) = self.keypair { + params.push(format!("--keypair {keypair}")); + } + if let Some(relayer) = self.relayer { + params.push(format!("--relayer {relayer}")); + } + if let Some(ip) = self.ip { + params.push(format!("--ip {ip}")); + } + if let Some(port) = self.port { + params.push(format!("--port {port}")); + } + if let Some(peering_port) = self.peering_port { + params.push(format!("--peering-port {peering_port}")); + } + if let Some(db_path) = self.db_path { + params.push(format!("--db-path {}", db_path.display())); + } + params.push(format!("--snapshot {}", self.snapshot.display())); + params.push(format!("--db-type {}", self.db_type)); + if self.utxo_validation { + params.push("--utxo-validation".to_string()); + } + // --poa-instant accepts `true` or `false` as param, and it is not a + // flag. + if self.poa_instant { + params.push("--poa-instant true".to_string()); + } else { + params.push("--poa-instant false".to_string()); + } + if self.enable_p2p { + params.push("--enable-p2p".to_string()); + } + if let Some(node) = self.bootstrap_nodes { + params.push(format!("--bootstrap-nodes {node}")); + } + if let Some(sync_header_batch_size) = self.sync_header_batch_size { + params.push(format!("--sync-header-batch-size {sync_header_batch_size}")); + } + if self.enable_relayer { + params.push("--enable-relayer".to_string()); + } + if let Some(relayer_listener) = self.relayer_listener { + params.push(format!( + "--relayer-v2-listening-contracts {}", + relayer_listener + )); + } + if let Some(da_deploy_height) = self.relayer_da_deploy_height { + params.push(format!("--relayer-da-deploy-height {da_deploy_height}")); + } + if let Some(log_page_size) = self.relayer_log_page_size { + params.push(format!("--relayer-log-page-size {log_page_size}")); + } + if let Some(sync_block) = self.sync_block_stream_buffer_size { + params.push(format!("--sync-block-stream-buffer-size {sync_block}")); + } + // Split run_cmd so that each arg is actually send as a separate + // arg. To correctly parse the args in the system level, each + // part of an arg should go to different indices of "argv". This + // means "--db-layer in-memory" needs to be interpreted as: + // "--db-layer", "in-memory" to be parsed correctly. + let params: Vec = params + .iter() + .flat_map(|cmd| cmd.split_whitespace()) + .map(|a| a.to_string()) + .collect(); + params + } +} diff --git a/forc-plugins/forc-node/src/testnet/cmd.rs b/forc-plugins/forc-node/src/testnet/cmd.rs new file mode 100644 index 00000000000..90a7801e861 --- /dev/null +++ b/forc-plugins/forc-node/src/testnet/cmd.rs @@ -0,0 +1,30 @@ +use crate::{ + consts::{DEFAULT_PEERING_PORT, DEFAULT_PORT, TESTNET_BOOTSTRAP_NODE}, + util::DbConfig, +}; +use clap::Parser; +use std::{net::IpAddr, path::PathBuf}; + +#[derive(Parser, Debug, Clone)] +pub struct TestnetCmd { + #[clap(long)] + pub peer_id: Option, + #[clap(long)] + pub secret: Option, + #[clap(long)] + pub relayer: Option, + #[clap(long, default_value = "0.0.0.0")] + pub ip: IpAddr, + #[clap(long, default_value_t = DEFAULT_PORT)] + pub port: u16, + #[clap(long, default_value_t = DEFAULT_PEERING_PORT)] + pub peering_port: u16, + #[clap(long, default_value = default_testnet_db_path().into_os_string())] + pub db_path: PathBuf, + #[clap(long, default_value_t = TESTNET_BOOTSTRAP_NODE.to_string())] + pub bootstrap_node: String, +} + +fn default_testnet_db_path() -> PathBuf { + DbConfig::Testnet.into() +} diff --git a/forc-plugins/forc-node/src/testnet/mod.rs b/forc-plugins/forc-node/src/testnet/mod.rs new file mode 100644 index 00000000000..8d8565f9f78 --- /dev/null +++ b/forc-plugins/forc-node/src/testnet/mod.rs @@ -0,0 +1,2 @@ +pub mod cmd; +pub mod op; diff --git a/forc-plugins/forc-node/src/testnet/op.rs b/forc-plugins/forc-node/src/testnet/op.rs new file mode 100644 index 00000000000..f6fb124da94 --- /dev/null +++ b/forc-plugins/forc-node/src/testnet/op.rs @@ -0,0 +1,102 @@ +use crate::{ + chain_config::{check_and_update_chain_config, ChainConfig}, + consts::{ + TESTNET_RELAYER_DA_DEPLOY_HEIGHT, TESTNET_RELAYER_LISTENING_CONTRACT, + TESTNET_RELAYER_LOG_PAGE_SIZE, TESTNET_SERVICE_NAME, TESTNET_SYNC_BLOCK_STREAM_BUFFER_SIZE, + TESTNET_SYNC_HEADER_BATCH_SIZE, + }, + run_opts::{DbType, RunOpts}, + testnet::cmd::TestnetCmd, + util::{ask_user_keypair, ask_user_string, HumanReadableCommand, KeyPair}, +}; +use anyhow::Context; +use forc_tracing::println_green; +use std::{ + net::IpAddr, + path::PathBuf, + process::{Child, Command}, +}; + +/// Configures the node with testnet configuration to connect the node to latest testnet. +/// Returns `None` if this is a dry_run and no child process created for fuel-core. +pub(crate) async fn run(cmd: TestnetCmd, dry_run: bool) -> anyhow::Result> { + check_and_update_chain_config(ChainConfig::Testnet).await?; + let keypair = if let (Some(peer_id), Some(secret)) = (&cmd.peer_id, &cmd.secret) { + KeyPair { + peer_id: peer_id.clone(), + secret: secret.clone(), + } + } else { + ask_user_keypair()? + }; + + let relayer = cmd.relayer.unwrap_or_else(|| { + ask_user_string("Ethereum RPC (Sepolia) Endpoint:").expect("Failed to get RPC endpoint") + }); + + let opts = TestnetOpts { + keypair, + relayer, + ip: cmd.ip, + port: cmd.port, + peering_port: cmd.peering_port, + db_path: cmd.db_path, + bootstrap_node: cmd.bootstrap_node, + }; + let run_opts = RunOpts::from(opts); + let params = run_opts.generate_params(); + let mut fuel_core_command = Command::new("fuel-core"); + fuel_core_command.arg("run"); + fuel_core_command.args(params.as_slice()); + if dry_run { + println_green(&format!( + "{}", + HumanReadableCommand::from(fuel_core_command) + )); + Ok(None) + } else { + // Spawn the process with proper error handling + let handle = fuel_core_command + .spawn() + .with_context(|| "Failed to spawn fuel-core process:".to_string())?; + Ok(Some(handle)) + } +} + +#[derive(Debug)] +pub struct TestnetOpts { + keypair: KeyPair, + relayer: String, + ip: IpAddr, + port: u16, + peering_port: u16, + db_path: PathBuf, + bootstrap_node: String, +} + +impl From for RunOpts { + fn from(value: TestnetOpts) -> Self { + Self { + service_name: Some(TESTNET_SERVICE_NAME.to_string()), + db_type: DbType::RocksDb, + debug: false, + snapshot: ChainConfig::Testnet.into(), + keypair: Some(value.keypair.secret), + relayer: Some(value.relayer), + ip: Some(value.ip), + port: Some(value.port), + peering_port: Some(value.peering_port), + db_path: Some(value.db_path), + bootstrap_nodes: Some(value.bootstrap_node), + utxo_validation: true, + poa_instant: false, + enable_p2p: true, + sync_header_batch_size: Some(TESTNET_SYNC_HEADER_BATCH_SIZE), + enable_relayer: true, + relayer_listener: Some(TESTNET_RELAYER_LISTENING_CONTRACT.to_string()), + relayer_da_deploy_height: Some(TESTNET_RELAYER_DA_DEPLOY_HEIGHT), + relayer_log_page_size: Some(TESTNET_RELAYER_LOG_PAGE_SIZE), + sync_block_stream_buffer_size: Some(TESTNET_SYNC_BLOCK_STREAM_BUFFER_SIZE), + } + } +} diff --git a/forc-plugins/forc-node/src/util.rs b/forc-plugins/forc-node/src/util.rs new file mode 100644 index 00000000000..95faa789fde --- /dev/null +++ b/forc-plugins/forc-node/src/util.rs @@ -0,0 +1,166 @@ +use crate::consts::DB_FOLDER; +use anyhow::{anyhow, bail, Result}; +use dialoguer::{theme::ColorfulTheme, Confirm, Input, Password}; +use forc_util::user_forc_directory; +use semver::Version; +use serde::{Deserialize, Serialize}; +use std::{ + fmt::Display, + path::PathBuf, + process::{Command, Stdio}, +}; + +pub enum DbConfig { + Local, + Testnet, + Ignition, +} + +impl From for PathBuf { + fn from(value: DbConfig) -> Self { + let user_db_dir = user_forc_directory().join(DB_FOLDER); + match value { + DbConfig::Local => user_db_dir.join("local"), + DbConfig::Testnet => user_db_dir.join("ignition-testnet"), + DbConfig::Ignition => user_db_dir.join("ignition"), + } + } +} + +#[derive(Serialize, Deserialize, Debug)] +pub struct KeyPair { + pub peer_id: String, + pub secret: String, +} + +/// Checks the local fuel-core's version that `forc-node` will be running. +pub(crate) fn get_fuel_core_version() -> anyhow::Result { + let version_cmd = Command::new("fuel-core") + .arg("--version") + .stdout(Stdio::piped()) + .output() + .expect("failed to run fuel-core, make sure that it is installed."); + + let version_output = String::from_utf8_lossy(&version_cmd.stdout).to_string(); + + // Version output is `fuel-core `. We should split it to only + // get the version part of it before parsing as semver. + let version = version_output + .split_whitespace() + .last() + .ok_or_else(|| anyhow!("fuel-core version parse failed"))?; + let version_semver = Version::parse(version)?; + + Ok(version_semver) +} + +/// Given a `Command`, wrap it to enable generating the actual string that would +/// create this command. +/// Example: +/// ```rust +/// let command = Command::new("fuel-core").arg("run"); +/// let command = HumanReadableCommand(command); +/// let formatted = format!("{command}"); +/// assert_eq!(&formatted, "fuel-core run"); +/// ``` +pub struct HumanReadableCommand(Command); + +impl Display for HumanReadableCommand { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + let dbg_out = format!("{:?}", self.0); + // This is in the ""command-name" "param-name" "param-val"" format. + let parsed = dbg_out + .replace("\" \"", " ") // replace " " between items with space + .replace("\"", ""); // remove remaining quotes at start/end + write!(f, "{parsed}") + } +} + +pub(crate) fn ask_user_yes_no_question(question: &str) -> anyhow::Result { + let answer = Confirm::with_theme(&ColorfulTheme::default()) + .with_prompt(question) + .default(false) + .show_default(false) + .interact()?; + Ok(answer) +} + +pub(crate) fn ask_user_discreetly(question: &str) -> anyhow::Result { + let discrete = Password::with_theme(&ColorfulTheme::default()) + .with_prompt(question) + .interact()?; + Ok(discrete) +} + +pub(crate) fn ask_user_string(question: &str) -> anyhow::Result { + let response = Input::with_theme(&ColorfulTheme::default()) + .with_prompt(question) + .interact_text()?; + Ok(response) +} + +impl From for HumanReadableCommand { + fn from(value: Command) -> Self { + Self(value) + } +} + +/// Ask if the user has a keypair generated and if so, collect the details. +/// If not, bails out with a help message about how to generate a keypair. +pub(crate) fn ask_user_keypair() -> Result { + let has_keypair = ask_user_yes_no_question("Do you have a keypair in hand?")?; + if has_keypair { + // ask the keypair + let peer_id = ask_user_string("Peer Id:")?; + let secret = ask_user_discreetly("Secret:")?; + Ok(KeyPair { peer_id, secret }) + } else { + bail!("Please create a keypair with `fuel-core-keygen new --key-type peering`"); + } +} + +#[cfg(test)] +mod tests { + use super::*; + use std::process::Command; + + #[test] + fn test_basic_command() { + let mut command = Command::new("fuel-core"); + command.arg("run"); + let human_readable = HumanReadableCommand(command); + assert_eq!(format!("{human_readable}"), "fuel-core run"); + } + + #[test] + fn test_command_with_multiple_args() { + let mut command = Command::new("fuel-core"); + command.arg("run"); + command.arg("--config"); + command.arg("config.toml"); + let human_readable = HumanReadableCommand(command); + assert_eq!( + format!("{human_readable}"), + "fuel-core run --config config.toml" + ); + } + + #[test] + fn test_command_no_args() { + let command = Command::new("fuel-core"); + let human_readable = HumanReadableCommand(command); + assert_eq!(format!("{human_readable}"), "fuel-core"); + } + + #[test] + fn test_command_with_path() { + let mut command = Command::new("fuel-core"); + command.arg("--config"); + command.arg("/path/to/config.toml"); + let human_readable = HumanReadableCommand(command); + assert_eq!( + format!("{human_readable}"), + "fuel-core --config /path/to/config.toml" + ); + } +}