diff --git a/Cargo.lock b/Cargo.lock index bc78218..8964abb 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -76,14 +76,15 @@ dependencies = [ [[package]] name = "ahash" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" +checksum = "cd7d5a2cecb58716e47d67d5703a249964b14c7be1ec3cad3affc295b2d1c35d" dependencies = [ "cfg-if", "getrandom 0.2.10", "once_cell", "version_check", + "zerocopy", ] [[package]] @@ -206,7 +207,7 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" dependencies = [ - "quote 1.0.33", + "quote", "syn 1.0.109", ] @@ -218,8 +219,8 @@ checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" dependencies = [ "num-bigint 0.4.4", "num-traits", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -254,8 +255,8 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae3281bc6d0fd7e549af32b52511e1302185bd688fd3359fa36423346ff682ea" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -269,12 +270,6 @@ dependencies = [ "rand 0.8.5", ] -[[package]] -name = "array-bytes" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ad284aeb45c13f2fb4f084de4a420ebf447423bdf9386c0540ce33cb3ef4b8c" - [[package]] name = "arrayref" version = "0.3.7" @@ -315,8 +310,8 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "726535892e8eae7e70657b4c8ea93d26b8553afb1ce617caee529ef96d7dee6c" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", "synstructure", ] @@ -327,8 +322,8 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2777730b2039ac0f95f093556e61b6d26cebed5393ca6f152717777cec3a42ed" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -389,9 +384,9 @@ version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -400,9 +395,9 @@ version = "0.1.73" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bc00ceb34980c03614e35a3a4e218276a0a824e911d07651cd0d858a51e8c0f0" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -551,12 +546,12 @@ dependencies = [ "lazycell", "peeking_take_while", "prettyplease 0.2.15", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "regex", "rustc-hash", "shlex", - "syn 2.0.37", + "syn 2.0.48", ] [[package]] @@ -570,6 +565,9 @@ name = "bitflags" version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635" +dependencies = [ + "serde", +] [[package]] name = "bitmaps" @@ -648,7 +646,7 @@ dependencies = [ "borsh-derive-internal 0.9.3", "borsh-schema-derive-internal 0.9.3", "proc-macro-crate 0.1.5", - "proc-macro2 1.0.67", + "proc-macro2", "syn 1.0.109", ] @@ -661,7 +659,7 @@ dependencies = [ "borsh-derive-internal 0.10.3", "borsh-schema-derive-internal 0.10.3", "proc-macro-crate 0.1.5", - "proc-macro2 1.0.67", + "proc-macro2", "syn 1.0.109", ] @@ -671,8 +669,8 @@ version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5449c28a7b352f2d1e592a8a28bf139bc71afb0764a14f3c02500935d8c44065" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -682,8 +680,8 @@ version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "afb438156919598d2c7bad7e1c0adf3d26ed3840dbc010db1a882a65583ca2fb" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -693,8 +691,8 @@ version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cdbd5696d8bfa21d53d9fe39a714a18538bad11492a42d066dbbc395fb1951c0" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -704,8 +702,8 @@ version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "634205cc43f74a1b9046ef87c4540ebda95696ec0f315024860cad7c5b0f5ccd" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -754,9 +752,9 @@ dependencies = [ [[package]] name = "bytemuck" -version = "1.14.0" +version = "1.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "374d28ec25809ee0e23827c2ab573d729e293f281dfe393500e7ad618baa61c6" +checksum = "a2ef034f05691a48569bd920a96c81b9d91bbad1ab5ac7c4616c1f6ef36cb79f" dependencies = [ "bytemuck_derive", ] @@ -767,9 +765,9 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "965ab7eb5f8f97d2a083c799f3a1b994fc397b2fe2da5d1da1626ce15a39f2b1" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -1135,10 +1133,10 @@ checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" dependencies = [ "fnv", "ident_case", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "strsim 0.10.0", - "syn 2.0.37", + "syn 2.0.48", ] [[package]] @@ -1148,8 +1146,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" dependencies = [ "darling_core", - "quote 1.0.33", - "syn 2.0.37", + "quote", + "syn 2.0.48", ] [[package]] @@ -1210,8 +1208,8 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -1283,32 +1281,32 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] -name = "dlopen" -version = "0.1.8" +name = "dlopen2" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71e80ad39f814a9abe68583cd50a2d45c8a67561c3361ab8da240587dda80937" +checksum = "09b4f5f101177ff01b8ec4ecc81eead416a8aa42819a2869311b3420fa114ffa" dependencies = [ - "dlopen_derive", - "lazy_static", + "dlopen2_derive", "libc", + "once_cell", "winapi", ] [[package]] -name = "dlopen_derive" -version = "0.1.4" +name = "dlopen2_derive" +version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f236d9e1b1fbd81cea0f9cbdc8dcc7e8ebcd80e6659cd7cb2ad5f6c05946c581" +checksum = "a6cbae11b3de8fce2a456e8ea3dada226b35fe791f0dc1d360c0941f0bb681f3" dependencies = [ - "libc", - "quote 0.6.13", - "syn 0.15.44", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -1388,9 +1386,9 @@ version = "1.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eecf8589574ce9b895052fa12d69af7a233f99e6107f5cb8dd1044f2a17bfdcb" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -1518,6 +1516,15 @@ dependencies = [ "percent-encoding", ] +[[package]] +name = "fs-err" +version = "2.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88a41f105fe1d5b6b34b2055e3dc59bb79b46b48b2040b9e6c7b4b5de097aa41" +dependencies = [ + "autocfg", +] + [[package]] name = "fs_extra" version = "1.3.0" @@ -1578,9 +1585,9 @@ version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -1754,14 +1761,14 @@ version = "0.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" dependencies = [ - "ahash 0.8.3", + "ahash 0.8.5", ] [[package]] name = "hashbrown" -version = "0.14.0" +version = "0.14.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c6201b9ff9fd90a5a3bac2e56a830d0caa509576f0e503818ee82c181b3437a" +checksum = "290f1a1d9242c78d09ce40a5e87e7554ee637af1351968159f4952f028f75604" [[package]] name = "headers" @@ -1950,9 +1957,9 @@ dependencies = [ "futures-util", "http", "hyper", - "rustls 0.21.7", + "rustls", "tokio", - "tokio-rustls 0.24.1", + "tokio-rustls", ] [[package]] @@ -2059,12 +2066,12 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.0.0" +version = "2.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5477fe2230a79769d8dc68e0eabf5437907c0457a5614a9e8dddb67f65eb65d" +checksum = "824b2ae422412366ba479e8111fd301f7b5faece8149317bb81925979a53f520" dependencies = [ "equivalent", - "hashbrown 0.14.0", + "hashbrown 0.14.3", ] [[package]] @@ -2308,6 +2315,18 @@ dependencies = [ "vcpkg", ] +[[package]] +name = "light-poseidon" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c9a85a9752c549ceb7578064b4ed891179d20acd85f27318573b64d2d7ee7ee" +dependencies = [ + "ark-bn254", + "ark-ff", + "num-bigint 0.4.4", + "thiserror", +] + [[package]] name = "linux-raw-sys" version = "0.4.7" @@ -2359,12 +2378,6 @@ dependencies = [ "libc", ] -[[package]] -name = "matches" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" - [[package]] name = "matchit" version = "0.7.3" @@ -2464,8 +2477,8 @@ version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5a7d5f7076603ebc68de2dc6a650ec331a062a13abaa346975be747bbfa4b789" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -2568,11 +2581,22 @@ version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] +[[package]] +name = "num-derive" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed3955f1a9c7c0c15e092f9c887db08b1fc683305fdf6eb6684f22555355e202" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.48", +] + [[package]] name = "num-integer" version = "0.1.45" @@ -2643,6 +2667,15 @@ dependencies = [ "num_enum_derive 0.6.1", ] +[[package]] +name = "num_enum" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02339744ee7253741199f897151b38e72257d13802d4ee837285cc2990a90845" +dependencies = [ + "num_enum_derive 0.7.2", +] + [[package]] name = "num_enum_derive" version = "0.5.11" @@ -2650,8 +2683,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" dependencies = [ "proc-macro-crate 1.3.1", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -2662,9 +2695,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" dependencies = [ "proc-macro-crate 1.3.1", - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "681030a937600a36906c185595136d26abfebb4aa9c65701cefcaf8578bb982b" +dependencies = [ + "proc-macro-crate 1.3.1", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -2724,9 +2769,9 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -2781,8 +2826,8 @@ checksum = "5f7d21ccd03305a674437ee1248f3ab5d4b1db095cf1caf49f1713ddf61956b7" dependencies = [ "Inflector", "proc-macro-error", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -2895,7 +2940,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e1d3afd2628e69da2be385eb6f2fd57c8ac7977ceeff6dc166ff1657b0e386a9" dependencies = [ "fixedbitset", - "indexmap 2.0.0", + "indexmap 2.2.2", ] [[package]] @@ -2913,9 +2958,9 @@ version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -2955,7 +3000,7 @@ checksum = "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6" [[package]] name = "poc-framework" -version = "0.3.0" +version = "0.4.0" dependencies = [ "bincode", "borsh 0.9.3", @@ -2967,6 +3012,7 @@ dependencies = [ "serde", "sha2 0.10.7", "sha3 0.10.8", + "solana-accounts-db", "solana-bpf-loader-program", "solana-cli-output", "solana-client", @@ -2982,9 +3028,10 @@ dependencies = [ "solana-stake-program", "solana-transaction-status", "solana-vote-program", - "spl-associated-token-account", - "spl-memo", - "spl-token", + "spl-associated-token-account 1.1.3", + "spl-memo 3.0.1", + "spl-token 3.5.0", + "spl-token-2022 1.0.0", ] [[package]] @@ -3023,7 +3070,7 @@ version = "0.1.25" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c8646e95016a7a6c4adea95bafa8a16baab64b583356217f2c85db4a39d9a86" dependencies = [ - "proc-macro2 1.0.67", + "proc-macro2", "syn 1.0.109", ] @@ -3033,8 +3080,8 @@ version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae005bd773ab59b4725093fd7df83fd7892f7d8eafb48dbd7de6e024e4215f9d" dependencies = [ - "proc-macro2 1.0.67", - "syn 2.0.37", + "proc-macro2", + "syn 2.0.48", ] [[package]] @@ -3063,8 +3110,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" dependencies = [ "proc-macro-error-attr", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", "version_check", ] @@ -3075,25 +3122,16 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "version_check", ] [[package]] name = "proc-macro2" -version = "0.4.30" +version = "1.0.78" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf3d2011ab5c909338f7887f4fc896d35932e29146c12c8d01da6b22a80ba759" -dependencies = [ - "unicode-xid 0.1.0", -] - -[[package]] -name = "proc-macro2" -version = "1.0.67" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d433d9f1a3e8c1263d9456598b16fec66f4acc9a74dacffd35c7bb09b3a1328" +checksum = "e2422ad645d89c99f8f3e6b88a9fdeca7fabeac836b1002371c4367c8f984aae" dependencies = [ "unicode-ident", ] @@ -3138,8 +3176,8 @@ checksum = "e5d2d8d10f3c6ded6da8b05b5fb3b8a5082514344d56c9f871412d29b4e075b4" dependencies = [ "anyhow", "itertools", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", ] @@ -3170,72 +3208,72 @@ dependencies = [ "percent-encoding", ] +[[package]] +name = "qualifier_attr" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e2e25ee72f5b24d773cae88422baddefff7714f97aab68d96fe2b6fc4a28fb2" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.48", +] + [[package]] name = "quinn" -version = "0.9.4" +version = "0.10.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e8b432585672228923edbbf64b8b12c14e1112f62e88737655b4a083dbcd78e" +checksum = "8cc2c5017e4b43d5995dcea317bc46c1e09404c0a9664d2908f7f02dfe943d75" dependencies = [ "bytes", "pin-project-lite", "quinn-proto", "quinn-udp", "rustc-hash", - "rustls 0.20.9", + "rustls", "thiserror", "tokio", "tracing", - "webpki", ] [[package]] name = "quinn-proto" -version = "0.9.5" +version = "0.10.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c956be1b23f4261676aed05a0046e204e8a6836e50203902683a718af0797989" +checksum = "141bf7dfde2fbc246bfd3fe12f2455aa24b0fbd9af535d8c86c7bd1381ff2b1a" dependencies = [ "bytes", "rand 0.8.5", "ring", "rustc-hash", - "rustls 0.20.9", + "rustls", "rustls-native-certs", "slab", "thiserror", "tinyvec", "tracing", - "webpki", ] [[package]] name = "quinn-udp" -version = "0.3.2" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "641538578b21f5e5c8ea733b736895576d0fe329bb883b937db6f4d163dbaaf4" +checksum = "055b4e778e8feb9f93c4e439f71dc2156ef13360b432b799e179a8c4cdf0b1d7" dependencies = [ + "bytes", "libc", - "quinn-proto", - "socket2 0.4.9", + "socket2 0.5.4", "tracing", - "windows-sys 0.42.0", -] - -[[package]] -name = "quote" -version = "0.6.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ce23b6b870e8f94f81fb0a363d65d86675884b34a09043c81e5562f11c1f8e1" -dependencies = [ - "proc-macro2 0.4.30", + "windows-sys 0.48.0", ] [[package]] name = "quote" -version = "1.0.33" +version = "1.0.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" +checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" dependencies = [ - "proc-macro2 1.0.67", + "proc-macro2", ] [[package]] @@ -3396,9 +3434,9 @@ dependencies = [ [[package]] name = "regex" -version = "1.9.5" +version = "1.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "697061221ea1b4a94a624f67d0ae2bfe4e22b8a17b6a192afb11046542cc8c47" +checksum = "b62dbe01f0b06f9d8dc7d49e05a0785f153b00b2c227856282f671e0318c9b15" dependencies = [ "aho-corasick", "memchr", @@ -3408,9 +3446,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.3.8" +version = "0.4.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2f401f4955220693b56f8ec66ee9c78abffd8d1c4f23dc41a23839eb88f0795" +checksum = "5bb987efffd3c6d0d8f5f89510bb458559eab11e4f869acb20bf845e016259cd" dependencies = [ "aho-corasick", "memchr", @@ -3419,9 +3457,9 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.7.5" +version = "0.8.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" +checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" [[package]] name = "reqwest" @@ -3449,14 +3487,14 @@ dependencies = [ "once_cell", "percent-encoding", "pin-project-lite", - "rustls 0.21.7", + "rustls", "rustls-pemfile", "serde", "serde_json", "serde_urlencoded", "tokio", "tokio-native-tls", - "tokio-rustls 0.24.1", + "tokio-rustls", "tokio-util", "tower-service", "url", @@ -3556,18 +3594,6 @@ dependencies = [ "windows-sys 0.48.0", ] -[[package]] -name = "rustls" -version = "0.20.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b80e3dec595989ea8510028f30c408a4630db12c9cbb8de34203b89d6577e99" -dependencies = [ - "log", - "ring", - "sct", - "webpki", -] - [[package]] name = "rustls" version = "0.21.7" @@ -3662,9 +3688,9 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1db149f81d46d2deba7cd3c50772474707729550221e69588478ebf9ada425ae" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -3730,9 +3756,9 @@ version = "1.0.188" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4eca7ac642d82aa35b60049a6eccb4be6be75e599bd2e9adb5f875a737654af2" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -3775,9 +3801,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "881b6f881b17d13214e5d494c939ebab463d01264ce1811e9d4ac3a882e7695f" dependencies = [ "darling", - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -3786,24 +3812,13 @@ version = "0.9.25" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1a49e178e4452f45cb61d0cd8cebc1b0fafd3e41929e996cef79aa3aca91f574" dependencies = [ - "indexmap 2.0.0", + "indexmap 2.2.2", "itoa", "ryu", "serde", "unsafe-libyaml", ] -[[package]] -name = "sha-1" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5058ada175748e33390e40e872bd0fe59a19f265d0158daa551c5a88a76009c" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - [[package]] name = "sha1" version = "0.10.6" @@ -3894,6 +3909,12 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2a30f10c911c0355f80f1c2faa8096efc4a58cdf8590b954d5b395efa071c711" +[[package]] +name = "siphasher" +version = "0.3.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38b58827f4464d87d377d175e90bf58eb00fd8716ff0a62f80356b5e61555d0d" + [[package]] name = "sized-chunks" version = "0.6.5" @@ -3957,9 +3978,9 @@ dependencies = [ [[package]] name = "solana-account-decoder" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0ada16ccd5ca6884ae28b716211c4f09d22225a9ebde14eccd4f605cc321e42" +checksum = "74a6ad350a6f633fd76e8bd1e77ad7a3ce75e3046d69957cdb042152e84d8957" dependencies = [ "Inflector", "base64 0.21.4", @@ -3970,25 +3991,85 @@ dependencies = [ "serde", "serde_derive", "serde_json", - "solana-address-lookup-table-program", "solana-config-program", "solana-sdk", - "spl-token", - "spl-token-2022", + "spl-token 4.0.0", + "spl-token-2022 1.0.0", + "spl-token-group-interface", + "spl-token-metadata-interface", "thiserror", "zstd", ] +[[package]] +name = "solana-accounts-db" +version = "1.17.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15c4fff17148e7b81804cb7997d8dfcad5f36dea61b931fa71494602c6396bc3" +dependencies = [ + "arrayref", + "bincode", + "blake3", + "bv", + "bytemuck", + "byteorder", + "bzip2", + "crossbeam-channel", + "dashmap", + "flate2", + "fnv", + "fs-err", + "im", + "index_list", + "itertools", + "lazy_static", + "log", + "lz4", + "memmap2", + "modular-bitfield", + "num-derive 0.3.3", + "num-traits", + "num_cpus", + "num_enum 0.6.1", + "ouroboros", + "percentage", + "qualifier_attr", + "rand 0.8.5", + "rayon", + "regex", + "rustc_version", + "serde", + "serde_derive", + "solana-bucket-map", + "solana-config-program", + "solana-frozen-abi", + "solana-frozen-abi-macro", + "solana-measure", + "solana-metrics", + "solana-program-runtime", + "solana-rayon-threadlimit", + "solana-sdk", + "solana-stake-program", + "solana-system-program", + "solana-vote-program", + "static_assertions", + "strum", + "strum_macros", + "tar", + "tempfile", + "thiserror", +] + [[package]] name = "solana-address-lookup-table-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "248b435722d18100b70bb8f09fd38b8a8c46031a0de86f6b31768f64cf4092c5" +checksum = "4c33e0707e51db8467a61766a0dc382dc0e482c60ae70d4673c0396d62f5c983" dependencies = [ "bincode", "bytemuck", "log", - "num-derive", + "num-derive 0.3.3", "num-traits", "rustc_version", "serde", @@ -4002,15 +4083,15 @@ dependencies = [ [[package]] name = "solana-bpf-loader-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70b84a554f12f89c72f3c2dea973a5105740814aeebfb04998cc0afd9e2e6a2e" +checksum = "a9e6afdc4cc3af5fa2bd2cdf654acae91a24300358a4370c82f4c34f026d52be" dependencies = [ "bincode", "byteorder", "libsecp256k1 0.6.0", "log", - "rand 0.7.3", + "scopeguard", "solana-measure", "solana-program-runtime", "solana-sdk", @@ -4021,16 +4102,17 @@ dependencies = [ [[package]] name = "solana-bucket-map" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c90e94b36eb9cdbe78a4d37c0ce1f96794c7fbae16baa0f6e51811ffbb25819b" +checksum = "acda9b3df626889f88bf2ab8960facf1b131dd27924c6e2bcca41b29cc208305" dependencies = [ "bv", + "bytemuck", "log", "memmap2", "modular-bitfield", "num_enum 0.6.1", - "rand 0.7.3", + "rand 0.8.5", "solana-measure", "solana-sdk", "tempfile", @@ -4038,14 +4120,13 @@ dependencies = [ [[package]] name = "solana-clap-utils" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2782dc1178498135d438ea51998e5a28be05f2ed5b9ff97e224d8ca1f6b16fe5" +checksum = "8cdf7db331e617e42df7793f40421b8b3ea74d893ec2306f401cde3ab816c5d7" dependencies = [ "chrono", "clap 2.34.0", "rpassword", - "solana-perf", "solana-remote-wallet", "solana-sdk", "thiserror", @@ -4056,9 +4137,9 @@ dependencies = [ [[package]] name = "solana-cli-config" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "538e8c1de6e6a948930a11f7debdbb21ff5492d09b67fb0d37a03c5208c233c7" +checksum = "630ed0731474c3e4c1b2d2c1089671a10e82e56c6f65c2d43eceae723fcfa244" dependencies = [ "dirs-next", "lazy_static", @@ -4072,9 +4153,9 @@ dependencies = [ [[package]] name = "solana-cli-output" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb41ef997e186c81a42d8b359eff0d8f0f3c61a02ad4a66111f189664a4f9d0d" +checksum = "42320a45b29c4d8375be02a71d2df8b8ddd3ce97c4cff7addd1cc8ceaf0d4417" dependencies = [ "Inflector", "base64 0.21.4", @@ -4094,24 +4175,24 @@ dependencies = [ "solana-sdk", "solana-transaction-status", "solana-vote-program", - "spl-memo", + "spl-memo 4.0.0", ] [[package]] name = "solana-client" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "969294bec354ba003bb4dc2e95e94beee4202d3244d6011434c282337601cc1f" +checksum = "26e6ac6371d264548d314865daad18a0a2fb2ba8b5e1ea9b92de004f9887e42a" dependencies = [ "async-trait", "bincode", + "dashmap", "futures", "futures-util", - "indexmap 1.9.3", + "indexmap 2.2.2", "indicatif", "log", "quinn", - "rand 0.7.3", "rayon", "solana-connection-cache", "solana-measure", @@ -4132,9 +4213,9 @@ dependencies = [ [[package]] name = "solana-compute-budget-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a33f864bd6ba7d6dfeb88b774edc31af0abd27df96763d4e8a3f91e34f4f0995" +checksum = "a4900e0d76d81564c0ea43396c5e9e24f34eba9cc36cab249b6ff6a576973855" dependencies = [ "solana-program-runtime", "solana-sdk", @@ -4142,9 +4223,9 @@ dependencies = [ [[package]] name = "solana-config-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0622d8798d060c84883572483f214b0d5c1640450e4322483cfe2e72823a6d7" +checksum = "5ce2f25dbe765208a79af782b79b2d06f382a82b13050890edd52dcab11078b8" dependencies = [ "bincode", "chrono", @@ -4156,16 +4237,17 @@ dependencies = [ [[package]] name = "solana-connection-cache" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1439d38886d31690d8e2573e656e6767d3ae790229050dfe71ade309d5664cb" +checksum = "f81baf526f3c36c4ae07fdd6d924e352e89444a9c77771baab66fe00c681825d" dependencies = [ "async-trait", "bincode", + "crossbeam-channel", "futures-util", - "indexmap 1.9.3", + "indexmap 2.2.2", "log", - "rand 0.7.3", + "rand 0.8.5", "rayon", "rcgen", "solana-measure", @@ -4175,19 +4257,42 @@ dependencies = [ "tokio", ] +[[package]] +name = "solana-cost-model" +version = "1.17.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "841b749107b994fb14ff14d80f3ffffdb68101b71b57d7d385e5e30a734cea1e" +dependencies = [ + "lazy_static", + "log", + "rustc_version", + "solana-address-lookup-table-program", + "solana-bpf-loader-program", + "solana-compute-budget-program", + "solana-config-program", + "solana-frozen-abi", + "solana-frozen-abi-macro", + "solana-loader-v4-program", + "solana-metrics", + "solana-program-runtime", + "solana-sdk", + "solana-stake-program", + "solana-system-program", + "solana-vote-program", +] + [[package]] name = "solana-entry" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f32fa8cf5f71c4bd9b08db79469811f1c47d3c577643da8d5544ef6ddd685683" +checksum = "e63abc6b205a9f6897772116a620f847b0d741bba4af5f84f0ee5570f4d9cc2b" dependencies = [ "bincode", "crossbeam-channel", - "dlopen", - "dlopen_derive", + "dlopen2", "lazy_static", "log", - "rand 0.7.3", + "rand 0.8.5", "rayon", "serde", "solana-measure", @@ -4200,9 +4305,9 @@ dependencies = [ [[package]] name = "solana-faucet" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ec77384c3c93e9f755ef0352c0c90ec98017e9db9908a9e7878dad60ea3244b" +checksum = "220737d8c607e3799b5bf10ba3425b13b347abec9d1a20c1dfdfd04a17c38dcf" dependencies = [ "bincode", "byteorder", @@ -4217,18 +4322,18 @@ dependencies = [ "solana-metrics", "solana-sdk", "solana-version", - "spl-memo", + "spl-memo 4.0.0", "thiserror", "tokio", ] [[package]] name = "solana-frozen-abi" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e74d294241df12a73a229e38a819e810d54234da494c3d43f8a1a828631047d" +checksum = "62311c3a992af13c270d9bf219b6d7534f7ddc30074fa31a5261273e9f7d4b83" dependencies = [ - "ahash 0.8.3", + "ahash 0.8.5", "blake3", "block-buffer 0.10.4", "bs58", @@ -4237,13 +4342,10 @@ dependencies = [ "cc", "either", "generic-array", - "getrandom 0.1.16", "im", "lazy_static", "log", "memmap2", - "once_cell", - "rand_core 0.6.4", "rustc_version", "serde", "serde_bytes", @@ -4257,25 +4359,25 @@ dependencies = [ [[package]] name = "solana-frozen-abi-macro" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dabde7fbd88a68eb083ae9d6d5f6855b7ba1bfc45d200c786b1b448ac49da5f" +checksum = "6a9b64778efc635c7cd8cae084fef4b034b7f2b5a0c022d5173179446c56e71f" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "rustc_version", - "syn 2.0.37", + "syn 2.0.48", ] [[package]] name = "solana-ledger" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87b139341b34e1dd43eb60a71d296688d0cf6101d4c21b21b2e8a62a912aecce" +checksum = "8fddcd3d11131039bddf4c1d98fe987c64ee3884626ad8c8f0c023e0ccd9e196" dependencies = [ "assert_matches", "bincode", - "bitflags 1.3.2", + "bitflags 2.4.0", "byteorder", "chrono", "chrono-humanize", @@ -4291,8 +4393,8 @@ dependencies = [ "num_cpus", "num_enum 0.6.1", "prost", - "rand 0.7.3", - "rand_chacha 0.2.2", + "rand 0.8.5", + "rand_chacha 0.3.1", "rayon", "reed-solomon-erasure", "rocksdb", @@ -4302,7 +4404,9 @@ dependencies = [ "serde_bytes", "sha2 0.10.7", "solana-account-decoder", + "solana-accounts-db", "solana-bpf-loader-program", + "solana-cost-model", "solana-entry", "solana-frozen-abi", "solana-frozen-abi-macro", @@ -4317,10 +4421,13 @@ dependencies = [ "solana-storage-bigtable", "solana-storage-proto", "solana-transaction-status", + "solana-vote", "solana-vote-program", - "spl-token", - "spl-token-2022", + "spl-token 4.0.0", + "spl-token-2022 1.0.0", "static_assertions", + "strum", + "strum_macros", "tempfile", "thiserror", "tokio", @@ -4330,12 +4437,11 @@ dependencies = [ [[package]] name = "solana-loader-v4-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de634a9a00c745e42c3278458c0c85d0aa088db2cf872f06af8210991bf51574" +checksum = "2a2c53ce07056371bf0998f872cfa4c23d156c9348f18f21e1f34b4bd956c51d" dependencies = [ "log", - "rand 0.7.3", "solana-measure", "solana-program-runtime", "solana-sdk", @@ -4344,9 +4450,9 @@ dependencies = [ [[package]] name = "solana-logger" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24dc0037a389d782c8de3c6f509b74efa1d60523ef9e5561cefe41f1a354fee0" +checksum = "6960f7149fb0ec738d04224f5f44b331c467e8fec4ede41c6c702562f0365688" dependencies = [ "env_logger", "lazy_static", @@ -4355,9 +4461,9 @@ dependencies = [ [[package]] name = "solana-measure" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19563c27f12801e0e65b42d0f216db1d910dfeaad88d8f1335dd6369697eda60" +checksum = "0d14133e480bd877b8b4174fc7fc8c591b227d451d0fd48c917e5d3af7bac978" dependencies = [ "log", "solana-sdk", @@ -4365,20 +4471,19 @@ dependencies = [ [[package]] name = "solana-merkle-tree" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10945018bc2fa7b773cbf519dfed76c6e8946daa1548abf2eb34591186915cb4" +checksum = "5b54c0e9971bae72fd81d6de36ace4f895e83f47b7f454122bae7f7a61b4b5d9" dependencies = [ "fast-math", - "matches", "solana-program", ] [[package]] name = "solana-metrics" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f74c557e821c7ff48c9b4ef4ab3a296918d7fb745e3f2e820ebdb38e8e3555b" +checksum = "9cf4c91c0dd58c83fa0065b777ebaf16a6977b145ae847937b4e8aa119993d96" dependencies = [ "crossbeam-channel", "gethostname", @@ -4386,23 +4491,24 @@ dependencies = [ "log", "reqwest", "solana-sdk", + "thiserror", ] [[package]] name = "solana-net-utils" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b7d5599760f8a287c59d96a5c52752028c1c72c815fe74e0d7990bb90684cbfc" +checksum = "dc57096f56badce23b05ca98da2490b2638e14c445be92bf7fdd011e0274aa45" dependencies = [ "bincode", "clap 3.2.25", "crossbeam-channel", "log", "nix", - "rand 0.7.3", + "rand 0.8.5", "serde", "serde_derive", - "socket2 0.4.9", + "socket2 0.5.4", "solana-logger", "solana-sdk", "solana-version", @@ -4412,25 +4518,27 @@ dependencies = [ [[package]] name = "solana-perf" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76b2adb00aa09d92cd3b4f614ddd4f81366524a0d8ae9dd63b64418f696171c6" +checksum = "f2bf7a94309c36fe1627a93ecc1001996bec1acc34cce557c0a64b43d32ad618" dependencies = [ - "ahash 0.8.3", + "ahash 0.8.5", "bincode", "bv", "caps", "curve25519-dalek", - "dlopen", - "dlopen_derive", + "dlopen2", "fnv", "lazy_static", "libc", "log", "nix", - "rand 0.7.3", + "rand 0.8.5", "rayon", + "rustc_version", "serde", + "solana-frozen-abi", + "solana-frozen-abi-macro", "solana-metrics", "solana-rayon-threadlimit", "solana-sdk", @@ -4439,18 +4547,17 @@ dependencies = [ [[package]] name = "solana-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a2faeb9c89b354b547a229e3b39fa8fd6d11c78362ba8580f0c4721739725b6" +checksum = "a75eabbb12920ffe88155f611450a17d6ae28b754b707ec63f83ada500014c8a" dependencies = [ "ark-bn254", "ark-ec", "ark-ff", "ark-serialize", - "array-bytes", "base64 0.21.4", "bincode", - "bitflags 1.3.2", + "bitflags 2.4.0", "blake3", "borsh 0.10.3", "borsh 0.9.3", @@ -4467,14 +4574,14 @@ dependencies = [ "lazy_static", "libc", "libsecp256k1 0.6.0", + "light-poseidon", "log", "memoffset 0.9.0", "num-bigint 0.4.4", - "num-derive", + "num-derive 0.3.3", "num-traits", "parking_lot 0.12.1", - "rand 0.7.3", - "rand_chacha 0.2.2", + "rand 0.8.5", "rustc_version", "rustversion", "serde", @@ -4494,9 +4601,9 @@ dependencies = [ [[package]] name = "solana-program-runtime" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f65907a405764cda63be89335ffd2138ade18f065e5cae09d20adab7fb09502" +checksum = "917a320dca9f88fb3ca4f5549205b0525e47f51b6b98eb34f6728038df484b44" dependencies = [ "base64 0.21.4", "bincode", @@ -4505,10 +4612,10 @@ dependencies = [ "itertools", "libc", "log", - "num-derive", + "num-derive 0.3.3", "num-traits", "percentage", - "rand 0.7.3", + "rand 0.8.5", "rustc_version", "serde", "solana-frozen-abi", @@ -4522,9 +4629,9 @@ dependencies = [ [[package]] name = "solana-pubsub-client" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "367e70572ebc81de7d8ca742342f7cf19b6b47d182dd9aa8932c7cfa71bb6dc4" +checksum = "db1ed23c4d7d03e6d8003deb3bdd2dc1b364bcf6a9ca7cd41736a24ac2803d40" dependencies = [ "crossbeam-channel", "futures-util", @@ -4547,9 +4654,9 @@ dependencies = [ [[package]] name = "solana-quic-client" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87daa01ce0ecd6667425c7f19f10388cbce63a62f8f69767ea37b69293e814cf" +checksum = "6c94e45645bb116a3519c346112e066950ce5e3701db66b25e7ca968026dacbf" dependencies = [ "async-mutex", "async-trait", @@ -4559,9 +4666,8 @@ dependencies = [ "log", "quinn", "quinn-proto", - "quinn-udp", "rcgen", - "rustls 0.20.9", + "rustls", "solana-connection-cache", "solana-measure", "solana-metrics", @@ -4575,9 +4681,9 @@ dependencies = [ [[package]] name = "solana-rayon-threadlimit" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb6593da84631b9b523dac91b04f4e2a366205f61112d677e8cbe2bfda57a176" +checksum = "2163dee2025e0a758c755fe8682ced64f40e81fee0d3641c39486a7c8acf8dc8" dependencies = [ "lazy_static", "num_cpus", @@ -4585,14 +4691,14 @@ dependencies = [ [[package]] name = "solana-remote-wallet" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a431bdda7679de1381722f6eef63dfc301f07cbd51a930a28e61ee42167448a5" +checksum = "352a233e1bc3164559ee03dabe034d4b056d3df30cb20f9813fb1d81290d014c" dependencies = [ "console", "dialoguer", "log", - "num-derive", + "num-derive 0.3.3", "num-traits", "parking_lot 0.12.1", "qstring", @@ -4604,9 +4710,9 @@ dependencies = [ [[package]] name = "solana-rpc-client" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2771ac12cdbde1aa6b55a129947f1428bb44d14314059c1e69674e1d58aaf9e1" +checksum = "89dd52108c0c7fea71f2417daf0310592f108459a4afc223f243e5021a7cea39" dependencies = [ "async-trait", "base64 0.21.4", @@ -4630,9 +4736,9 @@ dependencies = [ [[package]] name = "solana-rpc-client-api" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f401e2ae586fd60c1c8c0f406be521bfe4889c6c2854fbb76bd20e8bc2d57284" +checksum = "536fac51d733b6c73661da49859585c3e3e1427e8d94871db80c3f9e9b569f68" dependencies = [ "base64 0.21.4", "bs58", @@ -4646,15 +4752,15 @@ dependencies = [ "solana-sdk", "solana-transaction-status", "solana-version", - "spl-token-2022", + "spl-token-2022 1.0.0", "thiserror", ] [[package]] name = "solana-rpc-client-nonce-utils" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "46df2d20521eab49fadb9afe93808e9764767e193bd701c7d380a56d0dc7f8ad" +checksum = "8381f6604e62058e106c3be4d1693264eaed7d066e5caa375beb51b539d7a579" dependencies = [ "clap 2.34.0", "solana-clap-utils", @@ -4665,11 +4771,12 @@ dependencies = [ [[package]] name = "solana-runtime" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dd836895d54bcda07566caab7825649f33dda7f900bf7660e5547468909989c" +checksum = "091b596a19845387cf761b49bb5a4a3334427cd90cb863f242e57e4135fcc46c" dependencies = [ "arrayref", + "base64 0.21.4", "bincode", "blake3", "bv", @@ -4681,6 +4788,7 @@ dependencies = [ "dir-diff", "flate2", "fnv", + "fs-err", "im", "index_list", "itertools", @@ -4690,24 +4798,28 @@ dependencies = [ "lz4", "memmap2", "modular-bitfield", - "num-derive", + "num-derive 0.3.3", "num-traits", "num_cpus", "num_enum 0.6.1", - "once_cell", "ouroboros", "percentage", - "rand 0.7.3", + "qualifier_attr", + "rand 0.8.5", "rayon", "regex", "rustc_version", "serde", "serde_derive", + "serde_json", + "siphasher", + "solana-accounts-db", "solana-address-lookup-table-program", "solana-bpf-loader-program", "solana-bucket-map", "solana-compute-budget-program", "solana-config-program", + "solana-cost-model", "solana-frozen-abi", "solana-frozen-abi-macro", "solana-loader-v4-program", @@ -4719,6 +4831,8 @@ dependencies = [ "solana-sdk", "solana-stake-program", "solana-system-program", + "solana-version", + "solana-vote", "solana-vote-program", "solana-zk-token-proof-program", "solana-zk-token-sdk", @@ -4734,14 +4848,14 @@ dependencies = [ [[package]] name = "solana-sdk" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57f4046d0d487e3d79be809ff29c63c1484793956e6ccbc5d3307b0aafbf989d" +checksum = "f1628655c50328b0a676b1a956bfbdd39e4ee8e1d48f59aaa907da16393c742b" dependencies = [ "assert_matches", "base64 0.21.4", "bincode", - "bitflags 1.3.2", + "bitflags 2.4.0", "borsh 0.10.3", "bs58", "bytemuck", @@ -4759,13 +4873,14 @@ dependencies = [ "libsecp256k1 0.6.0", "log", "memmap2", - "num-derive", + "num-derive 0.3.3", "num-traits", "num_enum 0.6.1", "pbkdf2 0.11.0", "qstring", + "qualifier_attr", "rand 0.7.3", - "rand_chacha 0.2.2", + "rand 0.8.5", "rustc_version", "rustversion", "serde", @@ -4787,22 +4902,28 @@ dependencies = [ [[package]] name = "solana-sdk-macro" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "760fdfd4b7edb02fd9173a6dcec899ffae06ac21b66b65f8c7c5f3d17b12fa64" +checksum = "a17489fa2101a7bfbd19629e53f6801f4428c584a5964acfc861d0151eb9b502" dependencies = [ "bs58", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "rustversion", - "syn 2.0.37", + "syn 2.0.48", ] +[[package]] +name = "solana-security-txt" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "468aa43b7edb1f9b7b7b686d5c3aeb6630dc1708e86e31343499dd5c4d775183" + [[package]] name = "solana-stake-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d2be095a8ec22b7856b182b9de2067e2ab91570f0cafbca46d39bebe119e791" +checksum = "73571d611f591e1bdfbf746bc4b574e9a8036f8f611e623922f3a5c5f458b15b" dependencies = [ "bincode", "log", @@ -4815,9 +4936,9 @@ dependencies = [ [[package]] name = "solana-storage-bigtable" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3729c426b3b7702b4d56c0f19a4056f324dd703de1a6d445e950967711fd720" +checksum = "fdfb546939ab7dbb65c52f0d5057d576fa3662426a4c79fc44ec072cf741b9a6" dependencies = [ "backoff", "bincode", @@ -4849,9 +4970,9 @@ dependencies = [ [[package]] name = "solana-storage-proto" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0124784702a3ad8d1cba35ec8868cda27b0cfe8d6bca744322b65e4ec0b0d76" +checksum = "0ab4a4b6e4e4a66174a7abad173c692affe018f4bed31dec7e9943073687be9b" dependencies = [ "bincode", "bs58", @@ -4866,16 +4987,16 @@ dependencies = [ [[package]] name = "solana-streamer" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0125d00ca7e8e67d12f7f192a18d1dff2801a9c3e3239033af40b3e72ad92d76" +checksum = "2881a1815bccd67fc0a3587e1a753d17a04e55ac3a59820e30c43f8e47faac1f" dependencies = [ "async-channel", "bytes", "crossbeam-channel", "futures-util", "histogram", - "indexmap 1.9.3", + "indexmap 2.2.2", "itertools", "libc", "log", @@ -4885,10 +5006,9 @@ dependencies = [ "pkcs8", "quinn", "quinn-proto", - "quinn-udp", - "rand 0.7.3", + "rand 0.8.5", "rcgen", - "rustls 0.20.9", + "rustls", "solana-metrics", "solana-perf", "solana-sdk", @@ -4899,9 +5019,9 @@ dependencies = [ [[package]] name = "solana-system-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5d4305ec995efdf6c01ba055833e0f225461ed73c66fd715bb1d566b983bc1c" +checksum = "5acb8e57fca3c5115e5c4fc7c71bd4c87e4d3fbfb5f75037579728b9b9d2b98a" dependencies = [ "bincode", "log", @@ -4913,9 +5033,9 @@ dependencies = [ [[package]] name = "solana-thin-client" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61b6137bb86d37323482474d841dd5baba41d5e3cb8827e4f0f5e37e9ff09153" +checksum = "c9da32840c38fdbb5867ee8ec4501d48ccb5f6bfbc5d20e506af92fa5b6891c8" dependencies = [ "bincode", "log", @@ -4928,17 +5048,16 @@ dependencies = [ [[package]] name = "solana-tpu-client" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fe350f0f2e6a098c118e9a5820280bb3c512f27560ad848f793825f2cd76fa5" +checksum = "57763d8c245ccd9b06b7402ddb7bf3979ce0cd3be728a37d7612e15b71f5c86c" dependencies = [ "async-trait", "bincode", "futures-util", - "indexmap 1.9.3", + "indexmap 2.2.2", "indicatif", "log", - "rand 0.7.3", "rayon", "solana-connection-cache", "solana-measure", @@ -4953,14 +5072,14 @@ dependencies = [ [[package]] name = "solana-transaction-status" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bdf7379a72c051d7879f1c36cfdab5fed0653a2a613718bc5d343e44e603401" +checksum = "d374b4db545fe897d8f111d4b0150cd6417a94c7612724a2367fd268ff0d3bb2" dependencies = [ "Inflector", "base64 0.21.4", "bincode", - "borsh 0.9.3", + "borsh 0.10.3", "bs58", "lazy_static", "log", @@ -4968,20 +5087,19 @@ dependencies = [ "serde_derive", "serde_json", "solana-account-decoder", - "solana-address-lookup-table-program", "solana-sdk", - "spl-associated-token-account", - "spl-memo", - "spl-token", - "spl-token-2022", + "spl-associated-token-account 2.3.0", + "spl-memo 4.0.0", + "spl-token 4.0.0", + "spl-token-2022 1.0.0", "thiserror", ] [[package]] name = "solana-udp-client" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22c5d62db9c69e8eced8eb8fdb1f8317dbcb3ad37cb5cc0d495aec85b5a46f7f" +checksum = "8b4f8e8f987147c994c5b9ab78c0d85aa9d749fb82a01f7fd5d637eb0af8891a" dependencies = [ "async-trait", "solana-connection-cache", @@ -4994,9 +5112,9 @@ dependencies = [ [[package]] name = "solana-version" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d62712e119d6c616d1dea0fa5c1464f7316abe446e0b1eb4796cc9c77324c69" +checksum = "4e712bd25a150e931a4abf20b1116d640b37a646446dd0e336b4431277d8b473" dependencies = [ "log", "rustc_version", @@ -5008,15 +5126,34 @@ dependencies = [ "solana-sdk", ] +[[package]] +name = "solana-vote" +version = "1.17.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b064b3a81238229ae29cab8866ffb7076067b8fe518d75e22923a7f000b419c" +dependencies = [ + "crossbeam-channel", + "itertools", + "log", + "rustc_version", + "serde", + "serde_derive", + "solana-frozen-abi", + "solana-frozen-abi-macro", + "solana-sdk", + "solana-vote-program", + "thiserror", +] + [[package]] name = "solana-vote-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfde11af84827c25b484baf1743b5d0db068af32cf2e4f533148a2d2a31c2263" +checksum = "ca84f0eab3aa693d5af43d062c2c54022fc7ca0ea8792bd74d03e5120b4ea0f6" dependencies = [ "bincode", "log", - "num-derive", + "num-derive 0.3.3", "num-traits", "rustc_version", "serde", @@ -5032,13 +5169,12 @@ dependencies = [ [[package]] name = "solana-zk-token-proof-program" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2633ae5b15fd52b3c1c625d17b62284b328d67ee0b801c2bacb7e7429874e5bd" +checksum = "cc617d1bc29188034a5e2780f9eaa25b8eb844387e09e6b9f1ec1e7e966b004a" dependencies = [ "bytemuck", - "getrandom 0.1.16", - "num-derive", + "num-derive 0.3.3", "num-traits", "solana-program-runtime", "solana-sdk", @@ -5047,9 +5183,9 @@ dependencies = [ [[package]] name = "solana-zk-token-sdk" -version = "1.16.14" +version = "1.17.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3bdec366a15133a70a8dfc4f027b5d0f508bd7cb46af11971076c9ebaf9ede2d" +checksum = "0800a272fd47a03ec1a322078e7bef1d988c3d3d576c9d79547af55cbe1f8eab" dependencies = [ "aes-gcm-siv", "base64 0.21.4", @@ -5061,7 +5197,7 @@ dependencies = [ "itertools", "lazy_static", "merlin", - "num-derive", + "num-derive 0.3.3", "num-traits", "rand 0.7.3", "serde", @@ -5076,9 +5212,9 @@ dependencies = [ [[package]] name = "solana_rbpf" -version = "0.6.1" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17d4ba1e58947346e360fabde0697029d36ba83c42f669199b16a8931313cf29" +checksum = "3d457cc2ba742c120492a64b7fa60e22c575e891f6b55039f4d736568fb112a3" dependencies = [ "byteorder", "combine", @@ -5123,11 +5259,62 @@ checksum = "978dba3bcbe88d0c2c58366c254d9ea41c5f73357e72fc0bdee4d6b5fc99c8f4" dependencies = [ "assert_matches", "borsh 0.9.3", - "num-derive", + "num-derive 0.3.3", "num-traits", "solana-program", - "spl-token", - "spl-token-2022", + "spl-token 3.5.0", + "spl-token-2022 0.6.1", + "thiserror", +] + +[[package]] +name = "spl-associated-token-account" +version = "2.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "992d9c64c2564cc8f63a4b508bf3ebcdf2254b0429b13cd1d31adb6162432a5f" +dependencies = [ + "assert_matches", + "borsh 0.10.3", + "num-derive 0.4.2", + "num-traits", + "solana-program", + "spl-token 4.0.0", + "spl-token-2022 1.0.0", + "thiserror", +] + +[[package]] +name = "spl-discriminator" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "daa600f2fe56f32e923261719bae640d873edadbc5237681a39b8e37bfd4d263" +dependencies = [ + "bytemuck", + "solana-program", + "spl-discriminator-derive", +] + +[[package]] +name = "spl-discriminator-derive" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07fd7858fc4ff8fb0e34090e41d7eb06a823e1057945c26d480bfc21d2338a93" +dependencies = [ + "quote", + "spl-discriminator-syn", + "syn 2.0.48", +] + +[[package]] +name = "spl-discriminator-syn" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18fea7be851bd98d10721782ea958097c03a0c2a07d8d4997041d0ece6319a63" +dependencies = [ + "proc-macro2", + "quote", + "sha2 0.10.7", + "syn 2.0.48", "thiserror", ] @@ -5140,6 +5327,67 @@ dependencies = [ "solana-program", ] +[[package]] +name = "spl-memo" +version = "4.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0f180b03318c3dbab3ef4e1e4d46d5211ae3c780940dd0a28695aba4b59a75a" +dependencies = [ + "solana-program", +] + +[[package]] +name = "spl-pod" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85a5db7e4efb1107b0b8e52a13f035437cdcb36ef99c58f6d467f089d9b2915a" +dependencies = [ + "borsh 0.10.3", + "bytemuck", + "solana-program", + "solana-zk-token-sdk", + "spl-program-error", +] + +[[package]] +name = "spl-program-error" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e0657b6490196971d9e729520ba934911ff41fbb2cb9004463dbe23cf8b4b4f" +dependencies = [ + "num-derive 0.4.2", + "num-traits", + "solana-program", + "spl-program-error-derive", + "thiserror", +] + +[[package]] +name = "spl-program-error-derive" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1845dfe71fd68f70382232742e758557afe973ae19e6c06807b2c30f5d5cb474" +dependencies = [ + "proc-macro2", + "quote", + "sha2 0.10.7", + "syn 2.0.48", +] + +[[package]] +name = "spl-tlv-account-resolution" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56f335787add7fa711819f9e7c573f8145a5358a709446fe2d24bf2a88117c90" +dependencies = [ + "bytemuck", + "solana-program", + "spl-discriminator", + "spl-pod", + "spl-program-error", + "spl-type-length-value", +] + [[package]] name = "spl-token" version = "3.5.0" @@ -5148,13 +5396,28 @@ checksum = "8e85e168a785e82564160dcb87b2a8e04cee9bfd1f4d488c729d53d6a4bd300d" dependencies = [ "arrayref", "bytemuck", - "num-derive", + "num-derive 0.3.3", "num-traits", "num_enum 0.5.11", "solana-program", "thiserror", ] +[[package]] +name = "spl-token" +version = "4.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08459ba1b8f7c1020b4582c4edf0f5c7511a5e099a7a97570c9698d4f2337060" +dependencies = [ + "arrayref", + "bytemuck", + "num-derive 0.3.3", + "num-traits", + "num_enum 0.6.1", + "solana-program", + "thiserror", +] + [[package]] name = "spl-token-2022" version = "0.6.1" @@ -5163,16 +5426,96 @@ checksum = "0043b590232c400bad5ee9eb983ced003d15163c4c5d56b090ac6d9a57457b47" dependencies = [ "arrayref", "bytemuck", - "num-derive", + "num-derive 0.3.3", "num-traits", "num_enum 0.5.11", "solana-program", "solana-zk-token-sdk", - "spl-memo", - "spl-token", + "spl-memo 3.0.1", + "spl-token 3.5.0", + "thiserror", +] + +[[package]] +name = "spl-token-2022" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d697fac19fd74ff472dfcc13f0b442dd71403178ce1de7b5d16f83a33561c059" +dependencies = [ + "arrayref", + "bytemuck", + "num-derive 0.4.2", + "num-traits", + "num_enum 0.7.2", + "solana-program", + "solana-security-txt", + "solana-zk-token-sdk", + "spl-memo 4.0.0", + "spl-pod", + "spl-token 4.0.0", + "spl-token-group-interface", + "spl-token-metadata-interface", + "spl-transfer-hook-interface", + "spl-type-length-value", "thiserror", ] +[[package]] +name = "spl-token-group-interface" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b889509d49fa74a4a033ca5dae6c2307e9e918122d97e58562f5c4ffa795c75d" +dependencies = [ + "bytemuck", + "solana-program", + "spl-discriminator", + "spl-pod", + "spl-program-error", +] + +[[package]] +name = "spl-token-metadata-interface" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c16ce3ba6979645fb7627aa1e435576172dd63088dc7848cb09aa331fa1fe4f" +dependencies = [ + "borsh 0.10.3", + "solana-program", + "spl-discriminator", + "spl-pod", + "spl-program-error", + "spl-type-length-value", +] + +[[package]] +name = "spl-transfer-hook-interface" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7aabdb7c471566f6ddcee724beb8618449ea24b399e58d464d6b5bc7db550259" +dependencies = [ + "arrayref", + "bytemuck", + "solana-program", + "spl-discriminator", + "spl-pod", + "spl-program-error", + "spl-tlv-account-resolution", + "spl-type-length-value", +] + +[[package]] +name = "spl-type-length-value" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f9ebd75d29c5f48de5f6a9c114e08531030b75b8ac2c557600ac7da0b73b1e8" +dependencies = [ + "bytemuck", + "solana-program", + "spl-discriminator", + "spl-pod", + "spl-program-error", +] + [[package]] name = "static_assertions" version = "1.1.0" @@ -5207,8 +5550,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59" dependencies = [ "heck", - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "rustversion", "syn 1.0.109", ] @@ -5225,36 +5568,25 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a7973cce6668464ea31f176d85b13c7ab3bba2cb3b77a2ed26abd7801688010a" -[[package]] -name = "syn" -version = "0.15.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ca4b3b69a77cbe1ffc9e198781b7acb0c7365a883670e8f1c1bc66fba79a5c5" -dependencies = [ - "proc-macro2 0.4.30", - "quote 0.6.13", - "unicode-xid 0.1.0", -] - [[package]] name = "syn" version = "1.0.109" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "unicode-ident", ] [[package]] name = "syn" -version = "2.0.37" +version = "2.0.48" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7303ef2c05cd654186cb250d29049a24840ca25d2747c25c0381c8d9e2f582e8" +checksum = "0f3531638e407dfc0814761abb7c00a5b54992b849452a0646b7f65c9f770f3f" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "unicode-ident", ] @@ -5270,10 +5602,10 @@ version = "0.12.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", + "proc-macro2", + "quote", "syn 1.0.109", - "unicode-xid 0.2.4", + "unicode-xid", ] [[package]] @@ -5326,22 +5658,22 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "thiserror" -version = "1.0.48" +version = "1.0.56" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d6d7a740b8a666a7e828dd00da9c0dc290dff53154ea77ac109281de90589b7" +checksum = "d54378c645627613241d077a3a79db965db602882668f9136ac42af9ecb730ad" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.48" +version = "1.0.56" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49922ecae66cc8a249b77e68d1d0623c1b2c514f0060c27cdc68bd62a1219d35" +checksum = "fa0faa943b50f3db30a20aa7e265dbc66076993efed8463e8de414e5d06d3471" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -5441,9 +5773,9 @@ version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -5456,24 +5788,13 @@ dependencies = [ "tokio", ] -[[package]] -name = "tokio-rustls" -version = "0.23.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c43ee83903113e03984cb9e5cebe6c04a5116269e900e3ddba8f068a62adda59" -dependencies = [ - "rustls 0.20.9", - "tokio", - "webpki", -] - [[package]] name = "tokio-rustls" version = "0.24.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c28327cf380ac148141087fbfb9de9d7bd4e84ab5d2c28fbc911d753de8a7081" dependencies = [ - "rustls 0.21.7", + "rustls", "tokio", ] @@ -5490,18 +5811,17 @@ dependencies = [ [[package]] name = "tokio-tungstenite" -version = "0.17.2" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f714dd15bead90401d77e04243611caec13726c2408afd5b31901dfcdcb3b181" +checksum = "212d5dcb2a1ce06d81107c3d0ffa3121fe974b73f068c8282cb1c32328113b6c" dependencies = [ "futures-util", "log", - "rustls 0.20.9", + "rustls", "tokio", - "tokio-rustls 0.23.4", + "tokio-rustls", "tungstenite", - "webpki", - "webpki-roots 0.22.6", + "webpki-roots 0.25.2", ] [[package]] @@ -5539,21 +5859,21 @@ version = "0.19.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" dependencies = [ - "indexmap 2.0.0", + "indexmap 2.2.2", "toml_datetime", "winnow", ] [[package]] name = "tonic" -version = "0.8.3" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f219fad3b929bef19b1f86fbc0358d35daed8f2cac972037ac0dc10bbb8d5fb" +checksum = "3082666a3a6433f7f511c7192923fa1fe07c69332d3c6a2e6bb040b569199d5a" dependencies = [ "async-stream", "async-trait", "axum", - "base64 0.13.1", + "base64 0.21.4", "bytes", "futures-core", "futures-util", @@ -5565,29 +5885,26 @@ dependencies = [ "percent-encoding", "pin-project", "prost", - "prost-derive", "rustls-pemfile", "tokio", - "tokio-rustls 0.23.4", + "tokio-rustls", "tokio-stream", - "tokio-util", "tower", "tower-layer", "tower-service", "tracing", - "tracing-futures", ] [[package]] name = "tonic-build" -version = "0.8.4" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bf5e9b9c0f7e0a7c027dcfaba7b2c60816c7049171f679d99ee2ff65d0de8c4" +checksum = "a6fdaae4c2c638bb70fe42803a26fbd6fc6ac8c72f5c59f67ecc2a2dcabf4b07" dependencies = [ "prettyplease 0.1.25", - "proc-macro2 1.0.67", + "proc-macro2", "prost-build", - "quote 1.0.33", + "quote", "syn 1.0.109", ] @@ -5630,6 +5947,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" dependencies = [ "cfg-if", + "log", "pin-project-lite", "tracing-attributes", "tracing-core", @@ -5641,9 +5959,9 @@ version = "0.1.26" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] @@ -5655,16 +5973,6 @@ dependencies = [ "once_cell", ] -[[package]] -name = "tracing-futures" -version = "0.2.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97d095ae15e245a057c8e8451bab9b3ee1e1f68e9ba2b4fbc18d0ac5237835f2" -dependencies = [ - "pin-project", - "tracing", -] - [[package]] name = "trees" version = "0.4.2" @@ -5679,24 +5987,23 @@ checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" [[package]] name = "tungstenite" -version = "0.17.3" +version = "0.20.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e27992fd6a8c29ee7eef28fc78349aa244134e10ad447ce3b9f0ac0ed0fa4ce0" +checksum = "9e3dac10fd62eaf6617d3a904ae222845979aec67c615d1c842b4002c7666fb9" dependencies = [ - "base64 0.13.1", "byteorder", "bytes", + "data-encoding", "http", "httparse", "log", "rand 0.8.5", - "rustls 0.20.9", - "sha-1", + "rustls", + "sha1", "thiserror", "url", "utf-8", - "webpki", - "webpki-roots 0.22.6", + "webpki-roots 0.24.0", ] [[package]] @@ -5732,12 +6039,6 @@ version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e51733f11c9c4f72aa0c160008246859e340b00807569a0da0e7a1079b27ba85" -[[package]] -name = "unicode-xid" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc72304796d0818e357ead4e000d19c9c174ab23dc11093ac919054d20a6a7fc" - [[package]] name = "unicode-xid" version = "0.2.4" @@ -5876,9 +6177,9 @@ dependencies = [ "bumpalo", "log", "once_cell", - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", "wasm-bindgen-shared", ] @@ -5900,7 +6201,7 @@ version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" dependencies = [ - "quote 1.0.33", + "quote", "wasm-bindgen-macro-support", ] @@ -5910,9 +6211,9 @@ version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -5933,23 +6234,13 @@ dependencies = [ "wasm-bindgen", ] -[[package]] -name = "webpki" -version = "0.22.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0e74f82d49d545ad128049b7e88f6576df2da6b02e9ce565c6f533be576957e" -dependencies = [ - "ring", - "untrusted", -] - [[package]] name = "webpki-roots" -version = "0.22.6" +version = "0.24.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c71e40d7d2c34a5106301fb632274ca37242cd0c9d3e64dbece371a40a2d87" +checksum = "b291546d5d9d1eab74f069c77749f2cb8504a12caa20f0f2de93ddbf6f411888" dependencies = [ - "webpki", + "rustls-webpki", ] [[package]] @@ -6010,21 +6301,6 @@ dependencies = [ "windows-targets 0.48.5", ] -[[package]] -name = "windows-sys" -version = "0.42.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" -dependencies = [ - "windows_aarch64_gnullvm 0.42.2", - "windows_aarch64_msvc 0.42.2", - "windows_i686_gnu 0.42.2", - "windows_i686_msvc 0.42.2", - "windows_x86_64_gnu 0.42.2", - "windows_x86_64_gnullvm 0.42.2", - "windows_x86_64_msvc 0.42.2", -] - [[package]] name = "windows-sys" version = "0.45.0" @@ -6212,6 +6488,26 @@ dependencies = [ "time", ] +[[package]] +name = "zerocopy" +version = "0.7.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74d4d3961e53fa4c9a25a8637fc2bfaf2595b3d3ae34875568a5cf64787716be" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.7.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.48", +] + [[package]] name = "zeroize" version = "1.3.0" @@ -6227,9 +6523,9 @@ version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ - "proc-macro2 1.0.67", - "quote 1.0.33", - "syn 2.0.37", + "proc-macro2", + "quote", + "syn 2.0.48", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 47925bf..bd6dab4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "poc-framework" -version = "0.3.0" +version = "0.4.0" authors = [] edition = "2018" repository = "https://github.com/neodyme-labs/solana-poc-framework" @@ -14,22 +14,24 @@ itertools = "0.10.1" bincode = "1.3.3" rand = "0.7.3" borsh = "0.9.1" -solana-sdk = "~1.16" -solana-program = "~1.16" -solana-logger = "~1.16" -solana-runtime = "~1.16" -solana-transaction-status = "~1.16" -solana-cli-output = "~1.16" -solana-bpf-loader-program = "~1.16" -solana-compute-budget-program = "~1.16" -solana-vote-program = "~1.16" -solana-stake-program = "~1.16" -solana-config-program = "~1.16" -solana-client = "~1.16" -solana-faucet = "~1.16" -solana-program-runtime = "~1.16" -solana-ledger = "~1.16" +solana-sdk = "=1.17.17" +solana-program = "=1.17.17" +solana-logger = "=1.17.17" +solana-runtime = "=1.17.17" +solana-transaction-status = "=1.17.17" +solana-cli-output = "=1.17.17" +solana-bpf-loader-program = "=1.17.17" +solana-compute-budget-program = "=1.17.17" +solana-vote-program = "=1.17.17" +solana-stake-program = "=1.17.17" +solana-config-program = "=1.17.17" +solana-client = "=1.17.17" +solana-faucet = "=1.17.17" +solana-program-runtime = "=1.17.17" +solana-ledger = "=1.17.17" +solana-accounts-db = "=1.17.17" spl-token = "3.3.0" +spl-token-2022 = "1.0.0" spl-memo = "3.0.1" spl-associated-token-account = "1.0.5" serde = "1.0.125" diff --git a/src/lib.rs b/src/lib.rs index 1d45633..defb55f 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -7,18 +7,23 @@ use std::{ time::{SystemTime, UNIX_EPOCH}, }; -use borsh::BorshDeserialize; +use borsh::{BorshDeserialize, BorshSerialize}; use bpf_loader_upgradeable::UpgradeableLoaderState; use itertools::izip; use rand::{prelude::StdRng, rngs::OsRng, SeedableRng}; use serde::de::DeserializeOwned; use sha2::{Digest, Sha256}; +use solana_accounts_db::{ + accounts_db::AccountShrinkThreshold, + accounts_index::AccountSecondaryIndexes, + transaction_results::{TransactionExecutionResult, TransactionResults}, +}; use solana_cli_output::display::println_transaction; use solana_client::{rpc_client::RpcClient, rpc_config::RpcTransactionConfig}; use solana_program::{ bpf_loader, bpf_loader_upgradeable, hash::Hash, - instruction::Instruction, + instruction::{AccountMeta, Instruction}, loader_instruction, message::Message, program_option::COption, @@ -28,9 +33,7 @@ use solana_program::{ sysvar::{self, rent}, }; use solana_runtime::{ - accounts_db::AccountShrinkThreshold, - accounts_index::AccountSecondaryIndexes, - bank::{Bank, TransactionBalancesSet, TransactionExecutionResult, TransactionResults}, + bank::{Bank, TransactionBalancesSet}, genesis_utils, runtime_config::RuntimeConfig, }; @@ -39,9 +42,8 @@ use solana_sdk::{ commitment_config::CommitmentConfig, feature_set, genesis_config::GenesisConfig, - packet, - signature::Keypair, - signature::Signer, + packet::{self, PACKET_DATA_SIZE}, + signature::{Keypair, Signature, Signer}, system_transaction, transaction::{Transaction, VersionedTransaction}, }; @@ -62,6 +64,7 @@ pub use solana_transaction_status; pub use spl_associated_token_account; pub use spl_memo; pub use spl_token; +pub use spl_token_2022; mod keys; mod programs; @@ -71,7 +74,7 @@ pub trait Environment { /// Returns the keypair used to pay for all transactions. All transaction fees and rent costs are payed for by this keypair. fn payer(&self) -> Keypair; /// Executes the batch of transactions in the right order and waits for them to be confirmed. The execution results are returned. - fn execute_transaction(&mut self, txs: T) -> EncodedConfirmedTransactionWithStatusMeta + fn execute_transaction(&mut self, tx: T) -> EncodedConfirmedTransactionWithStatusMeta where VersionedTransaction: From; /// Fetch a recent blockhash, for construction of transactions. @@ -158,7 +161,7 @@ pub trait Environment { signers: &[&Keypair], ) -> EncodedConfirmedTransactionWithStatusMeta { let tx = self.tx_with_instructions(instructions, signers); - return self.execute_transaction(tx); + self.execute_transaction(tx) } /// Assemble the given instructions into a transaction and sign it. All transactions executed by this method are signed and payed for by the payer. @@ -169,7 +172,7 @@ pub trait Environment { new_payer: Keypair, ) -> EncodedConfirmedTransactionWithStatusMeta { let tx = self.tx_with_instructions_with_payer(instructions, signers, new_payer); - return self.execute_transaction(tx); + self.execute_transaction(tx) } /// Assemble the given instructions into a transaction and sign it. All transactions executed by this method are signed and payed for by the payer. @@ -181,7 +184,7 @@ pub trait Environment { ) -> EncodedConfirmedTransactionWithStatusMeta { let tx = self.tx_with_instructions(instructions, signers); println!("{:#?}", &tx); - return self.execute_transaction(tx); + self.execute_transaction(tx) } /// Assemble the given instructions into a transaction and sign it. All transactions executed by this method are signed and payed for by the new_payer. @@ -194,7 +197,7 @@ pub trait Environment { ) -> EncodedConfirmedTransactionWithStatusMeta { let tx = self.tx_with_instructions_with_payer(instructions, signers, new_payer); println!("{:#?}", &tx); - return self.execute_transaction(tx); + self.execute_transaction(tx) } /// Executes a transaction constructing an empty account with the specified amount of space and lamports, owned by the provided program. @@ -321,9 +324,77 @@ pub trait Environment { acc } + /// Execute a transaction creating and filling a given account with the given data. + /// The account is required to be empty and will be owned by spl_shared_memory afterwards. + // Development note: Prefer this function due to efficiencies. + fn create_account_with_data(&mut self, account: &Keypair, data: &[u8]) { + let shared_memory_program_id: Pubkey = "shmem4EWT2sPdVGvTZCzXXRAURL9G5vpPxNwSeKhHUL" + .parse() + .unwrap(); + // Calculate the largest chunk size that can be written to the account in a single transaction. + let chunk_size = PACKET_DATA_SIZE.saturating_sub(1).saturating_sub( + bincode::serialized_size(&Transaction { + signatures: vec![Signature::default()], + message: Message::new( + &[Instruction::new_with_bincode( + shared_memory_program_id, + &[0u64], + vec![AccountMeta::new(account.pubkey(), false)], + )], + Some(&self.payer().pubkey()), + ), + }) + .unwrap() as usize, + ); + + self.execute_as_transaction( + &[system_instruction::create_account( + &self.payer().pubkey(), + &account.pubkey(), + self.get_rent_excemption(data.len()), + data.len() as u64, + &shared_memory_program_id, + )], + &[&self.payer(), account], + ) + .assert_success(); + + let mut offset = 0usize; + for chunk in data.chunks(chunk_size) { + println!("writing bytes {} to {}", offset, offset + chunk.len()); + let tx_data = [&(offset as u64).to_le_bytes(), chunk].concat(); + self.execute_as_transaction( + &[Instruction::new_with_bytes( + shared_memory_program_id, + &tx_data, + vec![AccountMeta::new(account.pubkey(), false)], + )], + &[], + ) + .assert_success(); + offset += chunk.len(); + } + } + + /// Execute a transaction creating and filling a given account with the given data. + /// Serializes the data using bincode. + fn create_account_with_bincode( + &mut self, + account: &Keypair, + data: &T, + ) { + self.create_account_with_data(account, &bincode::serialize(&data).unwrap()); + } + + /// Execute a transaction creating and filling a given account with the given data. + /// Serializes the data using borsh. + fn create_account_with_borsh(&mut self, account: &Keypair, data: &T) { + self.create_account_with_data(account, &data.try_to_vec().unwrap()); + } + /// Executes a transaction creating and filling the given account with the given data. /// The account is required to be empty and will be owned by bpf_loader afterwards. - fn create_account_with_data(&mut self, account: &Keypair, data: Vec) { + fn create_program_account_with_data(&mut self, account: &Keypair, data: &[u8]) { self.execute_transaction(system_transaction::create_account( &self.payer(), account, @@ -361,7 +432,7 @@ pub trait Environment { let keypair = Keypair::generate(&mut rng); if self.get_account(keypair.pubkey()).is_none() { - self.create_account_with_data(&keypair, data); + self.create_program_account_with_data(&keypair, &data); self.execute_as_transaction( &[loader_instruction::finalize( &keypair.pubkey(), @@ -417,47 +488,44 @@ impl LocalEnvironment { } /// Advance the bank to the next blockhash. - pub fn advance_blockhash(&self) -> Hash { - let parent_distance = if self.bank.slot() == 0 { - 1 - } else { - self.bank.slot() - self.bank.parent_slot() - }; + pub fn advance_blockhash(self) -> Self { + let new_slot = self.bank.slot().saturating_add(1); - for _ in 0..parent_distance { - let last_blockhash = self.bank.last_blockhash(); - while self.bank.last_blockhash() == last_blockhash { - self.bank.register_tick(&Hash::new_unique()) - } + while !self.bank.is_complete() { + self.bank.register_tick(&Hash::new_unique()); } - self.get_latest_blockhash() - } -} - -impl Environment for LocalEnvironment { - fn payer(&self) -> Keypair { - clone_keypair(&self.faucet) + LocalEnvironment { + bank: Bank::new_from_parent(Arc::new(self.bank), &self.faucet.pubkey(), new_slot), + faucet: self.faucet, + } } - fn execute_transaction(&mut self, tx: T) -> EncodedConfirmedTransactionWithStatusMeta + pub fn execute_transactions( + &mut self, + txs: Vec, + ) -> Vec where VersionedTransaction: From, { - let tx = tx.into(); - let len = bincode::serialize(&tx).unwrap().len(); - if len > packet::PACKET_DATA_SIZE { - panic!( - "tx {:?} of size {} is {} too large", - tx, - len, - len - packet::PACKET_DATA_SIZE - ) - } - let txs = vec![tx]; - + let txs = txs + .into_iter() + .map(|tx| { + let tx = VersionedTransaction::from(tx); + let len = bincode::serialize(&tx).unwrap().len(); + if len > packet::PACKET_DATA_SIZE { + panic!( + "tx {:?} of size {} is {} too large", + tx, + len, + len - packet::PACKET_DATA_SIZE + ) + } + tx + }) + .collect::>(); let batch = self.bank.prepare_entry_batch(txs.clone()).unwrap(); - let tx_sanitized = batch.sanitized_transactions()[0].clone(); + let txs_sanitized = batch.sanitized_transactions(); let mut mint_decimals = HashMap::new(); let tx_pre_token_balances = solana_ledger::token_balances::collect_token_balances( @@ -492,103 +560,128 @@ impl Environment for LocalEnvironment { &batch, &mut mint_decimals, ); - let ( + + let mut encoded_confirmed_txs = vec![]; + + for ( tx, execution_result, pre_balances, post_balances, pre_token_balances, post_token_balances, - ) = izip!( + tx_sanitized, + ) in izip!( txs.iter(), execution_results.into_iter(), pre_balances.into_iter(), post_balances.into_iter(), tx_pre_token_balances.into_iter(), tx_post_token_balances.into_iter(), - ).next().expect("transaction could not be executed. Enable debug logging to get more information on why"); - - let fee = self - .bank - .get_fee_for_message(tx_sanitized.message()) - .expect("Fee calculation must succeed"); - - let status; - let inner_instructions; - let log_messages; - let return_data; - let compute_units_consumed; - - match execution_result { - TransactionExecutionResult::Executed { details, .. } => { - status = details.status; - inner_instructions = details.inner_instructions; - log_messages = details.log_messages; - return_data = details.return_data; - compute_units_consumed = Some(details.executed_units); - } - TransactionExecutionResult::NotExecuted(err) => { - status = Err(err); - inner_instructions = None; - log_messages = None; - return_data = None; - compute_units_consumed = None; + txs_sanitized.into_iter(), + ) { + let fee = self + .bank + .get_fee_for_message(tx_sanitized.message()) + .expect("Fee calculation must succeed"); + + let status; + let inner_instructions; + let log_messages; + let return_data; + let compute_units_consumed; + + match execution_result { + TransactionExecutionResult::Executed { details, .. } => { + status = details.status; + inner_instructions = details.inner_instructions; + log_messages = details.log_messages; + return_data = details.return_data; + compute_units_consumed = Some(details.executed_units); + } + TransactionExecutionResult::NotExecuted(err) => { + status = Err(err); + inner_instructions = None; + log_messages = None; + return_data = None; + compute_units_consumed = None; + } } + + let inner_instructions = inner_instructions.map(|inner_instructions| { + inner_instructions + .into_iter() + .enumerate() + .map(|(index, instructions)| { + let inner_ixs_mapped = instructions + .into_iter() + .map(|x| solana_transaction_status::InnerInstruction { + instruction: x.instruction, + stack_height: Some(x.stack_height as u32), + }) + .collect(); + InnerInstructions { + index: index as u8, + instructions: inner_ixs_mapped, + } + }) + .filter(|i| !i.instructions.is_empty()) + .collect() + }); + let tx_status_meta = TransactionStatusMeta { + status, + fee, + pre_balances, + post_balances, + pre_token_balances: Some(pre_token_balances), + post_token_balances: Some(post_token_balances), + inner_instructions, + log_messages, + rewards: None, + loaded_addresses: tx_sanitized.get_loaded_addresses(), + return_data, + compute_units_consumed, + }; + encoded_confirmed_txs.push( + ConfirmedTransactionWithStatusMeta { + slot, + tx_with_meta: TransactionWithStatusMeta::Complete( + VersionedTransactionWithStatusMeta { + transaction: tx.clone(), + meta: tx_status_meta, + }, + ), + block_time: Some( + SystemTime::now() + .duration_since(UNIX_EPOCH) + .unwrap() + .as_secs() + .try_into() + .unwrap(), + ), + } + .encode(UiTransactionEncoding::Binary, Some(0)) + .expect("Failed to encode transaction"), + ); } + encoded_confirmed_txs + } +} - let inner_instructions = inner_instructions.map(|inner_instructions| { - inner_instructions - .into_iter() - .enumerate() - .map(|(index, instructions)| { - let inner_ixs_mapped = instructions - .into_iter() - .map(|x| solana_transaction_status::InnerInstruction { - instruction: x.instruction, - stack_height: Some(x.stack_height as u32), - }) - .collect(); - InnerInstructions { - index: index as u8, - instructions: inner_ixs_mapped, - } - }) - .filter(|i| !i.instructions.is_empty()) - .collect() - }); - - let tx_status_meta = TransactionStatusMeta { - status, - fee, - pre_balances, - post_balances, - pre_token_balances: Some(pre_token_balances), - post_token_balances: Some(post_token_balances), - inner_instructions, - log_messages, - rewards: None, - loaded_addresses: tx_sanitized.get_loaded_addresses(), - return_data, - compute_units_consumed, - }; +impl Environment for LocalEnvironment { + fn payer(&self) -> Keypair { + clone_keypair(&self.faucet) + } - ConfirmedTransactionWithStatusMeta { - slot, - tx_with_meta: TransactionWithStatusMeta::Complete(VersionedTransactionWithStatusMeta { - transaction: tx.clone(), - meta: tx_status_meta, - }), - block_time: Some( - SystemTime::now() - .duration_since(UNIX_EPOCH) - .unwrap() - .as_secs() - .try_into() - .unwrap(), - ), - } - .encode(UiTransactionEncoding::Binary, Some(0)) - .expect("Failed to encode transaction") + fn execute_transaction(&mut self, tx: T) -> EncodedConfirmedTransactionWithStatusMeta + where + VersionedTransaction: From, + { + let tx: VersionedTransaction = tx.into(); + self.execute_transactions::(vec![tx]) + .into_iter() + .next() + .unwrap() } fn get_latest_blockhash(&self) -> Hash { @@ -620,10 +713,11 @@ impl LocalEnvironmentBuilder { &[], ); genesis_utils::activate_all_features(&mut config); - // Deactivate fix_recent_blockhashes feature to allow for advancing blockhashes without creating new banks + + // Deactiveate delay_visibility_of_program_deployment to allow to programs to run on the same slot they are deployed on config .accounts - .remove(&feature_set::fix_recent_blockhashes::id()); + .remove(&feature_set::delay_visibility_of_program_deployment::id()); let mut builder = LocalEnvironmentBuilder { faucet, config }; builder.add_account_with_data( @@ -642,6 +736,20 @@ impl LocalEnvironmentBuilder { ); builder.add_account_with_data(spl_memo::ID, bpf_loader::ID, programs::SPL_MEMO3, true); builder.add_account_with_data(spl_token::ID, bpf_loader::ID, programs::SPL_TOKEN, true); + builder.add_account_with_data( + spl_token_2022::ID, + bpf_loader::ID, + programs::SPL_TOKEN_2022, + true, + ); + builder.add_account_with_data( + "shmem4EWT2sPdVGvTZCzXXRAURL9G5vpPxNwSeKhHUL" + .parse() + .unwrap(), + bpf_loader::ID, + programs::SPL_SHARED_MEMORY, + true, + ); builder.add_account_with_lamports(rent::ID, sysvar::ID, 1); builder } @@ -858,16 +966,14 @@ impl LocalEnvironmentBuilder { false, None, None, - &exit, + exit, ); let env = LocalEnvironment { bank, faucet: clone_keypair(&self.faucet), }; - env.advance_blockhash(); - - env + env.advance_blockhash() } } diff --git a/src/programs.rs b/src/programs.rs index 61c2bf5..e87c567 100644 --- a/src/programs.rs +++ b/src/programs.rs @@ -6,3 +6,7 @@ pub const SPL_MEMO1: &[u8] = include_bytes!("programs/spl_memo-1.0.0.so"); pub const SPL_MEMO3: &[u8] = include_bytes!("programs/spl_memo-3.0.0.so"); pub const SPL_TOKEN: &[u8] = include_bytes!("programs/spl_token-4.0.0.so"); + +pub const SPL_TOKEN_2022: &[u8] = include_bytes!("programs/spl_token_2022-1.0.0.so"); + +pub const SPL_SHARED_MEMORY: &[u8] = include_bytes!("programs/spl_shared_memory-2.0.6.so"); diff --git a/src/programs/spl_shared_memory-2.0.6.so b/src/programs/spl_shared_memory-2.0.6.so new file mode 100644 index 0000000..4df7a14 Binary files /dev/null and b/src/programs/spl_shared_memory-2.0.6.so differ diff --git a/src/programs/spl_token_2022-1.0.0.so b/src/programs/spl_token_2022-1.0.0.so new file mode 100644 index 0000000..796fafc Binary files /dev/null and b/src/programs/spl_token_2022-1.0.0.so differ