diff --git a/Cargo.lock b/Cargo.lock index a79731d9..07c39bc5 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -103,8 +103,8 @@ checksum = "cf7d535e1381be3de2c0716c0a1c1e32ad9df1042cddcf7bc18d743569e53319" dependencies = [ "anchor-syn", "anyhow", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "regex", "syn 1.0.107", ] @@ -118,8 +118,8 @@ dependencies = [ "anchor-syn", "anyhow", "bs58 0.4.0", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "rustversion", "syn 1.0.107", ] @@ -131,7 +131,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e1be64a48e395fe00b8217287f226078be2cf32dae42fdf8a885b997945c3d28" dependencies = [ "anchor-syn", - "proc-macro2 1.0.49", + "proc-macro2 1.0.86", "syn 1.0.107", ] @@ -142,8 +142,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "38ea6713d1938c0da03656ff8a693b17dc0396da66d1ba320557f07e86eca0d4" dependencies = [ "anchor-syn", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -155,8 +155,8 @@ checksum = "d401f11efb3644285685f8339829a9786d43ed7490bb1699f33c478d04d5a582" dependencies = [ "anchor-syn", "anyhow", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -169,8 +169,8 @@ dependencies = [ "anchor-syn", "anyhow", "heck 0.3.3", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -182,8 +182,8 @@ checksum = "6ad769993b5266714e8939e47fbdede90e5c030333c7522d99a4d4748cf26712" dependencies = [ "anchor-syn", "anyhow", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -195,8 +195,8 @@ checksum = "4e677fae4a016a554acdd0e3b7f178d3acafaa7e7ffac6b8690cf4e171f1c116" dependencies = [ "anchor-syn", "anyhow", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -208,8 +208,8 @@ checksum = "340beef6809d1c3fcc7ae219153d981e95a8a277ff31985bd7050e32645dc9a8" dependencies = [ "anchor-syn", "anyhow", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -258,9 +258,9 @@ dependencies = [ "anyhow", "bs58 0.3.1", "heck 0.3.3", - "proc-macro2 1.0.49", + "proc-macro2 1.0.86", "proc-macro2-diagnostics", - "quote 1.0.23", + "quote 1.0.36", "serde", "serde_json", "sha2 0.9.8", @@ -285,9 +285,9 @@ checksum = "159bb86af3a200e19a068f4224eae4c8bb2d0fa054c7e5d1cacd5cef95e684cd" [[package]] name = "arrayref" -version = "0.3.6" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544" +checksum = "6b4930d2cb77ce62f89ee5d5289b4ac049559b1c45539271f5ed4fdc7db34545" [[package]] name = "arrayvec" @@ -314,7 +314,7 @@ dependencies = [ "num-traits", "rusticata-macros", "thiserror", - "time 0.3.15", + "time 0.3.17", ] [[package]] @@ -323,8 +323,8 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "726535892e8eae7e70657b4c8ea93d26b8553afb1ce617caee529ef96d7dee6c" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", "synstructure", ] @@ -335,8 +335,8 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2777730b2039ac0f95f093556e61b6d26cebed5393ca6f152717777cec3a42ed" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -375,8 +375,8 @@ version = "0.1.60" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "677d1d8ab452a3936018a687b20e6f7cf5363d713b732b8884001317b0e48aa3" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -497,7 +497,7 @@ dependencies = [ "borsh-derive-internal", "borsh-schema-derive-internal", "proc-macro-crate 0.1.5", - "proc-macro2 1.0.49", + "proc-macro2 1.0.86", "syn 1.0.107", ] @@ -507,8 +507,8 @@ version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5449c28a7b352f2d1e592a8a28bf139bc71afb0764a14f3c02500935d8c44065" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -518,8 +518,8 @@ version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cdbd5696d8bfa21d53d9fe39a714a18538bad11492a42d066dbbc395fb1951c0" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -587,8 +587,8 @@ version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5fe233b960f12f8007e3db2d136e3cb1c291bfd7396e384ee76025fc1a3932b4" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -606,9 +606,9 @@ checksum = "c4872d67bab6358e59559027aa3b9157c53d9358c51423c17554809a8858e0f8" [[package]] name = "bzip2" -version = "0.4.3" +version = "0.4.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6afcd980b5f3a45017c57e57a2fcccbb351cc43a356ce117ef760ef8052b89b0" +checksum = "bdb116a6ef3f6c3698828873ad02c3014b3c85cadb88496095628e3ef1e347f8" dependencies = [ "bzip2-sys", "libc", @@ -970,8 +970,8 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1042,8 +1042,8 @@ version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3bf95dc3f046b9da4f2d51833c0d3547d8564ef6910f5c1ed130306a75b92886" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1118,8 +1118,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f86b50932a01e7ec5c06160492ab660fb19b6bb2a7878030dd6cd68d21df9d4d" dependencies = [ "enum-ordinalize", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1159,8 +1159,8 @@ version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8958699f9359f0b04e691a13850d48b7de329138023876d07cbd024c2c820598" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1172,8 +1172,8 @@ checksum = "0b166c9e378360dd5a6666a9604bb4f54ae0cac39023ffbac425e917a2a04fef" dependencies = [ "num-bigint 0.4.3", "num-traits", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1184,8 +1184,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0eb359f1476bf611266ac1f5355bc14aeca37b299d0ebccc038ee7058891c9cb" dependencies = [ "once_cell", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1315,8 +1315,8 @@ version = "0.3.25" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bdfb8ce053d86b91919aad980c220b1fb8401a9394410e1c289ed7e66b61835d" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1842,6 +1842,15 @@ dependencies = [ "cfg-if", ] +[[package]] +name = "lru" +version = "0.7.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e999beba7b6e8345721bd280141ed958096a2e4abdf74f67ff4ce49b4b54e47a" +dependencies = [ + "hashbrown 0.12.3", +] + [[package]] name = "lz4" version = "1.24.0" @@ -1963,8 +1972,8 @@ version = "0.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5a7d5f7076603ebc68de2dc6a650ec331a062a13abaa346975be747bbfa4b789" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -1974,7 +1983,6 @@ version = "0.0.1" dependencies = [ "anchor-lang", "anchor-spl", - "bytemuck", "static_assertions", ] @@ -2061,8 +2069,8 @@ version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -2135,20 +2143,11 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "486ea01961c4a818096de679a8b740b26d9033146ac5291b1c98557658f8cdd9" dependencies = [ "proc-macro-crate 1.1.0", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] -[[package]] -name = "num_threads" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c7398b9c8b70908f6371f47ed36737907c87c52af34c268fed0bf0ceb92ead9" -dependencies = [ - "libc", -] - [[package]] name = "number_prefix" version = "0.4.0" @@ -2225,8 +2224,8 @@ checksum = "4a0d9d1a6191c4f391f87219d1ea42b23f09ee84d64763cd05ee6ea88d9f384d" dependencies = [ "Inflector", "proc-macro-error", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -2335,8 +2334,8 @@ version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6e8fe8163d14ce7f0cdac2e040116f22eac817edabff0be91e8aff7e9accf389" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -2419,8 +2418,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" dependencies = [ "proc-macro-error-attr", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", "version_check", ] @@ -2431,8 +2430,8 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "version_check", ] @@ -2447,9 +2446,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.49" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57a8eca9f9c4ffde41714334dee777596264c7825420f521abc92b5b5deb63a5" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -2460,8 +2459,8 @@ version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4bf29726d67464d49fa6224a1d07936a8c08bb3fba727c7493f6cf1616fdaada" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", "version_check", "yansi", @@ -2540,11 +2539,11 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.23" +version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8856d8364d252a14d474036ea1358d63c9e6965c8e5c1885c18f73d70bff9c7b" +checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ - "proc-macro2 1.0.49", + "proc-macro2 1.0.86", ] [[package]] @@ -2657,7 +2656,7 @@ checksum = "6413f3de1edee53342e6138e75b56d32e7bc6e332b3bd62d497b1929d4cfbcdd" dependencies = [ "pem", "ring", - "time 0.3.15", + "time 0.3.17", "yasna", ] @@ -2899,8 +2898,8 @@ version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bdbda6ac5cd1321e724fa9cee216f3a61885889b896f073b8f82322789c5250e" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -2945,9 +2944,9 @@ checksum = "58bc9567378fc7690d6b2addae4e60ac2eeea07becb2c64b9f218b53865cba2a" [[package]] name = "serde" -version = "1.0.151" +version = "1.0.203" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97fed41fc1a24994d044e6db6935e69511a1153b52c15eb42493b26fa87feba0" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" dependencies = [ "serde_derive", ] @@ -2963,13 +2962,13 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.151" +version = "1.0.203" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "255abe9a125a985c05190d687b320c12f9b1f0b99445e608c21ba0782c719ad8" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.86", + "quote 1.0.36", + "syn 2.0.68", ] [[package]] @@ -3122,9 +3121,9 @@ dependencies = [ [[package]] name = "solana-account-decoder" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "701ca0143761d40eb6e2933e8854d1c0a2918ede7419264b71bd142980c5fb32" +checksum = "ec36d5c2ec5469dacc4fd2bdfcaaf4b253a4814d86d88686d50fd407cf7b3330" dependencies = [ "Inflector", "base64 0.13.0", @@ -3147,9 +3146,9 @@ dependencies = [ [[package]] name = "solana-address-lookup-table-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03f403a837de4e5d6135bb8100b7aa982a1e5ecc166386258ce3583cd12e2d7c" +checksum = "bf23fb5a4ff0e902bf94fbc63ba51b10b1f86c6bca18574b583ec3baf6383a0b" dependencies = [ "bincode", "bytemuck", @@ -3168,9 +3167,9 @@ dependencies = [ [[package]] name = "solana-banks-client" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff6ec147cbc090269a141bfb8956e376c024aa7bf5813eb34c8288145a96595a" +checksum = "5ac06cef7cc665bf5cfcca5a370a112ae16d079cbff249cf7f257dd634b3df02" dependencies = [ "borsh", "futures", @@ -3185,9 +3184,9 @@ dependencies = [ [[package]] name = "solana-banks-interface" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c283d14c217ebb5aaa59cbcd3ed75df50f52074504aead0a1b1504d68a009a10" +checksum = "23be20887818b249d54c784baef2079e6961d0bf540f4cccc6154a5c7c898a1e" dependencies = [ "serde", "solana-sdk", @@ -3196,9 +3195,9 @@ dependencies = [ [[package]] name = "solana-banks-server" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d1c8a1bac13f3b79ab5b1b9d40236a1c968002a33007b33dff1909b89783ecc" +checksum = "4e58560a27b4f2632248f586cbe47da610903a3a66c910cf46936013fb4c8ab3" dependencies = [ "bincode", "crossbeam-channel", @@ -3216,9 +3215,9 @@ dependencies = [ [[package]] name = "solana-bpf-loader-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d288b850b004df3b5ac8af53b0510c5fdf37a2240b6bdd2fb78f4625d30fa497" +checksum = "05f7265b69671abf989ce40fd2d8d089e2f931cccfbdebeeb81134f3a37554b7" dependencies = [ "bincode", "byteorder", @@ -3235,9 +3234,9 @@ dependencies = [ [[package]] name = "solana-bucket-map" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9df2cd8e820633da71a0167054a42d191bc829a00636d994cf92dec0a045445f" +checksum = "2fbbb3fa652dfea91b7576f1ffd0dbc04c8d497c62de4260ea6352f274e688b8" dependencies = [ "log", "memmap2", @@ -3250,9 +3249,9 @@ dependencies = [ [[package]] name = "solana-clap-utils" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94635c6ba33899361777993370090a027abcefda4463f0f51863e0508cc0cd8a" +checksum = "39e6537858df8634c4cf7e9e8a84a9f1967b8983bcb4e4833cad3ae200b7170d" dependencies = [ "chrono", "clap 2.34.0", @@ -3268,9 +3267,9 @@ dependencies = [ [[package]] name = "solana-cli-config" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f3185e08728970d1cb67dbcd887180feef72d05b2c0a3a3c61af7f3df5383ed" +checksum = "2234deff9765c25fc6189322689d1b702490f4389680dfdef0af582856041844" dependencies = [ "dirs-next", "lazy_static", @@ -3284,9 +3283,9 @@ dependencies = [ [[package]] name = "solana-client" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1263dd1bd7473cc367e703f5198396e11dc83be37d10fb3f12fceca0a1eec749" +checksum = "e706f894fe68d518c125e27a7186d07a56f5b179d67c8fb2cf719cef8e1ee7cd" dependencies = [ "async-mutex", "async-trait", @@ -3338,9 +3337,9 @@ dependencies = [ [[package]] name = "solana-compute-budget-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abbbf355bee3a5ce0ac65d34ab892b866f064af0f84cfbbd9ae2316488a03fa9" +checksum = "29801945272acb8d0cf1eb46f6f9f17c630b1c1dc5f95cd1d4833e16313b3561" dependencies = [ "solana-program-runtime", "solana-sdk", @@ -3348,9 +3347,9 @@ dependencies = [ [[package]] name = "solana-config-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16219e0c1b2f0c919f238c8951078b45b9c6c00b18acec547eebe2821d2db916" +checksum = "645c2d438fdfa4f5774c70fb0eeb2325caa073c838a229ef6a876c65c8703294" dependencies = [ "bincode", "chrono", @@ -3362,9 +3361,9 @@ dependencies = [ [[package]] name = "solana-faucet" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435cfeb35c5f1e67e7e2ad5ac4106f04edaca0609ad52dbbc7ac051d884d6eca" +checksum = "3ba3e5e2acc09b2fcb54957d05c0943b194d48f825f879fc2cf5d255e2608b05" dependencies = [ "bincode", "byteorder", @@ -3386,9 +3385,9 @@ dependencies = [ [[package]] name = "solana-frozen-abi" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c5a383f43792311db749bbed4e7794222c9f118b609bc8252b4ea3ad88b4188" +checksum = "23b4953578272ac0fadec245e85e83ae86454611f0c0a7fff7d906835124bdcf" dependencies = [ "ahash", "blake3", @@ -3420,21 +3419,21 @@ dependencies = [ [[package]] name = "solana-frozen-abi-macro" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "062e282539e770967500945cd2fdb78170a1ea45aff7ad1b4ce4e2cc0b557db8" +checksum = "57892538250428ad3dc3cbe05f6cd75ad14f4f16734fcb91bc7cd5fbb63d6315" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "rustc_version", "syn 1.0.107", ] [[package]] name = "solana-logger" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c2bcbaba2c683e7bf80ff4f3a3cdcdaabdb0b21333e8d89aed06be136193d39" +checksum = "06aa701c49493e93085dd1e800c05475baca15a9d4d527b59794f2ed0b66e055" dependencies = [ "env_logger", "lazy_static", @@ -3443,9 +3442,9 @@ dependencies = [ [[package]] name = "solana-measure" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33bbb0e7ee37cdfd18f2636e687cfafcc2e85a7768e283941fd08da022bd0f66" +checksum = "f7300180957635b33c88bd6844a5dff4f1f5c6352d0861ee7845eab84185aa6a" dependencies = [ "log", "solana-sdk", @@ -3453,9 +3452,9 @@ dependencies = [ [[package]] name = "solana-metrics" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f77f7044d57975f001a2c8f3756e4a04f10ca886c69eb8ce0b1786aad52c663d" +checksum = "2960981c4bbe9177dafe986542ba11a10afcae320f4201aa809cd5b650e202e1" dependencies = [ "crossbeam-channel", "gethostname", @@ -3467,9 +3466,9 @@ dependencies = [ [[package]] name = "solana-net-utils" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96e4f0b106e881e087226056612ed06ad3c4ff6260d3f9a1c1d54649c127d34f" +checksum = "31062ce5ddceb92bdb78df2eaf33e9889c1519e8a8d89baa783e2d08a76cfc62" dependencies = [ "bincode", "clap 3.2.23", @@ -3489,9 +3488,9 @@ dependencies = [ [[package]] name = "solana-perf" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c02d0782ecaf35dafc7a88c63ec1f265edf6051b55489180d95757d71a4d66d6" +checksum = "23b2b84a3d7a24523b9117c0ae4608f1e561ae492638acea2bb2960a0c0c8eb6" dependencies = [ "ahash", "bincode", @@ -3516,9 +3515,9 @@ dependencies = [ [[package]] name = "solana-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75602376f2cea17ac301292a3ded6db73e968310ac482857237d95a34473b62a" +checksum = "3f99052873619df68913cb8e92e28ff251a5483828925e87fa97ba15a9cbad51" dependencies = [ "base64 0.13.0", "bincode", @@ -3565,9 +3564,9 @@ dependencies = [ [[package]] name = "solana-program-runtime" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eb4a1b61c005eb9c0767b215e428c51adfa6e0023691d37f05653a4cd29bce2b" +checksum = "4d57d0b6ef85b50f9ad6b9a75fc9d5051dc26f8b1a4ddf03656e3d603e139eb3" dependencies = [ "base64 0.13.0", "bincode", @@ -3592,9 +3591,9 @@ dependencies = [ [[package]] name = "solana-program-test" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20b272afb2c20891cd073aa1c8c437b1f6c4cf9e2140b167f4656f59eea12d7" +checksum = "e16f6b85c477d0bb6c661555a4740e77188d378a5e6ba09e42a7ec5e03c65323" dependencies = [ "assert_matches", "async-trait", @@ -3617,9 +3616,9 @@ dependencies = [ [[package]] name = "solana-rayon-threadlimit" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7091fe2ae498f482f549450e9c5c04e89867dd8622612c742e7c1586b11cc2c1" +checksum = "10e1d068ba8080ca1e41703c600cc9b263ff7ce26b6811cd83221723ae0d10ae" dependencies = [ "lazy_static", "num_cpus", @@ -3627,9 +3626,9 @@ dependencies = [ [[package]] name = "solana-remote-wallet" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "874c76b56601eaf7a91a4d119824b57625c638ce42c601166d1e44eef4b28fc6" +checksum = "661cd486da7419134663f1c3684d71d3fd6d13b8e557da23070f4c920b1d2baa" dependencies = [ "console", "dialoguer", @@ -3646,9 +3645,9 @@ dependencies = [ [[package]] name = "solana-runtime" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77c023c21c8c5015113a33b1ec3644d913db2a591e06e6cca9a647bc9a0f58c0" +checksum = "6e79c7c2bfc2308bac38952759713fe3d50c127f3f8a001bead82c02c385a050" dependencies = [ "arrayref", "bincode", @@ -3667,6 +3666,7 @@ dependencies = [ "itertools", "lazy_static", "log", + "lru", "lz4", "memmap2", "num-derive", @@ -3706,9 +3706,9 @@ dependencies = [ [[package]] name = "solana-sdk" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a46085d2548bb943e7210b28b09378e361350577b391a94457ad78af1a9f75ef" +checksum = "edb47da3e18cb669f6ace0b40cee0610e278903783e0c9f7fce1e1beb881a1b7" dependencies = [ "assert_matches", "base64 0.13.0", @@ -3757,22 +3757,22 @@ dependencies = [ [[package]] name = "solana-sdk-macro" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "faa38323e649c70b698e49f1ded17849a9b5da2e0821a38ad08327307009e274" +checksum = "7d41a09b9cecd0a4df63c78a192adee99ebf2d3757c19713a68246e1d9789c7c" dependencies = [ "bs58 0.4.0", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "rustversion", "syn 1.0.107", ] [[package]] name = "solana-send-transaction-service" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0df295d36fc53f0a87d00334fef1fc68242b695531719685a160c190ac938da1" +checksum = "79a75165c4ee1cc3723961f26f96ffd7618d4fd7ae84f45a3cc3503bff5dae96" dependencies = [ "crossbeam-channel", "log", @@ -3785,9 +3785,9 @@ dependencies = [ [[package]] name = "solana-stake-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c2463c564273fdabc6eb5d8aeacf4440aad54fcebf3b1bd57c12b5af81c299c" +checksum = "42a3aca202edb3d30cc711e55469e9efebebbf8ccbda702a9df8c72c8a8feb0c" dependencies = [ "bincode", "log", @@ -3808,9 +3808,9 @@ dependencies = [ [[package]] name = "solana-streamer" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "57ec79681ce38d1b80ffad5507a4b25f6fc9eba827a589fc789561a022a605cf" +checksum = "a2ffb2c6918eda6aa8b18219790b7a4e4d74914aeae97cb1a0e09fdb943b18cc" dependencies = [ "crossbeam-channel", "futures-util", @@ -3837,9 +3837,9 @@ dependencies = [ [[package]] name = "solana-transaction-status" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72d3da9fd5d3d7b7c0bc8c071e614c15f73d75612b1a724a4ebf3139458cbb24" +checksum = "df1a6ee396d436ae4ee36350043c3cb34ad66b7515f045c1e5006695559d88ac" dependencies = [ "Inflector", "base64 0.13.0", @@ -3866,9 +3866,9 @@ dependencies = [ [[package]] name = "solana-version" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9592a3fb652a0b84593e18935db930e5f7e9614efaf26e15f3cace1c6d47151" +checksum = "d177dc97f7facd8fbc3148f3d44a9ff5bbbc72c1db7e2889dc4911ae641cea8a" dependencies = [ "log", "rustc_version", @@ -3882,9 +3882,9 @@ dependencies = [ [[package]] name = "solana-vote-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1eddab05371499a937a222f101fd9e2b708b87c575ca3cf01e0c012e14aff79d" +checksum = "6280815d28c90ea8f51c8eb2026258e8693cab5a8456ee7b207a791b20f9c576" dependencies = [ "bincode", "log", @@ -3903,9 +3903,9 @@ dependencies = [ [[package]] name = "solana-zk-token-proof-program" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82ca75686a92656caf2aa29c66020dc1b2e1b1cc7ffce6ada8a6f89201d84d54" +checksum = "ba228bf732741df3b21222beadf86407f54a814d621b478c0666da06d1ef1083" dependencies = [ "bytemuck", "getrandom 0.1.16", @@ -3918,9 +3918,9 @@ dependencies = [ [[package]] name = "solana-zk-token-sdk" -version = "1.14.11" +version = "1.14.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d81faf1b8f5c550923f01e9b2c41aec8f646cceff7fd72ca6712d10a4022f163" +checksum = "7ab38abd096769f79fd8e3fe8465070f04742395db724606a5263c8ebc215567" dependencies = [ "aes-gcm-siv", "arrayref", @@ -3999,9 +3999,9 @@ dependencies = [ [[package]] name = "spl-governance" -version = "2.2.1" +version = "3.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c13bfa6d1b1e922fe0dca06ec53a43fd56706906586fe8d0154f420c78af5aa" +checksum = "f7a42340af2f3334ee1ee718e6d68b939c98cab4ceb381429f952c72d68e1ebf" dependencies = [ "arrayref", "bincode", @@ -4019,9 +4019,9 @@ dependencies = [ [[package]] name = "spl-governance-addin-api" -version = "0.1.1" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9451f56e707e635a40a285965e1927733c956a0049a08f4b6c80215445aba7f1" +checksum = "1e0feddb2c7efa42f39954e3bb1b0bfc6dc7e9292ca467eff40ecd934c14106b" dependencies = [ "borsh", "solana-program", @@ -4030,9 +4030,9 @@ dependencies = [ [[package]] name = "spl-governance-tools" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a206f0837415046d919f3075d6b3af9bd3f1f707c887898c335a6210b194627" +checksum = "3bd674d9e8f3fc9ea628dcbe56d48991ea1cb05b994a7845782572c705efd836" dependencies = [ "arrayref", "bincode", @@ -4122,8 +4122,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59" dependencies = [ "heck 0.4.0", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "rustversion", "syn 1.0.107", ] @@ -4157,8 +4157,19 @@ version = "1.0.107" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1f4064b5b16e03ae50984a5a8ed5d4f8803e6bc1fd170a3cda91a1be4b18e3f5" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "2.0.68" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "901fa70d88b9d6c98022e23b4136f9f3e54e4662c3bc1bd1d84a42a9a0f0c1e9" +dependencies = [ + "proc-macro2 1.0.86", + "quote 1.0.36", "unicode-ident", ] @@ -4168,8 +4179,8 @@ version = "0.12.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", "unicode-xid 0.2.2", ] @@ -4215,8 +4226,8 @@ version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0ee42b4e559f17bce0385ebf511a7beb67d5cc33c12c96b7f4e9789919d9c10f" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -4283,8 +4294,8 @@ version = "1.0.38" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1fb327af4685e4d03fa8cbcf1716380da910eeb2bb8be417e7f9fd3fb164f36f" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -4310,21 +4321,30 @@ dependencies = [ [[package]] name = "time" -version = "0.3.15" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d634a985c4d4238ec39cacaed2e7ae552fbd3c476b552c1deac3021b7d7eaf0c" +checksum = "a561bf4617eebd33bca6434b988f39ed798e527f51a1e797d0ee4f61c0a38376" dependencies = [ "itoa 1.0.1", - "libc", - "num_threads", + "serde", + "time-core", "time-macros", ] +[[package]] +name = "time-core" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" + [[package]] name = "time-macros" -version = "0.2.4" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42657b1a6f4d817cda8e7a0ace261fe0cc946cf3a80314390b22cc61ae080792" +checksum = "d967f99f534ca7e495c575c62638eebc2898a8c84c119b89e250477bc4ba16b2" +dependencies = [ + "time-core", +] [[package]] name = "tiny-bip39" @@ -4386,8 +4406,8 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c9efc1aba077437943f7515666aa2b882dfabfbfdf89c819ea75a8d6e9eaba5e" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -4508,8 +4528,8 @@ version = "0.1.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f4f480b8f81512e825f337ad51e94c1eb5d3bbdf2b363dcd01e2b19a9ffe3f8e" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", ] @@ -4769,8 +4789,8 @@ dependencies = [ "bumpalo", "log", "once_cell", - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", "wasm-bindgen-shared", ] @@ -4793,7 +4813,7 @@ version = "0.2.83" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "052be0f94026e6cbc75cdefc9bae13fd6052cdcaf532fa6c45e7ae33a1e6c810" dependencies = [ - "quote 1.0.23", + "quote 1.0.36", "wasm-bindgen-macro-support", ] @@ -4803,8 +4823,8 @@ version = "0.2.83" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "07bc0c051dc5f23e307b13285f9d75df86bfdf816c5721e573dec1f9b8aa193c" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", "wasm-bindgen-backend", "wasm-bindgen-shared", @@ -5000,7 +5020,7 @@ dependencies = [ "oid-registry", "rusticata-macros", "thiserror", - "time 0.3.15", + "time 0.3.17", ] [[package]] @@ -5033,7 +5053,7 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "aed2e7a52e3744ab4d0c05c20aa065258e84c49fd4226f5191b2ed29712710b4" dependencies = [ - "time 0.3.15", + "time 0.3.17", ] [[package]] @@ -5051,8 +5071,8 @@ version = "1.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "65f1a51723ec88c66d5d1fe80c841f17f63587d6691901d66be9bec6c3b51f73" dependencies = [ - "proc-macro2 1.0.49", - "quote 1.0.23", + "proc-macro2 1.0.86", + "quote 1.0.36", "syn 1.0.107", "synstructure", ] diff --git a/Cargo.toml b/Cargo.toml index ae5a23fb..7fddbb6d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -6,5 +6,13 @@ members = [ # Otherwise the build will fail since Anchor uploads only parts of the source tree. ] +[workspace.dependencies] +solana-program = "1.14.10" +solana-sdk = "1.14.10" +solana-program-test = "1.14.10" +anchor-lang = "0.26.0" +anchor-spl = "0.26.0" +static_assertions = "1.1" + [profile.release] overflow-checks = true diff --git a/program-states/Cargo.toml b/program-states/Cargo.toml index 629449b7..c24dcf71 100644 --- a/program-states/Cargo.toml +++ b/program-states/Cargo.toml @@ -1,3 +1,4 @@ +cargo-features = ["workspace-inheritance"] [package] name = "mplx-staking-states" version = "0.0.1" @@ -14,7 +15,6 @@ crate-type = ["cdylib", "lib"] test-sbf = [] [dependencies] -anchor-lang = { version = "0.26.0", features = ["init-if-needed"] } -anchor-spl = { version = "0.26.0" } -static_assertions = "1.1" -bytemuck = "1.9.1" \ No newline at end of file +anchor-lang = { workspace = true, features = ["init-if-needed"] } +anchor-spl = { workspace = true } +static_assertions = { workspace = true } \ No newline at end of file diff --git a/programs/voter-stake-registry/Cargo.toml b/programs/voter-stake-registry/Cargo.toml index d95fc1f9..7070bbf8 100644 --- a/programs/voter-stake-registry/Cargo.toml +++ b/programs/voter-stake-registry/Cargo.toml @@ -1,3 +1,4 @@ +cargo-features = ["workspace-inheritance"] [package] name = "voter-stake-registry" version = "0.2.4" @@ -21,31 +22,19 @@ test-sbf = [] [dependencies] # a) for deployment use these -anchor-lang = { version = "0.26.0", features = ["init-if-needed"] } -anchor-spl = { version = "0.26.0" } -# b) while testing, use below dependencies for debugging instead of above ones -# anchor-lang = { git = "https://github.com/microwavedcola1/anchor.git", branch = "master-debug" } -# anchor-spl = { git = "https://github.com/microwavedcola1/anchor.git", branch = "master-debug", features = ["governance"]} - -# The rev used for spl-governance must match what the fixture binary -# programs/voter-stake-registry/tests/fixtures/spl_governance.so is built from. +anchor-lang = { workspace = true, features = ["init-if-needed"] } +anchor-spl = { workspace = true } +solana-program = { workspace = true } +static_assertions = { workspace = true } bytemuck = "1.9.1" - -# WARNING: Be careful about upgrading the spl-governance dependency! -# Recently the discriminator for new VoterWeightRecord accounts has changed, and upgrading -# this dependency here without also upgrading the spl-governance program instance beforehand -# would lead to VWR accounts that are unusable until the spl-governance program is upgraded. -spl-governance = { version = "=2.2.1", features = ["no-entrypoint"] } -spl-governance-addin-api = "=0.1.1" - -solana-program = "1.14.10" -static_assertions = "1.1" +spl-governance = { version = "3.1.1", features = ["no-entrypoint"] } +spl-governance-addin-api = "0.1.3" mplx-staking-states = { path="../../program-states" } [dev-dependencies] -solana-sdk = "1.14.10" -solana-program-test = "1.14.10" +solana-sdk = { workspace = true } +solana-program-test = { workspace = true } spl-token = { version = "^3.0.0", features = ["no-entrypoint"] } spl-associated-token-account = { version = "^1.0.3", features = ["no-entrypoint"] } log = "0.4.14" diff --git a/programs/voter-stake-registry/tests/fixtures/spl_governance.so b/programs/voter-stake-registry/tests/fixtures/spl_governance.so deleted file mode 100755 index daf93351..00000000 Binary files a/programs/voter-stake-registry/tests/fixtures/spl_governance.so and /dev/null differ diff --git a/programs/voter-stake-registry/tests/fixtures/spl_governance_3_1_1.so b/programs/voter-stake-registry/tests/fixtures/spl_governance_3_1_1.so new file mode 100644 index 00000000..8fe929b5 Binary files /dev/null and b/programs/voter-stake-registry/tests/fixtures/spl_governance_3_1_1.so differ diff --git a/programs/voter-stake-registry/tests/program_test/governance.rs b/programs/voter-stake-registry/tests/program_test/governance.rs index d960c880..c4321c75 100644 --- a/programs/voter-stake-registry/tests/program_test/governance.rs +++ b/programs/voter-stake-registry/tests/program_test/governance.rs @@ -4,6 +4,8 @@ use solana_sdk::{ pubkey::Pubkey, signature::{Keypair, Signer}, }; +use spl_governance::state::realm::GoverningTokenConfigAccountArgs; +use spl_governance::state::realm_config::GoverningTokenType; use spl_governance::state::{proposal, vote_record}; use std::rc::Rc; @@ -73,17 +75,22 @@ impl GovernanceCookie { ) .0; + let community_token_args = GoverningTokenConfigAccountArgs { + voter_weight_addin: Some(*voter_weight_addin), + max_voter_weight_addin: None, + token_type: GoverningTokenType::Liquid, + }; let instructions = vec![spl_governance::instruction::create_realm( &self.program_id, &realm_authority, &community_token_mint.pubkey.unwrap(), &payer.pubkey(), None, - Some(*voter_weight_addin), + Some(community_token_args), None, name.to_string(), 0, - spl_governance::state::enums::MintMaxVoteWeightSource::SupplyFraction(10000000000), + spl_governance::state::enums::MintMaxVoterWeightSource::SupplyFraction(10000000000), )]; let signer = Keypair::from_base58_string(&payer.to_base58_string()); @@ -166,14 +173,21 @@ impl GovernanceRealmCookie { &authority.pubkey(), Some(voter.voter_weight_record), spl_governance::state::governance::GovernanceConfig { - vote_threshold_percentage: - spl_governance::state::enums::VoteThresholdPercentage::YesVote(50), + community_vote_threshold: + spl_governance::state::enums::VoteThreshold::YesVotePercentage(50), min_community_weight_to_create_proposal: 1000, min_transaction_hold_up_time: 0, - max_voting_time: 10, - vote_tipping: spl_governance::state::enums::VoteTipping::Disabled, - proposal_cool_off_time: 0, + voting_base_time: 10, + community_vote_tipping: spl_governance::state::enums::VoteTipping::Disabled, min_council_weight_to_create_proposal: 1, + council_vote_threshold: spl_governance::state::enums::VoteThreshold::Disabled, + council_veto_vote_threshold: + spl_governance::state::enums::VoteThreshold::Disabled, + council_vote_tipping: spl_governance::state::enums::VoteTipping::Disabled, + community_veto_vote_threshold: + spl_governance::state::enums::VoteThreshold::Disabled, + voting_cool_off_time: 0, + deposit_exempt_proposal_count: 10, }, ), ]; @@ -221,14 +235,21 @@ impl GovernanceRealmCookie { &authority.pubkey(), Some(voter.voter_weight_record), spl_governance::state::governance::GovernanceConfig { - vote_threshold_percentage: - spl_governance::state::enums::VoteThresholdPercentage::YesVote(50), + community_vote_threshold: + spl_governance::state::enums::VoteThreshold::YesVotePercentage(50), min_community_weight_to_create_proposal: 1000, min_transaction_hold_up_time: 0, - max_voting_time: 10, - vote_tipping: spl_governance::state::enums::VoteTipping::Disabled, - proposal_cool_off_time: 0, + voting_base_time: 10, + community_vote_tipping: spl_governance::state::enums::VoteTipping::Strict, min_council_weight_to_create_proposal: 1, + council_vote_threshold: spl_governance::state::enums::VoteThreshold::Disabled, + council_veto_vote_threshold: + spl_governance::state::enums::VoteThreshold::Disabled, + council_vote_tipping: spl_governance::state::enums::VoteTipping::Disabled, + community_veto_vote_threshold: + spl_governance::state::enums::VoteThreshold::Disabled, + voting_cool_off_time: 0, + deposit_exempt_proposal_count: 10, }, true, ), @@ -259,11 +280,12 @@ impl GovernanceRealmCookie { payer: &Keypair, vwr_instruction: Instruction, ) -> std::result::Result { + let proposal_seed = Pubkey::new_unique(); let proposal = spl_governance::state::proposal::get_proposal_address( &self.governance.program_id, &governance, &self.community_token_mint.pubkey.unwrap(), - &0u32.to_le_bytes(), + &proposal_seed, ); let instructions = vec![ @@ -282,7 +304,7 @@ impl GovernanceRealmCookie { proposal::VoteType::SingleChoice, vec!["yes".into()], true, - 0, + &proposal_seed, ), spl_governance::instruction::add_signatory( &self.governance.program_id, @@ -367,6 +389,7 @@ impl GovernanceRealmCookie { ) -> std::result::Result<(), BanksClientError> { let instructions = vec![spl_governance::instruction::relinquish_vote( &self.governance.program_id, + &self.realm, &governance, &proposal.address, &token_owner_record, diff --git a/programs/voter-stake-registry/tests/program_test/mod.rs b/programs/voter-stake-registry/tests/program_test/mod.rs index a2bb4a82..2d2c8c9c 100644 --- a/programs/voter-stake-registry/tests/program_test/mod.rs +++ b/programs/voter-stake-registry/tests/program_test/mod.rs @@ -121,7 +121,7 @@ impl TestContext { let governance_program_id = Pubkey::from_str("GovernanceProgramTest1111111111111111111111").unwrap(); test.add_program( - "spl_governance", + "spl_governance_3_1_1", governance_program_id, processor!(spl_governance::processor::process_instruction), );