diff --git a/Cargo.lock b/Cargo.lock index 2c1dbfd..3c82b12 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -243,7 +243,7 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" dependencies = [ - "quote 1.0.33", + "quote 1.0.35", "syn 1.0.109", ] @@ -255,8 +255,8 @@ checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" dependencies = [ "num-bigint 0.4.4", "num-traits", - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -291,8 +291,8 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae3281bc6d0fd7e549af32b52511e1302185bd688fd3359fa36423346ff682ea" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -352,8 +352,8 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "726535892e8eae7e70657b4c8ea93d26b8553afb1ce617caee529ef96d7dee6c" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", "synstructure", ] @@ -364,8 +364,8 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2777730b2039ac0f95f093556e61b6d26cebed5393ca6f152717777cec3a42ed" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -411,13 +411,13 @@ dependencies = [ [[package]] name = "async-trait" -version = "0.1.76" +version = "0.1.79" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "531b97fb4cd3dfdce92c35dedbfdc1f0b9d8091c8ca943d6dae340ef5012d514" +checksum = "a507401cad91ec6a857ed5513a2073c82a9b9048762b885bb98655b306964681" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -466,9 +466,9 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.5" +version = "0.21.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35636a1494ede3b646cc98f74f8e62c773a38a659ebc777a2cf26b9b74171df9" +checksum = "9d297deb1925b89f2ccc13d7635fa0714f12c87adce1c75356b39ca9b7178567" [[package]] name = "base64ct" @@ -493,9 +493,9 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.4.1" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "327762f6e5a765692301e5bb513e0d9fef63be86bbc14528052b1cd3e6f03e07" +checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" [[package]] name = "bitmaps" @@ -574,7 +574,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.72", + "proc-macro2 1.0.79", "syn 1.0.109", ] @@ -587,7 +587,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.72", + "proc-macro2 1.0.79", "syn 1.0.109", ] @@ -597,8 +597,8 @@ version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5449c28a7b352f2d1e592a8a28bf139bc71afb0764a14f3c02500935d8c44065" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -608,8 +608,8 @@ version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "afb438156919598d2c7bad7e1c0adf3d26ed3840dbc010db1a882a65583ca2fb" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -619,8 +619,8 @@ version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cdbd5696d8bfa21d53d9fe39a714a18538bad11492a42d066dbbc395fb1951c0" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -630,8 +630,8 @@ version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "634205cc43f74a1b9046ef87c4540ebda95696ec0f315024860cad7c5b0f5ccd" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -693,9 +693,9 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "965ab7eb5f8f97d2a083c799f3a1b994fc397b2fe2da5d1da1626ce15a39f2b1" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -820,9 +820,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cf9804afaaf59a91e75b022a30fb7229a7901f60c755489cc61c9b423b836442" dependencies = [ "heck", - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -870,15 +870,15 @@ dependencies = [ [[package]] name = "console" -version = "0.15.7" +version = "0.15.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c926e00cc70edefdc64d3a5ff31cc65bb97a3460097762bd23afb4d8145fccf8" +checksum = "0e1f83fc076bd6dd27517eacdf25fef6c4dfe5f1d7448bafaaf3a26f13b5e4eb" dependencies = [ "encode_unicode", "lazy_static", "libc", "unicode-width", - "windows-sys 0.45.0", + "windows-sys 0.52.0", ] [[package]] @@ -949,11 +949,10 @@ dependencies = [ [[package]] name = "crossbeam-channel" -version = "0.5.10" +version = "0.5.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82a9b73a36529d9c47029b9fb3a6f0ea3cc916a261195352ba19e770fc1748b2" +checksum = "ab3db02a9c5b5121e1e42fbdb1aeb65f5e02624cc58c43f2884c6ccac0b82f95" dependencies = [ - "cfg-if", "crossbeam-utils", ] @@ -1055,10 +1054,10 @@ checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" dependencies = [ "fnv", "ident_case", - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "strsim 0.10.0", - "syn 2.0.43", + "syn 2.0.57", ] [[package]] @@ -1068,8 +1067,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" dependencies = [ "darling_core", - "quote 1.0.33", - "syn 2.0.43", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -1123,8 +1122,8 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -1187,9 +1186,9 @@ version = "0.2.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -1279,22 +1278,22 @@ dependencies = [ [[package]] name = "enum-iterator" -version = "1.4.1" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7add3873b5dd076766ee79c8e406ad1a472c385476b9e38849f8eec24f1be689" +checksum = "9fd242f399be1da0a5354aa462d57b4ab2b4ee0683cc552f7c007d2d12d36e94" dependencies = [ "enum-iterator-derive", ] [[package]] name = "enum-iterator-derive" -version = "1.2.1" +version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eecf8589574ce9b895052fa12d69af7a233f99e6107f5cb8dd1044f2a17bfdcb" +checksum = "03cdc46ec28bd728e67540c528013c6a10eb69a02eb31078a1bda695438cbfb8" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -1423,9 +1422,9 @@ version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -1852,9 +1851,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.66" +version = "0.3.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cee9c64da59eae3b50095c18d3e74f8b73c0b86d2792824ff01bbce68ba229ca" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" dependencies = [ "wasm-bindgen", ] @@ -1901,9 +1900,9 @@ checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" [[package]] name = "libc" -version = "0.2.151" +version = "0.2.153" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "302d7ab3130588088d277783b1e2d2e10c9e9e4a16dd9050e6ec93fb3e7048f4" +checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" [[package]] name = "libredox" @@ -1911,7 +1910,7 @@ version = "0.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "85c833ca1e66078851dba29046874e38f08b2c883700aa29a03ddd3b23814ee8" dependencies = [ - "bitflags 2.4.1", + "bitflags 2.5.0", "libc", "redox_syscall", ] @@ -2066,8 +2065,6 @@ dependencies = [ [[package]] name = "nifty-asset" version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc61286914c500078d36e89d76313f6a05170f051e05c5026825a299985bb268" dependencies = [ "borsh 0.10.3", "kaigan", @@ -2083,8 +2080,6 @@ dependencies = [ [[package]] name = "nifty-asset-types" version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "726bb0e84e179a3d6fd8e7da05d632d70b3ea797bb431779c9ac8c4512cdc5d4" dependencies = [ "borsh 0.10.3", "bytemuck", @@ -2098,6 +2093,7 @@ name = "nifty-cli" version = "0.0.0" dependencies = [ "anyhow", + "bincode", "borsh 0.9.3", "clap 4.4.12", "dirs", @@ -2193,8 +2189,8 @@ version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", ] @@ -2204,9 +2200,9 @@ version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cfb77679af88f8b125209d354a202862602672222e7f2313fdd6dc349bad4712" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -2272,11 +2268,11 @@ dependencies = [ [[package]] name = "num_enum" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "683751d591e6d81200c39fb0d1032608b77724f34114db54f571ff1317b337c0" +checksum = "02339744ee7253741199f897151b38e72257d13802d4ee837285cc2990a90845" dependencies = [ - "num_enum_derive 0.7.1", + "num_enum_derive 0.7.2", ] [[package]] @@ -2286,21 +2282,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" dependencies = [ "proc-macro-crate 1.3.1", - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] name = "num_enum_derive" -version = "0.7.1" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c11e44798ad209ccdd91fc192f0526a369a01234f7373e1b141c96d7cee4f0e" +checksum = "681030a937600a36906c185595136d26abfebb4aa9c65701cefcaf8578bb982b" dependencies = [ - "proc-macro-crate 2.0.1", - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro-crate 3.1.0", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -2523,12 +2519,11 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "2.0.1" +version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "97dc5fea232fc28d2f597b37c4876b348a40e33f3b02cc975c8d006d78d94b1a" +checksum = "6d37c51ca738a55da99dc0c4a34860fd675453b8b36209178c2249bb13651284" dependencies = [ - "toml_datetime", - "toml_edit 0.20.2", + "toml_edit 0.21.1", ] [[package]] @@ -2542,9 +2537,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.72" +version = "1.0.79" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a293318316cf6478ec1ad2a21c49390a8d5b5eae9fab736467d93fbc0edc29c5" +checksum = "e835ff2298f5721608eb1a980ecaee1aef2c132bf95ecc026a11b7bf3c01c02e" dependencies = [ "unicode-ident", ] @@ -2619,11 +2614,11 @@ dependencies = [ [[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.72", + "proc-macro2 1.0.79", ] [[package]] @@ -2708,9 +2703,9 @@ dependencies = [ [[package]] name = "rayon" -version = "1.8.0" +version = "1.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c27db03db7734835b3f53954b534c91069375ce6ccaa2e065441e07d9b6cdb1" +checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa" dependencies = [ "either", "rayon-core", @@ -2718,9 +2713,9 @@ dependencies = [ [[package]] name = "rayon-core" -version = "1.12.0" +version = "1.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ce3fb6ad83f861aac485e76e1985cd109d9a3713802152be56c3b1f0e0658ed" +checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2" dependencies = [ "crossbeam-deque", "crossbeam-utils", @@ -2794,7 +2789,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "37b1ae8d9ac08420c66222fb9096fc5de435c3c48542bc5336c51892cffafb41" dependencies = [ "async-compression", - "base64 0.21.5", + "base64 0.21.7", "bytes", "encoding_rs", "futures-core", @@ -2924,7 +2919,7 @@ version = "0.38.28" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "72e572a5e8ca657d7366229cdde4bd14c4eb5499a9573d4d366fe1b599daa316" dependencies = [ - "bitflags 2.4.1", + "bitflags 2.5.0", "errno", "libc", "linux-raw-sys", @@ -2973,7 +2968,7 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1c74cae0a4cf6ccbbf5f359f08efdf8ee7e1dc532573bf0db71968cb56b1448c" dependencies = [ - "base64 0.21.5", + "base64 0.21.7", ] [[package]] @@ -3028,9 +3023,9 @@ version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1db149f81d46d2deba7cd3c50772474707729550221e69588478ebf9ada425ae" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -3068,44 +3063,44 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.20" +version = "1.0.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "836fa6a3e1e547f9a2c4040802ec865b5d85f4014efe00555d7090a3dcaa1090" +checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" [[package]] name = "serde" -version = "1.0.193" +version = "1.0.197" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25dd9975e68d0cb5aa1120c288333fc98731bd1dd12f561e468ea4728c042b89" +checksum = "3fb1c873e1b9b056a4dc4c0c198b24c3ffa059243875552b2bd0933b1aee4ce2" dependencies = [ "serde_derive", ] [[package]] name = "serde_bytes" -version = "0.11.13" +version = "0.11.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8bb1879ea93538b78549031e2d54da3e901fd7e75f2e4dc758d760937b123d10" +checksum = "8b8497c313fd43ab992087548117643f6fcd935cbf36f176ffda0aacf9591734" dependencies = [ "serde", ] [[package]] name = "serde_derive" -version = "1.0.193" +version = "1.0.197" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43576ca501357b9b071ac53cdc7da8ef0cbd9493d8df094cd821777ea6e894d3" +checksum = "7eb0b34b42edc17f6b7cac84a52a1c5f0e1bb2227e997ca9011ea3dd34e8610b" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] name = "serde_json" -version = "1.0.108" +version = "1.0.115" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d1c7e3eac408d115102c4c24ad393e0821bb3a5df4d506a80f85f7a742a526b" +checksum = "12dc5c46daa8e9fdf4f5e71b6cf9a53f2487da0e86e55808e2d35539666497dd" dependencies = [ "itoa", "ryu", @@ -3140,7 +3135,7 @@ version = "3.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "64cd236ccc1b7a29e7e2739f27c0b2dd199804abc4290e32f59f3b68d6405c23" dependencies = [ - "base64 0.21.5", + "base64 0.21.7", "chrono", "hex", "indexmap 1.9.3", @@ -3158,9 +3153,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "881b6f881b17d13214e5d494c939ebab463d01264ce1811e9d4ac3a882e7695f" dependencies = [ "darling", - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -3170,9 +3165,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "93634eb5f75a2323b16de4748022ac4297f9e76b6dced2be287a099f41b5e788" dependencies = [ "darling", - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -3318,7 +3313,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b5763ba7519b166b152ca2c6f8defa22cd07d3aea42a3a86b74519857fc3d464" dependencies = [ "Inflector", - "base64 0.21.5", + "base64 0.21.7", "bincode", "bs58", "bv", @@ -3482,10 +3477,10 @@ version = "1.16.25" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f516f992211a2ab70de5c367190575c97e02d156f9f1d8b76886d673f30e88a2" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "rustc_version", - "syn 2.0.43", + "syn 2.0.57", ] [[package]] @@ -3583,7 +3578,7 @@ dependencies = [ "ark-ff", "ark-serialize", "array-bytes", - "base64 0.21.5", + "base64 0.21.7", "bincode", "bitflags 1.3.2", "blake3", @@ -3633,7 +3628,7 @@ version = "1.16.25" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3da0e9dd63326ded2055b42e54aa37baa6aeb8adaea658a0059c234af6d05c02" dependencies = [ - "base64 0.21.5", + "base64 0.21.7", "bincode", "eager", "enum-iterator", @@ -3744,7 +3739,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f273acbce4493bc1de8174b94cfaee112b72263ae1684a6e13890f5004be53fb" dependencies = [ "async-trait", - "base64 0.21.5", + "base64 0.21.7", "bincode", "bs58", "indicatif", @@ -3769,7 +3764,7 @@ version = "1.16.25" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4462198830687b83870985db945c5d49c720d83abf516c8206fefba12cca689d" dependencies = [ - "base64 0.21.5", + "base64 0.21.7", "bs58", "jsonrpc-core", "reqwest", @@ -3805,7 +3800,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2087e15c92d4d6b3f085dc12fbe9614141c811f90a54cc418240ac30b608133f" dependencies = [ "assert_matches", - "base64 0.21.5", + "base64 0.21.7", "bincode", "bitflags 1.3.2", "borsh 0.10.3", @@ -3858,10 +3853,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2e0e0e7ee984b0f9179a1d4f4e9e67ce675de2324b5a98b61d2bdb61be3c19bb" dependencies = [ "bs58", - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "rustversion", - "syn 2.0.43", + "syn 2.0.57", ] [[package]] @@ -3944,7 +3939,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7992d9605a65967b5e40e6ef8e285a953888e4789f0f5e3fb7339bf018cbb677" dependencies = [ "Inflector", - "base64 0.21.5", + "base64 0.21.7", "bincode", "borsh 0.10.3", "bs58", @@ -4023,7 +4018,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1457c85ab70a518438b9ac2b0c56037b9f6693060dfb617bbb93c7116e4f0c22" dependencies = [ "aes-gcm-siv", - "base64 0.21.5", + "base64 0.21.7", "bincode", "bytemuck", "byteorder", @@ -4119,9 +4114,9 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fadbefec4f3c678215ca72bd71862697bb06b41fd77c0088902dd3203354387b" dependencies = [ - "quote 1.0.33", + "quote 1.0.35", "spl-discriminator-syn", - "syn 2.0.43", + "syn 2.0.57", ] [[package]] @@ -4130,10 +4125,10 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0e5f2044ca42c8938d54d1255ce599c79a1ffd86b677dfab695caa20f9ffc3f2" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "sha2 0.10.8", - "syn 2.0.43", + "syn 2.0.57", "thiserror", ] @@ -4178,10 +4173,10 @@ version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ab5269c8e868da17b6552ef35a51355a017bd8e0eae269c201fef830d35fa52c" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "sha2 0.10.8", - "syn 2.0.43", + "syn 2.0.57", ] [[package]] @@ -4223,7 +4218,7 @@ dependencies = [ "bytemuck", "num-derive 0.4.1", "num-traits", - "num_enum 0.7.1", + "num_enum 0.7.2", "solana-program", "solana-zk-token-sdk", "spl-memo", @@ -4313,19 +4308,19 @@ version = "1.0.109" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "unicode-ident", ] [[package]] name = "syn" -version = "2.0.43" +version = "2.0.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee659fb5f3d355364e1f3e5bc10fb82068efbf824a1e9d1c9504244a6469ad53" +checksum = "11a6ae1e52eb25aab8f3fb9fca13be982a373b8f1157ca14b897a825ba4a2d35" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "unicode-ident", ] @@ -4335,8 +4330,8 @@ version = "0.12.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", + "proc-macro2 1.0.79", + "quote 1.0.35", "syn 1.0.109", "unicode-xid 0.2.4", ] @@ -4401,22 +4396,22 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "thiserror" -version = "1.0.53" +version = "1.0.58" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2cd5904763bad08ad5513ddbb12cf2ae273ca53fa9f68e843e236ec6dfccc09" +checksum = "03468839009160513471e86a034bb2c5c0e4baae3b43f79ffc55c4a5427b3297" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.53" +version = "1.0.58" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3dcf4a824cce0aeacd6f38ae6f24234c8e80d68632338ebaa1443b5df9e29e19" +checksum = "c61f3ba182994efc43764a46c018c347bc492c79f024e705f46567b418f6d4f7" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -4507,9 +4502,9 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -4585,9 +4580,9 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "0.6.3" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" +checksum = "3550f4e9685620ac18a50ed434eb3aec30db8ba93b0287467bca5826ea25baf1" [[package]] name = "toml_edit" @@ -4602,9 +4597,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.20.2" +version = "0.21.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" +checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1" dependencies = [ "indexmap 2.1.0", "toml_datetime", @@ -4634,9 +4629,9 @@ version = "0.1.27" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -4832,9 +4827,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ed0d4f68a3015cc185aff4db9506a015f4b96f95303897bfa23f846db54064e" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -4842,16 +4837,16 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b56f625e64f3a1084ded111c4d5f477df9f8c92df113852fa5a374dbda78826" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" dependencies = [ "bumpalo", "log", "once_cell", - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", "wasm-bindgen-shared", ] @@ -4869,32 +4864,32 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0162dbf37223cd2afce98f3d0785506dcb8d266223983e4b5b525859e6e182b2" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" dependencies = [ - "quote 1.0.33", + "quote 1.0.35", "wasm-bindgen-macro-support", ] [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0eb82fcb7930ae6219a7ecfd55b217f5f0893484b7a13022ebb2b2bf20b5283" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.89" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ab9b36309365056cd639da3134bf87fa8f3d86008abf99e612384a6eecd459f" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "web-sys" @@ -4986,15 +4981,6 @@ dependencies = [ "windows_x86_64_msvc 0.42.2", ] -[[package]] -name = "windows-sys" -version = "0.45.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" -dependencies = [ - "windows-targets 0.42.2", -] - [[package]] name = "windows-sys" version = "0.48.0" @@ -5013,21 +4999,6 @@ dependencies = [ "windows-targets 0.52.0", ] -[[package]] -name = "windows-targets" -version = "0.42.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" -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-targets" version = "0.48.5" @@ -5245,9 +5216,9 @@ version = "0.7.32" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] @@ -5265,9 +5236,9 @@ version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ - "proc-macro2 1.0.72", - "quote 1.0.33", - "syn 2.0.43", + "proc-macro2 1.0.79", + "quote 1.0.35", + "syn 2.0.57", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 43fb221..83ac298 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,13 +12,16 @@ path = "src/main.rs" [dependencies] anyhow = "1.0.75" +bincode = "1.3.3" borsh = { version = "0.9.3" } clap = { version = "4.4.10", features = ["derive"] } dirs = "5.0.1" indexmap = { version = "2.1.0", features = ["serde"] } indicatif = "0.17.8" -nifty-asset = { version = "0.1.0", features = ["serde"] } -nifty-asset-types = { version = "0.1.0" } +# nifty-asset = { version = "0.1.0", features = ["serde"] } +nifty-asset = { path = "../asset/clients/rust/asset", features = ["serde"] } +# nifty-asset-types = { version = "0.1.0" } +nifty-asset-types = { path = "../asset/programs/asset/types" } podded = "0.5.1" retry = "2.0.0" serde = "1.0.193" diff --git a/example_extensions/asset.json b/example_extensions/asset.json index 24020fe..99dec22 100644 --- a/example_extensions/asset.json +++ b/example_extensions/asset.json @@ -68,7 +68,8 @@ { "extension_type": "Metadata", "value": { - "symbol": "SMB", + "symbol": "SAKURA", + "description": "example description", "uri": "https://arweave.net/62Z5yOFbIeFqvoOl-aq75EAGSDzS-GxpIKC2ws5LVDc" } } diff --git a/example_extensions/image-asset.json b/example_extensions/image-asset.json index 5ba9bb2..b32cf2b 100644 --- a/example_extensions/image-asset.json +++ b/example_extensions/image-asset.json @@ -6,58 +6,6 @@ "asset_keypair_file": null, "owner": "Dn5Pq1Nus6Wt1Lw8rLuH7XgMfRUKxXzMR9BEta45TzAs", "extensions": [ - { - "extension_type": "Creators", - "value": [ - { - "address": "AaSZHtdnHTcW4En23vJfmXxhZceoAfZnAjc8kYvherJ8", - "verified": true, - "share": 70 - }, - { - "address": "8UWRNwLHxD5DmEJ2cjVFdVpCNhfxL7bLkYpXG1o9srEN", - "verified": false, - "share": 20 - }, - { - "address": "5rH8qo7XzGaR5N8tMVQ32GuSw4HvwdBdnGN37ZGgsHnC", - "verified": false, - "share": 5 - }, - { - "address": "5Bw5EaQrCvgom3HFQ3ojUg2jd87nwzonPj4r5dVZKj7F", - "verified": false, - "share": 5 - }, - { - "address": "6367jssNbexBy38ydoZjBQJPGVN9oP6yteyfK5HCERki", - "verified": false, - "share": 0 - } - ] - }, - { - "extension_type": "Attributes", - "value": [ - { - "name": "skin", - "value": "blue" - } - ] - }, - { - "extension_type": "Links", - "value": [ - { - "name": "twitter", - "value": "https://twitter.com/sakura" - }, - { - "name": "instagram", - "value": "https://instagram.com/sakura" - } - ] - }, { "extension_type": "Blob", "value": { diff --git a/example_extensions/metadata-asset.json b/example_extensions/metadata-asset.json new file mode 100644 index 0000000..ac5a42f --- /dev/null +++ b/example_extensions/metadata-asset.json @@ -0,0 +1,17 @@ +{ + "name": "Sakura Kinomoto", + "mutable": false, + "standard": "NonFungible", + "asset_keypair_file": null, + "owner": "Dn5Pq1Nus6Wt1Lw8rLuH7XgMfRUKxXzMR9BEta45TzAs", + "extensions": [ + { + "extension_type": "Metadata", + "value": { + "symbol": "SYMBOL", + "description": "Description", + "uri": "https://arweave.net/62Z5yOFbIeFqvoOl-aq75EAGSDzS-GxpIKC2ws5LVDc" + } + } + ] +} diff --git a/src/commands/decode.rs b/src/commands/decode.rs index e0f2e9b..9aa70c7 100644 --- a/src/commands/decode.rs +++ b/src/commands/decode.rs @@ -1,7 +1,7 @@ use std::{fmt, ops::Deref}; use nifty_asset::{ - extensions::{Blob, Links, Manager, Royalties}, + extensions::{Attributes, Blob, ExtensionData, Grouping, Links, Manager, Metadata, Royalties}, types::Creator, JsonCreator, }; @@ -9,7 +9,7 @@ use nifty_asset_types::{ constraints::{ And, Constraint, FromBytes, Not, Operator, OperatorType, Or, OwnedBy, PubkeyMatch, }, - extensions::{Attributes, Extension, ExtensionData, ExtensionType, Grouping, Metadata}, + extensions::{Extension, ExtensionType}, podded::ZeroCopy, }; use serde_json::{json, Value}; diff --git a/src/commands/mint.rs b/src/commands/mint.rs index f632f7b..57dbdec 100644 --- a/src/commands/mint.rs +++ b/src/commands/mint.rs @@ -1,6 +1,4 @@ -use std::fs::File; - -use nifty_asset::{AssetArgs, AssetFile, ExtensionArgs, MintAccounts, MintIxArgs}; +use crate::transaction::pack_instructions; use super::*; @@ -42,7 +40,6 @@ pub async fn handle_mint(args: MintArgs) -> Result<()> { .map(|extension| ExtensionArgs { extension_type: extension.extension_type.clone(), data: extension.value.clone().into_data(), - chunked: true, }) .collect::>(); @@ -52,8 +49,11 @@ pub async fn handle_mint(args: MintArgs) -> Result<()> { extension_args, })?; - for instruction in instructions { - let sig = send_and_confirm_tx(&config.client, &[&authority_sk, &asset_sk], &[instruction])?; + let packed_instructions = pack_instructions(2, &authority_sk.pubkey(), &instructions); + + // Instructions are packed to max data length sizes, so we only put one in each tx. + for instructions in packed_instructions { + let sig = send_and_confirm_tx(&config.client, &[&authority_sk, &asset_sk], &instructions)?; println!("sig: {}", sig); } diff --git a/src/commands/mint_batch.rs b/src/commands/mint_batch.rs index 3874d51..bbb63d4 100644 --- a/src/commands/mint_batch.rs +++ b/src/commands/mint_batch.rs @@ -1,5 +1,7 @@ use std::{sync::Arc, time::Duration}; +use crate::transaction::pack_instructions; + use super::*; use indicatif::{MultiProgress, ProgressBar, ProgressStyle}; @@ -108,7 +110,6 @@ pub async fn handle_mint_batch(args: MintBatchArgs) -> Result<()> { .map(|extension| ExtensionArgs { extension_type: extension.extension_type.clone(), data: extension.value.clone().into_data(), - chunked: true, }) .collect::>(); @@ -146,10 +147,13 @@ pub async fn handle_mint_batch(args: MintBatchArgs) -> Result<()> { let pb = mp.add(ProgressBar::new(asset_instructions.len() as u64)); pb.set_style(sty.clone()); - for instruction in asset_instructions { + let packed_instructions = + pack_instructions(2, &authority_sk.pubkey(), &asset_instructions); + + for instructions in packed_instructions { let asset_sk = &asset_keys.lock().await[i]; let asset_address = &asset_sk.pubkey(); - let res = send_and_confirm_tx(&client, &[&authority_sk, &asset_sk], &[instruction]); + let res = send_and_confirm_tx(&client, &[&authority_sk, &asset_sk], &instructions); pb.set_message(format!("sending transactions for asset {asset_address}")); pb.inc(1); diff --git a/src/commands/mod.rs b/src/commands/mod.rs index 1ae2aaf..d45d077 100644 --- a/src/commands/mod.rs +++ b/src/commands/mod.rs @@ -39,9 +39,10 @@ pub use { }, serde::{Deserialize, Serialize}, solana_program::system_program, - solana_sdk::pubkey::Pubkey, solana_sdk::{ + pubkey::Pubkey, signature::{read_keypair_file, Keypair}, signer::Signer, + transaction::Transaction, }, }; diff --git a/src/commands/transfer.rs b/src/commands/transfer.rs index 5863fa5..8294b93 100644 --- a/src/commands/transfer.rs +++ b/src/commands/transfer.rs @@ -22,7 +22,7 @@ pub fn handle_transfer(args: TransferArgs) -> Result<()> { asset, signer, recipient, - group_asset: None, + group: None, } .instruction(); diff --git a/src/transaction.rs b/src/transaction.rs index 804836c..fb8dfd9 100644 --- a/src/transaction.rs +++ b/src/transaction.rs @@ -1,8 +1,10 @@ use anyhow::Result; +use nifty_asset::MAX_TX_SIZE; use retry::{delay::Exponential, retry}; use solana_client::rpc_client::RpcClient; use solana_program::instruction::Instruction; use solana_sdk::{ + pubkey::Pubkey, signature::{Keypair, Signature}, signer::Signer, transaction::Transaction, @@ -47,3 +49,30 @@ pub fn send_and_confirm_tx_with_retries( Ok(res) } + +pub fn pack_instructions<'a>( + num_signers: u32, + payer: &'a Pubkey, + ixs: &'a [Instruction], +) -> Vec> { + let mut instructions = vec![]; + let mut tx_instructions = vec![]; + + // 64 bytes for each signature + Message size + let max_payload_size = MAX_TX_SIZE - std::mem::size_of::() * num_signers as usize; + + for ix in ixs { + tx_instructions.push(ix.clone()); + let tx = Transaction::new_with_payer(tx_instructions.as_slice(), Some(payer)); + let tx_len = bincode::serialize(&tx).unwrap().len(); + + if tx_len > max_payload_size { + let last_ix = tx_instructions.pop().unwrap(); + instructions.push(tx_instructions.clone()); + tx_instructions.clear(); + tx_instructions.push(last_ix); + } + } + + instructions +}