diff --git a/.github/workflows/build-api.yml b/.github/workflows/build-api.yml new file mode 100644 index 000000000..15684355a --- /dev/null +++ b/.github/workflows/build-api.yml @@ -0,0 +1,113 @@ +name: Build das api components +# This workflow uses github runners. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +# This may be adjusted to whatever suits best your runners config. +# Current config will build on manual trigger or pull-request (each push) +on: + # pull_request can be removed, to save minutes on github runners + pull_request: + workflow_dispatch: + push: + branches: + - 'main' + +env: + CARGO_TERM_COLOR: always + +jobs: + build-api: + strategy: + matrix: + os: [ubuntu-20.04, ubuntu-22.04] + # This can be also be runned on self-hosted github runners + runs-on: ["${{ matrix.os }}"] + + steps: + - name: checkout repo + uses: actions/checkout@v3 + # This step can be omited, to save storage space on the organization account + # Build process will take longer + - name: set build cache + uses: actions/cache@v3 + with: + path: | + ~/.cargo/bin/ + ~/.cargo/registry/index/ + ~/.cargo/registry/cache/ + ~/.cargo/git/db/ + digital-asset-rpc-infrastructure/target/ + key: ${{ matrix.os }}_digital-asset-rpc-infrastructure_${{ hashFiles('digital-asset-rpc-infrastructure/Cargo.lock') }} + restore-keys: | + ${{ matrix.os }}_digital-asset-rpc-infrastructure + + - name: build digital asset rpc infra + run: cargo build --verbose --release + + - name: rename binaries for ubuntu22 release + if: matrix.os == 'ubuntu-22.04' + run: | + mv target/release/nft_ingester target/release/nft_ingester22 + mv target/release/fetch_trees target/release/fetch_trees22 + mv target/release/migration target/release/migration22 + mv target/release/das_api target/release/das_api22 + + # This steps can be omited to save space, are mostly in place to validate binaries (manually) and path to them + # Omiting this will save on storage consumption on the account + - name: Publish artifact + if: matrix.os == 'ubuntu-22.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: nft_ingester22 + path: target/release/nft_ingester22 + + - name: Publish artifact + if: matrix.os == 'ubuntu-22.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: das_api22 + path: target/release/das_api22 + + - name: Publish artifact + if: matrix.os == 'ubuntu-22.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: migration22 + path: target/release/migration22 + + - name: Publish artifact + if: matrix.os == 'ubuntu-22.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: fetch-trees22 + path: target/release/fetch_trees22 + + - name: Publish artifact + if: matrix.os == 'ubuntu-20.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: nft_ingester + path: target/release/nft_ingester + + - name: Publish artifact + if: matrix.os == 'ubuntu-20.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: das_api + path: target/release/das_api + + - name: Publish artifact + if: matrix.os == 'ubuntu-20.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: migration + path: target/release/migration + + - name: Publish artifact + if: matrix.os == 'ubuntu-20.04' + uses: actions/upload-artifact@v3.1.1 + with: + name: fetch-trees + path: target/release/fetch_trees diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 03dfd81ca..1fb299094 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,35 +1,27 @@ -name: Build das api components -# This workflow uses github runners. +name: Check lock file, fmt, clippy + concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true -# This may be adjusted to whatever suits best your runners config. -# Current config will build on manual trigger or pull-request (each push) on: - # pull_request can be removed, to save minutes on github runners pull_request: - workflow_dispatch: push: branches: - 'main' + workflow_dispatch: env: CARGO_TERM_COLOR: always jobs: - build-api: - strategy: - matrix: - os: [ubuntu-20.04, ubuntu-22.04] - # This can be also be runned on self-hosted github runners - runs-on: ["${{ matrix.os }}"] + test: + runs-on: ubuntu-22.04 steps: - name: checkout repo uses: actions/checkout@v3 - # This step can be omited, to save storage space on the organization account - # Build process will take longer + - name: set build cache uses: actions/cache@v3 with: @@ -39,83 +31,19 @@ jobs: ~/.cargo/registry/cache/ ~/.cargo/git/db/ digital-asset-rpc-infrastructure/target/ - key: ${{ matrix.os }}_digital-asset-rpc-infrastructure_${{ hashFiles('digital-asset-rpc-infrastructure/Cargo.lock') }} - restore-keys: | - ${{ matrix.os }}_digital-asset-rpc-infrastructure - - - name: build digital asset rpc infra - run: cargo build --verbose --release - - - name: build das_api - working-directory: das_api - run: cargo build --verbose --release + key: cargo-${{ hashFiles('**/Cargo.lock') }}-0001 - - name: build migration - working-directory: migration - run: cargo build --verbose --release - - - name: rename binaries for ubuntu22 release - if: matrix.os == 'ubuntu-22.04' + # Cargo.lock + - name: Check lock file run: | - mv target/release/nft_ingester target/release/nft_ingester22 - mv target/release/fetch_trees target/release/fetch_trees22 - mv das_api/target/release/das_api das_api/target/release/das_api22 - mv migration/target/release/migration migration/target/release/migration22 + cargo tree + git checkout Cargo.lock + cargo tree --frozen - # This steps can be omited to save space, are mostly in place to validate binaries (manually) and path to them - # Omiting this will save on storage consumption on the account - - name: Publish artifact - if: matrix.os == 'ubuntu-22.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: nft_ingester22 - path: target/release/nft_ingester22 + # fmt + - name: Check fmt + run: cargo fmt --all -- --check - - name: Publish artifact - if: matrix.os == 'ubuntu-22.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: das_api22 - path: das_api/target/release/das_api22 - - - name: Publish artifact - if: matrix.os == 'ubuntu-22.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: migration22 - path: migration/target/release/migration22 - - - name: Publish artifact - if: matrix.os == 'ubuntu-22.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: fetch-trees22 - path: migration/target/release/fetch_trees22 - - - name: Publish artifact - if: matrix.os == 'ubuntu-20.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: nft_ingester - path: target/release/nft_ingester - - - name: Publish artifact - if: matrix.os == 'ubuntu-20.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: das_api - path: das_api/target/release/das_api - - - name: Publish artifact - if: matrix.os == 'ubuntu-20.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: migration - path: migration/target/release/migration - - - name: Publish artifact - if: matrix.os == 'ubuntu-20.04' - uses: actions/upload-artifact@v3.1.1 - with: - name: fetch-trees - path: target/release/fetch_trees + # clippy + - name: Check clippy + run: cargo clippy --all-targets --tests diff --git a/.gitignore b/.gitignore index b168f6bbc..c396adfb8 100644 --- a/.gitignore +++ b/.gitignore @@ -23,10 +23,3 @@ programs *.iml skaffold-state.json test-programs - -# Rust build dirs -/das_api/target -/migration/target -/tests/*/target -/*/target -/target diff --git a/Cargo.lock b/Cargo.lock index fc7d6b751..fa43fe85e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -18,7 +18,7 @@ version = "0.7.12" dependencies = [ "anyhow", "bs58 0.4.0", - "clap 4.4.6", + "clap 4.4.8", "env_logger 0.10.0", "figment", "flatbuffers", @@ -583,6 +583,16 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9b34d609dfbaf33d6889b2b7106d3ca345eacad44200913df5ba02bfd31d2ba9" +[[package]] +name = "async-attributes" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a3203e79f4dd9bdda415ed03cf14dae5a2bf775c683a00f94e9cd1faf0f596e5" +dependencies = [ + "quote 1.0.33", + "syn 1.0.109", +] + [[package]] name = "async-channel" version = "1.9.0" @@ -590,8 +600,21 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" dependencies = [ "concurrent-queue", - "event-listener", + "event-listener 2.5.3", + "futures-core", +] + +[[package]] +name = "async-channel" +version = "2.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d37875bd9915b7d67c2f117ea2c30a0989874d0b2cb694fe25403c85763c0c9e" +dependencies = [ + "concurrent-queue", + "event-listener 3.1.0", + "event-listener-strategy", "futures-core", + "pin-project-lite", ] [[package]] @@ -608,21 +631,51 @@ dependencies = [ "tokio", ] +[[package]] +name = "async-executor" +version = "1.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc5ea910c42e5ab19012bab31f53cb4d63d54c3a27730f9a833a88efcf4bb52d" +dependencies = [ + "async-lock 3.1.1", + "async-task", + "concurrent-queue", + "fastrand 2.0.1", + "futures-lite 2.0.1", + "slab", +] + +[[package]] +name = "async-global-executor" +version = "2.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1b6f5d7df27bd294849f8eec66ecfc63d11814df7a4f5d74168a2394467b776" +dependencies = [ + "async-channel 1.9.0", + "async-executor", + "async-io", + "async-lock 2.8.0", + "blocking", + "futures-lite 1.13.0", + "once_cell", + "tokio", +] + [[package]] name = "async-io" version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" dependencies = [ - "async-lock", + "async-lock 2.8.0", "autocfg", "cfg-if", "concurrent-queue", - "futures-lite", + "futures-lite 1.13.0", "log", "parking", "polling", - "rustix 0.37.24", + "rustix 0.37.27", "slab", "socket2 0.4.9", "waker-fn", @@ -634,7 +687,18 @@ version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "287272293e9d8c41773cec55e365490fe034813a2f172f502d6ddcf75b2f582b" dependencies = [ - "event-listener", + "event-listener 2.5.3", +] + +[[package]] +name = "async-lock" +version = "3.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "655b9c7fe787d3b25cc0f804a1a8401790f0c5bc395beb5a64dc77d8de079105" +dependencies = [ + "event-listener 3.1.0", + "event-listener-strategy", + "pin-project-lite", ] [[package]] @@ -643,7 +707,34 @@ version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "479db852db25d9dbf6204e6cb6253698f175c15726470f78af0d918e99d6156e" dependencies = [ - "event-listener", + "event-listener 2.5.3", +] + +[[package]] +name = "async-std" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62565bb4402e926b29953c785397c6dc0391b7b446e45008b0049eb43cec6f5d" +dependencies = [ + "async-attributes", + "async-channel 1.9.0", + "async-global-executor", + "async-io", + "async-lock 2.8.0", + "crossbeam-utils", + "futures-channel", + "futures-core", + "futures-io", + "futures-lite 1.13.0", + "gloo-timers", + "kv-log-macro", + "log", + "memchr", + "once_cell", + "pin-project-lite", + "pin-utils", + "slab", + "wasm-bindgen-futures", ] [[package]] @@ -668,6 +759,12 @@ dependencies = [ "syn 2.0.38", ] +[[package]] +name = "async-task" +version = "4.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4eb2cdb97421e01129ccb49169d8279ed21e829929144f4a22a6e54ac549ca1" + [[package]] name = "async-trait" version = "0.1.73" @@ -790,29 +887,31 @@ version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" +[[package]] +name = "beef" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a8241f3ebb85c056b509d4327ad0358fbbba6ffb340bf388f26350aeda225b1" +dependencies = [ + "serde", +] + [[package]] name = "bgtask_creator" version = "0.7.12" dependencies = [ "anyhow", - "bs58 0.4.0", - "clap 4.4.6", - "das-tree-backfiller", + "clap 4.4.8", "digital_asset_types", "futures", - "indicatif", "lazy_static", "log", "nft_ingester", "prometheus", - "reqwest", "sea-orm", "sea-query 0.28.5", - "serde", - "serde_json", "solana-sdk", "sqlx", - "thiserror", "tokio", "txn_forwarder", ] @@ -900,9 +999,9 @@ checksum = "8d696c370c750c948ada61c69a0ee2cbbb9c50b1019ddb86d9317157a99c2cae" [[package]] name = "blockbuster" -version = "0.9.0-beta.1" +version = "0.9.0-beta.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e0240c1218958c0d51284d783fa055f551d769bb8b7a4abf635b17fa9620dc" +checksum = "a32a0edd58b3aaaf55684bc9ad82e012b3345cb46a25fcae507b3b9034b83d44" dependencies = [ "anchor-lang", "async-trait", @@ -923,6 +1022,22 @@ dependencies = [ "thiserror", ] +[[package]] +name = "blocking" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a37913e8dc4ddcc604f0c6d3bf2887c995153af3611de9e23c352b44c1b9118" +dependencies = [ + "async-channel 2.1.0", + "async-lock 3.1.1", + "async-task", + "fastrand 2.0.1", + "futures-io", + "futures-lite 2.0.1", + "piper", + "tracing", +] + [[package]] name = "borsh" version = "0.9.3" @@ -1049,6 +1164,16 @@ dependencies = [ "tinyvec", ] +[[package]] +name = "bstr" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "542f33a8835a0884b006a0c3df3dadd99c0c3f296ed26c2fdc8028e01ad6230c" +dependencies = [ + "memchr", + "serde", +] + [[package]] name = "bumpalo" version = "3.14.0" @@ -1210,6 +1335,7 @@ checksum = "4ea181bf566f71cb9a5d17a59e1871af638180a18fb0035c92ae62b705207123" dependencies = [ "atty", "bitflags 1.3.2", + "clap_derive 3.2.25", "clap_lex 0.2.4", "indexmap 1.9.3", "once_cell", @@ -1220,31 +1346,44 @@ dependencies = [ [[package]] name = "clap" -version = "4.4.6" +version = "4.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d04704f56c2cde07f43e8e2c154b43f216dc5c92fc98ada720177362f953b956" +checksum = "2275f18819641850fa26c89acc84d465c1bf91ce57bc2748b28c420473352f64" dependencies = [ "clap_builder", - "clap_derive", + "clap_derive 4.4.7", ] [[package]] name = "clap_builder" -version = "4.4.6" +version = "4.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e231faeaca65ebd1ea3c737966bf858971cd38c3849107aa3ea7de90a804e45" +checksum = "07cdf1b148b25c1e1f7a42225e30a0d99a615cd4637eae7365548dd4529b95bc" dependencies = [ "anstream", "anstyle", - "clap_lex 0.5.1", + "clap_lex 0.6.0", "strsim 0.10.0", ] [[package]] name = "clap_derive" -version = "4.4.2" +version = "3.2.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0862016ff20d69b84ef8247369fabf5c008a7417002411897d40ee1f4532b873" +checksum = "ae6371b8bdc8b7d3959e9cf7b22d4435ef3e79e138688421ec654acf8c81b008" +dependencies = [ + "heck 0.4.1", + "proc-macro-error", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", +] + +[[package]] +name = "clap_derive" +version = "4.4.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf9804afaaf59a91e75b022a30fb7229a7901f60c755489cc61c9b423b836442" dependencies = [ "heck 0.4.1", "proc-macro2 1.0.69", @@ -1263,9 +1402,9 @@ dependencies = [ [[package]] name = "clap_lex" -version = "0.5.1" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd7cc57abe963c6d3b9d8be5b06ba7c8957a930305ca90304f24ef040aa6f961" +checksum = "702fc72eb24e5a1e48ce58027a675bc24edd52096d5397d4aea7c6dd9eca0bd1" [[package]] name = "colorchoice" @@ -1583,7 +1722,7 @@ dependencies = [ [[package]] name = "das-metadata-json" -version = "0.1.0" +version = "0.7.2" dependencies = [ "anyhow", "backon", @@ -1591,7 +1730,7 @@ dependencies = [ "cadence", "cadence-macros", "chrono", - "clap 4.4.6", + "clap 4.4.8", "das-tree-backfiller", "derive_more", "digital_asset_types", @@ -1618,7 +1757,7 @@ dependencies = [ [[package]] name = "das-tree-backfiller" -version = "0.1.0" +version = "0.7.2" dependencies = [ "anchor-client", "anchor-lang", @@ -1630,7 +1769,7 @@ dependencies = [ "cadence", "cadence-macros", "chrono", - "clap 4.4.6", + "clap 4.4.8", "digital_asset_types", "env_logger 0.10.0", "figment", @@ -1665,6 +1804,45 @@ dependencies = [ "uuid", ] +[[package]] +name = "das_api" +version = "0.7.2" +dependencies = [ + "anchor-lang", + "async-trait", + "blockbuster", + "bs58 0.4.0", + "cadence", + "cadence-macros", + "digital_asset_types", + "env_logger 0.10.0", + "figment", + "hyper", + "jsonrpsee", + "jsonrpsee-core", + "log", + "metrics", + "mpl-bubblegum", + "mpl-candy-guard", + "mpl-candy-machine-core", + "mpl-token-metadata", + "open-rpc-derive", + "open-rpc-schema", + "schemars", + "schemars_derive", + "sea-orm", + "serde", + "serde_json", + "solana-sdk", + "sqlx", + "thiserror", + "tokio", + "tokio-postgres", + "tower", + "tower-http", + "tracing", +] + [[package]] name = "data-encoding" version = "2.4.0" @@ -1733,6 +1911,12 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "deunicode" +version = "1.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6a1abaf4d861455be59f64fd2b55606cb151fce304ede7165f410243ce96bde6" + [[package]] name = "dialoguer" version = "0.10.4" @@ -1781,7 +1965,6 @@ dependencies = [ "mime_guess", "num-derive 0.3.3", "num-traits", - "reqwest", "schemars", "schemars_derive", "sea-orm", @@ -1994,14 +2177,35 @@ version = "2.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" +[[package]] +name = "event-listener" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d93877bcde0eb80ca09131a08d23f0a5c18a620b01db137dba666d18cd9b30c2" +dependencies = [ + "concurrent-queue", + "parking", + "pin-project-lite", +] + +[[package]] +name = "event-listener-strategy" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d96b852f1345da36d551b9473fa1e2b1eb5c5195585c6c018118bc92a8d91160" +dependencies = [ + "event-listener 3.1.0", + "pin-project-lite", +] + [[package]] name = "fake" -version = "2.8.0" +version = "2.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9af7b0c58ac9d03169e27f080616ce9f64004edca3d2ef4147a811c21b23b319" +checksum = "26221445034074d46b276e13eb97a265ebdb8ed8da705c4dddd3dd20b66b45d2" dependencies = [ + "deunicode", "rand 0.8.5", - "unidecode", ] [[package]] @@ -2038,7 +2242,7 @@ dependencies = [ "anyhow", "async-trait", "borsh 0.10.3", - "clap 4.4.6", + "clap 4.4.8", "mpl-bubblegum", "solana-account-decoder", "solana-client", @@ -2057,7 +2261,7 @@ dependencies = [ "pear", "serde", "serde_yaml", - "toml 0.8.2", + "toml 0.8.8", "uncased", "version_check", ] @@ -2204,6 +2408,20 @@ dependencies = [ "waker-fn", ] +[[package]] +name = "futures-lite" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3831c2651acb5177cbd83943f3d9c8912c5ad03c76afcc0e9511ba568ec5ebb" +dependencies = [ + "fastrand 2.0.1", + "futures-core", + "futures-io", + "memchr", + "parking", + "pin-project-lite", +] + [[package]] name = "futures-macro" version = "0.3.28" @@ -2304,6 +2522,31 @@ version = "0.28.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6fb8d784f27acf97159b40fc4db5ecd8aa23b9ad5ef69cdd136d3bc80665f0c0" +[[package]] +name = "globset" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "759c97c1e17c55525b57192c06a267cda0ac5210b222d6b82189a2338fa1c13d" +dependencies = [ + "aho-corasick", + "bstr", + "fnv", + "log", + "regex", +] + +[[package]] +name = "gloo-timers" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b995a66bb87bebce9a0f4a95aed01daca4872c050bfcb21653361c03bc35e5c" +dependencies = [ + "futures-channel", + "futures-core", + "js-sys", + "wasm-bindgen", +] + [[package]] name = "goblin" version = "0.5.4" @@ -2495,6 +2738,12 @@ dependencies = [ "pin-project-lite", ] +[[package]] +name = "http-range-header" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "add0ab9360ddbd88cfeb3bd9574a1d85cfdfa14db10b3e21d3700dbc4328758f" + [[package]] name = "httparse" version = "1.8.0" @@ -2648,7 +2897,7 @@ dependencies = [ "console", "instant", "number_prefix", - "portable-atomic", + "portable-atomic 1.4.3", "unicode-width", ] @@ -2763,6 +3012,94 @@ dependencies = [ "serde_json", ] +[[package]] +name = "jsonrpsee" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "367a292944c07385839818bb71c8d76611138e2dedb0677d035b8da21d29c78b" +dependencies = [ + "jsonrpsee-core", + "jsonrpsee-proc-macros", + "jsonrpsee-server", + "jsonrpsee-types", + "tracing", +] + +[[package]] +name = "jsonrpsee-core" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b5dde66c53d6dcdc8caea1874a45632ec0fcf5b437789f1e45766a1512ce803" +dependencies = [ + "anyhow", + "arrayvec", + "async-trait", + "beef", + "futures-channel", + "futures-util", + "globset", + "hyper", + "jsonrpsee-types", + "parking_lot 0.12.1", + "rand 0.8.5", + "rustc-hash", + "serde", + "serde_json", + "soketto", + "thiserror", + "tokio", + "tracing", +] + +[[package]] +name = "jsonrpsee-proc-macros" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44e8ab85614a08792b9bff6c8feee23be78c98d0182d4c622c05256ab553892a" +dependencies = [ + "heck 0.4.1", + "proc-macro-crate 1.3.1", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", +] + +[[package]] +name = "jsonrpsee-server" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf4d945a6008c9b03db3354fb3c83ee02d2faa9f2e755ec1dfb69c3551b8f4ba" +dependencies = [ + "futures-channel", + "futures-util", + "http", + "hyper", + "jsonrpsee-core", + "jsonrpsee-types", + "serde", + "serde_json", + "soketto", + "tokio", + "tokio-stream", + "tokio-util", + "tower", + "tracing", +] + +[[package]] +name = "jsonrpsee-types" +version = "0.16.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "245ba8e5aa633dd1c1e4fae72bce06e71f42d34c14a2767c6b4d173b57bee5e5" +dependencies = [ + "anyhow", + "beef", + "serde", + "serde_json", + "thiserror", + "tracing", +] + [[package]] name = "kaigan" version = "0.2.2" @@ -2781,6 +3118,15 @@ dependencies = [ "cpufeatures", ] +[[package]] +name = "kv-log-macro" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0de8b303297635ad57c9f5059fd9cee7a47f8e8daa09df0fcd07dd39fb22977f" +dependencies = [ + "log", +] + [[package]] name = "lazy_static" version = "1.4.0" @@ -2883,6 +3229,9 @@ name = "log" version = "0.4.20" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +dependencies = [ + "value-bag", +] [[package]] name = "matchers" @@ -2960,6 +3309,38 @@ dependencies = [ "wasm-bindgen", ] +[[package]] +name = "metrics" +version = "0.20.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b9b8653cec6897f73b519a43fba5ee3d50f62fe9af80b428accdcc093b4a849" +dependencies = [ + "ahash 0.7.6", + "metrics-macros", + "portable-atomic 0.3.20", +] + +[[package]] +name = "metrics-macros" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "731f8ecebd9f3a4aa847dfe75455e4757a45da40a7793d2f0b1f9b6ed18b23f3" +dependencies = [ + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", +] + +[[package]] +name = "migration" +version = "0.7.2" +dependencies = [ + "async-std", + "enum-iterator", + "enum-iterator-derive", + "sea-orm-migration", +] + [[package]] name = "mime" version = "0.3.17" @@ -3004,9 +3385,9 @@ dependencies = [ [[package]] name = "mpl-bubblegum" -version = "1.0.1-beta.3" +version = "1.0.1-beta.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29346f26192bb7f73330196fde4c8cfb35675bf1a4b026cd088f7ca8fda69f3f" +checksum = "e59d102fe6f8b063a06a226874ea815b269316390ce3bf991b29ea9c54ccc467" dependencies = [ "borsh 0.10.3", "kaigan", @@ -3163,7 +3544,7 @@ dependencies = [ "cadence", "cadence-macros", "chrono", - "clap 4.4.6", + "clap 4.4.8", "das-metadata-json", "digital_asset_types", "env_logger 0.10.0", @@ -3460,6 +3841,30 @@ version = "0.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" +[[package]] +name = "open-rpc-derive" +version = "0.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae3de03a56750973a83c76a40fb4b81969d42fad152cd0e787e25c79dcf54e3f" +dependencies = [ + "open-rpc-schema", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", +] + +[[package]] +name = "open-rpc-schema" +version = "0.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6919654a78166b8d8f266f702ce763c0880c11a2e75e1de9cc3e51704abf620" +dependencies = [ + "schemars", + "schemars_derive", + "serde", + "serde_json", +] + [[package]] name = "openssl" version = "0.10.57" @@ -3506,9 +3911,9 @@ dependencies = [ [[package]] name = "os_str_bytes" -version = "6.5.1" +version = "6.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d5d9eb14b174ee9aa2ef96dc2b94637a2d4b6e7cb873c7e171f0c20c6cf3eac" +checksum = "e2355d85b9a3786f481747ced0e0ff2ba35213a1f9bd406ed906554d7af805a1" [[package]] name = "ouroboros" @@ -3541,9 +3946,9 @@ checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" [[package]] name = "parking" -version = "2.1.1" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e52c774a4c39359c1d1c52e43f73dd91a75a614652c825408eec30c95a9b2067" +checksum = "bb813b8af86854136c6922af0598d719255ecb2179515e6e7730d468f05c9cae" [[package]] name = "parking_lot" @@ -3684,18 +4089,18 @@ dependencies = [ [[package]] name = "pin-project" -version = "1.1.3" +version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fda4ed1c6c173e3fc7a83629421152e01d7b1f9b7f65fb301e490e8cfc656422" +checksum = "0302c4a0442c456bd56f841aee5c3bfd17967563f6fadc9ceb9f9c23cf3807e0" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.3" +version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" +checksum = "266c042b60c9c76b8d53061e52b2e0d1116abc57cefc8c5cd671619a56ac3690" dependencies = [ "proc-macro2 1.0.69", "quote 1.0.33", @@ -3714,6 +4119,17 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" +[[package]] +name = "piper" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "668d31b1c4eba19242f2088b2bf3316b82ca31082a8335764db4e083db7485d4" +dependencies = [ + "atomic-waker", + "fastrand 2.0.1", + "futures-io", +] + [[package]] name = "pkcs8" version = "0.8.0" @@ -3799,6 +4215,15 @@ dependencies = [ "universal-hash", ] +[[package]] +name = "portable-atomic" +version = "0.3.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e30165d31df606f5726b090ec7592c308a0eaf61721ff64c9a3018e344a8753e" +dependencies = [ + "portable-atomic 1.4.3", +] + [[package]] name = "portable-atomic" version = "1.4.3" @@ -4439,23 +4864,23 @@ dependencies = [ [[package]] name = "rpassword" -version = "7.2.0" +version = "7.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6678cf63ab3491898c0d021b493c94c9b221d91295294a2a5746eacbe5928322" +checksum = "80472be3c897911d0137b2d2b9055faf6eeac5b14e324073d83bc17b191d7e3f" dependencies = [ "libc", "rtoolbox", - "winapi", + "windows-sys 0.48.0", ] [[package]] name = "rtoolbox" -version = "0.0.1" +version = "0.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "034e22c514f5c0cb8a10ff341b9b048b5ceb21591f31c8f44c43b960f9b3524a" +checksum = "c247d24e63230cdb56463ae328478bd5eac8b8faa8c69461a77e8e323afac90e" dependencies = [ "libc", - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -4525,9 +4950,9 @@ dependencies = [ [[package]] name = "rustix" -version = "0.37.24" +version = "0.37.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4279d76516df406a8bd37e7dff53fd37d1a093f997a3c34a5c21658c126db06d" +checksum = "fea8ca367a3a01fe35e6943c400addf443c0f57670e6ec51196f71a4b8762dd2" dependencies = [ "bitflags 1.3.2", "errno", @@ -4714,6 +5139,22 @@ dependencies = [ "uuid", ] +[[package]] +name = "sea-orm-cli" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ebe1f820fe8949cf6a57272ba9ebd0be766e47c9b85c04b3cabea40ab9459b3" +dependencies = [ + "chrono", + "clap 3.2.25", + "dotenvy", + "regex", + "sea-schema", + "tracing", + "tracing-subscriber", + "url", +] + [[package]] name = "sea-orm-macros" version = "0.10.7" @@ -4727,6 +5168,22 @@ dependencies = [ "syn 1.0.109", ] +[[package]] +name = "sea-orm-migration" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ed3cdfa669e4c385922f902b9a58e0c2128782a4d0fe79c6c34f3b927565e5b" +dependencies = [ + "async-trait", + "clap 3.2.25", + "dotenvy", + "sea-orm", + "sea-orm-cli", + "sea-schema", + "tracing", + "tracing-subscriber", +] + [[package]] name = "sea-query" version = "0.27.2" @@ -4791,6 +5248,29 @@ dependencies = [ "thiserror", ] +[[package]] +name = "sea-schema" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38d5fda574d980e9352b6c7abd6fc75697436fe0078cac2b548559b52643ad3b" +dependencies = [ + "futures", + "sea-query 0.27.2", + "sea-schema-derive", +] + +[[package]] +name = "sea-schema-derive" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56821b7076f5096b8f726e2791ad255a99c82498e08ec477a65a96c461ff1927" +dependencies = [ + "heck 0.3.3", + "proc-macro2 1.0.69", + "quote 1.0.33", + "syn 1.0.109", +] + [[package]] name = "sea-strum" version = "0.23.0" @@ -4902,9 +5382,9 @@ dependencies = [ [[package]] name = "serde_spanned" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96426c9936fd7a0124915f9185ea1d20aa9445cc9821142f0a73bc9207a2e186" +checksum = "12022b835073e5b11e90a14f86838ceb1c8fb0325b72416845c487ac0fa95e80" dependencies = [ "serde", ] @@ -4978,6 +5458,19 @@ dependencies = [ "unsafe-libyaml", ] +[[package]] +name = "sha-1" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "99cd6713db3cf16b6c84e06321e049a9b9f699826e16096d23bbcc44d15d51a6" +dependencies = [ + "block-buffer 0.9.0", + "cfg-if", + "cpufeatures", + "digest 0.9.0", + "opaque-debug", +] + [[package]] name = "sha-1" version = "0.10.1" @@ -5173,6 +5666,22 @@ dependencies = [ "windows-sys 0.48.0", ] +[[package]] +name = "soketto" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41d1c5305e39e09653383c2c7244f2f78b3bcae37cf50c64cb4789c9f5096ec2" +dependencies = [ + "base64 0.13.1", + "bytes", + "futures", + "http", + "httparse", + "log", + "rand 0.8.5", + "sha-1 0.9.8", +] + [[package]] name = "solana-account-decoder" version = "1.16.16" @@ -5757,7 +6266,7 @@ version = "1.16.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f00e575f2bd5ae2776870fbd1d7379d4ad392c015e2a4e2a328953b821a9d36d" dependencies = [ - "async-channel", + "async-channel 1.9.0", "bytes", "crossbeam-channel", "futures-util", @@ -6278,7 +6787,7 @@ dependencies = [ "dirs", "dotenvy", "either", - "event-listener", + "event-listener 2.5.3", "futures-channel", "futures-core", "futures-intrusive", @@ -6363,7 +6872,7 @@ version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b6bcb902b974bc20b50c3ad3148022a366a46c9a676b587684ff46c237a3329e" dependencies = [ - "async-channel", + "async-channel 1.9.0", "async-io", "atomic 0.5.3", "crossbeam-channel", @@ -6516,18 +7025,18 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "thiserror" -version = "1.0.50" +version = "1.0.49" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9a7210f5c9a7156bb50aa36aed4c95afb51df0df00713949448cf9e97d382d2" +checksum = "1177e8c6d7ede7afde3585fd2513e611227efd6481bd78d2e82ba1ce16557ed4" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.50" +version = "1.0.49" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "266b2e40bc00e5a6c09c3584011e08b06f123c00362c92b975ba9843aaaa14b8" +checksum = "10712f02019e9288794769fba95cd6847df9874d49d871d062172f9dd41bc4cc" dependencies = [ "proc-macro2 1.0.69", "quote 1.0.33", @@ -6740,6 +7249,7 @@ checksum = "1d68074620f57a0b21594d9735eb2e98ab38b17f80d3fcb189fca266771ca60d" dependencies = [ "bytes", "futures-core", + "futures-io", "futures-sink", "pin-project-lite", "tokio", @@ -6757,21 +7267,21 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.2" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "185d8ab0dfbb35cf1399a6344d8484209c088f75f8f68230da55d48d95d43e3d" +checksum = "a1a195ec8c9da26928f773888e0742ca3ca1040c6cd859c919c9f59c1954ab35" dependencies = [ "serde", "serde_spanned", "toml_datetime", - "toml_edit 0.20.2", + "toml_edit 0.21.0", ] [[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" dependencies = [ "serde", ] @@ -6789,9 +7299,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.20.2" +version = "0.21.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "396e4d48bbb2b7554c944bde63101b5ae446cff6ec4a24227428f15eb72ef338" +checksum = "d34d383cd00a163b4a5b85053df514d45bc330f6de7737edfe0a93311d1eaa03" dependencies = [ "indexmap 2.0.2", "serde", @@ -6800,6 +7310,41 @@ dependencies = [ "winnow", ] +[[package]] +name = "tower" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" +dependencies = [ + "tower-layer", + "tower-service", + "tracing", +] + +[[package]] +name = "tower-http" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f873044bf02dd1e8239e9c1293ea39dad76dc594ec16185d0a1bf31d8dc8d858" +dependencies = [ + "bitflags 1.3.2", + "bytes", + "futures-core", + "futures-util", + "http", + "http-body", + "http-range-header", + "pin-project-lite", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-layer" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" + [[package]] name = "tower-service" version = "0.3.2" @@ -6842,12 +7387,12 @@ dependencies = [ [[package]] name = "tracing-log" -version = "0.1.3" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" +checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" dependencies = [ - "lazy_static", "log", + "once_cell", "tracing-core", ] @@ -6863,9 +7408,9 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.17" +version = "0.3.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" +checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" dependencies = [ "matchers", "nu-ansi-term", @@ -6889,7 +7434,7 @@ dependencies = [ "anchor-client", "anyhow", "bs58 0.4.0", - "clap 4.4.6", + "clap 4.4.8", "digital_asset_types", "env_logger 0.10.0", "flatbuffers", @@ -6941,7 +7486,7 @@ dependencies = [ "log", "rand 0.8.5", "rustls 0.20.9", - "sha-1", + "sha-1 0.10.1", "thiserror", "url", "utf-8", @@ -6954,7 +7499,7 @@ name = "txn_forwarder" version = "0.7.12" dependencies = [ "anyhow", - "clap 4.4.6", + "clap 4.4.8", "env_logger 0.10.0", "figment", "flatbuffers", @@ -7049,12 +7594,6 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e" -[[package]] -name = "unidecode" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "402bb19d8e03f1d1a7450e2bd613980869438e0666331be3e073089124aa1adc" - [[package]] name = "universal-hash" version = "0.4.1" @@ -7141,6 +7680,12 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" +[[package]] +name = "value-bag" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a72e1902dde2bd6441347de2b70b7f5d59bf157c6c62f0c44572607a1d55bbe" + [[package]] name = "vcpkg" version = "0.2.15" diff --git a/Cargo.toml b/Cargo.toml index d3677d7ee..583f3c720 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,8 +1,11 @@ [workspace] +resolver = "2" members = [ + "das_api", "digital_asset_types", "metadata_json", "metaplex-rpc-proxy", + "migration", "nft_ingester", "tree_backfiller", "tools/acc_forwarder", @@ -12,12 +15,107 @@ members = [ "tools/tree-status", "tools/txn_forwarder", ] -exclude = [ - "das_api", - "migration", - "metaplex_program_library", - "solana_program_library", -] + +[workspace.package] +version = "0.7.2" +edition = "2021" +repository = "https://github.com/metaplex-foundation/digital-asset-rpc-infrastructure" +publish = false + +[workspace.dependencies] +anchor-client = "0.28.0" +anchor-lang = "0.28.0" +anyhow = "1.0.75" +async-std = "1.0.0" +async-trait = "0.1.60" +base64 = "0.21.0" +blockbuster = "=0.9.0-beta.5" +borsh = "~0.10.3" +borsh-derive = "~0.10.3" +bs58 = "0.4.0" +cadence = "0.29.0" +cadence-macros = "0.29.0" +chrono = "0.4.19" +clap = "4.2.2" +das-metadata-json = { path = "metadata_json" } +das-tree-backfiller = { path = "tree_backfiller" } +digital_asset_types = { path = "digital_asset_types" } +enum-iterator = "1.2.0" +enum-iterator-derive = "1.1.0" +env_logger = "0.10.0" +fake = "2.5.0" +figment = "0.10.8" +flatbuffers = "23.1.21" +futures = "0.3.28" +futures-util = "0.3.27" +hex = "0.4.3" +hyper = "0.14.23" +indexmap = "1.9.3" +jsonpath_lib = "0.3.0" +jsonrpsee = "0.16.2" +jsonrpsee-core = "0.16.2" +lazy_static = "1.4.0" +log = "0.4.17" +metrics = "0.20.1" +mime_guess = "2.0.4" +mpl-bubblegum = "=1.0.1-beta.4" +mpl-candy-guard = "2.0.0" +mpl-candy-machine-core = "2.0.1" +mpl-token-metadata = "=2.0.0-beta.1" +nft_ingester = { path = "nft_ingester" } +num-derive = "0.3.3" +num-integer = { version = "0.1.44", default_features = false } +num-traits = "0.2.15" +open-rpc-derive = "0.0.4" +open-rpc-schema = "0.0.4" +plerkle_messenger = "1.6.0" +plerkle_serialization = "1.6.0" +prometheus = "0.13.3" +proxy-wasm = "0.2.0" +rand = "0.8.5" +redis = "0.22.3" +regex = "1.6.0" +reqwest = "0.11.13" +rust-crypto = "0.2.36" +schemars = "0.8.6" +schemars_derive = "0.8.6" +sea-orm = "0.10.6" +sea-orm-migration = "0.10.6" +sea-query = "0.28.1" +serde = "1.0.137" +serde_json = "1.0.81" +solana-account-decoder = "~1.16.16" +solana-client = "~1.16.16" +solana-geyser-plugin-interface = "~1.16.16" +solana-program = "~1.16.16" +solana-sdk = "~1.16.16" +solana-sdk-macro = "~1.16.16" +solana-transaction-status = "~1.16.16" +spl-account-compression = "0.2.0" +spl-associated-token-account = ">= 1.1.3, < 3.0" +spl-concurrent-merkle-tree = "0.2.0" +spl-noop = "0.2.0" +spl-token = ">= 3.5.0, < 5.0" +sqlx = "0.6.2" +stretto = "0.7.2" +thiserror = "1.0.31" +tokio = "1.30.0" +tokio-postgres = "0.7.7" +tokio-stream = "0.1.14" +tower = "0.4.13" +tower-http = "0.3.5" +tracing = "0.1.35" +tracing-subscriber = "0.3.16" +txn_forwarder = { path = "tools/txn_forwarder" } +url = "2.3.1" +uuid = "1.0.0" +wasi = "0.7.0" +wasm-bindgen = "0.2.83" + +[workspace.lints.clippy] +clone_on_ref_ptr = "deny" +missing_const_for_fn = "deny" +trivially_copy_pass_by_ref = "deny" [profile.release] lto = true diff --git a/README.md b/README.md index 2784bcad9..87d87aa79 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,14 @@ ## IMPORTANT: See Prerequisites below ## Digital Asset RPC API Infrastructure -This repo houses the API Ingester and Database Types components of the Metaplex Digital Asset RPC API. Together these -components are responsible for the aggregation of Solana Validator Data into an extremely fast and well typed api. This -api provides a nice interface on top of the Metaplex programs. It abstracts the byte layout on chain, allows for -super-fast querying and searching, as well as serves the merkle proofs needed to operate over compressed nfts. + +This repo houses the API Ingester and Database Types components of the Metaplex Digital Asset RPC API. Together these +components are responsible for the aggregation of Solana Validator Data into an extremely fast and well typed api. This +api provides a nice interface on top of the Metaplex programs. It abstracts the byte layout on chain, allows for +super-fast querying and searching, as well as serves the merkle proofs needed to operate over compressed nfts. ### Components + 1. Ingester -> A background processing system that gets messages from a [Messenger](https://github.com/metaplex-foundation/digital-asset-validator-plugin), and uses [BlockBuster](https://github.com/metaplex-foundation/blockbuster) Parsers to store the canonical representation of Metaplex types in a storage system. This system also holds the re-articulated Merkle tree that supports the compressed NFTs system. 2. Api -> A JSON Rpc api that serves Metaplex objects. This api allows filtering, pagination and searching over Metaplex data. This data includes serving the merkle proofs for the compressed NFTs system. It is intended to be run right alongside the Solana RPC and works in much the same way. Just like the solana RPC takes data from the validator and serves it in a new format, so this api takes data off the validator and serves it. @@ -14,44 +16,48 @@ The API specification is located here https://github.com/metaplex-foundation/api This spec is what providers of this api must implement against. ### Infrastructure and Deployment Examples -Along with the above rust binaries, this repo also maintains examples and best practice settings for running the entire infrastructure. -The example infrastructure is as follows. -* A Solana No-Vote Validator - This validator is configured to only have secure access to the validator ledger and account data under consensus. -* A Geyser Plugin (Plerkle) - The above validator is further configured to load this geyser plugin that sends Plerkle Serialized Messages over a messaging system. -* A Redis Cluster (Stream Optimized) - The example messaging system is a light weight redis deployment that supports the streaming configuration. -* A Kubernetes Cluster - The orchestration system for the API and Ingester processes. Probably overkill for a small installation, but it's a rock solid platform for critical software. +Along with the above rust binaries, this repo also maintains examples and best practice settings for running the entire infrastructure. +The example infrastructure is as follows. + +- A Solana No-Vote Validator - This validator is configured to only have secure access to the validator ledger and account data under consensus. +- A Geyser Plugin (Plerkle) - The above validator is further configured to load this geyser plugin that sends Plerkle Serialized Messages over a messaging system. +- A Redis Cluster (Stream Optimized) - The example messaging system is a light weight redis deployment that supports the streaming configuration. +- A Kubernetes Cluster - The orchestration system for the API and Ingester processes. Probably overkill for a small installation, but it's a rock solid platform for critical software. This repo houses Helm Charts, Docker files and Terraform files to assist in the deployment of the example infrastructure. ### Developing #### Prerequisites: + You must clone the https://github.com/metaplex-foundation/blockbuster repo, this is un publishable for now due to active development in like 1000 branches and serious mathematics avoiding dependency hell. Because this is a multi component system the easiest way to develop or locally test this system is with docker but developing locally without docker is possible. #### Regenerating DB Types + Edit the init.sql, then run `docker compose up db` Then with a local `DATABASE_URL` var exported like this `export DATABASE_URL=postgres://solana:solana@localhost/solana` you can run -` sea-orm-cli generate entity -o ./digital_asset_types/src/dao/generated/ --database-url $DATABASE_URL --with-serde both --expanded-format` +`sea-orm-cli generate entity -o ./digital_asset_types/src/dao/generated/ --database-url $DATABASE_URL --with-serde both --expanded-format` If you need to install `sea-orm-cli` run `cargo install sea-orm-cli`. Note: The current SeaORM types were generated using version 0.9.3 so unless you want to upgrade you can install using `cargo install sea-orm-cli --version 0.9.3`. -Also note: The migration `m20230224_093722_performance_improvements` needs to be commented out of the migration lib.rs in order for the Sea ORM `Relations` to generate correctly. - #### Developing Locally - *Prerequisites* - * A Postgres Server running with the database setup according to ./init.sql - * A Redis instance that has streams enabled or a version that supports streams - * A local solana validator with the Plerkle plugin running. - * Environment Variables set to allow your validator, ingester and api to access those prerequisites. + +_Prerequisites_ + +- A Postgres Server running with the database setup according to ./init.sql +- A Redis instance that has streams enabled or a version that supports streams +- A local solana validator with the Plerkle plugin running. +- Environment Variables set to allow your validator, ingester and api to access those prerequisites. See [Plugin Configuration](https://github.com/metaplex-foundation/digital-asset-validator-plugin#building-locally) for how to locally configure the test validator plugin to work. For the API you need the following environment variables: + ```bash APP_DATABASE_URL=postgres://solana:solana@db/solana #change to your db host APP_SERVER_PORT=9090 @@ -62,6 +68,7 @@ cargo run -p das_api ``` For the Ingester you need the following environment variables: + ```bash INGESTER_DATABASE_CONFIG: '{listener_channel="backfill_item_added", url="postgres://solana:solana@db/solana"}' # your database host INGESTER_MESSENGER_CONFIG: '{messenger_type="Redis", connection_config={ redis_connection_str="redis://redis" } }' #your redis @@ -72,13 +79,14 @@ INGESTER_RPC_CONFIG: '{url="http://validator:8899", commitment="finalized"}' # y cargo run -p nft_ingester ``` - When making changes you will need to stop the cargo process and re-run. Someday we will have auto rebuild for local cargo stuff but for now you are on your own. #### NOTE + ``` -INGESTER_ROLE +INGESTER_ROLE ``` + This environment variable can be used to split the work load. All for a combined setup @@ -89,48 +97,102 @@ Background for just the background tasks. For production you should split the coponents up. ### Developing With Docker + Developing with Docker is much easier, but has some nuances to it. This test docker compose system relies on a programs folder being accessible, this folder needs to have the shared object files for the following programs -* Token Metadata -* Bubblegum -* Gummyroll -* Token 2022 -* Latest version of the Associated token program -You need to run the following script (which takes a long time) in order to get all those .so files. +- Token Metadata +- Bubblegum +- Gummyroll +- Token 2022 +- Latest version of the Associated token program + +You need to run the following script in order to get the .so files. ```bash -chmod +x ./prepare-local-docker-env.sh ./prepare-local-docker-env.sh ``` + This script grabs all the code for these programs and compiles it, and chucks it into your programs folder. Go grab some coffe because this will take a while/ If you get some permissions errors, just sudo delete the programs directory and start again. #### Authentication with Docker and AWS -```aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin {your aws container registry}``` +`aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin {your aws container registry}` #### Running the application -We use ``docker-compose`` to build the multi-container Docker application. On some systems its ``docker compose``. +We use `docker-compose` to build the multi-container Docker application. On some systems its `docker compose`. + ```bash -docker-compose build +docker-compose build ``` + This builds the docker container for API and the Ingester components and will download the appropriate Redis, Postgres and Solana+plerkle docker images. Keep in mind that the version `latest` on the Solana Validator image will match the latest version available on the docs, for other versions please change that version in your docker compose file. ```bash -docker-compose up +docker-compose up ``` #### Developing -When making changes you will need to ``docker compose up --build --force-recreate`` again to get the latest changes. +When making changes you will need to `docker compose up --build --force-recreate` again to get the latest changes. Also when mucking about with the docker file if your gut tells you that something is wrong, and you are getting build errors run `docker compose build --no-cache` -Sometimes you will want to delete the db do so with `sudo rm -rf db-data`. You can also delete the ledger with `sudo rm -rf ledger`. +Sometimes you will want to delete the db do so with `sudo rm -rf db-data`. You can also delete the ledger with `sudo rm -rf ledger`. + +#### Running Bubblegum Test Sequences + +While running the multi-container Docker application locally, you can run a script located in `tools/txn_forwarder/bubblegum_tests` that will send sequences of bubblegum transactions via the `txn_forwarder`, and then use `psql` to read and verify the indexing results in the local Postgres database. + +```bash +sudo rm -rf db-data/ +sudo rm -rf ledger/ +docker compose up --force-recreate --build +``` + +_In another terminal:_ + +```bash +cd tools/txn_forwarder/bubblegum_tests/ +./run-bubblegum-sequences.sh +``` + +You should see it log something like: + +``` +Running 10 scenarios forwards +mint_transfer_burn.scenario initial asset table state passed +mint_transfer_burn.scenario initial asset_creators table state passed +mint_transfer_burn.scenario initial asset_grouping table state passed +mint_transfer_burn.scenario initial cl_items table state passed +... +mint_to_collection_unverify_collection.scenario asset table passed +mint_to_collection_unverify_collection.scenario asset_creators table passed +mint_to_collection_unverify_collection.scenario asset_grouping table passed +mint_to_collection_unverify_collection.scenario cl_items table passed + +ALL TESTS PASSED FORWARDS! +``` + +You can also run the sequences in reverse: + +```bash +./run-bubblegum-sequences.sh reverse +``` + +And after it runs you should see `ALL TESTS PASSED IN REVERSE!` + +A few detailed notes about this test script: + +- This script is not all-encompassing. It is only meant to automate some normal basic tests that were previously done manually. The reason this test is not added to CI is because requires a more powerful system to run the Docker application, which contains the no-vote Solana validator. +- The test sequences are in `.scenario` files, but instead of sending those files to the `txn_forwarder` directly (which supports the file format), we parse them out and send them individually using the `single` parameter. This is because using the `.scenario` file directly results in random ordering of the transactions and we are explicity trying to test them going forwards and in reverse. +- In general the expected database results are the same when running the transactions forwards and backwards. However, for assets that are decompressed, this is not true because we don't index some of the asset information from Bubblegum mint indexing if we already know the asset has been decompressed. We instead let Token Metadata account based indexing fill in that information. This is not reflected by this test script so the results differ when running these sequences in reverse. The differing results are reflected in test files with the `_reverse` suffix. #### Logs + To get a reasonable amount of logs while running Docker, direct grafana logs to a file: + ``` grafana: ... @@ -138,7 +200,9 @@ grafana: ... - GF_LOG_MODE=file ``` + and set Solana Rust logs to error level: + ``` solana: ... @@ -149,10 +213,13 @@ and set Solana Rust logs to error level: #### Interacting with API Once everything is working you can see that there is a api being served on + ``` http://localhost:9090 ``` + And a Metrics System on + ``` http://localhost:3000 ``` @@ -193,10 +260,12 @@ curl --request POST --url http://localhost:9090 --header 'Content-Type: applicat }' | json_pp ``` -# Deploying to Kubernetes +# Deploying to Kubernetes + Using skaffold you can deploy to k8s, make sure you authenticate with your docker registry Make sure you have the env vars you need to satisfy this part of the skaffold.yaml + ```yaml ... setValueTemplates: @@ -218,6 +287,7 @@ Make sure you have the env vars you need to satisfy this part of the skaffold.ya metrics.data_dog_api_key: "{{.DATA_DOG_API}}" ... ``` + ```bash skaffold build --file-output skaffold-state.json --cache-artifacts=false ## Your namepsace may differ. @@ -225,21 +295,26 @@ skaffold deploy -p devnet --build-artifacts skaffold-state.json --namespace devn ``` # METRICS + Here are the metrics that various parts of ths system expose; ## NFT INGESTER + ### ACKING + count ingester.ack - number of messages acked tagged by stream count ingester.stream.ack_error - error acking a message count ingester.stream.receive_error - error getting stream data ### Stream Metrics + ingester.stream_redelivery - Stream tagged of messages re delivered ingester.stream_size - Size of stream, tagged by stream ingester.stream_size_error - Error getting the stream size ### Stream Specific Metrics + All these metrics are tagged by stream count ingester.seen time ingester.proc_time @@ -249,6 +324,7 @@ count ingester.not_implemented count ingester.ingest_error ### BG Tasks + time ingester.bgtask.proc_time count ingester.bgtask.success count ingester.bgtask.error @@ -257,17 +333,15 @@ time ingester.bgtask.bus_time count ingester.bgtask.identical ### BACKFILLER + count ingester.backfiller.task_panic count ingester.backfiller.task_error guage ingester.backfiller.missing_trees ### Startup + ingester.startup ## API -api_call - - - - +api_call diff --git a/das_api/Cargo.lock b/das_api/Cargo.lock deleted file mode 100644 index 3b4aea3fe..000000000 --- a/das_api/Cargo.lock +++ /dev/null @@ -1,5864 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aead" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b613b8e1e3cf911a086f53f03bf286f52fd7a7258e4fa606f0ef220d39d8877" -dependencies = [ - "generic-array", -] - -[[package]] -name = "aes" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" -dependencies = [ - "cfg-if", - "cipher", - "cpufeatures", - "opaque-debug", -] - -[[package]] -name = "aes-gcm-siv" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "589c637f0e68c877bbd59a4599bbe849cac8e5f3e4b5a3ebae8f528cd218dcdc" -dependencies = [ - "aead", - "aes", - "cipher", - "ctr", - "polyval", - "subtle", - "zeroize", -] - -[[package]] -name = "ahash" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" -dependencies = [ - "getrandom 0.2.10", - "once_cell", - "version_check", -] - -[[package]] -name = "ahash" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" -dependencies = [ - "cfg-if", - "getrandom 0.2.10", - "once_cell", - "version_check", -] - -[[package]] -name = "aho-corasick" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" -dependencies = [ - "memchr", -] - -[[package]] -name = "aliasable" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "250f629c0161ad8107cf89319e990051fae62832fd343083bea452d93e2205fd" - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "allocator-api2" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" - -[[package]] -name = "anchor-attribute-access-control" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "faa5be5b72abea167f87c868379ba3c2be356bfca9e6f474fd055fa0f7eeb4f2" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "regex", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-account" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f468970344c7c9f9d03b4da854fd7c54f21305059f53789d0045c1dd803f0018" -dependencies = [ - "anchor-syn", - "anyhow", - "bs58 0.5.0", - "proc-macro2", - "quote", - "rustversion", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-constant" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59948e7f9ef8144c2aefb3f32a40c5fce2798baeec765ba038389e82301017ef" -dependencies = [ - "anchor-syn", - "proc-macro2", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-error" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc753c9d1c7981cb8948cf7e162fb0f64558999c0413058e2d43df1df5448086" -dependencies = [ - "anchor-syn", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-event" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f38b4e172ba1b52078f53fdc9f11e3dc0668ad27997838a0aad2d148afac8c97" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-program" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4eebd21543606ab61e2d83d9da37d24d3886a49f390f9c43a1964735e8c0f0d5" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-derive-accounts" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec4720d899b3686396cced9508f23dab420f1308344456ec78ef76f98fda42af" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-derive-space" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f495e85480bd96ddeb77b71d499247c7d4e8b501e75ecb234e9ef7ae7bd6552a" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-lang" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d2d4b20100f1310a774aba3471ef268e5c4ba4d5c28c0bbe663c2658acbc414" -dependencies = [ - "anchor-attribute-access-control", - "anchor-attribute-account", - "anchor-attribute-constant", - "anchor-attribute-error", - "anchor-attribute-event", - "anchor-attribute-program", - "anchor-derive-accounts", - "anchor-derive-space", - "arrayref", - "base64 0.13.1", - "bincode", - "borsh 0.10.3", - "bytemuck", - "getrandom 0.2.10", - "solana-program", - "thiserror", -] - -[[package]] -name = "anchor-syn" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a125e4b0cc046cfec58f5aa25038e34cf440151d58f0db3afc55308251fe936d" -dependencies = [ - "anyhow", - "bs58 0.5.0", - "heck 0.3.3", - "proc-macro2", - "quote", - "serde", - "serde_json", - "sha2 0.10.8", - "syn 1.0.109", - "thiserror", -] - -[[package]] -name = "android-tzdata" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e999941b234f3131b00bc13c22d06e8c5ff726d1b6318ac7eb276997bbb4fef0" - -[[package]] -name = "android_system_properties" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "819e7219dbd41043ac279b19830f2efc897156490d7fd6ea916720117ee66311" -dependencies = [ - "libc", -] - -[[package]] -name = "anyhow" -version = "1.0.75" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6" - -[[package]] -name = "ark-bn254" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a22f4561524cd949590d78d7d4c5df8f592430d221f7f3c9497bbafd8972120f" -dependencies = [ - "ark-ec", - "ark-ff", - "ark-std", -] - -[[package]] -name = "ark-ec" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "defd9a439d56ac24968cca0571f598a61bc8c55f71d50a89cda591cb750670ba" -dependencies = [ - "ark-ff", - "ark-poly", - "ark-serialize", - "ark-std", - "derivative", - "hashbrown 0.13.2", - "itertools 0.10.5", - "num-traits", - "zeroize", -] - -[[package]] -name = "ark-ff" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" -dependencies = [ - "ark-ff-asm", - "ark-ff-macros", - "ark-serialize", - "ark-std", - "derivative", - "digest 0.10.7", - "itertools 0.10.5", - "num-bigint 0.4.4", - "num-traits", - "paste", - "rustc_version", - "zeroize", -] - -[[package]] -name = "ark-ff-asm" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-ff-macros" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" -dependencies = [ - "num-bigint 0.4.4", - "num-traits", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-poly" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d320bfc44ee185d899ccbadfa8bc31aab923ce1558716e1997a1e74057fe86bf" -dependencies = [ - "ark-ff", - "ark-serialize", - "ark-std", - "derivative", - "hashbrown 0.13.2", -] - -[[package]] -name = "ark-serialize" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" -dependencies = [ - "ark-serialize-derive", - "ark-std", - "digest 0.10.7", - "num-bigint 0.4.4", -] - -[[package]] -name = "ark-serialize-derive" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae3281bc6d0fd7e549af32b52511e1302185bd688fd3359fa36423346ff682ea" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-std" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" -dependencies = [ - "num-traits", - "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" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b4930d2cb77ce62f89ee5d5289b4ac049559b1c45539271f5ed4fdc7db34545" - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "ascii" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eab1c04a571841102f5345a8fc0f6bb3d31c315dec879b5c6e42e40ce7ffa34e" - -[[package]] -name = "assert_matches" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b34d609dfbaf33d6889b2b7106d3ca345eacad44200913df5ba02bfd31d2ba9" - -[[package]] -name = "async-compression" -version = "0.3.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "942c7cd7ae39e91bde4820d74132e9862e62c2f386c3aa90ccf55949f5bad63a" -dependencies = [ - "brotli", - "flate2", - "futures-core", - "memchr", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "async-compression" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb42b2197bf15ccb092b62c74515dbd8b86d0effd934795f6687c93b6e679a2c" -dependencies = [ - "brotli", - "flate2", - "futures-core", - "memchr", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "async-stream" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd56dd203fef61ac097dd65721a419ddccb106b2d2b70ba60a6b529f03961a51" -dependencies = [ - "async-stream-impl", - "futures-core", - "pin-project-lite", -] - -[[package]] -name = "async-stream-impl" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "async-trait" -version = "0.1.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc00ceb34980c03614e35a3a4e218276a0a824e911d07651cd0d858a51e8c0f0" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "atoi" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7c57d12312ff59c811c0643f4d80830505833c9ffaebd193d819392b265be8e" -dependencies = [ - "num-traits", -] - -[[package]] -name = "atomic" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d818003e740b63afc82337e3160717f4f63078720a810b7b903e70a5d1d2994" -dependencies = [ - "bytemuck", -] - -[[package]] -name = "atty" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8" -dependencies = [ - "hermit-abi 0.1.19", - "libc", - "winapi", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "backtrace" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2089b7e3f35b9dd2d0ed921ead4f6d318c27680d4a5bd167b3ee120edb105837" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "bae" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33b8de67cc41132507eeece2584804efcb15f85ba516e34c944b7667f480397a" -dependencies = [ - "heck 0.3.3", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "base64" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3441f0f7b02788e948e47f457ca01f1d7e6d92c693bc132c22b087d3141c03ff" - -[[package]] -name = "base64" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" - -[[package]] -name = "base64" -version = "0.21.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ba43ea6f343b788c8764558649e08df62f86c6ef251fdaeb1ffd010a9ae50a2" - -[[package]] -name = "beef" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a8241f3ebb85c056b509d4327ad0358fbbba6ffb340bf388f26350aeda225b1" -dependencies = [ - "serde", -] - -[[package]] -name = "bincode" -version = "1.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcad" -dependencies = [ - "serde", -] - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635" - -[[package]] -name = "bitmaps" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "031043d04099746d8db04daf1fa424b2bc8bd69d92b25962dcde24da39ab64a2" -dependencies = [ - "typenum", -] - -[[package]] -name = "bitvec" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" -dependencies = [ - "funty", - "radium", - "tap", - "wyz", -] - -[[package]] -name = "blake3" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0231f06152bf547e9c2b5194f247cd97aacf6dcd8b15d8e5ec0663f64580da87" -dependencies = [ - "arrayref", - "arrayvec", - "cc", - "cfg-if", - "constant_time_eq", - "digest 0.10.7", -] - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "block-padding", - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-padding" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d696c370c750c948ada61c69a0ee2cbbb9c50b1019ddb86d9317157a99c2cae" - -[[package]] -name = "blockbuster" -version = "0.9.0-beta.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e0240c1218958c0d51284d783fa055f551d769bb8b7a4abf635b17fa9620dc" -dependencies = [ - "anchor-lang", - "async-trait", - "borsh 0.10.3", - "bs58 0.4.0", - "flatbuffers", - "lazy_static", - "log", - "mpl-bubblegum", - "mpl-candy-guard", - "mpl-candy-machine-core", - "mpl-token-metadata", - "plerkle_serialization", - "solana-sdk", - "spl-account-compression", - "spl-noop", - "spl-token 4.0.0", - "thiserror", -] - -[[package]] -name = "borsh" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15bf3650200d8bffa99015595e10f1fbd17de07abbc25bb067da79e769939bfa" -dependencies = [ - "borsh-derive 0.9.3", - "hashbrown 0.11.2", -] - -[[package]] -name = "borsh" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4114279215a005bc675e386011e594e1d9b800918cea18fcadadcce864a2046b" -dependencies = [ - "borsh-derive 0.10.3", - "hashbrown 0.13.2", -] - -[[package]] -name = "borsh-derive" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6441c552f230375d18e3cc377677914d2ca2b0d36e52129fe15450a2dce46775" -dependencies = [ - "borsh-derive-internal 0.9.3", - "borsh-schema-derive-internal 0.9.3", - "proc-macro-crate 0.1.5", - "proc-macro2", - "syn 1.0.109", -] - -[[package]] -name = "borsh-derive" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0754613691538d51f329cce9af41d7b7ca150bc973056f1156611489475f54f7" -dependencies = [ - "borsh-derive-internal 0.10.3", - "borsh-schema-derive-internal 0.10.3", - "proc-macro-crate 0.1.5", - "proc-macro2", - "syn 1.0.109", -] - -[[package]] -name = "borsh-derive-internal" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5449c28a7b352f2d1e592a8a28bf139bc71afb0764a14f3c02500935d8c44065" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "borsh-derive-internal" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "afb438156919598d2c7bad7e1c0adf3d26ed3840dbc010db1a882a65583ca2fb" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "borsh-schema-derive-internal" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdbd5696d8bfa21d53d9fe39a714a18538bad11492a42d066dbbc395fb1951c0" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "borsh-schema-derive-internal" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634205cc43f74a1b9046ef87c4540ebda95696ec0f315024860cad7c5b0f5ccd" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "brotli" -version = "3.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "516074a47ef4bce09577a3b379392300159ce5b1ba2e501ff1c819950066100f" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da74e2b81409b1b743f8f0c62cc6254afefb8b8e50bbfe3735550f7aeefa3448" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bs58" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3" - -[[package]] -name = "bs58" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5353f36341f7451062466f0b755b96ac3a9547e4d7f6b70d603fc721a7d7896" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "bstr" -version = "1.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c2f7349907b712260e64b0afe2f84692af14a454be26187d9df565c7f69266a" -dependencies = [ - "memchr", - "serde", -] - -[[package]] -name = "bumpalo" -version = "3.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f30e7476521f6f8af1a1c4c0b8cc94f0bee37d91763d0ca2665f299b6cd8aec" - -[[package]] -name = "bv" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8834bb1d8ee5dc048ee3124f2c7c1afcc6bc9aed03f11e9dfd8c69470a5db340" -dependencies = [ - "feature-probe", - "serde", -] - -[[package]] -name = "bytecheck" -version = "0.6.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b6372023ac861f6e6dc89c8344a8f398fb42aaba2b5dbc649ca0c0e9dbcb627" -dependencies = [ - "bytecheck_derive", - "ptr_meta", - "simdutf8", -] - -[[package]] -name = "bytecheck_derive" -version = "0.6.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7ec4c6f261935ad534c0c22dbef2201b45918860eb1c574b972bd213a76af61" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "bytemuck" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "374d28ec25809ee0e23827c2ab573d729e293f281dfe393500e7ad618baa61c6" -dependencies = [ - "bytemuck_derive", -] - -[[package]] -name = "bytemuck_derive" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "965ab7eb5f8f97d2a083c799f3a1b994fc397b2fe2da5d1da1626ce15a39f2b1" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" - -[[package]] -name = "cadence" -version = "0.29.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f39286bc075b023101dccdb79456a1334221c768b8faede0c2aff7ed29a9482d" -dependencies = [ - "crossbeam-channel", -] - -[[package]] -name = "cadence-macros" -version = "0.29.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a9f07a3c8a329df611200b46f7969235cf6377ad01d5b3d6e92555d4fc70781" -dependencies = [ - "cadence", -] - -[[package]] -name = "cc" -version = "1.0.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1174fb0b6ec23863f8b971027804a42614e347eafb0a95bf0b12cdae21fc4d0" -dependencies = [ - "jobserver", - "libc", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "chrono" -version = "0.4.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f2c685bad3eb3d45a01354cedb7d5faa66194d1d58ba6e267a8de788f79db38" -dependencies = [ - "android-tzdata", - "iana-time-zone", - "js-sys", - "num-traits", - "serde", - "wasm-bindgen", - "windows-targets", -] - -[[package]] -name = "cipher" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" -dependencies = [ - "generic-array", -] - -[[package]] -name = "combine" -version = "3.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da3da6baa321ec19e1cc41d31bf599f00c783d0517095cdaf0332e3fe8d20680" -dependencies = [ - "ascii", - "byteorder", - "either", - "memchr", - "unreachable", -] - -[[package]] -name = "console_error_panic_hook" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a06aeb73f470f66dcdbf7223caeebb85984942f22f1adb2a088cf9668146bbbc" -dependencies = [ - "cfg-if", - "wasm-bindgen", -] - -[[package]] -name = "console_log" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89f72f65e8501878b8a004d5a1afb780987e2ce2b4532c562e367a72c57499f" -dependencies = [ - "log", - "web-sys", -] - -[[package]] -name = "constant_time_eq" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7144d30dcf0fafbce74250a3963025d8d52177934239851c917d29f1df280c2" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" - -[[package]] -name = "cpufeatures" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" -dependencies = [ - "libc", -] - -[[package]] -name = "crc" -version = "3.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86ec7a15cbe22e59248fc7eadb1907dab5ba09372595da4d73dd805ed4417dfe" -dependencies = [ - "crc-catalog", -] - -[[package]] -name = "crc-catalog" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cace84e55f07e7301bae1c519df89cdad8cc3cd868413d3fdbdeca9ff3db484" - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce6fd6f855243022dcecf8702fef0c297d4338e226845fe067f6341ad9fa0cef" -dependencies = [ - "cfg-if", - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae211234986c545741a7dc064309f67ee1e5ad243d0e48335adc0484d960bcc7" -dependencies = [ - "autocfg", - "cfg-if", - "crossbeam-utils", - "memoffset", - "scopeguard", -] - -[[package]] -name = "crossbeam-queue" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1cfb3ea8a53f37c40dea2c7bedcbd88bdfae54f5e2175d6ecaff1c988353add" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crunchy" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "crypto-mac" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" -dependencies = [ - "generic-array", - "subtle", -] - -[[package]] -name = "ctr" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" -dependencies = [ - "cipher", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90f9d052967f590a76e62eb387bd0bbb1b000182c3cefe5364db6b7211651bc0" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "serde", - "subtle", - "zeroize", -] - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core 0.13.4", - "darling_macro 0.13.4", -] - -[[package]] -name = "darling" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" -dependencies = [ - "darling_core 0.20.3", - "darling_macro 0.20.3", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 1.0.109", -] - -[[package]] -name = "darling_core" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 2.0.38", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core 0.13.4", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" -dependencies = [ - "darling_core 0.20.3", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "das_api" -version = "0.7.2" -dependencies = [ - "anchor-lang", - "async-trait", - "blockbuster", - "bs58 0.4.0", - "cadence", - "cadence-macros", - "digital_asset_types", - "env_logger 0.10.0", - "figment", - "hyper", - "jsonrpsee", - "jsonrpsee-core", - "log", - "metrics", - "mpl-bubblegum", - "mpl-candy-guard", - "mpl-candy-machine-core", - "mpl-token-metadata", - "open-rpc-derive", - "open-rpc-schema", - "schemars", - "schemars_derive", - "sea-orm", - "serde", - "serde_json", - "solana-sdk", - "sqlx", - "thiserror", - "tokio", - "tokio-postgres", - "tower", - "tower-http", - "tracing", -] - -[[package]] -name = "deranged" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2696e8a945f658fd14dc3b87242e6b80cd0f36ff04ea560fa39082368847946" -dependencies = [ - "serde", -] - -[[package]] -name = "derivation-path" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5c37193a1db1d8ed868c03ec7b152175f26160a5b740e5e484143877e0adf0" - -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "digital_asset_types" -version = "0.7.2" -dependencies = [ - "async-trait", - "blockbuster", - "bs58 0.4.0", - "futures", - "indexmap 1.9.3", - "jsonpath_lib", - "log", - "mime_guess", - "num-derive 0.3.3", - "num-traits", - "reqwest", - "schemars", - "schemars_derive", - "sea-orm", - "sea-query 0.28.5", - "serde", - "serde_json", - "solana-sdk", - "spl-concurrent-merkle-tree", - "thiserror", - "tokio", - "url", -] - -[[package]] -name = "dirs" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3aa72a6f96ea37bbc5aa912f6788242832f75369bdfdadcb0e38423f100059" -dependencies = [ - "dirs-sys", -] - -[[package]] -name = "dirs-sys" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dotenvy" -version = "0.15.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" - -[[package]] -name = "dyn-clone" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23d2f3407d9a573d666de4b5bdf10569d73ca9478087346697dcbae6244bfbcd" - -[[package]] -name = "eager" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abe71d579d1812060163dff96056261deb5bf6729b100fa2e36a68b9649ba3d3" - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "ed25519-dalek-bip32" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d2be62a4061b872c8c0873ee4fc6f101ce7b889d039f019c5fa2af471a59908" -dependencies = [ - "derivation-path", - "ed25519-dalek", - "hmac 0.12.1", - "sha2 0.10.8", -] - -[[package]] -name = "either" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" -dependencies = [ - "serde", -] - -[[package]] -name = "encoding_rs" -version = "0.8.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7268b386296a025e474d5140678f75d6de9493ae55a5d709eeb9dd08149945e1" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "enum-iterator" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7add3873b5dd076766ee79c8e406ad1a472c385476b9e38849f8eec24f1be689" -dependencies = [ - "enum-iterator-derive", -] - -[[package]] -name = "enum-iterator-derive" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eecf8589574ce9b895052fa12d69af7a233f99e6107f5cb8dd1044f2a17bfdcb" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "env_logger" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a12e6657c4c97ebab115a42dcee77225f7f482cdd841cf7088c657a42e9e00e7" -dependencies = [ - "atty", - "humantime", - "log", - "regex", - "termcolor", -] - -[[package]] -name = "env_logger" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85cdab6a89accf66733ad5a1693a4dcced6aeff64602b634530dd73c1f3ee9f0" -dependencies = [ - "humantime", - "is-terminal", - "log", - "regex", - "termcolor", -] - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3e13f66a2f95e32a39eaa81f6b95d42878ca0e1db0c7543723dfe12557e860" -dependencies = [ - "libc", - "windows-sys", -] - -[[package]] -name = "event-listener" -version = "2.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" - -[[package]] -name = "fallible-iterator" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4443176a9f2c162692bd3d352d745ef9413eec5782a80d8fd6f8a1ac692a07f7" - -[[package]] -name = "fastrand" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" - -[[package]] -name = "feature-probe" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "835a3dc7d1ec9e75e2b5fb4ba75396837112d2060b03f7d43bc1897c7f7211da" - -[[package]] -name = "figment" -version = "0.10.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a014ac935975a70ad13a3bff2463b1c1b083b35ae4cb6309cfc59476aa7a181f" -dependencies = [ - "atomic", - "pear", - "serde", - "uncased", - "version_check", -] - -[[package]] -name = "finl_unicode" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fcfdc7a0362c9f4444381a9e697c79d435fe65b52a37466fc2c1184cee9edc6" - -[[package]] -name = "flatbuffers" -version = "23.5.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dac53e22462d78c16d64a1cd22371b54cc3fe94aa15e7886a2fa6e5d1ab8640" -dependencies = [ - "bitflags 1.3.2", - "rustc_version", -] - -[[package]] -name = "flate2" -version = "1.0.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6c98ee8095e9d1dcbf2fcc6d95acccb90d1c81db1e44725c6a984b1dbdfb010" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "funty" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" - -[[package]] -name = "futures" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23342abe12aba583913b2e62f22225ff9c950774065e4bfb61a19cd9770fec40" -dependencies = [ - "futures-channel", - "futures-core", - "futures-executor", - "futures-io", - "futures-sink", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-channel" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" - -[[package]] -name = "futures-executor" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-intrusive" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a604f7a68fbf8103337523b1fadc8ade7361ee3f112f7c680ad179651616aed5" -dependencies = [ - "futures-core", - "lock_api", - "parking_lot 0.11.2", -] - -[[package]] -name = "futures-io" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" - -[[package]] -name = "futures-macro" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "futures-sink" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" - -[[package]] -name = "futures-task" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" - -[[package]] -name = "futures-util" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" -dependencies = [ - "futures-channel", - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "serde", - "typenum", - "version_check", -] - -[[package]] -name = "gethostname" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1ebd34e35c46e00bb73e81363248d627782724609fe1b6396f553f68fe3862e" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "js-sys", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", - "wasm-bindgen", -] - -[[package]] -name = "getrandom" -version = "0.2.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" -dependencies = [ - "cfg-if", - "js-sys", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "wasm-bindgen", -] - -[[package]] -name = "gimli" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fb8d784f27acf97159b40fc4db5ecd8aa23b9ad5ef69cdd136d3bc80665f0c0" - -[[package]] -name = "globset" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "759c97c1e17c55525b57192c06a267cda0ac5210b222d6b82189a2338fa1c13d" -dependencies = [ - "aho-corasick", - "bstr", - "fnv", - "log", - "regex", -] - -[[package]] -name = "goblin" -version = "0.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7666983ed0dd8d21a6f6576ee00053ca0926fb281a5522577a4dbd0f1b54143" -dependencies = [ - "log", - "plain", - "scroll", -] - -[[package]] -name = "h2" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91fc23aa11be92976ef4729127f1a74adf36d8436f7816b185d18df956790833" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http", - "indexmap 1.9.3", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hash32" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0c35f58762feb77d74ebe43bdbc3210f09be9fe6742234d573bacc26ed92b67" -dependencies = [ - "byteorder", -] - -[[package]] -name = "hashbrown" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab5ef0d4909ef3724cc8cce6ccc8572c5c817592e9285f5464f8e86f8bd3726e" -dependencies = [ - "ahash 0.7.6", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" -dependencies = [ - "ahash 0.7.6", -] - -[[package]] -name = "hashbrown" -version = "0.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" -dependencies = [ - "ahash 0.8.3", -] - -[[package]] -name = "hashbrown" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dfda62a12f55daeae5015f81b0baea145391cb4520f86c248fc615d72640d12" -dependencies = [ - "ahash 0.8.3", - "allocator-api2", -] - -[[package]] -name = "hashlink" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" -dependencies = [ - "hashbrown 0.14.1", -] - -[[package]] -name = "hdrhistogram" -version = "7.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f19b9f54f7c7f55e31401bb647626ce0cf0f67b0004982ce815b3ee72a02aa8" -dependencies = [ - "byteorder", - "num-traits", -] - -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "hermit-abi" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hkdf" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" -dependencies = [ - "hmac 0.12.1", -] - -[[package]] -name = "hmac" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "126888268dcc288495a26bf004b38c5fdbb31682f992c84ceb046a1f0fe38840" -dependencies = [ - "crypto-mac", - "digest 0.9.0", -] - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "hmac-drbg" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1" -dependencies = [ - "digest 0.9.0", - "generic-array", - "hmac 0.8.1", -] - -[[package]] -name = "http" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" -dependencies = [ - "bytes", - "http", - "pin-project-lite", -] - -[[package]] -name = "http-range-header" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "add0ab9360ddbd88cfeb3bd9574a1d85cfdfa14db10b3e21d3700dbc4328758f" - -[[package]] -name = "httparse" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" - -[[package]] -name = "httpdate" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" - -[[package]] -name = "humantime" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" - -[[package]] -name = "hyper" -version = "0.14.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa", - "pin-project-lite", - "socket2 0.4.9", - "tokio", - "tower-service", - "tracing", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d78e1e73ec14cf7375674f74d7dde185c8206fd9dea6fb6295e8a98098aaa97" -dependencies = [ - "futures-util", - "http", - "hyper", - "rustls 0.21.7", - "tokio", - "tokio-rustls 0.24.1", -] - -[[package]] -name = "hyper-tls" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" -dependencies = [ - "bytes", - "hyper", - "native-tls", - "tokio", - "tokio-native-tls", -] - -[[package]] -name = "iana-time-zone" -version = "0.1.57" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" -dependencies = [ - "android_system_properties", - "core-foundation-sys", - "iana-time-zone-haiku", - "js-sys", - "wasm-bindgen", - "windows", -] - -[[package]] -name = "iana-time-zone-haiku" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" -dependencies = [ - "cc", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "im" -version = "15.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0acd33ff0285af998aaf9b57342af478078f53492322fafc47450e09397e0e9" -dependencies = [ - "bitmaps", - "rand_core 0.6.4", - "rand_xoshiro", - "rayon", - "serde", - "sized-chunks", - "typenum", - "version_check", -] - -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown 0.12.3", -] - -[[package]] -name = "indexmap" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8adf3ddd720272c6ea8bf59463c04e0f93d0bbf7c5439b691bca2987e0270897" -dependencies = [ - "equivalent", - "hashbrown 0.14.1", -] - -[[package]] -name = "inlinable_string" -version = "0.1.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8fae54786f62fb2918dcfae3d568594e50eb9b5c25bf04371af6fe7516452fb" - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "ipnet" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" - -[[package]] -name = "iri-string" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f0f7638c1e223529f1bfdc48c8b133b9e0b434094d1d28473161ee48b235f78" -dependencies = [ - "nom", -] - -[[package]] -name = "is-terminal" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" -dependencies = [ - "hermit-abi 0.3.3", - "rustix", - "windows-sys", -] - -[[package]] -name = "itertools" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" -dependencies = [ - "either", -] - -[[package]] -name = "itertools" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" - -[[package]] -name = "jobserver" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "936cfd212a0155903bcbc060e316fb6cc7cbf2e1907329391ebadc1fe0ce77c2" -dependencies = [ - "libc", -] - -[[package]] -name = "js-sys" -version = "0.3.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "jsonpath_lib" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaa63191d68230cccb81c5aa23abd53ed64d83337cacbb25a7b8c7979523774f" -dependencies = [ - "log", - "serde", - "serde_json", -] - -[[package]] -name = "jsonrpsee" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "367a292944c07385839818bb71c8d76611138e2dedb0677d035b8da21d29c78b" -dependencies = [ - "jsonrpsee-core", - "jsonrpsee-proc-macros", - "jsonrpsee-server", - "jsonrpsee-types", - "tracing", -] - -[[package]] -name = "jsonrpsee-core" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b5dde66c53d6dcdc8caea1874a45632ec0fcf5b437789f1e45766a1512ce803" -dependencies = [ - "anyhow", - "arrayvec", - "async-trait", - "beef", - "futures-channel", - "futures-util", - "globset", - "hyper", - "jsonrpsee-types", - "parking_lot 0.12.1", - "rand 0.8.5", - "rustc-hash", - "serde", - "serde_json", - "soketto", - "thiserror", - "tokio", - "tracing", -] - -[[package]] -name = "jsonrpsee-proc-macros" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44e8ab85614a08792b9bff6c8feee23be78c98d0182d4c622c05256ab553892a" -dependencies = [ - "heck 0.4.1", - "proc-macro-crate 1.3.1", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "jsonrpsee-server" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4d945a6008c9b03db3354fb3c83ee02d2faa9f2e755ec1dfb69c3551b8f4ba" -dependencies = [ - "futures-channel", - "futures-util", - "http", - "hyper", - "jsonrpsee-core", - "jsonrpsee-types", - "serde", - "serde_json", - "soketto", - "tokio", - "tokio-stream", - "tokio-util", - "tower", - "tracing", -] - -[[package]] -name = "jsonrpsee-types" -version = "0.16.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "245ba8e5aa633dd1c1e4fae72bce06e71f42d34c14a2767c6b4d173b57bee5e5" -dependencies = [ - "anyhow", - "beef", - "serde", - "serde_json", - "thiserror", - "tracing", -] - -[[package]] -name = "kaigan" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a26f49495f94a283312e7ef45a243540ef20c9356bb01c8d84a61ac8ba5339b" -dependencies = [ - "borsh 0.10.3", -] - -[[package]] -name = "keccak" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.149" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" - -[[package]] -name = "libsecp256k1" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9d220bc1feda2ac231cb78c3d26f27676b8cf82c96971f7aeef3d0cf2797c73" -dependencies = [ - "arrayref", - "base64 0.12.3", - "digest 0.9.0", - "hmac-drbg", - "libsecp256k1-core", - "libsecp256k1-gen-ecmult", - "libsecp256k1-gen-genmult", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "typenum", -] - -[[package]] -name = "libsecp256k1-core" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0f6ab710cec28cef759c5f18671a27dae2a5f952cdaaee1d8e2908cb2478a80" -dependencies = [ - "crunchy", - "digest 0.9.0", - "subtle", -] - -[[package]] -name = "libsecp256k1-gen-ecmult" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccab96b584d38fac86a83f07e659f0deafd0253dc096dab5a36d53efe653c5c3" -dependencies = [ - "libsecp256k1-core", -] - -[[package]] -name = "libsecp256k1-gen-genmult" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67abfe149395e3aa1c48a2beb32b068e2334402df8181f818d3aee2b304c4f5d" -dependencies = [ - "libsecp256k1-core", -] - -[[package]] -name = "linux-raw-sys" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" - -[[package]] -name = "lock_api" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" - -[[package]] -name = "md-5" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf" -dependencies = [ - "cfg-if", - "digest 0.10.7", -] - -[[package]] -name = "memchr" -version = "2.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" - -[[package]] -name = "memmap2" -version = "0.5.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83faa42c0a078c393f6b29d5db232d8be22776a891f8f56e5284faee4a20b327" -dependencies = [ - "libc", -] - -[[package]] -name = "memoffset" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" -dependencies = [ - "autocfg", -] - -[[package]] -name = "merlin" -version = "3.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58c38e2799fc0978b65dfff8023ec7843e2330bb462f19198840b34b6582397d" -dependencies = [ - "byteorder", - "keccak", - "rand_core 0.6.4", - "zeroize", -] - -[[package]] -name = "metrics" -version = "0.20.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b9b8653cec6897f73b519a43fba5ee3d50f62fe9af80b428accdcc093b4a849" -dependencies = [ - "ahash 0.7.6", - "metrics-macros", - "portable-atomic 0.3.20", -] - -[[package]] -name = "metrics-macros" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "731f8ecebd9f3a4aa847dfe75455e4757a45da40a7793d2f0b1f9b6ed18b23f3" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "mime_guess" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4192263c238a5f0d0c6bfd21f336a313a4ce1c450542449ca191bb657b4642ef" -dependencies = [ - "mime", - "unicase", -] - -[[package]] -name = "minimal-lexical" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" - -[[package]] -name = "miniz_oxide" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys", -] - -[[package]] -name = "mpl-bubblegum" -version = "1.0.1-beta.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29346f26192bb7f73330196fde4c8cfb35675bf1a4b026cd088f7ca8fda69f3f" -dependencies = [ - "borsh 0.10.3", - "kaigan", - "num-derive 0.3.3", - "num-traits", - "solana-program", - "thiserror", -] - -[[package]] -name = "mpl-candy-guard" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59c5c2ffb233226e0c531f1cf800909e46120e98722eeb53dae68b0996303a38" -dependencies = [ - "anchor-lang", - "arrayref", - "mpl-candy-guard-derive", - "mpl-candy-machine-core", - "mpl-token-auth-rules", - "mpl-token-metadata", - "solana-gateway", - "solana-program", - "spl-associated-token-account", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", -] - -[[package]] -name = "mpl-candy-guard-derive" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18e4d3002ea881e94a238798faf87a006a687297a24bd4b3f810fbb63611173d" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "mpl-candy-machine-core" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4db99e1aac3bdebf907338aec5f1785701b8a82e6bdac5f42a270750d37c5264" -dependencies = [ - "anchor-lang", - "arrayref", - "mpl-token-auth-rules", - "mpl-token-metadata", - "solana-program", - "spl-associated-token-account", - "spl-token 4.0.0", -] - -[[package]] -name = "mpl-token-auth-rules" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66b1ec5ee0570f688cc84ff4624c5c50732f1a2bfc789f6b34af5b563428d971" -dependencies = [ - "borsh 0.10.3", - "bytemuck", - "mpl-token-metadata-context-derive 0.2.1", - "num-derive 0.3.3", - "num-traits", - "rmp-serde", - "serde", - "shank", - "solana-program", - "solana-zk-token-sdk", - "thiserror", -] - -[[package]] -name = "mpl-token-metadata" -version = "2.0.0-beta.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3545bd5fe73416f6514cd93899612e0e138619e72df8bc7d19906a12688c69e" -dependencies = [ - "arrayref", - "borsh 0.10.3", - "mpl-token-auth-rules", - "mpl-token-metadata-context-derive 0.3.0", - "mpl-utils", - "num-derive 0.3.3", - "num-traits", - "serde", - "serde_with 1.14.0", - "shank", - "solana-program", - "spl-associated-token-account", - "spl-token 4.0.0", - "thiserror", -] - -[[package]] -name = "mpl-token-metadata-context-derive" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12989bc45715b0ee91944855130131479f9c772e198a910c3eb0ea327d5bffc3" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "mpl-token-metadata-context-derive" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5a739019e11d93661a64ef5fe108ab17c79b35961e944442ff6efdd460ad01a" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "mpl-utils" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f2e4f92aec317d5853c0cc4c03c55f5178511c45bb3dbb441aea63117bf3dc9" -dependencies = [ - "arrayref", - "solana-program", - "spl-token-2022 0.6.1", -] - -[[package]] -name = "native-tls" -version = "0.2.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07226173c32f2926027b63cce4bcd8076c3552846cbe7925f3aaffeac0a3b92e" -dependencies = [ - "lazy_static", - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nom" -version = "7.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" -dependencies = [ - "memchr", - "minimal-lexical", -] - -[[package]] -name = "num" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8536030f9fea7127f841b45bb6243b27255787fb4eb83958aa1ef9d2fdc0c36" -dependencies = [ - "num-bigint 0.2.6", - "num-complex", - "num-integer", - "num-iter", - "num-rational", - "num-traits", -] - -[[package]] -name = "num-bigint" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "090c7f9998ee0ff65aa5b723e4009f7b217707f1fb5ea551329cc4d6231fb304" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-bigint" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608e7659b5c3d7cba262d894801b9ec9d00de989e8a82bd4bef91d08da45cdc0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-complex" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6b19411a9719e753aff12e5187b74d60d3dc449ec3f4dc21e3989c3f554bc95" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-derive" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "num-derive" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfb77679af88f8b125209d354a202862602672222e7f2313fdd6dc349bad4712" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-iter" -version = "0.1.43" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d03e6c028c5dc5cac6e2dec0efda81fc887605bb3d884578bb6d6bf7514e252" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c000134b5dbf44adc5cb772486d335293351644b801551abe8f75c84cfa4aef" -dependencies = [ - "autocfg", - "num-bigint 0.2.6", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi 0.3.3", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" -dependencies = [ - "num_enum_derive 0.5.11", -] - -[[package]] -name = "num_enum" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a015b430d3c108a207fd776d2e2196aaf8b1cf8cf93253e3a097ff3085076a1" -dependencies = [ - "num_enum_derive 0.6.1", -] - -[[package]] -name = "num_enum" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70bf6736f74634d299d00086f02986875b3c2d924781a6a2cb6c201e73da0ceb" -dependencies = [ - "num_enum_derive 0.7.0", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" -dependencies = [ - "proc-macro-crate 1.3.1", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "num_enum_derive" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" -dependencies = [ - "proc-macro-crate 1.3.1", - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "num_enum_derive" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ea360eafe1022f7cc56cd7b869ed57330fb2453d0c7831d99b74c65d2f5597" -dependencies = [ - "proc-macro-crate 1.3.1", - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "object" -version = "0.32.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf5f9dd3933bd50a9e1f149ec995f39ae2c496d31fd772c1fd45ebc27e902b0" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" - -[[package]] -name = "opaque-debug" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" - -[[package]] -name = "open-rpc-derive" -version = "0.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae3de03a56750973a83c76a40fb4b81969d42fad152cd0e787e25c79dcf54e3f" -dependencies = [ - "open-rpc-schema", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "open-rpc-schema" -version = "0.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6919654a78166b8d8f266f702ce763c0880c11a2e75e1de9cc3e51704abf620" -dependencies = [ - "schemars", - "schemars_derive", - "serde", - "serde_json", -] - -[[package]] -name = "openssl" -version = "0.10.57" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bac25ee399abb46215765b1cb35bc0212377e58a061560d8b29b024fd0430e7c" -dependencies = [ - "bitflags 2.4.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db4d56a4c0478783083cfafcc42493dd4a981d41669da64b4572a2a089b51b1d" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "ouroboros" -version = "0.15.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1358bd1558bd2a083fed428ffeda486fbfb323e698cdda7794259d592ca72db" -dependencies = [ - "aliasable", - "ouroboros_macro", -] - -[[package]] -name = "ouroboros_macro" -version = "0.15.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f7d21ccd03305a674437ee1248f3ab5d4b1db095cf1caf49f1713ddf61956b7" -dependencies = [ - "Inflector", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "parking_lot" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99" -dependencies = [ - "instant", - "lock_api", - "parking_lot_core 0.8.6", -] - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core 0.9.8", -] - -[[package]] -name = "parking_lot_core" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60a2cfe6f0ad2bfc16aefa463b497d5c7a5ecd44a23efa72aa342d90177356dc" -dependencies = [ - "cfg-if", - "instant", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "winapi", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.3.5", - "smallvec", - "windows-targets", -] - -[[package]] -name = "paste" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" - -[[package]] -name = "pbkdf2" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "216eaa586a190f0a738f2f918511eecfa90f13295abec0e457cdebcceda80cbd" -dependencies = [ - "crypto-mac", -] - -[[package]] -name = "pbkdf2" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "pear" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61a386cd715229d399604b50d1361683fe687066f42d56f54be995bc6868f71c" -dependencies = [ - "inlinable_string", - "pear_codegen", - "yansi", -] - -[[package]] -name = "pear_codegen" -version = "0.2.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da9f0f13dac8069c139e8300a6510e3f4143ecf5259c60b116a9b271b4ca0d54" -dependencies = [ - "proc-macro2", - "proc-macro2-diagnostics", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "percent-encoding" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" - -[[package]] -name = "percentage" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd23b938276f14057220b707937bcb42fa76dda7560e57a2da30cb52d557937" -dependencies = [ - "num", -] - -[[package]] -name = "phf" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ade2d8b8f33c7333b51bcf0428d37e217e9f32192ae4772156f65063b8ce03dc" -dependencies = [ - "phf_shared", -] - -[[package]] -name = "phf_shared" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90fcb95eef784c2ac79119d1dd819e162b5da872ce6f3c3abe1e8ca1c082f72b" -dependencies = [ - "siphasher", -] - -[[package]] -name = "pin-project" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fda4ed1c6c173e3fc7a83629421152e01d7b1f9b7f65fb301e490e8cfc656422" -dependencies = [ - "pin-project-internal", -] - -[[package]] -name = "pin-project-internal" -version = "1.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4359fd9c9171ec6e8c62926d6faaf553a8dc3f64e1507e76da7911b4f6a04405" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "pkg-config" -version = "0.3.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" - -[[package]] -name = "plain" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6" - -[[package]] -name = "plerkle_serialization" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f021e409a6a1ec8b7a325db27254e7fa3942e845cfe96f5f8f494977f2646a8" -dependencies = [ - "bs58 0.4.0", - "chrono", - "flatbuffers", - "serde", - "solana-sdk", - "solana-transaction-status", - "thiserror", -] - -[[package]] -name = "polyval" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1" -dependencies = [ - "cfg-if", - "cpufeatures", - "opaque-debug", - "universal-hash", -] - -[[package]] -name = "portable-atomic" -version = "0.3.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e30165d31df606f5726b090ec7592c308a0eaf61721ff64c9a3018e344a8753e" -dependencies = [ - "portable-atomic 1.4.3", -] - -[[package]] -name = "portable-atomic" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31114a898e107c51bb1609ffaf55a0e011cf6a4d7f1170d0015a165082c0338b" - -[[package]] -name = "postgres-protocol" -version = "0.6.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49b6c5ef183cd3ab4ba005f1ca64c21e8bd97ce4699cfea9e8d9a2c4958ca520" -dependencies = [ - "base64 0.21.4", - "byteorder", - "bytes", - "fallible-iterator", - "hmac 0.12.1", - "md-5", - "memchr", - "rand 0.8.5", - "sha2 0.10.8", - "stringprep", -] - -[[package]] -name = "postgres-types" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d2234cdee9408b523530a9b6d2d6b373d1db34f6a8e51dc03ded1828d7fb67c" -dependencies = [ - "bytes", - "fallible-iterator", - "postgres-protocol", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro-crate" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d6ea3c4595b96363c13943497db34af4460fb474a95c43f4446ad341b8c9785" -dependencies = [ - "toml", -] - -[[package]] -name = "proc-macro-crate" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" -dependencies = [ - "once_cell", - "toml_edit", -] - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - -[[package]] -name = "proc-macro2" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "proc-macro2-diagnostics" -version = "0.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af066a9c399a26e020ada66a034357a868728e72cd426f3adcd35f80d88d88c8" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", - "version_check", - "yansi", -] - -[[package]] -name = "ptr_meta" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0738ccf7ea06b608c10564b31debd4f5bc5e197fc8bfe088f68ae5ce81e7a4f1" -dependencies = [ - "ptr_meta_derive", -] - -[[package]] -name = "ptr_meta_derive" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16b845dbfca988fa33db069c0e230574d15a3088f147a87b64c7589eb662c9ac" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "qstring" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d464fae65fff2680baf48019211ce37aaec0c78e9264c84a3e484717f965104e" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "quote" -version = "1.0.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radium" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.10", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_xoshiro" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f97cdb2a36ed4183de61b2f824cc45c9f1037f28afe0a322e9fff4c108b5aaa" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "rayon" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c27db03db7734835b3f53954b534c91069375ce6ccaa2e065441e07d9b6cdb1" -dependencies = [ - "either", - "rayon-core", -] - -[[package]] -name = "rayon-core" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ce3fb6ad83f861aac485e76e1985cd109d9a3713802152be56c3b1f0e0658ed" -dependencies = [ - "crossbeam-deque", - "crossbeam-utils", -] - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags 1.3.2", -] - -[[package]] -name = "redox_syscall" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" -dependencies = [ - "bitflags 1.3.2", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.10", - "redox_syscall 0.2.16", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.9.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebee201405406dbf528b8b672104ae6d6d63e6d118cb10e4d51abbc7b58044ff" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata", - "regex-syntax", -] - -[[package]] -name = "regex-automata" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b23e92ee4318893fa3fe3e6fb365258efbfe6ac6ab30f090cdcbb7aa37efa9" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" - -[[package]] -name = "rend" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2571463863a6bd50c32f94402933f03457a3fbaf697a707c5be741e459f08fd" -dependencies = [ - "bytecheck", -] - -[[package]] -name = "reqwest" -version = "0.11.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "046cd98826c46c2ac8ddecae268eb5c2e58628688a5fc7a2643704a73faba95b" -dependencies = [ - "async-compression 0.4.3", - "base64 0.21.4", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "hyper", - "hyper-rustls", - "hyper-tls", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls 0.21.7", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "system-configuration", - "tokio", - "tokio-native-tls", - "tokio-rustls 0.24.1", - "tokio-util", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "webpki-roots 0.25.2", - "winreg", -] - -[[package]] -name = "ring" -version = "0.16.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" -dependencies = [ - "cc", - "libc", - "once_cell", - "spin 0.5.2", - "untrusted 0.7.1", - "web-sys", - "winapi", -] - -[[package]] -name = "ring" -version = "0.17.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "911b295d2d302948838c8ac142da1ee09fa7863163b44e6715bc9357905878b8" -dependencies = [ - "cc", - "getrandom 0.2.10", - "libc", - "spin 0.9.8", - "untrusted 0.9.0", - "windows-sys", -] - -[[package]] -name = "rkyv" -version = "0.7.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0200c8230b013893c0b2d6213d6ec64ed2b9be2e0e016682b7224ff82cff5c58" -dependencies = [ - "bitvec", - "bytecheck", - "hashbrown 0.12.3", - "ptr_meta", - "rend", - "rkyv_derive", - "seahash", - "tinyvec", - "uuid", -] - -[[package]] -name = "rkyv_derive" -version = "0.7.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2e06b915b5c230a17d7a736d1e2e63ee753c256a8614ef3f5147b13a4f5541d" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "rmp" -version = "0.8.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f9860a6cc38ed1da53456442089b4dfa35e7cedaa326df63017af88385e6b20" -dependencies = [ - "byteorder", - "num-traits", - "paste", -] - -[[package]] -name = "rmp-serde" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bffea85eea980d8a74453e5d02a8d93028f3c34725de143085a844ebe953258a" -dependencies = [ - "byteorder", - "rmp", - "serde", -] - -[[package]] -name = "rust_decimal" -version = "1.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4c4216490d5a413bc6d10fa4742bd7d4955941d062c0ef873141d6b0e7b30fd" -dependencies = [ - "arrayvec", - "borsh 0.10.3", - "bytes", - "num-traits", - "rand 0.8.5", - "rkyv", - "serde", - "serde_json", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" - -[[package]] -name = "rustc-hash" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.38.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a74ee2d7c2581cd139b42447d7d9389b889bdaad3a73f1ebb16f2a3237bb19c" -dependencies = [ - "bitflags 2.4.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys", -] - -[[package]] -name = "rustls" -version = "0.20.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b80e3dec595989ea8510028f30c408a4630db12c9cbb8de34203b89d6577e99" -dependencies = [ - "log", - "ring 0.16.20", - "sct", - "webpki", -] - -[[package]] -name = "rustls" -version = "0.21.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd8d6c9f025a446bc4d18ad9632e69aec8f287aa84499ee335599fabd20c3fd8" -dependencies = [ - "log", - "ring 0.16.20", - "rustls-webpki", - "sct", -] - -[[package]] -name = "rustls-pemfile" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" -dependencies = [ - "base64 0.21.4", -] - -[[package]] -name = "rustls-webpki" -version = "0.101.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c7d5dece342910d9ba34d259310cae3e0154b873b35408b787b59bce53d34fe" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - -[[package]] -name = "rustversion" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" - -[[package]] -name = "ryu" -version = "1.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" - -[[package]] -name = "schannel" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c3733bf4cf7ea0880754e19cb5a462007c4a8c1914bff372ccc95b464f1df88" -dependencies = [ - "windows-sys", -] - -[[package]] -name = "schemars" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f7b0ce13155372a76ee2e1c5ffba1fe61ede73fbea5630d61eee6fac4929c0c" -dependencies = [ - "dyn-clone", - "schemars_derive", - "serde", - "serde_json", -] - -[[package]] -name = "schemars_derive" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e85e2a16b12bdb763244c69ab79363d71db2b4b918a2def53f80b02e0574b13c" -dependencies = [ - "proc-macro2", - "quote", - "serde_derive_internals", - "syn 1.0.109", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "scroll" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04c565b551bafbef4157586fa379538366e4385d42082f255bfd96e4fe8519da" -dependencies = [ - "scroll_derive", -] - -[[package]] -name = "scroll_derive" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1db149f81d46d2deba7cd3c50772474707729550221e69588478ebf9ada425ae" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "sct" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - -[[package]] -name = "sea-orm" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88694d01b528a94f90ad87f8d2f546d060d070eee180315c67d158cb69476034" -dependencies = [ - "async-stream", - "async-trait", - "chrono", - "futures", - "futures-util", - "log", - "ouroboros", - "rust_decimal", - "sea-orm-macros", - "sea-query 0.27.2", - "sea-query-binder", - "sea-strum", - "serde", - "serde_json", - "sqlx", - "thiserror", - "time", - "tracing", - "url", - "uuid", -] - -[[package]] -name = "sea-orm-macros" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7216195de9c6b2474fd0efab486173dccd0eff21f28cc54aa4c0205d52fb3af0" -dependencies = [ - "bae", - "heck 0.3.3", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "sea-query" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4f0fc4d8e44e1d51c739a68d336252a18bc59553778075d5e32649be6ec92ed" -dependencies = [ - "chrono", - "rust_decimal", - "sea-query-derive 0.2.0", - "serde_json", - "time", - "uuid", -] - -[[package]] -name = "sea-query" -version = "0.28.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbab99b8cd878ab7786157b7eb8df96333a6807cc6e45e8888c85b51534b401a" -dependencies = [ - "sea-query-derive 0.3.0", -] - -[[package]] -name = "sea-query-binder" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c2585b89c985cfacfe0ec9fc9e7bb055b776c1a2581c4e3c6185af2b8bf8865" -dependencies = [ - "chrono", - "rust_decimal", - "sea-query 0.27.2", - "serde_json", - "sqlx", - "time", - "uuid", -] - -[[package]] -name = "sea-query-derive" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34cdc022b4f606353fe5dc85b09713a04e433323b70163e81513b141c6ae6eb5" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "syn 1.0.109", - "thiserror", -] - -[[package]] -name = "sea-query-derive" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63f62030c60f3a691f5fe251713b4e220b306e50a71e1d6f9cce1f24bb781978" -dependencies = [ - "heck 0.4.1", - "proc-macro2", - "quote", - "syn 1.0.109", - "thiserror", -] - -[[package]] -name = "sea-strum" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "391d06a6007842cfe79ac6f7f53911b76dfd69fc9a6769f1cf6569d12ce20e1b" -dependencies = [ - "sea-strum_macros", -] - -[[package]] -name = "sea-strum_macros" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69b4397b825df6ccf1e98bcdabef3bbcfc47ff5853983467850eeab878384f21" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "rustversion", - "syn 1.0.109", -] - -[[package]] -name = "seahash" -version = "4.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c107b6f4780854c8b126e228ea8869f4d7b71260f962fefb57b996b8959ba6b" - -[[package]] -name = "security-framework" -version = "2.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05b64fb303737d99b81884b2c63433e9ae28abebe5eb5045dcdd175dc2ecf4de" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e932934257d3b408ed8f30db49d85ea163bfe74961f017f405b025af298f0c7a" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad977052201c6de01a8ef2aa3378c4bd23217a056337d1d6da40468d267a4fb0" - -[[package]] -name = "serde" -version = "1.0.188" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf9e0fcba69a370eed61bcf2b728575f726b50b55cba78064753d708ddc7549e" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_bytes" -version = "0.11.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab33ec92f677585af6d88c65593ae2375adde54efdbf16d597f2cbc7a6d368ff" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_derive" -version = "1.0.188" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4eca7ac642d82aa35b60049a6eccb4be6be75e599bd2e9adb5f875a737654af2" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "serde_derive_internals" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85bf8229e7920a9f636479437026331ce11aa132b4dde37d121944a44d6e5f3c" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "serde_json" -version = "1.0.107" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b420ce6e3d8bd882e9b243c6eed35dbc9a6110c9769e74b584e0d68d1f20c65" -dependencies = [ - "indexmap 2.0.2", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros 1.5.2", -] - -[[package]] -name = "serde_with" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07ff71d2c147a7b57362cead5e22f772cd52f6ab31cfcd9edcd7f6aeb2a0afbe" -dependencies = [ - "serde", - "serde_with_macros 2.3.3", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling 0.13.4", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "serde_with_macros" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "881b6f881b17d13214e5d494c939ebab463d01264ce1811e9d4ac3a882e7695f" -dependencies = [ - "darling 0.20.3", - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "sha-1" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99cd6713db3cf16b6c84e06321e049a9b9f699826e16096d23bbcc44d15d51a6" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha1" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f81199417d4e5de3f04b1e871023acea7389672c4135918f05aa9cbf2f2fa809" -dependencies = [ - "block-buffer 0.9.0", - "digest 0.9.0", - "keccak", - "opaque-debug", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "shank" -version = "0.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b63e565b5e95ad88ab38f312e89444c749360641c509ef2de0093b49f55974a5" -dependencies = [ - "shank_macro", -] - -[[package]] -name = "shank_macro" -version = "0.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63927d22a1e8b74bda98cc6e151fcdf178b7abb0dc6c4f81e0bbf5ffe2fc4ec8" -dependencies = [ - "proc-macro2", - "quote", - "shank_macro_impl", - "syn 1.0.109", -] - -[[package]] -name = "shank_macro_impl" -version = "0.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ce03403df682f80f4dc1efafa87a4d0cb89b03726d0565e6364bdca5b9a441" -dependencies = [ - "anyhow", - "proc-macro2", - "quote", - "serde", - "syn 1.0.109", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simdutf8" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f27f6278552951f1f2b8cf9da965d10969b2efdea95a6ec47987ab46edfe263a" - -[[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" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16d69225bde7a69b235da73377861095455d298f2b970996eec25ddbb42b3d1e" -dependencies = [ - "bitmaps", - "typenum", -] - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" - -[[package]] -name = "socket2" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "socket2" -version = "0.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4031e820eb552adee9295814c0ced9e5cf38ddf1e8b7d566d6de8e2538ea989e" -dependencies = [ - "libc", - "windows-sys", -] - -[[package]] -name = "soketto" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "41d1c5305e39e09653383c2c7244f2f78b3bcae37cf50c64cb4789c9f5096ec2" -dependencies = [ - "base64 0.13.1", - "bytes", - "futures", - "http", - "httparse", - "log", - "rand 0.8.5", - "sha-1", -] - -[[package]] -name = "solana-account-decoder" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f52aec62a85932e26d1085864b0f7b99b31934aec8dd132429bfef6d7fb1d3a6" -dependencies = [ - "Inflector", - "base64 0.21.4", - "bincode", - "bs58 0.4.0", - "bv", - "lazy_static", - "serde", - "serde_derive", - "serde_json", - "solana-address-lookup-table-program", - "solana-config-program", - "solana-sdk", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", - "spl-token-metadata-interface", - "thiserror", - "zstd", -] - -[[package]] -name = "solana-address-lookup-table-program" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee0bd25f4ba0a15fc16c57b41b1e1b14f5271b83214fda158fdedb58758d394e" -dependencies = [ - "bincode", - "bytemuck", - "log", - "num-derive 0.3.3", - "num-traits", - "rustc_version", - "serde", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-program", - "solana-program-runtime", - "solana-sdk", - "thiserror", -] - -[[package]] -name = "solana-config-program" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fd0fc1efb91a1661aeb1ff6a691156c3b1bffdaed0aa096589499dd83f9e50b" -dependencies = [ - "bincode", - "chrono", - "serde", - "serde_derive", - "solana-program-runtime", - "solana-sdk", -] - -[[package]] -name = "solana-frozen-abi" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02eb4f0ed3eade20f4abdcc0031167344237cd6e16808bd0f33945f9db7861fe" -dependencies = [ - "ahash 0.8.3", - "blake3", - "block-buffer 0.10.4", - "bs58 0.4.0", - "bv", - "byteorder", - "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", - "serde_derive", - "serde_json", - "sha2 0.10.8", - "solana-frozen-abi-macro", - "subtle", - "thiserror", -] - -[[package]] -name = "solana-frozen-abi-macro" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f28514761a285944cbad5b3d7930546369b80a713ba37d84bcf6ed2753611765" -dependencies = [ - "proc-macro2", - "quote", - "rustc_version", - "syn 2.0.38", -] - -[[package]] -name = "solana-gateway" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d148eb75d0799f6825dc2a840b85c065e3d6d12212845add3e059163f98770e" -dependencies = [ - "borsh 0.10.3", - "num-derive 0.4.1", - "num-traits", - "solana-program", - "thiserror", -] - -[[package]] -name = "solana-logger" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c310c6749435ce1ea25a9ae3edfb2fd2c2aed2aa4d4f7e0487a8077a0b1ee30" -dependencies = [ - "env_logger 0.9.3", - "lazy_static", - "log", -] - -[[package]] -name = "solana-measure" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d171357580e62aa4ca19c780e25f4e74de064e2780cb8b9f6b6901d986fcd23" -dependencies = [ - "log", - "solana-sdk", -] - -[[package]] -name = "solana-metrics" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "013cbb3c82588278d2be18d3317ece5286cb54a3a06d5d38fc31e2a76a6d5e2d" -dependencies = [ - "crossbeam-channel", - "gethostname", - "lazy_static", - "log", - "reqwest", - "solana-sdk", -] - -[[package]] -name = "solana-program" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cff2aa5434a77413e9d43e971ceb47bdb003f2e8bbc0365a25b684aca2605c25" -dependencies = [ - "ark-bn254", - "ark-ec", - "ark-ff", - "ark-serialize", - "array-bytes", - "base64 0.21.4", - "bincode", - "bitflags 1.3.2", - "blake3", - "borsh 0.10.3", - "borsh 0.9.3", - "bs58 0.4.0", - "bv", - "bytemuck", - "cc", - "console_error_panic_hook", - "console_log", - "curve25519-dalek", - "getrandom 0.2.10", - "itertools 0.10.5", - "js-sys", - "lazy_static", - "libc", - "libsecp256k1", - "log", - "memoffset", - "num-bigint 0.4.4", - "num-derive 0.3.3", - "num-traits", - "parking_lot 0.12.1", - "rand 0.7.3", - "rand_chacha 0.2.2", - "rustc_version", - "rustversion", - "serde", - "serde_bytes", - "serde_derive", - "serde_json", - "sha2 0.10.8", - "sha3 0.10.8", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-sdk-macro", - "thiserror", - "tiny-bip39", - "wasm-bindgen", - "zeroize", -] - -[[package]] -name = "solana-program-runtime" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d1832fefc2187142dac169812518ec20da68b09abad86e4a78f8ae1787e4f56" -dependencies = [ - "base64 0.21.4", - "bincode", - "eager", - "enum-iterator", - "itertools 0.10.5", - "libc", - "log", - "num-derive 0.3.3", - "num-traits", - "percentage", - "rand 0.7.3", - "rustc_version", - "serde", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-measure", - "solana-metrics", - "solana-sdk", - "solana_rbpf", - "thiserror", -] - -[[package]] -name = "solana-sdk" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b1002048941cedbd7dd6a96fdaa3dc5238b998aaa70b81946b1e3ec108cc2be" -dependencies = [ - "assert_matches", - "base64 0.21.4", - "bincode", - "bitflags 1.3.2", - "borsh 0.10.3", - "bs58 0.4.0", - "bytemuck", - "byteorder", - "chrono", - "derivation-path", - "digest 0.10.7", - "ed25519-dalek", - "ed25519-dalek-bip32", - "generic-array", - "hmac 0.12.1", - "itertools 0.10.5", - "js-sys", - "lazy_static", - "libsecp256k1", - "log", - "memmap2", - "num-derive 0.3.3", - "num-traits", - "num_enum 0.6.1", - "pbkdf2 0.11.0", - "qstring", - "rand 0.7.3", - "rand_chacha 0.2.2", - "rustc_version", - "rustversion", - "serde", - "serde_bytes", - "serde_derive", - "serde_json", - "serde_with 2.3.3", - "sha2 0.10.8", - "sha3 0.10.8", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-logger", - "solana-program", - "solana-sdk-macro", - "thiserror", - "uriparse", - "wasm-bindgen", -] - -[[package]] -name = "solana-sdk-macro" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b41b63b2da4a37ce323aba108db21f4c7bfa638dd1bf58fdc870f83bdce48ba" -dependencies = [ - "bs58 0.4.0", - "proc-macro2", - "quote", - "rustversion", - "syn 2.0.38", -] - -[[package]] -name = "solana-transaction-status" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db0b811793e78a908119cc02edca3ff8b54d5660104ebd06cc0e2e7e2f66900b" -dependencies = [ - "Inflector", - "base64 0.21.4", - "bincode", - "borsh 0.10.3", - "bs58 0.4.0", - "lazy_static", - "log", - "serde", - "serde_derive", - "serde_json", - "solana-account-decoder", - "solana-address-lookup-table-program", - "solana-sdk", - "spl-associated-token-account", - "spl-memo 4.0.0", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", - "thiserror", -] - -[[package]] -name = "solana-zk-token-sdk" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d1fe77918563768a65fd5d6cd2fa06cf0aeb11e529a1ef8c230b0fe018600e3" -dependencies = [ - "aes-gcm-siv", - "base64 0.21.4", - "bincode", - "bytemuck", - "byteorder", - "curve25519-dalek", - "getrandom 0.1.16", - "itertools 0.10.5", - "lazy_static", - "merlin", - "num-derive 0.3.3", - "num-traits", - "rand 0.7.3", - "serde", - "serde_json", - "sha3 0.9.1", - "solana-program", - "solana-sdk", - "subtle", - "thiserror", - "zeroize", -] - -[[package]] -name = "solana_rbpf" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17d4ba1e58947346e360fabde0697029d36ba83c42f669199b16a8931313cf29" -dependencies = [ - "byteorder", - "combine", - "goblin", - "hash32", - "libc", - "log", - "rand 0.8.5", - "rustc-demangle", - "scroll", - "thiserror", - "winapi", -] - -[[package]] -name = "spin" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "spl-account-compression" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df052fd79e45c75c84ef20f5f2dcf037aeed230d0f2400bf68fa388cc0ece240" -dependencies = [ - "anchor-lang", - "bytemuck", - "spl-concurrent-merkle-tree", - "spl-noop", -] - -[[package]] -name = "spl-associated-token-account" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "385e31c29981488f2820b2022d8e731aae3b02e6e18e2fd854e4c9a94dc44fc3" -dependencies = [ - "assert_matches", - "borsh 0.10.3", - "num-derive 0.4.1", - "num-traits", - "solana-program", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", - "thiserror", -] - -[[package]] -name = "spl-concurrent-merkle-tree" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "141eaea58588beae81b71d101373a53f096737739873de42d6b1368bc2b8fc30" -dependencies = [ - "bytemuck", - "solana-program", - "thiserror", -] - -[[package]] -name = "spl-discriminator" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cce5d563b58ef1bb2cdbbfe0dfb9ffdc24903b10ae6a4df2d8f425ece375033f" -dependencies = [ - "bytemuck", - "solana-program", - "spl-discriminator-derive", -] - -[[package]] -name = "spl-discriminator-derive" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fadbefec4f3c678215ca72bd71862697bb06b41fd77c0088902dd3203354387b" -dependencies = [ - "quote", - "spl-discriminator-syn", - "syn 2.0.38", -] - -[[package]] -name = "spl-discriminator-syn" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e5f2044ca42c8938d54d1255ce599c79a1ffd86b677dfab695caa20f9ffc3f2" -dependencies = [ - "proc-macro2", - "quote", - "sha2 0.10.8", - "syn 2.0.38", - "thiserror", -] - -[[package]] -name = "spl-memo" -version = "3.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0dc6f70db6bacea7ff25870b016a65ba1d1b6013536f08e4fd79a8f9005325" -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-noop" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6dd67ea3d0070a12ff141f5da46f9695f49384a03bce1203a5608f5739437950" -dependencies = [ - "solana-program", -] - -[[package]] -name = "spl-pod" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2881dddfca792737c0706fa0175345ab282b1b0879c7d877bad129645737c079" -dependencies = [ - "borsh 0.10.3", - "bytemuck", - "solana-program", - "solana-zk-token-sdk", - "spl-program-error", -] - -[[package]] -name = "spl-program-error" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "249e0318493b6bcf27ae9902600566c689b7dfba9f1bdff5893e92253374e78c" -dependencies = [ - "num-derive 0.4.1", - "num-traits", - "solana-program", - "spl-program-error-derive", - "thiserror", -] - -[[package]] -name = "spl-program-error-derive" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab5269c8e868da17b6552ef35a51355a017bd8e0eae269c201fef830d35fa52c" -dependencies = [ - "proc-macro2", - "quote", - "sha2 0.10.8", - "syn 2.0.38", -] - -[[package]] -name = "spl-tlv-account-resolution" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "062e148d3eab7b165582757453632ffeef490c02c86a48bfdb4988f63eefb3b9" -dependencies = [ - "bytemuck", - "solana-program", - "spl-discriminator", - "spl-pod", - "spl-program-error", - "spl-type-length-value", -] - -[[package]] -name = "spl-token" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e85e168a785e82564160dcb87b2a8e04cee9bfd1f4d488c729d53d6a4bd300d" -dependencies = [ - "arrayref", - "bytemuck", - "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" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0043b590232c400bad5ee9eb983ced003d15163c4c5d56b090ac6d9a57457b47" -dependencies = [ - "arrayref", - "bytemuck", - "num-derive 0.3.3", - "num-traits", - "num_enum 0.5.11", - "solana-program", - "solana-zk-token-sdk", - "spl-memo 3.0.1", - "spl-token 3.5.0", - "thiserror", -] - -[[package]] -name = "spl-token-2022" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4abf34a65ba420584a0c35f3903f8d727d1f13ababbdc3f714c6b065a686e86" -dependencies = [ - "arrayref", - "bytemuck", - "num-derive 0.4.1", - "num-traits", - "num_enum 0.7.0", - "solana-program", - "solana-zk-token-sdk", - "spl-memo 4.0.0", - "spl-pod", - "spl-token 4.0.0", - "spl-token-metadata-interface", - "spl-transfer-hook-interface", - "spl-type-length-value", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "051d31803f873cabe71aec3c1b849f35248beae5d19a347d93a5c9cccc5d5a9b" -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.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a468e6f6371f9c69aae760186ea9f1a01c2908351b06a5e0026d21cfc4d7ecac" -dependencies = [ - "bytemuck", - "solana-program", - "spl-discriminator", - "spl-pod", - "spl-program-error", -] - -[[package]] -name = "sqlformat" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b7b278788e7be4d0d29c0f39497a0eef3fba6bbc8e70d8bf7fde46edeaa9e85" -dependencies = [ - "itertools 0.11.0", - "nom", - "unicode_categories", -] - -[[package]] -name = "sqlx" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8de3b03a925878ed54a954f621e64bf55a3c1bd29652d0d1a17830405350188" -dependencies = [ - "sqlx-core", - "sqlx-macros", -] - -[[package]] -name = "sqlx-core" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa8241483a83a3f33aa5fff7e7d9def398ff9990b2752b6c6112b83c6d246029" -dependencies = [ - "ahash 0.7.6", - "atoi", - "base64 0.13.1", - "bitflags 1.3.2", - "byteorder", - "bytes", - "chrono", - "crc", - "crossbeam-queue", - "dirs", - "dotenvy", - "either", - "event-listener", - "futures-channel", - "futures-core", - "futures-intrusive", - "futures-util", - "hashlink", - "hex", - "hkdf", - "hmac 0.12.1", - "indexmap 1.9.3", - "itoa", - "libc", - "log", - "md-5", - "memchr", - "num-bigint 0.4.4", - "once_cell", - "paste", - "percent-encoding", - "rand 0.8.5", - "rust_decimal", - "rustls 0.20.9", - "rustls-pemfile", - "serde", - "serde_json", - "sha1", - "sha2 0.10.8", - "smallvec", - "sqlformat", - "sqlx-rt", - "stringprep", - "thiserror", - "time", - "tokio-stream", - "url", - "uuid", - "webpki-roots 0.22.6", - "whoami", -] - -[[package]] -name = "sqlx-macros" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9966e64ae989e7e575b19d7265cb79d7fc3cbbdf179835cb0d716f294c2049c9" -dependencies = [ - "dotenvy", - "either", - "heck 0.4.1", - "hex", - "once_cell", - "proc-macro2", - "quote", - "serde", - "serde_json", - "sha2 0.10.8", - "sqlx-core", - "sqlx-rt", - "syn 1.0.109", - "url", -] - -[[package]] -name = "sqlx-rt" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "804d3f245f894e61b1e6263c84b23ca675d96753b5abfd5cc8597d86806e8024" -dependencies = [ - "once_cell", - "tokio", - "tokio-rustls 0.23.4", -] - -[[package]] -name = "stringprep" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb41d74e231a107a1b4ee36bd1214b11285b77768d2e3824aedafa988fd36ee6" -dependencies = [ - "finl_unicode", - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "subtle" -version = "2.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e96b79aaa137db8f61e26363a0c9b47d8b4ec75da28b7d1d614c2303e232408b" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tap" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" - -[[package]] -name = "tempfile" -version = "3.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb94d2f3cc536af71caac6b6fcebf65860b347e7ce0cc9ebe8f70d3e521054ef" -dependencies = [ - "cfg-if", - "fastrand", - "redox_syscall 0.3.5", - "rustix", - "windows-sys", -] - -[[package]] -name = "termcolor" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6093bad37da69aab9d123a8091e4be0aa4a03e4d601ec641c327398315f62b64" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "thiserror" -version = "1.0.49" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1177e8c6d7ede7afde3585fd2513e611227efd6481bd78d2e82ba1ce16557ed4" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.49" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10712f02019e9288794769fba95cd6847df9874d49d871d062172f9dd41bc4cc" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "time" -version = "0.3.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "426f806f4089c493dcac0d24c29c01e2c38baf8e30f1b716ee37e83d200b18fe" -dependencies = [ - "deranged", - "itoa", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" - -[[package]] -name = "time-macros" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" -dependencies = [ - "time-core", -] - -[[package]] -name = "tiny-bip39" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffc59cb9dfc85bb312c3a78fd6aa8a8582e310b0fa885d5bb877f6dcc601839d" -dependencies = [ - "anyhow", - "hmac 0.8.1", - "once_cell", - "pbkdf2 0.4.0", - "rand 0.7.3", - "rustc-hash", - "sha2 0.9.9", - "thiserror", - "unicode-normalization", - "wasm-bindgen", - "zeroize", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.33.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot 0.12.1", - "pin-project-lite", - "signal-hook-registry", - "socket2 0.5.4", - "tokio-macros", - "windows-sys", -] - -[[package]] -name = "tokio-macros" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-postgres" -version = "0.7.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d340244b32d920260ae7448cb72b6e238bddc3d4f7603394e7dd46ed8e48f5b8" -dependencies = [ - "async-trait", - "byteorder", - "bytes", - "fallible-iterator", - "futures-channel", - "futures-util", - "log", - "parking_lot 0.12.1", - "percent-encoding", - "phf", - "pin-project-lite", - "postgres-protocol", - "postgres-types", - "rand 0.8.5", - "socket2 0.5.4", - "tokio", - "tokio-util", - "whoami", -] - -[[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", - "tokio", -] - -[[package]] -name = "tokio-stream" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" -dependencies = [ - "futures-core", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d68074620f57a0b21594d9735eb2e98ab38b17f80d3fcb189fca266771ca60d" -dependencies = [ - "bytes", - "futures-core", - "futures-io", - "futures-sink", - "pin-project-lite", - "tokio", - "tracing", -] - -[[package]] -name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_datetime" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" - -[[package]] -name = "toml_edit" -version = "0.19.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" -dependencies = [ - "indexmap 2.0.2", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower" -version = "0.4.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8fa9be0de6cf49e536ce1851f987bd21a43b771b09473c3549a6c853db37c1c" -dependencies = [ - "futures-core", - "futures-util", - "hdrhistogram", - "indexmap 1.9.3", - "pin-project", - "pin-project-lite", - "rand 0.8.5", - "slab", - "tokio", - "tokio-util", - "tower-layer", - "tower-service", - "tracing", -] - -[[package]] -name = "tower-http" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f873044bf02dd1e8239e9c1293ea39dad76dc594ec16185d0a1bf31d8dc8d858" -dependencies = [ - "async-compression 0.3.15", - "base64 0.13.1", - "bitflags 1.3.2", - "bytes", - "futures-core", - "futures-util", - "http", - "http-body", - "http-range-header", - "httpdate", - "iri-string", - "mime", - "mime_guess", - "percent-encoding", - "pin-project-lite", - "tokio", - "tokio-util", - "tower", - "tower-layer", - "tower-service", - "tracing", - "uuid", -] - -[[package]] -name = "tower-layer" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c20c8dbed6283a09604c3e69b4b7eeb54e298b8a600d4d5ecb5ad39de609f1d0" - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "log", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "tracing-core" -version = "0.1.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0955b8137a1df6f1a2e9a37d8a6656291ff0297c1a97c24e0d8425fe2312f79a" -dependencies = [ - "once_cell", -] - -[[package]] -name = "try-lock" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "uncased" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b9bc53168a4be7402ab86c3aad243a84dd7381d09be0eddc81280c1da95ca68" -dependencies = [ - "version_check", -] - -[[package]] -name = "unicase" -version = "2.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7d2d4dafb69621809a81864c9c1b864479e1235c0dd4e199924b9742439ed89" -dependencies = [ - "version_check", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "unicode_categories" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e" - -[[package]] -name = "universal-hash" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f214e8f697e925001e66ec2c6e37a4ef93f0f78c2eed7814394e10c62025b05" -dependencies = [ - "generic-array", - "subtle", -] - -[[package]] -name = "unreachable" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "382810877fe448991dfc7f0dd6e3ae5d58088fd0ea5e35189655f84e6814fa56" -dependencies = [ - "void", -] - -[[package]] -name = "untrusted" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "uriparse" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0200d0fc04d809396c2ad43f3c95da3582a2556eba8d453c1087f4120ee352ff" -dependencies = [ - "fnv", - "lazy_static", -] - -[[package]] -name = "url" -version = "2.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "143b538f18257fac9cad154828a57c6bf5157e1aa604d4816b5995bf6de87ae5" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "uuid" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79daa5ed5740825c40b389c5e50312b9c86df53fccd33f281df655642b43869d" -dependencies = [ - "getrandom 0.2.10", - "serde", -] - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "void" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn 2.0.38", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" - -[[package]] -name = "web-sys" -version = "0.3.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webpki" -version = "0.22.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed63aea5ce73d0ff405984102c42de94fc55a6b75765d621c65262469b3c9b53" -dependencies = [ - "ring 0.17.2", - "untrusted 0.9.0", -] - -[[package]] -name = "webpki-roots" -version = "0.22.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c71e40d7d2c34a5106301fb632274ca37242cd0c9d3e64dbece371a40a2d87" -dependencies = [ - "webpki", -] - -[[package]] -name = "webpki-roots" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14247bb57be4f377dfb94c72830b8ce8fc6beac03cf4bf7b9732eadd414123fc" - -[[package]] -name = "whoami" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22fc3756b8a9133049b26c7f61ab35416c130e8c09b660f5b3958b446f52cc50" -dependencies = [ - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "winapi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" -dependencies = [ - "winapi-i686-pc-windows-gnu", - "winapi-x86_64-pc-windows-gnu", -] - -[[package]] -name = "winapi-i686-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" - -[[package]] -name = "winapi-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f29e6f9198ba0d26b4c9f07dbe6f9ed633e1f3d5b8b414090084349e46a52596" -dependencies = [ - "winapi", -] - -[[package]] -name = "winapi-x86_64-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" - -[[package]] -name = "windows" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e686886bc078bc1b0b600cac0147aadb815089b6e4da64016cbd754b6342700f" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc", - "windows_i686_gnu", - "windows_i686_msvc", - "windows_x86_64_gnu", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "winnow" -version = "0.5.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "037711d82167854aff2018dfd193aa0fef5370f456732f0d5a0c59b0f1b4b907" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.50.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" -dependencies = [ - "cfg-if", - "windows-sys", -] - -[[package]] -name = "wyz" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" -dependencies = [ - "tap", -] - -[[package]] -name = "yansi" -version = "1.0.0-rc.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1367295b8f788d371ce2dbc842c7b709c73ee1364d30351dd300ec2203b12377" - -[[package]] -name = "zeroize" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4756f7db3f7b5574938c3eb1c117038b8e07f95ee6718c0efad4ac21508f1efd" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "zstd" -version = "0.11.2+zstd.1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20cc960326ece64f010d2d2107537f26dc589a6573a316bd5b1dba685fa5fde4" -dependencies = [ - "zstd-safe", -] - -[[package]] -name = "zstd-safe" -version = "5.0.2+zstd.1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d2a5585e04f9eea4b2a3d1eca508c4dee9592a89ef6f450c11719da0726f4db" -dependencies = [ - "libc", - "zstd-sys", -] - -[[package]] -name = "zstd-sys" -version = "2.0.8+zstd.1.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5556e6ee25d32df2586c098bbfa278803692a20d0ab9565e049480d52707ec8c" -dependencies = [ - "cc", - "libc", - "pkg-config", -] diff --git a/das_api/Cargo.toml b/das_api/Cargo.toml index c99d8b21a..c56afe88f 100644 --- a/das_api/Cargo.toml +++ b/das_api/Cargo.toml @@ -1,41 +1,44 @@ [package] name = "das_api" -version = "0.7.2" -edition = "2021" - -# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html +version = { workspace = true } +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -digital_asset_types = { path = "../digital_asset_types", features = ["json_types", "sql_types"] } -jsonrpsee = {version = "0.16.2", features = ["server", "macros"]} -jsonrpsee-core = {version = "0.16.2", features =["server"]} -tower-http={version = "0.3.5", features = ["full"]} -tower={version="0.4.13", features = ["full"]} -hyper = "0.14.23" -tracing = "0.1.35" -metrics = "0.20.1" -figment = { version = "0.10.6", features = ["env"] } -serde = "1.0.137" -thiserror = "1.0.31" -tokio = {version="1.23.0"} -async-trait = "0.1.56" -serde_json = "1.0.81" -cadence = "0.29.0" -cadence-macros = "0.29.0" -sqlx = { version = "0.6.2", features = ["macros", "runtime-tokio-rustls", "postgres", "uuid", "offline", "json"] } -sea-orm = { version = "0.10.6", features = ["macros", "runtime-tokio-rustls", "sqlx-postgres"] } -tokio-postgres = "0.7.7" -solana-sdk = "~1.16.16" -bs58 = "0.4.0" -log = "0.4.17" -env_logger = "0.10" -schemars = "0.8.6" -schemars_derive = "0.8.6" -open-rpc-derive = { version = "0.0.4"} -open-rpc-schema = { version = "0.0.4"} -blockbuster = "0.9.0-beta.1" -anchor-lang = "0.28.0" -mpl-token-metadata = { version = "=2.0.0-beta.1", features = ["serde-feature"] } -mpl-candy-machine-core = { version = "2.0.1", features = ["no-entrypoint"] } -mpl-bubblegum = "1.0.1-beta.3" -mpl-candy-guard = { version = "2.0.0", features = ["no-entrypoint"] } +anchor-lang = { workspace = true } +async-trait = { workspace = true } +blockbuster = { workspace = true } +bs58 = { workspace = true } +cadence = { workspace = true } +cadence-macros = { workspace = true } +digital_asset_types = { workspace = true, features = ["json_types", "sql_types"] } +env_logger = { workspace = true } +figment = { workspace = true, features = ["env"] } +hyper = { workspace = true } +jsonrpsee = { workspace = true, features = ["server", "macros"]} +jsonrpsee-core = { workspace = true, features =["server"]} +log = { workspace = true } +metrics = { workspace = true } +mpl-bubblegum = { workspace = true } +mpl-candy-guard = { workspace = true, features = ["no-entrypoint"] } +mpl-candy-machine-core = { workspace = true, features = ["no-entrypoint"] } +mpl-token-metadata = { workspace = true, features = ["serde-feature"] } +open-rpc-derive = { workspace = true } +open-rpc-schema = { workspace = true } +schemars = { workspace = true } +schemars_derive = { workspace = true } +sea-orm = { workspace = true, features = ["macros", "runtime-tokio-rustls", "sqlx-postgres"] } +serde = { workspace = true } +serde_json = { workspace = true } +solana-sdk = { workspace = true } +sqlx = { workspace = true, features = ["macros", "runtime-tokio-rustls", "postgres", "uuid", "offline", "json"] } +thiserror = { workspace = true } +tokio = { workspace = true, features = ["signal"] } +tokio-postgres = { workspace = true } +tower = { workspace = true } +tower-http = { workspace = true, features = ["cors"] } +tracing = { workspace = true } + +[lints] +workspace = true diff --git a/das_api/src/api/api_impl.rs b/das_api/src/api/api_impl.rs index 8678c8421..7456c5ec2 100644 --- a/das_api/src/api/api_impl.rs +++ b/das_api/src/api/api_impl.rs @@ -7,16 +7,15 @@ use digital_asset_types::{ Cursor, PageOptions, SearchAssetsQuery, }, dapi::{ - get_asset, get_asset_batch, get_asset_proof_batch, get_assets_by_authority, + get_asset, get_asset_proofs, get_asset_signatures, get_assets, get_assets_by_authority, get_assets_by_creator, get_assets_by_group, get_assets_by_owner, get_proof_for_asset, - search_assets, get_signatures_for_asset + search_assets, }, rpc::{ filter::{AssetSortBy, SearchConditionType}, response::GetGroupingResponse, - OwnershipModel, RoyaltyModel }, - rpc::{}, + rpc::{OwnershipModel, RoyaltyModel}, }; use open_rpc_derive::document_rpc; use sea_orm::{sea_query::ConditionType, ConnectionTrait, DbBackend, Statement}; @@ -33,7 +32,6 @@ use { sea_orm::{DatabaseConnection, DbErr, SqlxPostgresConnector}, sqlx::postgres::PgPoolOptions, }; - use digital_asset_types::rpc::response::TransactionSignatureList; pub struct DasApi { db_connection: DatabaseConnection, @@ -69,25 +67,25 @@ impl DasApi { fn validate_pagination( &self, - limit: &Option, - page: &Option, + limit: Option, + page: Option, before: &Option, after: &Option, cursor: &Option, - sorting: &Option<&AssetSorting>, + sorting: Option, ) -> Result { let mut is_cursor_enabled = true; let mut page_opt = PageOptions::default(); if let Some(limit) = limit { // make config item - if *limit > 1000 { + if limit > 1000 { return Err(DasApiError::PaginationExceededError); } } if let Some(page) = page { - if *page == 0 { + if page == 0 { return Err(DasApiError::PaginationEmptyError); } @@ -131,7 +129,7 @@ impl DasApi { if sort.sort_by != AssetSortBy::Id { return Err(DasApiError::PaginationSortingValidationError); } - page_opt.cursor = Some(self.get_cursor(&cursor)?); + page_opt.cursor = Some(self.get_cursor(cursor)?); } } else { page_opt.page = page.map(|x| x as u64); @@ -180,11 +178,11 @@ impl ApiContract for DasApi { .map_err(Into::into) } - async fn get_asset_proof_batch( + async fn get_asset_proofs( self: &DasApi, - payload: GetAssetProofBatch, + payload: GetAssetProofs, ) -> Result>, DasApiError> { - let GetAssetProofBatch { ids } = payload; + let GetAssetProofs { ids } = payload; let batch_size = ids.len(); if batch_size > 1000 { @@ -196,7 +194,7 @@ impl ApiContract for DasApi { .map(|id| validate_pubkey(id.clone()).map(|id| id.to_bytes().to_vec())) .collect::>, _>>()?; - let proofs = get_asset_proof_batch(&self.db_connection, id_bytes).await?; + let proofs = get_asset_proofs(&self.db_connection, id_bytes).await?; let result: HashMap> = ids .iter() @@ -206,25 +204,19 @@ impl ApiContract for DasApi { } async fn get_asset(self: &DasApi, payload: GetAsset) -> Result { - let GetAsset { - id, - display_options, - } = payload; + let GetAsset { id, options } = payload; let id_bytes = validate_pubkey(id.clone())?.to_bytes().to_vec(); - let display_options = display_options.unwrap_or_default(); - get_asset(&self.db_connection, id_bytes, &display_options.into()) + let options = options.unwrap_or_default(); + get_asset(&self.db_connection, id_bytes, &options) .await .map_err(Into::into) } - async fn get_asset_batch( + async fn get_assets( self: &DasApi, - payload: GetAssetBatch, + payload: GetAssets, ) -> Result>, DasApiError> { - let GetAssetBatch { - ids, - display_options, - } = payload; + let GetAssets { ids, options } = payload; let batch_size = ids.len(); if batch_size > 1000 { @@ -236,15 +228,9 @@ impl ApiContract for DasApi { .map(|id| validate_pubkey(id.clone()).map(|id| id.to_bytes().to_vec())) .collect::>, _>>()?; - let display_options = display_options.unwrap_or_default(); + let options = options.unwrap_or_default(); - let assets = get_asset_batch( - &self.db_connection, - id_bytes, - batch_size as u64, - &display_options.into(), - ) - .await?; + let assets = get_assets(&self.db_connection, id_bytes, batch_size as u64, &options).await?; let result: Vec> = ids.iter().map(|id| assets.get(id).cloned()).collect(); Ok(result) @@ -261,7 +247,7 @@ impl ApiContract for DasApi { page, before, after, - display_options, + options, cursor, } = payload; let before: Option = before.filter(|before| !before.is_empty()); @@ -269,15 +255,15 @@ impl ApiContract for DasApi { let owner_address = validate_pubkey(owner_address.clone())?; let owner_address_bytes = owner_address.to_bytes().to_vec(); let sort_by = sort_by.unwrap_or_default(); - let display_options = display_options.unwrap_or_default(); + let options = options.unwrap_or_default(); let page_options = - self.validate_pagination(&limit, &page, &before, &after, &cursor, &Some(&sort_by))?; + self.validate_pagination(limit, page, &before, &after, &cursor, Some(sort_by))?; get_assets_by_owner( &self.db_connection, owner_address_bytes, sort_by, &page_options, - &display_options, + &options, ) .await .map_err(Into::into) @@ -295,22 +281,22 @@ impl ApiContract for DasApi { page, before, after, - display_options, + options, cursor, } = payload; let before: Option = before.filter(|before| !before.is_empty()); let after: Option = after.filter(|after| !after.is_empty()); let sort_by = sort_by.unwrap_or_default(); - let display_options = display_options.unwrap_or_default(); + let options = options.unwrap_or_default(); let page_options = - self.validate_pagination(&limit, &page, &before, &after, &cursor, &Some(&sort_by))?; + self.validate_pagination(limit, page, &before, &after, &cursor, Some(sort_by))?; get_assets_by_group( &self.db_connection, group_key, group_value, sort_by, &page_options, - &display_options, + &options, ) .await .map_err(Into::into) @@ -328,7 +314,7 @@ impl ApiContract for DasApi { page, before, after, - display_options, + options, cursor, } = payload; let creator_address = validate_pubkey(creator_address.clone())?; @@ -336,16 +322,16 @@ impl ApiContract for DasApi { let sort_by = sort_by.unwrap_or_default(); let page_options = - self.validate_pagination(&limit, &page, &before, &after, &cursor, &Some(&sort_by))?; + self.validate_pagination(limit, page, &before, &after, &cursor, Some(sort_by))?; let only_verified = only_verified.unwrap_or_default(); - let display_options = display_options.unwrap_or_default(); + let options = options.unwrap_or_default(); get_assets_by_creator( &self.db_connection, creator_address_bytes, only_verified, sort_by, &page_options, - &display_options, + &options, ) .await .map_err(Into::into) @@ -362,22 +348,22 @@ impl ApiContract for DasApi { page, before, after, - display_options, + options, cursor, } = payload; let sort_by = sort_by.unwrap_or_default(); let authority_address = validate_pubkey(authority_address.clone())?; let authority_address_bytes = authority_address.to_bytes().to_vec(); - let display_options = display_options.unwrap_or_default(); + let options = options.unwrap_or_default(); let page_options = - self.validate_pagination(&limit, &page, &before, &after, &cursor, &Some(&sort_by))?; + self.validate_pagination(limit, page, &before, &after, &cursor, Some(sort_by))?; get_assets_by_authority( &self.db_connection, authority_address_bytes, sort_by, &page_options, - &display_options, + &options, ) .await .map_err(Into::into) @@ -386,7 +372,6 @@ impl ApiContract for DasApi { async fn search_assets(&self, payload: SearchAssets) -> Result { let SearchAssets { negate, - /// Defaults to [ConditionType, condition_type, interface, owner_address, @@ -411,12 +396,11 @@ impl ApiContract for DasApi { before, after, json_uri, - display_options, + options, cursor, name, } = payload; - // Deserialize search assets query let spec: Option<(SpecificationVersions, SpecificationAssetClass)> = interface.map(|x| x.into()); @@ -468,43 +452,21 @@ impl ApiContract for DasApi { json_uri, name, }; - let display_options = display_options.unwrap_or_default(); + let options = options.unwrap_or_default(); let sort_by = sort_by.unwrap_or_default(); let page_options = - self.validate_pagination(&limit, &page, &before, &after, &cursor, &Some(&sort_by))?; + self.validate_pagination(limit, page, &before, &after, &cursor, Some(sort_by))?; // Execute query - search_assets( - &self.db_connection, - saq, - sort_by, - &page_options, - &display_options, - ) - .await - .map_err(Into::into) - } - - async fn get_grouping( - self: &DasApi, - payload: GetGrouping, - ) -> Result { - let GetGrouping { - group_key, - group_value, - } = payload; - let gs = get_grouping(&self.db_connection, group_key.clone(), group_value.clone()).await?; - Ok(GetGroupingResponse { - group_key, - group_name: group_value, - group_size: gs.size, - }) + search_assets(&self.db_connection, saq, sort_by, &page_options, &options) + .await + .map_err(Into::into) } - async fn get_signatures_for_asset( + async fn get_asset_signatures( self: &DasApi, - payload: GetSignaturesForAsset, + payload: GetAssetSignatures, ) -> Result { - let GetSignaturesForAsset { + let GetAssetSignatures { id, limit, page, @@ -512,8 +474,8 @@ impl ApiContract for DasApi { after, tree, leaf_index, - sort_by, cursor, + sort_direction, } = payload; if !((id.is_some() && tree.is_none() && leaf_index.is_none()) @@ -525,12 +487,33 @@ impl ApiContract for DasApi { } let id = validate_opt_pubkey(&id)?; let tree = validate_opt_pubkey(&tree)?; - let sort_by = sort_by.unwrap_or_default(); - let page_options = - self.validate_pagination(&limit, &page, &before, &after, &cursor, &Some(&sort_by))?; - get_signatures_for_asset(&self.db_connection, id, tree, leaf_index, sort_by, &page_options) - .await - .map_err(Into::into) + let page_options = self.validate_pagination(limit, page, &before, &after, &cursor, None)?; + + get_asset_signatures( + &self.db_connection, + id, + tree, + leaf_index, + page_options, + sort_direction, + ) + .await + .map_err(Into::into) + } + async fn get_grouping( + self: &DasApi, + payload: GetGrouping, + ) -> Result { + let GetGrouping { + group_key, + group_value, + } = payload; + let gs = get_grouping(&self.db_connection, group_key.clone(), group_value.clone()).await?; + Ok(GetGroupingResponse { + group_key, + group_name: group_value, + group_size: gs.size, + }) } } diff --git a/das_api/src/api/mod.rs b/das_api/src/api/mod.rs index 14ba499fa..53959b19c 100644 --- a/das_api/src/api/mod.rs +++ b/das_api/src/api/mod.rs @@ -1,7 +1,7 @@ use crate::DasApiError; use async_trait::async_trait; -use digital_asset_types::rpc::display_options::DisplayOptions; -use digital_asset_types::rpc::filter::SearchConditionType; +use digital_asset_types::rpc::filter::{AssetSortDirection, SearchConditionType}; +use digital_asset_types::rpc::options::Options; use digital_asset_types::rpc::response::{AssetList, TransactionSignatureList}; use digital_asset_types::rpc::{filter::AssetSorting, response::GetGroupingResponse}; use digital_asset_types::rpc::{Asset, AssetProof, Interface, OwnershipModel, RoyaltyModel}; @@ -23,8 +23,8 @@ pub struct GetAssetsByGroup { pub page: Option, pub before: Option, pub after: Option, - #[serde(default)] - pub display_options: Option, + #[serde(default, alias = "displayOptions")] + pub options: Option, #[serde(default)] pub cursor: Option, } @@ -38,8 +38,8 @@ pub struct GetAssetsByOwner { pub page: Option, pub before: Option, pub after: Option, - #[serde(default)] - pub display_options: Option, + #[serde(default, alias = "displayOptions")] + pub options: Option, #[serde(default)] pub cursor: Option, } @@ -48,16 +48,16 @@ pub struct GetAssetsByOwner { #[serde(deny_unknown_fields, rename_all = "camelCase")] pub struct GetAsset { pub id: String, - #[serde(default)] - pub display_options: Option, + #[serde(default, alias = "displayOptions")] + pub options: Option, } #[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize, JsonSchema)] #[serde(deny_unknown_fields, rename_all = "camelCase")] -pub struct GetAssetBatch { +pub struct GetAssets { pub ids: Vec, - #[serde(default)] - pub display_options: Option, + #[serde(default, alias = "displayOptions")] + pub options: Option, } #[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize, JsonSchema)] @@ -68,7 +68,7 @@ pub struct GetAssetProof { #[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize, JsonSchema)] #[serde(deny_unknown_fields, rename_all = "camelCase")] -pub struct GetAssetProofBatch { +pub struct GetAssetProofs { pub ids: Vec, } @@ -82,8 +82,8 @@ pub struct GetAssetsByCreator { pub page: Option, pub before: Option, pub after: Option, - #[serde(default)] - pub display_options: Option, + #[serde(default, alias = "displayOptions")] + pub options: Option, #[serde(default)] pub cursor: Option, } @@ -117,8 +117,8 @@ pub struct SearchAssets { pub after: Option, #[serde(default)] pub json_uri: Option, - #[serde(default)] - pub display_options: Option, + #[serde(default, alias = "displayOptions")] + pub options: Option, #[serde(default)] pub cursor: Option, #[serde(default)] @@ -134,8 +134,8 @@ pub struct GetAssetsByAuthority { pub page: Option, pub before: Option, pub after: Option, - #[serde(default)] - pub display_options: Option, + #[serde(default, alias = "displayOptions")] + pub options: Option, #[serde(default)] pub cursor: Option, } @@ -147,9 +147,9 @@ pub struct GetGrouping { pub group_value: String, } -#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize, JsonSchema)] +#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize, JsonSchema, Default)] #[serde(deny_unknown_fields, rename_all = "camelCase")] -pub struct GetSignaturesForAsset { +pub struct GetAssetSignatures { pub id: Option, pub limit: Option, pub page: Option, @@ -157,9 +157,10 @@ pub struct GetSignaturesForAsset { pub after: Option, pub tree: Option, pub leaf_index: Option, - pub sort_by: Option, #[serde(default)] pub cursor: Option, + #[serde(default)] + pub sort_direction: Option, } #[document_rpc] @@ -173,13 +174,13 @@ pub trait ApiContract: Send + Sync + 'static { )] async fn get_asset_proof(&self, payload: GetAssetProof) -> Result; #[rpc( - name = "getAssetProofBatch", + name = "getAssetProofs", params = "named", summary = "Get merkle proofs for compressed assets by their IDs" )] - async fn get_asset_proof_batch( + async fn get_asset_proofs( &self, - payload: GetAssetProofBatch, + payload: GetAssetProofs, ) -> Result>, DasApiError>; #[rpc( name = "getAsset", @@ -188,14 +189,11 @@ pub trait ApiContract: Send + Sync + 'static { )] async fn get_asset(&self, payload: GetAsset) -> Result; #[rpc( - name = "getAssetBatch", + name = "getAssets", params = "named", summary = "Get assets by their IDs" )] - async fn get_asset_batch( - &self, - payload: GetAssetBatch, - ) -> Result>, DasApiError>; + async fn get_assets(&self, payload: GetAssets) -> Result>, DasApiError>; #[rpc( name = "getAssetsByOwner", params = "named", @@ -239,18 +237,18 @@ pub trait ApiContract: Send + Sync + 'static { )] async fn search_assets(&self, payload: SearchAssets) -> Result; #[rpc( - name = "getGrouping", - params = "named", - summary = "Get a list of assets grouped by a specific authority" - )] - async fn get_grouping(&self, payload: GetGrouping) -> Result; - #[rpc( - name = "getSignaturesForAsset", + name = "getAssetSignatures", params = "named", summary = "Get transaction signatures for an asset" )] - async fn get_signatures_for_asset( + async fn get_asset_signatures( &self, - payload: GetSignaturesForAsset, + payload: GetAssetSignatures, ) -> Result; + #[rpc( + name = "getGrouping", + params = "named", + summary = "Get a list of assets grouped by a specific authority" + )] + async fn get_grouping(&self, payload: GetGrouping) -> Result; } diff --git a/das_api/src/builder.rs b/das_api/src/builder.rs index 29cf717b2..9e3da1c81 100644 --- a/das_api/src/builder.rs +++ b/das_api/src/builder.rs @@ -22,17 +22,16 @@ impl RpcApiBuilder { })?; module.register_alias("getAssetProof", "get_asset_proof")?; - module.register_async_method( - "get_asset_proof_batch", - |rpc_params, rpc_context| async move { - let payload = rpc_params.parse::()?; - rpc_context - .get_asset_proof_batch(payload) - .await - .map_err(Into::into) - }, - )?; - module.register_alias("getAssetProofBatch", "get_asset_proof_batch")?; + module.register_async_method("get_asset_proofs", |rpc_params, rpc_context| async move { + let payload = rpc_params.parse::()?; + rpc_context + .get_asset_proofs(payload) + .await + .map_err(Into::into) + })?; + module.register_alias("getAssetProofs", "get_asset_proofs")?; + module.register_alias("get_asset_proof_batch", "get_asset_proofs")?; + module.register_alias("getAssetProofBatch", "get_asset_proofs")?; module.register_async_method("get_asset", |rpc_params, rpc_context| async move { let payload = rpc_params.parse::()?; @@ -40,14 +39,13 @@ impl RpcApiBuilder { })?; module.register_alias("getAsset", "get_asset")?; - module.register_async_method("get_asset_batch", |rpc_params, rpc_context| async move { - let payload = rpc_params.parse::()?; - rpc_context - .get_asset_batch(payload) - .await - .map_err(Into::into) + module.register_async_method("get_assets", |rpc_params, rpc_context| async move { + let payload = rpc_params.parse::()?; + rpc_context.get_assets(payload).await.map_err(Into::into) })?; - module.register_alias("getAssetBatch", "get_asset_batch")?; + module.register_alias("getAssets", "get_assets")?; + module.register_alias("get_asset_batch", "get_assets")?; + module.register_alias("getAssetBatch", "get_assets")?; module.register_async_method( "get_assets_by_owner", @@ -96,23 +94,23 @@ impl RpcApiBuilder { )?; module.register_alias("getAssetsByGroup", "get_assets_by_group")?; - module.register_async_method("search_assets", |rpc_params, rpc_context| async move { - let payload = rpc_params.parse::()?; - rpc_context.search_assets(payload).await.map_err(Into::into) - })?; - module.register_alias("searchAssets", "search_assets")?; - module.register_async_method( - "get_signatures_for_asset", + "getAssetSignatures", |rpc_params, rpc_context| async move { - let payload = rpc_params.parse::()?; + let payload = rpc_params.parse::()?; rpc_context - .get_signatures_for_asset(payload) + .get_asset_signatures(payload) .await .map_err(Into::into) }, )?; - module.register_alias("getSignaturesForAsset", "get_signatures_for_asset")?; + module.register_alias("getSignaturesForAsset", "getAssetSignatures")?; + + module.register_async_method("search_assets", |rpc_params, rpc_context| async move { + let payload = rpc_params.parse::()?; + rpc_context.search_assets(payload).await.map_err(Into::into) + })?; + module.register_alias("searchAssets", "search_assets")?; module.register_async_method("schema", |_, rpc_context| async move { Ok(rpc_context.schema()) diff --git a/das_api/src/error.rs b/das_api/src/error.rs index 4b009ceac..e6b626f19 100644 --- a/das_api/src/error.rs +++ b/das_api/src/error.rs @@ -2,6 +2,7 @@ use log::{debug, error}; use {jsonrpsee::core::Error as RpcError, jsonrpsee::types::error::CallError, thiserror::Error}; +#[allow(clippy::enum_variant_names)] #[derive(Error, Debug)] pub enum DasApiError { #[error("Config Missing or Error: {0}")] @@ -28,20 +29,20 @@ pub enum DasApiError { PaginationExceededError, #[error("Cursor Validation Err: {0} is invalid")] CursorValidationError(String), - #[error("Pagination Sorting Error. Only sorting based on id is support for this pagination")] + #[error("Pagination Sorting Error. Only sorting based on id is supported for this pagination option.")] PaginationSortingValidationError, } -impl Into for DasApiError { - fn into(self) -> RpcError { - match self { - Self::ValidationError(_) => { - debug!("{}", self); +impl From for RpcError { + fn from(error: DasApiError) -> RpcError { + match error { + DasApiError::ValidationError(_) => { + debug!("{}", error); } _ => { - error!("{}", self); + error!("{}", error); } } - RpcError::Call(CallError::from_std_error(self)) + RpcError::Call(CallError::from_std_error(error)) } } diff --git a/digital_asset_types/Cargo.toml b/digital_asset_types/Cargo.toml index 07a08f468..f7cab08ee 100644 --- a/digital_asset_types/Cargo.toml +++ b/digital_asset_types/Cargo.toml @@ -1,47 +1,39 @@ [package] name = "digital_asset_types" -version = "0.7.2" -edition = "2021" -publish = false - +version = { workspace = true } +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -spl-concurrent-merkle-tree = "0.2.0" -sea-orm = { optional = true, version = "0.10.6", features = [ - "macros", - "runtime-tokio-rustls", - "sqlx-postgres", - "with-chrono", -] } -sea-query = { version = "0.28.1", features = ["postgres-array"] } -serde = { version = "1.0.137", optional = true } -serde_json = { version = "1.0.81", optional = true, features = [ - "preserve_order", -] } -bs58 = "0.4.0" -borsh = { version = "~0.10.3", optional = true } -borsh-derive = { version = "~0.10.3", optional = true } -solana-sdk = "~1.16.16" -num-traits = "0.2.15" -num-derive = "0.3.3" -thiserror = "1.0.31" -blockbuster = "0.9.0-beta.1" -jsonpath_lib = "0.3.0" -mime_guess = "2.0.4" -url = "2.3.1" -futures = "0.3.25" -reqwest = "0.11.13" -async-trait = "0.1.60" -tokio = { version = "1.22.0", features = ["full"] } -schemars = "0.8.6" -schemars_derive = "0.8.6" -log = "0.4.17" -indexmap = "1.9.3" - -[dev-dependencies] -reqwest = "0.11.13" +async-trait = { workspace = true } +blockbuster = { workspace = true } +borsh = { workspace = true, optional = true } +borsh-derive = { workspace = true, optional = true } +bs58 = { workspace = true } +futures = { workspace = true } +indexmap = { workspace = true } +jsonpath_lib = { workspace = true } +log = { workspace = true } +mime_guess = { workspace = true } +num-derive = { workspace = true } +num-traits = { workspace = true } +schemars = { workspace = true } +schemars_derive = { workspace = true } +sea-orm = { optional = true, features = ["macros", "runtime-tokio-rustls", "sqlx-postgres", "with-chrono", "mock"], workspace = true } +sea-query = { workspace = true, features = ["postgres-array"] } +serde = { workspace = true, optional = true } +serde_json = { workspace = true, features = ["preserve_order"], optional = true } +solana-sdk = { workspace = true } +spl-concurrent-merkle-tree = { workspace = true } +thiserror = { workspace = true } +tokio = { workspace = true } +url = { workspace = true } [features] default = ["json_types", "sql_types"] json_types = ["serde", "serde_json"] sql_types = ["sea-orm"] + +[lints] +workspace = true diff --git a/digital_asset_types/src/dao/extensions/asset.rs b/digital_asset_types/src/dao/extensions/asset.rs new file mode 100644 index 000000000..ed3757bf2 --- /dev/null +++ b/digital_asset_types/src/dao/extensions/asset.rs @@ -0,0 +1,104 @@ +use sea_orm::{EntityTrait, EnumIter, Related, RelationDef, RelationTrait}; + +use crate::dao::{ + asset, asset_authority, asset_creators, asset_data, asset_grouping, + asset_v1_account_attachments, + sea_orm_active_enums::{OwnerType, RoyaltyTargetType}, +}; + +#[derive(Copy, Clone, Debug, EnumIter)] +pub enum Relation { + AssetData, + AssetV1AccountAttachments, + AssetAuthority, + AssetCreators, + AssetGrouping, +} + +impl RelationTrait for Relation { + fn def(&self) -> RelationDef { + match self { + Self::AssetData => asset::Entity::belongs_to(asset_data::Entity) + .from(asset::Column::AssetData) + .to(asset_data::Column::Id) + .into(), + Self::AssetV1AccountAttachments => { + asset::Entity::has_many(asset_v1_account_attachments::Entity).into() + } + Self::AssetAuthority => asset::Entity::has_many(asset_authority::Entity).into(), + Self::AssetCreators => asset::Entity::has_many(asset_creators::Entity).into(), + Self::AssetGrouping => asset::Entity::has_many(asset_grouping::Entity).into(), + } + } +} + +impl Related for asset::Entity { + fn to() -> RelationDef { + Relation::AssetData.def() + } +} + +impl Related for asset::Entity { + fn to() -> RelationDef { + Relation::AssetV1AccountAttachments.def() + } +} + +impl Related for asset::Entity { + fn to() -> RelationDef { + Relation::AssetAuthority.def() + } +} + +impl Related for asset::Entity { + fn to() -> RelationDef { + Relation::AssetCreators.def() + } +} + +impl Related for asset::Entity { + fn to() -> RelationDef { + Relation::AssetGrouping.def() + } +} + +impl Default for RoyaltyTargetType { + fn default() -> Self { + Self::Creators + } +} + +impl Default for asset::Model { + fn default() -> Self { + Self { + id: vec![], + alt_id: None, + specification_version: None, + specification_asset_class: None, + owner: None, + owner_type: OwnerType::Single, + delegate: None, + frozen: Default::default(), + supply: Default::default(), + supply_mint: None, + compressed: Default::default(), + compressible: Default::default(), + seq: None, + tree_id: None, + leaf: None, + nonce: None, + royalty_target_type: RoyaltyTargetType::Unknown, + royalty_target: None, + royalty_amount: Default::default(), + asset_data: None, + created_at: None, + burnt: Default::default(), + slot_updated: None, + data_hash: None, + creator_hash: None, + owner_delegate_seq: None, + leaf_seq: None, + base_info_seq: None, + } + } +} diff --git a/digital_asset_types/src/dao/extensions/asset_authority.rs b/digital_asset_types/src/dao/extensions/asset_authority.rs new file mode 100644 index 000000000..30ec05617 --- /dev/null +++ b/digital_asset_types/src/dao/extensions/asset_authority.rs @@ -0,0 +1,25 @@ +use sea_orm::{EntityTrait, EnumIter, Related, RelationDef, RelationTrait}; + +use crate::dao::{asset, asset_authority}; + +#[derive(Copy, Clone, Debug, EnumIter)] +pub enum Relation { + Asset, +} + +impl RelationTrait for Relation { + fn def(&self) -> RelationDef { + match self { + Self::Asset => asset_authority::Entity::belongs_to(asset::Entity) + .from(asset_authority::Column::AssetId) + .to(asset::Column::Id) + .into(), + } + } +} + +impl Related for asset_authority::Entity { + fn to() -> RelationDef { + Relation::Asset.def() + } +} diff --git a/digital_asset_types/src/dao/extensions/asset_creators.rs b/digital_asset_types/src/dao/extensions/asset_creators.rs new file mode 100644 index 000000000..35d36e98d --- /dev/null +++ b/digital_asset_types/src/dao/extensions/asset_creators.rs @@ -0,0 +1,25 @@ +use sea_orm::{EntityTrait, EnumIter, Related, RelationDef, RelationTrait}; + +use crate::dao::{asset, asset_creators}; + +#[derive(Copy, Clone, Debug, EnumIter)] +pub enum Relation { + Asset, +} + +impl RelationTrait for Relation { + fn def(&self) -> RelationDef { + match self { + Self::Asset => asset_creators::Entity::belongs_to(asset::Entity) + .from(asset_creators::Column::AssetId) + .to(asset::Column::Id) + .into(), + } + } +} + +impl Related for asset_creators::Entity { + fn to() -> RelationDef { + Relation::Asset.def() + } +} diff --git a/digital_asset_types/src/dao/extensions/asset_data.rs b/digital_asset_types/src/dao/extensions/asset_data.rs new file mode 100644 index 000000000..93bb00bfc --- /dev/null +++ b/digital_asset_types/src/dao/extensions/asset_data.rs @@ -0,0 +1,22 @@ +use sea_orm::{EntityTrait, EnumIter, Related, RelationDef, RelationTrait}; + +use crate::dao::{asset, asset_data}; + +#[derive(Copy, Clone, Debug, EnumIter)] +pub enum Relation { + Asset, +} + +impl RelationTrait for Relation { + fn def(&self) -> RelationDef { + match self { + Self::Asset => asset_data::Entity::has_many(asset::Entity).into(), + } + } +} + +impl Related for asset_data::Entity { + fn to() -> RelationDef { + Relation::Asset.def() + } +} diff --git a/digital_asset_types/src/dao/extensions/asset_grouping.rs b/digital_asset_types/src/dao/extensions/asset_grouping.rs new file mode 100644 index 000000000..1d1bce87a --- /dev/null +++ b/digital_asset_types/src/dao/extensions/asset_grouping.rs @@ -0,0 +1,25 @@ +use sea_orm::{EntityTrait, EnumIter, Related, RelationDef, RelationTrait}; + +use crate::dao::{asset, asset_grouping}; + +#[derive(Copy, Clone, Debug, EnumIter)] +pub enum Relation { + Asset, +} + +impl RelationTrait for Relation { + fn def(&self) -> RelationDef { + match self { + Self::Asset => asset_grouping::Entity::belongs_to(asset::Entity) + .from(asset_grouping::Column::AssetId) + .to(asset::Column::Id) + .into(), + } + } +} + +impl Related for asset_grouping::Entity { + fn to() -> RelationDef { + Relation::Asset.def() + } +} diff --git a/digital_asset_types/src/dao/extensions/asset_v1_account_attachment.rs b/digital_asset_types/src/dao/extensions/asset_v1_account_attachment.rs new file mode 100644 index 000000000..c231b6e92 --- /dev/null +++ b/digital_asset_types/src/dao/extensions/asset_v1_account_attachment.rs @@ -0,0 +1,25 @@ +use sea_orm::{EntityTrait, EnumIter, Related, RelationDef, RelationTrait}; + +use crate::dao::{asset, asset_v1_account_attachments}; + +#[derive(Copy, Clone, Debug, EnumIter)] +pub enum Relation { + Asset, +} + +impl RelationTrait for Relation { + fn def(&self) -> RelationDef { + match self { + Self::Asset => asset_v1_account_attachments::Entity::belongs_to(asset::Entity) + .from(asset_v1_account_attachments::Column::AssetId) + .to(asset::Column::Id) + .into(), + } + } +} + +impl Related for asset_v1_account_attachments::Entity { + fn to() -> RelationDef { + Relation::Asset.def() + } +} diff --git a/digital_asset_types/src/dao/extensions/instruction.rs b/digital_asset_types/src/dao/extensions/instruction.rs new file mode 100644 index 000000000..c58a91891 --- /dev/null +++ b/digital_asset_types/src/dao/extensions/instruction.rs @@ -0,0 +1,52 @@ +use crate::dao::sea_orm_active_enums::Instruction; + +impl From<&str> for Instruction { + fn from(s: &str) -> Self { + match s { + "Burn" => Instruction::Burn, + "CancelRedeem" => Instruction::CancelRedeem, + "Compress" => Instruction::Compress, + "DecompressV1" => Instruction::DecompressV1, + "Delegate" => Instruction::Delegate, + "MintToCollectionV1" => Instruction::MintToCollectionV1, + "MintV1" => Instruction::MintV1, + "Redeem" => Instruction::Redeem, + "SetAndVerifyCollection" => Instruction::SetAndVerifyCollection, + "Transfer" => Instruction::Transfer, + "UnverifyCollection" => Instruction::UnverifyCollection, + "UnverifyCreator" => Instruction::UnverifyCreator, + "VerifyCollection" => Instruction::VerifyCollection, + "VerifyCreator" => Instruction::VerifyCreator, + "UpdateMetadata" => Instruction::UpdateMetadata, + _ => Instruction::Unknown, + } + } +} + +pub trait PascalCase { + fn to_pascal_case(&self) -> String; +} + +impl PascalCase for Instruction { + fn to_pascal_case(&self) -> String { + let s = match self { + Instruction::Burn => "Burn", + Instruction::CancelRedeem => "CancelRedeem", + Instruction::Compress => "Compress", + Instruction::DecompressV1 => "DecompressV1", + Instruction::Delegate => "Delegate", + Instruction::MintToCollectionV1 => "MintToCollectionV1", + Instruction::MintV1 => "MintV1", + Instruction::Redeem => "Redeem", + Instruction::SetAndVerifyCollection => "SetAndVerifyCollection", + Instruction::Transfer => "Transfer", + Instruction::Unknown => "Unknown", + Instruction::UnverifyCollection => "UnverifyCollection", + Instruction::UnverifyCreator => "UnverifyCreator", + Instruction::VerifyCollection => "VerifyCollection", + Instruction::VerifyCreator => "VerifyCreator", + Instruction::UpdateMetadata => "UpdateMetadata", + }; + s.to_string() + } +} diff --git a/digital_asset_types/src/dao/extensions/mod.rs b/digital_asset_types/src/dao/extensions/mod.rs new file mode 100644 index 000000000..bcfc3e130 --- /dev/null +++ b/digital_asset_types/src/dao/extensions/mod.rs @@ -0,0 +1,7 @@ +pub mod asset; +pub mod asset_authority; +pub mod asset_creators; +pub mod asset_data; +pub mod asset_grouping; +pub mod asset_v1_account_attachment; +pub mod instruction; diff --git a/digital_asset_types/src/dao/generated/asset.rs b/digital_asset_types/src/dao/generated/asset.rs index 0ced69299..e03ae6866 100644 --- a/digital_asset_types/src/dao/generated/asset.rs +++ b/digital_asset_types/src/dao/generated/asset.rs @@ -44,8 +44,8 @@ pub struct Model { pub data_hash: Option, pub creator_hash: Option, pub owner_delegate_seq: Option, - pub was_decompressed: bool, pub leaf_seq: Option, + pub base_info_seq: Option, } #[derive(Copy, Clone, Debug, EnumIter, DeriveColumn)] @@ -76,8 +76,8 @@ pub enum Column { DataHash, CreatorHash, OwnerDelegateSeq, - WasDecompressed, LeafSeq, + BaseInfoSeq, } #[derive(Copy, Clone, Debug, EnumIter, DerivePrimaryKey)] @@ -93,13 +93,7 @@ impl PrimaryKeyTrait for PrimaryKey { } #[derive(Copy, Clone, Debug, EnumIter)] -pub enum Relation { - AssetData, - AssetV1AccountAttachments, - AssetCreators, - AssetAuthority, - AssetGrouping, -} +pub enum Relation {} impl ColumnTrait for Column { type EntityName = Entity; @@ -131,56 +125,15 @@ impl ColumnTrait for Column { Self::DataHash => ColumnType::Char(Some(50u32)).def().null(), Self::CreatorHash => ColumnType::Char(Some(50u32)).def().null(), Self::OwnerDelegateSeq => ColumnType::BigInteger.def().null(), - Self::WasDecompressed => ColumnType::Boolean.def(), Self::LeafSeq => ColumnType::BigInteger.def().null(), + Self::BaseInfoSeq => ColumnType::BigInteger.def().null(), } } } impl RelationTrait for Relation { fn def(&self) -> RelationDef { - match self { - Self::AssetData => Entity::belongs_to(super::asset_data::Entity) - .from(Column::AssetData) - .to(super::asset_data::Column::Id) - .into(), - Self::AssetV1AccountAttachments => { - Entity::has_many(super::asset_v1_account_attachments::Entity).into() - } - Self::AssetCreators => Entity::has_many(super::asset_creators::Entity).into(), - Self::AssetAuthority => Entity::has_many(super::asset_authority::Entity).into(), - Self::AssetGrouping => Entity::has_many(super::asset_grouping::Entity).into(), - } - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::AssetData.def() - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::AssetV1AccountAttachments.def() - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::AssetCreators.def() - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::AssetAuthority.def() - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::AssetGrouping.def() + panic!("No RelationDef") } } diff --git a/digital_asset_types/src/dao/generated/asset_authority.rs b/digital_asset_types/src/dao/generated/asset_authority.rs index 88d0ed72f..5ba29e6bd 100644 --- a/digital_asset_types/src/dao/generated/asset_authority.rs +++ b/digital_asset_types/src/dao/generated/asset_authority.rs @@ -45,9 +45,7 @@ impl PrimaryKeyTrait for PrimaryKey { } #[derive(Copy, Clone, Debug, EnumIter)] -pub enum Relation { - Asset, -} +pub enum Relation {} impl ColumnTrait for Column { type EntityName = Entity; @@ -65,18 +63,7 @@ impl ColumnTrait for Column { impl RelationTrait for Relation { fn def(&self) -> RelationDef { - match self { - Self::Asset => Entity::belongs_to(super::asset::Entity) - .from(Column::AssetId) - .to(super::asset::Column::Id) - .into(), - } - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::Asset.def() + panic!("No RelationDef") } } diff --git a/digital_asset_types/src/dao/generated/asset_creators.rs b/digital_asset_types/src/dao/generated/asset_creators.rs index 21f34dcf7..af4f0c768 100644 --- a/digital_asset_types/src/dao/generated/asset_creators.rs +++ b/digital_asset_types/src/dao/generated/asset_creators.rs @@ -49,9 +49,7 @@ impl PrimaryKeyTrait for PrimaryKey { } #[derive(Copy, Clone, Debug, EnumIter)] -pub enum Relation { - Asset, -} +pub enum Relation {} impl ColumnTrait for Column { type EntityName = Entity; @@ -71,18 +69,7 @@ impl ColumnTrait for Column { impl RelationTrait for Relation { fn def(&self) -> RelationDef { - match self { - Self::Asset => Entity::belongs_to(super::asset::Entity) - .from(Column::AssetId) - .to(super::asset::Column::Id) - .into(), - } - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::Asset.def() + panic!("No RelationDef") } } diff --git a/digital_asset_types/src/dao/generated/asset_data.rs b/digital_asset_types/src/dao/generated/asset_data.rs index c8177b628..c96c265e6 100644 --- a/digital_asset_types/src/dao/generated/asset_data.rs +++ b/digital_asset_types/src/dao/generated/asset_data.rs @@ -26,6 +26,7 @@ pub struct Model { pub reindex: Option, pub raw_name: Option>, pub raw_symbol: Option>, + pub base_info_seq: Option, } #[derive(Copy, Clone, Debug, EnumIter, DeriveColumn)] @@ -40,6 +41,7 @@ pub enum Column { Reindex, RawName, RawSymbol, + BaseInfoSeq, } #[derive(Copy, Clone, Debug, EnumIter, DerivePrimaryKey)] @@ -55,9 +57,7 @@ impl PrimaryKeyTrait for PrimaryKey { } #[derive(Copy, Clone, Debug, EnumIter)] -pub enum Relation { - Asset, -} +pub enum Relation {} impl ColumnTrait for Column { type EntityName = Entity; @@ -73,21 +73,14 @@ impl ColumnTrait for Column { Self::Reindex => ColumnType::Boolean.def().null(), Self::RawName => ColumnType::Binary.def().null(), Self::RawSymbol => ColumnType::Binary.def().null(), + Self::BaseInfoSeq => ColumnType::BigInteger.def().null(), } } } impl RelationTrait for Relation { fn def(&self) -> RelationDef { - match self { - Self::Asset => Entity::has_many(super::asset::Entity).into(), - } - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::Asset.def() + panic!("No RelationDef") } } diff --git a/digital_asset_types/src/dao/generated/asset_grouping.rs b/digital_asset_types/src/dao/generated/asset_grouping.rs index 5d5c0e749..8196d33bd 100644 --- a/digital_asset_types/src/dao/generated/asset_grouping.rs +++ b/digital_asset_types/src/dao/generated/asset_grouping.rs @@ -49,9 +49,7 @@ impl PrimaryKeyTrait for PrimaryKey { } #[derive(Copy, Clone, Debug, EnumIter)] -pub enum Relation { - Asset, -} +pub enum Relation {} impl ColumnTrait for Column { type EntityName = Entity; @@ -71,18 +69,7 @@ impl ColumnTrait for Column { impl RelationTrait for Relation { fn def(&self) -> RelationDef { - match self { - Self::Asset => Entity::belongs_to(super::asset::Entity) - .from(Column::AssetId) - .to(super::asset::Column::Id) - .into(), - } - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::Asset.def() + panic!("No RelationDef") } } diff --git a/digital_asset_types/src/dao/generated/asset_v1_account_attachments.rs b/digital_asset_types/src/dao/generated/asset_v1_account_attachments.rs index f8b0ff21a..2d571b25e 100644 --- a/digital_asset_types/src/dao/generated/asset_v1_account_attachments.rs +++ b/digital_asset_types/src/dao/generated/asset_v1_account_attachments.rs @@ -46,9 +46,7 @@ impl PrimaryKeyTrait for PrimaryKey { } #[derive(Copy, Clone, Debug, EnumIter)] -pub enum Relation { - Asset, -} +pub enum Relation {} impl ColumnTrait for Column { type EntityName = Entity; @@ -66,18 +64,7 @@ impl ColumnTrait for Column { impl RelationTrait for Relation { fn def(&self) -> RelationDef { - match self { - Self::Asset => Entity::belongs_to(super::asset::Entity) - .from(Column::AssetId) - .to(super::asset::Column::Id) - .into(), - } - } -} - -impl Related for Entity { - fn to() -> RelationDef { - Relation::Asset.def() + panic!("No RelationDef") } } diff --git a/digital_asset_types/src/dao/generated/cl_audits.rs b/digital_asset_types/src/dao/generated/cl_audits.rs deleted file mode 100644 index f013a7138..000000000 --- a/digital_asset_types/src/dao/generated/cl_audits.rs +++ /dev/null @@ -1,97 +0,0 @@ -//! SeaORM Entity. Generated by sea-orm-codegen 0.9.3 - -use sea_orm::entity::prelude::*; -use serde::{Deserialize, Serialize}; - -#[derive(Copy, Clone, Default, Debug, DeriveEntity)] -pub struct Entity; - -impl EntityName for Entity { - fn table_name(&self) -> &str { - "cl_audits" - } -} - -#[derive(Clone, Debug, PartialEq, DeriveModel, DeriveActiveModel, Serialize, Deserialize)] -pub struct Model { - pub id: i64, - pub tree: Vec, - pub node_idx: i64, - pub leaf_idx: Option, - pub seq: i64, - pub level: i64, - pub hash: Vec, - pub created_at: DateTime, - pub tx: String, - pub instruction: Option, -} - -#[derive(Copy, Clone, Debug, EnumIter, DeriveColumn)] -pub enum Column { - Id, - Tree, - NodeIdx, - LeafIdx, - Seq, - Level, - Hash, - CreatedAt, - Tx, - #[sea_orm(column_name = "Instruction")] - Instruction, -} - -#[derive(Copy, Clone, Debug, EnumIter, DerivePrimaryKey)] -pub enum PrimaryKey { - Id, -} - -impl PrimaryKeyTrait for PrimaryKey { - type ValueType = i64; - fn auto_increment() -> bool { - true - } -} - -#[derive(Copy, Clone, Debug, EnumIter)] -pub enum Relation {} - -impl ColumnTrait for Column { - type EntityName = Entity; - fn def(&self) -> ColumnDef { - match self { - Self::Id => ColumnType::BigInteger.def(), - Self::Tree => ColumnType::Binary.def(), - Self::NodeIdx => ColumnType::BigInteger.def(), - Self::LeafIdx => ColumnType::BigInteger.def().null(), - Self::Seq => ColumnType::BigInteger.def(), - Self::Level => ColumnType::BigInteger.def(), - Self::Hash => ColumnType::Binary.def(), - Self::CreatedAt => ColumnType::DateTime.def(), - Self::Tx => ColumnType::String(None).def(), - Self::Instruction => ColumnType::String(None).def().null(), - } - } -} - -impl RelationTrait for Relation { - fn def(&self) -> RelationDef { - panic!("No RelationDef") - } -} - -impl ActiveModelBehavior for ActiveModel {} - -impl From for ActiveModel { - fn from(item: crate::dao::cl_items::ActiveModel) -> Self { - return ActiveModel { - tree: item.tree, - level: item.level, - node_idx: item.node_idx, - hash: item.hash, - seq: item.seq, - leaf_idx: item.leaf_idx, - ..Default::default() - }; - } -} diff --git a/digital_asset_types/src/dao/generated/cl_audits_v2.rs b/digital_asset_types/src/dao/generated/cl_audits_v2.rs index 64d2eff60..d1875c254 100644 --- a/digital_asset_types/src/dao/generated/cl_audits_v2.rs +++ b/digital_asset_types/src/dao/generated/cl_audits_v2.rs @@ -1,6 +1,6 @@ -//! `SeaORM` Entity. Generated by sea-orm-codegen 0.10.5 +//! SeaORM Entity. Generated by sea-orm-codegen 0.9.3 -use super::sea_orm_active_enums::BubblegumInstruction; +use super::sea_orm_active_enums::Instruction; use sea_orm::entity::prelude::*; use serde::{Deserialize, Serialize}; @@ -13,7 +13,7 @@ impl EntityName for Entity { } } -#[derive(Clone, Debug, PartialEq, DeriveModel, DeriveActiveModel, Eq, Serialize, Deserialize)] +#[derive(Clone, Debug, PartialEq, DeriveModel, DeriveActiveModel, Serialize, Deserialize)] pub struct Model { pub id: i64, pub tree: Vec, @@ -21,7 +21,7 @@ pub struct Model { pub seq: i64, pub created_at: DateTime, pub tx: Vec, - pub instruction: BubblegumInstruction, + pub instruction: Instruction, } #[derive(Copy, Clone, Debug, EnumIter, DeriveColumn)] @@ -60,7 +60,7 @@ impl ColumnTrait for Column { Self::Seq => ColumnType::BigInteger.def(), Self::CreatedAt => ColumnType::DateTime.def(), Self::Tx => ColumnType::Binary.def(), - Self::Instruction => BubblegumInstruction::db_type(), + Self::Instruction => Instruction::db_type(), } } } diff --git a/digital_asset_types/src/dao/generated/mod.rs b/digital_asset_types/src/dao/generated/mod.rs index e06532f46..cb7314768 100644 --- a/digital_asset_types/src/dao/generated/mod.rs +++ b/digital_asset_types/src/dao/generated/mod.rs @@ -9,7 +9,6 @@ pub mod asset_data; pub mod asset_grouping; pub mod asset_v1_account_attachments; pub mod backfill_items; -pub mod cl_audits; pub mod cl_audits_v2; pub mod cl_items; pub mod raw_txn; diff --git a/digital_asset_types/src/dao/generated/prelude.rs b/digital_asset_types/src/dao/generated/prelude.rs index 000bddc1b..93d74ee01 100644 --- a/digital_asset_types/src/dao/generated/prelude.rs +++ b/digital_asset_types/src/dao/generated/prelude.rs @@ -1,16 +1 @@ //! SeaORM Entity. Generated by sea-orm-codegen 0.9.3 - -pub use super::asset::Entity as Asset; -pub use super::asset_authority::Entity as AssetAuthority; -pub use super::asset_creators::Entity as AssetCreators; -pub use super::asset_data::Entity as AssetData; -pub use super::asset_grouping::Entity as AssetGrouping; -pub use super::asset_v1_account_attachments::Entity as AssetV1AccountAttachments; -pub use super::backfill_items::Entity as BackfillItems; -pub use super::cl_audits::Entity as ClAudits; -pub use super::cl_audits_v2::Entity as ClAuditsV2; -pub use super::cl_items::Entity as ClItems; -pub use super::raw_txn::Entity as RawTxn; -pub use super::tasks::Entity as Tasks; -pub use super::token_accounts::Entity as TokenAccounts; -pub use super::tokens::Entity as Tokens; diff --git a/digital_asset_types/src/dao/generated/sea_orm_active_enums.rs b/digital_asset_types/src/dao/generated/sea_orm_active_enums.rs index 62217d83e..7576ec245 100644 --- a/digital_asset_types/src/dao/generated/sea_orm_active_enums.rs +++ b/digital_asset_types/src/dao/generated/sea_orm_active_enums.rs @@ -4,38 +4,16 @@ use sea_orm::entity::prelude::*; use serde::{Deserialize, Serialize}; #[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] -#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "chain_mutability")] -pub enum ChainMutability { - #[sea_orm(string_value = "immutable")] - Immutable, - #[sea_orm(string_value = "mutable")] - Mutable, - #[sea_orm(string_value = "unknown")] - Unknown, -} -#[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] -#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "mutability")] -pub enum Mutability { - #[sea_orm(string_value = "immutable")] - Immutable, - #[sea_orm(string_value = "mutable")] - Mutable, +#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "owner_type")] +pub enum OwnerType { + #[sea_orm(string_value = "single")] + Single, + #[sea_orm(string_value = "token")] + Token, #[sea_orm(string_value = "unknown")] Unknown, } #[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] -#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "task_status")] -pub enum TaskStatus { - #[sea_orm(string_value = "failed")] - Failed, - #[sea_orm(string_value = "pending")] - Pending, - #[sea_orm(string_value = "running")] - Running, - #[sea_orm(string_value = "success")] - Success, -} -#[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] #[sea_orm( rs_type = "String", db_type = "Enum", @@ -52,20 +30,32 @@ pub enum RoyaltyTargetType { Unknown, } #[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] +#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "mutability")] +pub enum Mutability { + #[sea_orm(string_value = "immutable")] + Immutable, + #[sea_orm(string_value = "mutable")] + Mutable, + #[sea_orm(string_value = "unknown")] + Unknown, +} +#[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] #[sea_orm( rs_type = "String", db_type = "Enum", - enum_name = "specification_versions" + enum_name = "v1_account_attachments" )] -pub enum SpecificationVersions { +pub enum V1AccountAttachments { + #[sea_orm(string_value = "edition")] + Edition, + #[sea_orm(string_value = "edition_marker")] + EditionMarker, + #[sea_orm(string_value = "master_edition_v1")] + MasterEditionV1, + #[sea_orm(string_value = "master_edition_v2")] + MasterEditionV2, #[sea_orm(string_value = "unknown")] Unknown, - #[sea_orm(string_value = "v0")] - V0, - #[sea_orm(string_value = "v1")] - V1, - #[sea_orm(string_value = "v2")] - V2, } #[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] #[sea_orm( @@ -96,42 +86,46 @@ pub enum SpecificationAssetClass { Unknown, } #[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] -#[sea_orm( - rs_type = "String", - db_type = "Enum", - enum_name = "v1_account_attachments" -)] -pub enum V1AccountAttachments { - #[sea_orm(string_value = "edition")] - Edition, - #[sea_orm(string_value = "edition_marker")] - EditionMarker, - #[sea_orm(string_value = "master_edition_v1")] - MasterEditionV1, - #[sea_orm(string_value = "master_edition_v2")] - MasterEditionV2, +#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "chain_mutability")] +pub enum ChainMutability { + #[sea_orm(string_value = "immutable")] + Immutable, + #[sea_orm(string_value = "mutable")] + Mutable, #[sea_orm(string_value = "unknown")] Unknown, } #[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] -#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "owner_type")] -pub enum OwnerType { - #[sea_orm(string_value = "single")] - Single, - #[sea_orm(string_value = "token")] - Token, - #[sea_orm(string_value = "unknown")] - Unknown, +#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "task_status")] +pub enum TaskStatus { + #[sea_orm(string_value = "failed")] + Failed, + #[sea_orm(string_value = "pending")] + Pending, + #[sea_orm(string_value = "running")] + Running, + #[sea_orm(string_value = "success")] + Success, } -#[derive(Debug, Clone, PartialEq, Eq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] +#[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] #[sea_orm( rs_type = "String", db_type = "Enum", - enum_name = "bubblegum_instruction" + enum_name = "specification_versions" )] -pub enum BubblegumInstruction { - #[sea_orm(string_value = "bubblegum_instruction")] - BubblegumInstruction, +pub enum SpecificationVersions { + #[sea_orm(string_value = "unknown")] + Unknown, + #[sea_orm(string_value = "v0")] + V0, + #[sea_orm(string_value = "v1")] + V1, + #[sea_orm(string_value = "v2")] + V2, +} +#[derive(Debug, Clone, PartialEq, EnumIter, DeriveActiveEnum, Serialize, Deserialize)] +#[sea_orm(rs_type = "String", db_type = "Enum", enum_name = "instruction")] +pub enum Instruction { #[sea_orm(string_value = "burn")] Burn, #[sea_orm(string_value = "cancel_redeem")] @@ -158,39 +152,10 @@ pub enum BubblegumInstruction { UnverifyCollection, #[sea_orm(string_value = "unverify_creator")] UnverifyCreator, + #[sea_orm(string_value = "update_metadata")] + UpdateMetadata, #[sea_orm(string_value = "verify_collection")] VerifyCollection, #[sea_orm(string_value = "verify_creator")] VerifyCreator, - #[sea_orm(string_value = "create_tree")] - CreateTree, -} - -impl std::str::FromStr for BubblegumInstruction { - type Err = sea_orm::DbErr; - - fn from_str(s: &str) -> Result { - match s { - "MintV1" => Ok(BubblegumInstruction::MintV1), - "MintToCollectionV1" => Ok(BubblegumInstruction::MintToCollectionV1), - "Redeem" => Ok(BubblegumInstruction::Redeem), - "CancelRedeem" => Ok(BubblegumInstruction::CancelRedeem), - "Transfer" => Ok(BubblegumInstruction::Transfer), - "Delegate" => Ok(BubblegumInstruction::Delegate), - "DecompressV1" => Ok(BubblegumInstruction::DecompressV1), - "Compress" => Ok(BubblegumInstruction::Compress), - "Burn" => Ok(BubblegumInstruction::Burn), - "CreateTree" => Ok(BubblegumInstruction::CreateTree), - "VerifyCreator" => Ok(BubblegumInstruction::VerifyCreator), - "UnverifyCreator" => Ok(BubblegumInstruction::UnverifyCreator), - "VerifyCollection" => Ok(BubblegumInstruction::VerifyCollection), - "UnverifyCollection" => Ok(BubblegumInstruction::UnverifyCollection), - "SetAndVerifyCollection" => Ok(BubblegumInstruction::SetAndVerifyCollection), - "Unknown" => Ok(BubblegumInstruction::Unknown), - _ => Err(sea_orm::DbErr::Custom(format!( - "Invalid value for BubblegumInstruction: {}", - s - ))), - } - } } diff --git a/digital_asset_types/src/dao/mod.rs b/digital_asset_types/src/dao/mod.rs index 2622c3659..bf1e540ab 100644 --- a/digital_asset_types/src/dao/mod.rs +++ b/digital_asset_types/src/dao/mod.rs @@ -7,6 +7,8 @@ use self::sea_orm_active_enums::{ }; pub use full_asset::*; pub use generated::*; +pub mod extensions; + use sea_orm::{ entity::*, sea_query::Expr, @@ -73,71 +75,6 @@ pub struct SearchAssetsQuery { } impl SearchAssetsQuery { - pub fn count_conditions(&self) -> usize { - // Initialize counter - // todo ever heard of a flipping macro - let mut num_conditions = 0; - if self.specification_version.is_some() { - num_conditions += 1; - } - if self.specification_asset_class.is_some() { - num_conditions += 1; - } - if self.owner_address.is_some() { - num_conditions += 1; - } - if self.owner_type.is_some() { - num_conditions += 1; - } - if self.delegate.is_some() { - num_conditions += 1; - } - if self.frozen.is_some() { - num_conditions += 1; - } - if self.supply.is_some() { - num_conditions += 1; - } - if self.supply_mint.is_some() { - num_conditions += 1; - } - if self.compressed.is_some() { - num_conditions += 1; - } - if self.compressible.is_some() { - num_conditions += 1; - } - if self.royalty_target_type.is_some() { - num_conditions += 1; - } - if self.royalty_target.is_some() { - num_conditions += 1; - } - if self.royalty_amount.is_some() { - num_conditions += 1; - } - if self.burnt.is_some() { - num_conditions += 1; - } - if self.creator_address.is_some() { - num_conditions += 1; - } - if self.creator_address.is_some() { - num_conditions += 1; - } - if self.grouping.is_some() { - num_conditions += 1; - } - if self.json_uri.is_some() { - num_conditions += 1; - } - if self.name.is_some() { - num_conditions += 1; - } - - num_conditions - } - pub fn conditions(&self) -> Result<(Condition, Vec), DbErr> { let mut conditions = match self.condition_type { // None --> default to all when no option is provided @@ -145,8 +82,6 @@ impl SearchAssetsQuery { Some(ConditionType::Any) => Condition::any(), }; - let mut joins = Vec::new(); - conditions = conditions .add_option( self.specification_version @@ -163,18 +98,12 @@ impl SearchAssetsQuery { .to_owned() .map(|x| asset::Column::Owner.eq(x)), ) - .add_option( - self.owner_type - .clone() - .map(|x| asset::Column::OwnerType.eq(x)), - ) .add_option( self.delegate .to_owned() .map(|x| asset::Column::Delegate.eq(x)), ) .add_option(self.frozen.map(|x| asset::Column::Frozen.eq(x))) - .add_option(self.supply.map(|x| asset::Column::Supply.eq(x))) .add_option( self.supply_mint .to_owned() @@ -198,6 +127,36 @@ impl SearchAssetsQuery { ) .add_option(self.burnt.map(|x| asset::Column::Burnt.eq(x))); + if let Some(s) = self.supply { + conditions = conditions.add(asset::Column::Supply.eq(s)); + } else { + // By default, we ignore malformed tokens by ignoring tokens with supply=0 + // unless they are burnt. + // + // cNFTs keep supply=1 after they are burnt. + // Regular NFTs go to supply=0 after they are burnt. + conditions = conditions.add( + asset::Column::Supply + .ne(0) + .or(asset::Column::Burnt.eq(true)), + ) + } + + if let Some(o) = self.owner_type.clone() { + conditions = conditions.add(asset::Column::OwnerType.eq(o)); + } else { + // Default to NFTs + // + // In theory, the owner_type=single check should be sufficient, + // however there is an old bug that has marked some non-NFTs as "single" with supply > 1. + // The supply check guarentees we do not include those. + conditions = conditions.add_option(Some( + asset::Column::OwnerType + .eq(OwnerType::Single) + .and(asset::Column::Supply.lte(1)), + )); + } + if let Some(c) = self.creator_address.to_owned() { conditions = conditions.add(asset_creators::Column::Creator.eq(c)); } @@ -209,8 +168,9 @@ impl SearchAssetsQuery { } // If creator_address or creator_verified is set, join with asset_creators + let mut joins = Vec::new(); if self.creator_address.is_some() || self.creator_verified.is_some() { - let rel = asset_creators::Relation::Asset + let rel = extensions::asset_creators::Relation::Asset .def() .rev() .on_condition(|left, right| { @@ -222,8 +182,8 @@ impl SearchAssetsQuery { } if let Some(a) = self.authority_address.to_owned() { - conditions = conditions.add(asset_authority::Column::Authority.eq(a.clone())); - let rel = asset_authority::Relation::Asset + conditions = conditions.add(asset_authority::Column::Authority.eq(a)); + let rel = extensions::asset_authority::Relation::Asset .def() .rev() .on_condition(|left, right| { @@ -239,7 +199,7 @@ impl SearchAssetsQuery { .add(asset_grouping::Column::GroupKey.eq(g.0)) .add(asset_grouping::Column::GroupValue.eq(g.1)); conditions = conditions.add(cond); - let rel = asset_grouping::Relation::Asset + let rel = extensions::asset_grouping::Relation::Asset .def() .rev() .on_condition(|left, right| { @@ -253,7 +213,7 @@ impl SearchAssetsQuery { if let Some(ju) = self.json_uri.to_owned() { let cond = Condition::all().add(asset_data::Column::MetadataUrl.eq(ju)); conditions = conditions.add(cond); - let rel = asset_data::Relation::Asset + let rel = extensions::asset_data::Relation::Asset .def() .rev() .on_condition(|left, right| { @@ -272,10 +232,10 @@ impl SearchAssetsQuery { })?; let name_expr = - SimpleExpr::Custom(format!("chain_data->>'name' LIKE '%{}%'", name_as_str).into()); + SimpleExpr::Custom(format!("chain_data->>'name' LIKE '%{}%'", name_as_str)); conditions = conditions.add(name_expr); - let rel = asset_data::Relation::Asset + let rel = extensions::asset_data::Relation::Asset .def() .rev() .on_condition(|left, right| { diff --git a/digital_asset_types/src/dao/scopes/asset.rs b/digital_asset_types/src/dao/scopes/asset.rs index da58b5d23..58e4cbbaf 100644 --- a/digital_asset_types/src/dao/scopes/asset.rs +++ b/digital_asset_types/src/dao/scopes/asset.rs @@ -1,19 +1,18 @@ use crate::{ dao::{ - asset::{self, Entity}, - asset_authority, asset_creators, asset_data, asset_grouping, cl_audits, Cursor, FullAsset, - GroupingSize, Pagination, + asset::{self}, + asset_authority, asset_creators, asset_data, asset_grouping, cl_audits_v2, + extensions::{self, instruction::PascalCase}, + sea_orm_active_enums::Instruction, + Cursor, FullAsset, GroupingSize, Pagination, }, - dapi::common::safe_select, - rpc::response::AssetList, + rpc::filter::AssetSortDirection, }; -// >>>>>>> helius-nikhil/get-sigs-for-asset - use indexmap::IndexMap; use sea_orm::{entity::*, query::*, ConnectionTrait, DbErr, Order}; use std::collections::HashMap; -pub fn paginate<'db, T, C>( +pub fn paginate( pagination: &Pagination, limit: u64, stmt: T, @@ -52,6 +51,7 @@ where stmt.limit(limit) } +#[allow(clippy::too_many_arguments)] pub async fn get_by_creator( conn: &impl ConnectionTrait, creator: Vec, @@ -63,7 +63,7 @@ pub async fn get_by_creator( show_unverified_collections: bool, ) -> Result, DbErr> { let mut condition = Condition::all() - .add(asset_creators::Column::Creator.eq(creator)) + .add(asset_creators::Column::Creator.eq(creator.clone())) .add(asset::Column::Supply.gt(0)); if only_verified { condition = condition.add(asset_creators::Column::Verified.eq(true)); @@ -71,12 +71,13 @@ pub async fn get_by_creator( get_by_related_condition( conn, condition, - asset::Relation::AssetCreators, + extensions::asset::Relation::AssetCreators, sort_by, sort_direction, pagination, limit, show_unverified_collections, + Some(creator), ) .await } @@ -102,6 +103,7 @@ pub async fn get_grouping( Ok(GroupingSize { size }) } +#[allow(clippy::too_many_arguments)] pub async fn get_by_grouping( conn: &impl ConnectionTrait, group_key: String, @@ -129,12 +131,13 @@ pub async fn get_by_grouping( Condition::all() .add(condition) .add(asset::Column::Supply.gt(0)), - asset::Relation::AssetGrouping, + extensions::asset::Relation::AssetGrouping, sort_by, sort_direction, pagination, limit, show_unverified_collections, + None, ) .await } @@ -164,7 +167,7 @@ pub async fn get_assets_by_owner( .await } -pub async fn get_asset_batch( +pub async fn get_assets( conn: &impl ConnectionTrait, asset_ids: Vec>, pagination: &Pagination, @@ -202,16 +205,18 @@ pub async fn get_by_authority( get_by_related_condition( conn, cond, - asset::Relation::AssetAuthority, + extensions::asset::Relation::AssetAuthority, sort_by, sort_direction, pagination, limit, show_unverified_collections, + None, ) .await } +#[allow(clippy::too_many_arguments)] async fn get_by_related_condition( conn: &impl ConnectionTrait, condition: Condition, @@ -221,6 +226,7 @@ async fn get_by_related_condition( pagination: &Pagination, limit: u64, show_unverified_collections: bool, + required_creator: Option>, ) -> Result, DbErr> where E: RelationTrait, @@ -238,13 +244,14 @@ where let assets = paginate(pagination, limit, stmt, sort_direction, asset::Column::Id) .all(conn) .await?; - get_related_for_assets(conn, assets, show_unverified_collections).await + get_related_for_assets(conn, assets, show_unverified_collections, required_creator).await } pub async fn get_related_for_assets( conn: &impl ConnectionTrait, assets: Vec, show_unverified_collections: bool, + required_creator: Option>, ) -> Result, DbErr> { let asset_ids = assets.iter().map(|a| a.id.clone()).collect::>(); @@ -277,29 +284,47 @@ pub async fn get_related_for_assets( acc }); let ids = assets_map.keys().cloned().collect::>(); - let authorities = asset_authority::Entity::find() - .filter(asset_authority::Column::AssetId.is_in(ids.clone())) - .order_by_asc(asset_authority::Column::AssetId) - .all(conn) - .await?; - for a in authorities.into_iter() { - if let Some(asset) = assets_map.get_mut(&a.asset_id) { - asset.authorities.push(a); - } - } + // Get all creators for all assets in `assets_map``. let creators = asset_creators::Entity::find() .filter(asset_creators::Column::AssetId.is_in(ids.clone())) .order_by_asc(asset_creators::Column::AssetId) .order_by_asc(asset_creators::Column::Position) .all(conn) .await?; + + // Add the creators to the assets in `asset_map``. for c in creators.into_iter() { if let Some(asset) = assets_map.get_mut(&c.asset_id) { asset.creators.push(c); } } + // Filter out stale creators from each asset. + for (_id, asset) in assets_map.iter_mut() { + filter_out_stale_creators(&mut asset.creators); + } + + // If we passed in a required creator, we make sure that creator is still in the creator array + // of each asset after stale creators were filtered out above. Only retain those assets that + // have the required creator. This corrects `getAssetByCreators` from returning assets for + // which the required creator is no longer in the creator array. + if let Some(required) = required_creator { + assets_map.retain(|_id, asset| asset.creators.iter().any(|c| c.creator == required)); + } + + let ids = assets_map.keys().cloned().collect::>(); + let authorities = asset_authority::Entity::find() + .filter(asset_authority::Column::AssetId.is_in(ids.clone())) + .order_by_asc(asset_authority::Column::AssetId) + .all(conn) + .await?; + for a in authorities.into_iter() { + if let Some(asset) = assets_map.get_mut(&a.asset_id) { + asset.authorities.push(a); + } + } + let cond = if show_unverified_collections { Condition::all() } else { @@ -326,6 +351,7 @@ pub async fn get_related_for_assets( Ok(assets_map.into_iter().map(|(_, v)| v).collect()) } +#[allow(clippy::too_many_arguments)] pub async fn get_assets_by_condition( conn: &impl ConnectionTrait, condition: Condition, @@ -350,7 +376,8 @@ pub async fn get_assets_by_condition( let assets = paginate(pagination, limit, stmt, sort_direction, asset::Column::Id) .all(conn) .await?; - let full_assets = get_related_for_assets(conn, assets, show_unverified_collections).await?; + let full_assets = + get_related_for_assets(conn, assets, show_unverified_collections, None).await?; Ok(full_assets) } @@ -376,11 +403,14 @@ pub async fn get_by_id( .order_by_asc(asset_authority::Column::AssetId) .all(conn) .await?; - let creators: Vec = asset_creators::Entity::find() + let mut creators: Vec = asset_creators::Entity::find() .filter(asset_creators::Column::AssetId.eq(asset.id.clone())) .order_by_asc(asset_creators::Column::Position) .all(conn) .await?; + + filter_out_stale_creators(&mut creators); + let grouping: Vec = asset_grouping::Entity::find() .filter(asset_grouping::Column::AssetId.eq(asset.id.clone())) .filter(asset_grouping::Column::GroupValue.is_not_null()) @@ -403,19 +433,59 @@ pub async fn get_by_id( }) } -pub async fn get_signatures_for_asset( +pub async fn fetch_transactions( + conn: &impl ConnectionTrait, + tree: Vec, + leaf_idx: i64, + pagination: &Pagination, + limit: u64, + sort_direction: Option, +) -> Result, DbErr> { + // Default sort direction is Desc + // Similar to GetSignaturesForAddress in the Solana API + let sort_direction = sort_direction.unwrap_or(AssetSortDirection::Desc); + let sort_order = match sort_direction { + AssetSortDirection::Asc => sea_orm::Order::Asc, + AssetSortDirection::Desc => sea_orm::Order::Desc, + }; + + let mut stmt = cl_audits_v2::Entity::find().filter(cl_audits_v2::Column::Tree.eq(tree)); + stmt = stmt.filter(cl_audits_v2::Column::LeafIdx.eq(leaf_idx)); + stmt = stmt.order_by(cl_audits_v2::Column::Seq, sort_order.clone()); + + stmt = paginate( + pagination, + limit, + stmt, + sort_order, + cl_audits_v2::Column::Seq, + ); + let transactions = stmt.all(conn).await?; + let transaction_list = transactions + .into_iter() + .map(|transaction| { + let tx = bs58::encode(transaction.tx).into_string(); + let ix = Instruction::to_pascal_case(&transaction.instruction).to_string(); + (tx, ix) + }) + .collect(); + + Ok(transaction_list) +} + +pub async fn get_asset_signatures( conn: &impl ConnectionTrait, asset_id: Option>, tree_id: Option>, leaf_idx: Option, - sort_direction: Order, pagination: &Pagination, limit: u64, -) -> Result)>, DbErr> { + sort_direction: Option, +) -> Result, DbErr> { // if tree_id and leaf_idx are provided, use them directly to fetch transactions if let (Some(tree_id), Some(leaf_idx)) = (tree_id, leaf_idx) { let transactions = - fetch_transactions(conn, tree_id, leaf_idx, sort_direction, pagination, limit).await?; + fetch_transactions(conn, tree_id, leaf_idx, pagination, limit, sort_direction).await?; return Ok(transactions); } @@ -440,41 +510,46 @@ pub async fn get_signatures_for_asset( if tree.is_empty() { return Err(DbErr::Custom("Empty tree for asset".to_string())); } - let leaf_id = asset + let leaf_idx = asset .nonce .ok_or(DbErr::RecordNotFound("Leaf ID does not exist".to_string()))?; let transactions = - fetch_transactions(conn, tree, leaf_id, sort_direction, pagination, limit).await?; + fetch_transactions(conn, tree, leaf_idx, pagination, limit, sort_direction).await?; Ok(transactions) } else { Ok(Vec::new()) } } -pub async fn fetch_transactions( - conn: &impl ConnectionTrait, - tree: Vec, - leaf_id: i64, - sort_direction: Order, - pagination: &Pagination, - limit: u64, -) -> Result)>, DbErr> { - let mut stmt = cl_audits::Entity::find().filter(cl_audits::Column::Tree.eq(tree)); - stmt = stmt.filter(cl_audits::Column::LeafIdx.eq(leaf_id)); - stmt = stmt.order_by(cl_audits::Column::CreatedAt, sea_orm::Order::Desc); +fn filter_out_stale_creators(creators: &mut Vec) { + // If the first creator is an empty Vec, it means the creator array is empty (which is allowed + // for compressed assets in Bubblegum). + if !creators.is_empty() && creators[0].creator.is_empty() { + creators.clear(); + } else { + // For both compressed and non-compressed assets, any creators that do not have the max + // `slot_updated` value are stale and should be removed. + let max_slot_updated = creators.iter().map(|creator| creator.slot_updated).max(); + if let Some(max_slot_updated) = max_slot_updated { + creators.retain(|creator| creator.slot_updated == max_slot_updated); + } - stmt = paginate( - pagination, - limit, - stmt, - sort_direction, - cl_audits::Column::Id, - ); - let transactions = stmt.all(conn).await?; - let transaction_list: Vec<(String, Option)> = transactions - .into_iter() - .map(|transaction| (transaction.tx, transaction.instruction)) - .collect(); + // For compressed assets, any creators that do not have the max `seq` value are stale and + // should be removed. A `seq` value of 0 indicates a decompressed or never-compressed + // asset. So if a `seq` value of 0 is present, then all creators with nonzero `seq` values + // are stale and should be removed. + let seq = if creators + .iter() + .map(|creator| creator.seq) + .any(|seq| seq == Some(0)) + { + Some(Some(0)) + } else { + creators.iter().map(|creator| creator.seq).max() + }; - Ok(transaction_list) + if let Some(seq) = seq { + creators.retain(|creator| creator.seq == seq); + } + } } diff --git a/digital_asset_types/src/dapi/assets_by_authority.rs b/digital_asset_types/src/dapi/assets_by_authority.rs index 774b23b3e..59404f3e0 100644 --- a/digital_asset_types/src/dapi/assets_by_authority.rs +++ b/digital_asset_types/src/dapi/assets_by_authority.rs @@ -1,7 +1,7 @@ use crate::dao::scopes; use crate::dao::PageOptions; -use crate::rpc::display_options::DisplayOptions; use crate::rpc::filter::AssetSorting; +use crate::rpc::options::Options; use crate::rpc::response::AssetList; use sea_orm::DatabaseConnection; use sea_orm::DbErr; @@ -13,9 +13,9 @@ pub async fn get_assets_by_authority( authority: Vec, sorting: AssetSorting, page_options: &PageOptions, - display_options: &DisplayOptions, + options: &Options, ) -> Result { - let pagination = create_pagination(&page_options)?; + let pagination = create_pagination(page_options)?; let (sort_direction, sort_column) = create_sorting(sorting); let assets = scopes::asset::get_by_authority( db, @@ -24,13 +24,13 @@ pub async fn get_assets_by_authority( sort_direction, &pagination, page_options.limit, - display_options.show_unverified_collections, + options.show_unverified_collections, ) .await?; Ok(build_asset_response( assets, page_options.limit, &pagination, - display_options, + options, )) } diff --git a/digital_asset_types/src/dapi/assets_by_creator.rs b/digital_asset_types/src/dapi/assets_by_creator.rs index 6df93cf26..9ce5de591 100644 --- a/digital_asset_types/src/dapi/assets_by_creator.rs +++ b/digital_asset_types/src/dapi/assets_by_creator.rs @@ -1,22 +1,23 @@ use crate::dao::scopes; use crate::dao::PageOptions; -use crate::rpc::display_options::DisplayOptions; use crate::rpc::filter::AssetSorting; +use crate::rpc::options::Options; use crate::rpc::response::AssetList; use sea_orm::DatabaseConnection; use sea_orm::DbErr; use super::common::{build_asset_response, create_pagination, create_sorting}; +#[allow(clippy::too_many_arguments)] pub async fn get_assets_by_creator( db: &DatabaseConnection, creator: Vec, only_verified: bool, sorting: AssetSorting, page_options: &PageOptions, - display_options: &DisplayOptions, + options: &Options, ) -> Result { - let pagination = create_pagination(&page_options)?; + let pagination = create_pagination(page_options)?; let (sort_direction, sort_column) = create_sorting(sorting); let assets = scopes::asset::get_by_creator( db, @@ -26,13 +27,13 @@ pub async fn get_assets_by_creator( sort_direction, &pagination, page_options.limit, - display_options.show_unverified_collections, + options.show_unverified_collections, ) .await?; Ok(build_asset_response( assets, page_options.limit, &pagination, - display_options, + options, )) } diff --git a/digital_asset_types/src/dapi/assets_by_group.rs b/digital_asset_types/src/dapi/assets_by_group.rs index 4a9472799..68784b9f4 100644 --- a/digital_asset_types/src/dapi/assets_by_group.rs +++ b/digital_asset_types/src/dapi/assets_by_group.rs @@ -1,21 +1,23 @@ use crate::dao::scopes; use crate::dao::PageOptions; -use crate::rpc::display_options::DisplayOptions; use crate::rpc::filter::AssetSorting; +use crate::rpc::options::Options; use crate::rpc::response::AssetList; use sea_orm::DatabaseConnection; use sea_orm::DbErr; use super::common::{build_asset_response, create_pagination, create_sorting}; + +#[allow(clippy::too_many_arguments)] pub async fn get_assets_by_group( db: &DatabaseConnection, group_key: String, group_value: String, sorting: AssetSorting, page_options: &PageOptions, - display_options: &DisplayOptions, + options: &Options, ) -> Result { - let pagination = create_pagination(&page_options)?; + let pagination = create_pagination(page_options)?; let (sort_direction, sort_column) = create_sorting(sorting); let assets = scopes::asset::get_by_grouping( db, @@ -25,13 +27,13 @@ pub async fn get_assets_by_group( sort_direction, &pagination, page_options.limit, - display_options.show_unverified_collections, + options.show_unverified_collections, ) .await?; Ok(build_asset_response( assets, page_options.limit, &pagination, - display_options, + options, )) } diff --git a/digital_asset_types/src/dapi/assets_by_owner.rs b/digital_asset_types/src/dapi/assets_by_owner.rs index 9e7b3bc89..c3c4da3a5 100644 --- a/digital_asset_types/src/dapi/assets_by_owner.rs +++ b/digital_asset_types/src/dapi/assets_by_owner.rs @@ -1,7 +1,7 @@ use crate::dao::scopes; use crate::dao::PageOptions; -use crate::rpc::display_options::DisplayOptions; use crate::rpc::filter::AssetSorting; +use crate::rpc::options::Options; use crate::rpc::response::AssetList; use sea_orm::DatabaseConnection; use sea_orm::DbErr; @@ -13,9 +13,9 @@ pub async fn get_assets_by_owner( owner_address: Vec, sort_by: AssetSorting, page_options: &PageOptions, - display_options: &DisplayOptions, + options: &Options, ) -> Result { - let pagination = create_pagination(&page_options)?; + let pagination = create_pagination(page_options)?; let (sort_direction, sort_column) = create_sorting(sort_by); let assets = scopes::asset::get_assets_by_owner( db, @@ -24,13 +24,13 @@ pub async fn get_assets_by_owner( sort_direction, &pagination, page_options.limit, - display_options.show_unverified_collections, + options.show_unverified_collections, ) .await?; Ok(build_asset_response( assets, page_options.limit, &pagination, - display_options, + options, )) } diff --git a/digital_asset_types/src/dapi/change_logs.rs b/digital_asset_types/src/dapi/change_logs.rs index 11e1aa5ca..7023ad12f 100644 --- a/digital_asset_types/src/dapi/change_logs.rs +++ b/digital_asset_types/src/dapi/change_logs.rs @@ -89,7 +89,7 @@ pub async fn get_proof_for_asset( Ok(asset_proof) } -pub async fn get_asset_proof_batch( +pub async fn get_asset_proofs( db: &DatabaseConnection, asset_ids: Vec>, ) -> Result, DbErr> { @@ -180,12 +180,12 @@ pub async fn get_asset_proof_batch( }) .collect(); - let leaf_info = asset_map.get(&leaf).unwrap(); + let leaf_info = asset_map.get(leaf).unwrap(); let asset_proof = build_asset_proof( leaf_info.tree_id.clone(), leaf_info.node_idx, leaf_info.hash.clone(), - &req_indexes, + req_indexes, &required_nodes, ); @@ -201,7 +201,7 @@ fn build_asset_proof( leaf_node_idx: i64, leaf_hash: Vec, req_indexes: &Vec, - required_nodes: &Vec, + required_nodes: &[SimpleChangeLog], ) -> AssetProof { let mut final_node_list = vec![SimpleChangeLog::default(); req_indexes.len()]; for node in required_nodes.iter() { @@ -252,5 +252,5 @@ pub fn get_required_nodes_for_proof(index: i64) -> Vec { idx >>= 1 } indexes.push(1); - return indexes; + indexes } diff --git a/digital_asset_types/src/dapi/common/asset.rs b/digital_asset_types/src/dapi/common/asset.rs index 007d793f9..655eefdc4 100644 --- a/digital_asset_types/src/dapi/common/asset.rs +++ b/digital_asset_types/src/dapi/common/asset.rs @@ -3,8 +3,8 @@ use crate::dao::FullAsset; use crate::dao::PageOptions; use crate::dao::Pagination; use crate::dao::{asset, asset_authority, asset_creators, asset_data, asset_grouping}; -use crate::rpc::display_options::DisplayOptions; use crate::rpc::filter::{AssetSortBy, AssetSortDirection, AssetSorting}; +use crate::rpc::options::Options; use crate::rpc::response::TransactionSignatureList; use crate::rpc::response::{AssetError, AssetList}; use crate::rpc::{ @@ -23,7 +23,7 @@ use std::path::Path; use url::Url; pub fn to_uri(uri: String) -> Option { - Url::parse(&*uri).ok() + Url::parse(&uri).ok() } pub fn get_mime(url: Url) -> Option { @@ -51,7 +51,7 @@ pub fn build_asset_response( assets: Vec, limit: u64, pagination: &Pagination, - display_options: &DisplayOptions, + options: &Options, ) -> AssetList { let total = assets.len() as u32; let (page, before, after, cursor) = match pagination { @@ -71,7 +71,7 @@ pub fn build_asset_response( } }; - let (items, errors) = asset_list_to_rpc(assets, display_options); + let (items, errors) = asset_list_to_rpc(assets, options); AssetList { total, limit: limit as u32, @@ -85,22 +85,19 @@ pub fn build_asset_response( } pub fn build_transaction_signatures_response( - items: Vec<(String, Option)>, + items: Vec<(String, String)>, limit: u64, pagination: &Pagination, ) -> TransactionSignatureList { let total = items.len() as u32; - let (page, before, after, cursor) = match pagination { + let (page, before, after) = match pagination { Pagination::Keyset { before, after } => { let bef = before.clone().and_then(|x| String::from_utf8(x).ok()); let aft = after.clone().and_then(|x| String::from_utf8(x).ok()); - (None, bef, aft, None) - } - Pagination::Page { page } => (Some(*page), None, None, None), - Pagination::Cursor(_) => { - // tmp: helius please fix it ;) - (None, None, None, None) + (None, bef, aft) } + Pagination::Page { page } => (Some(*page), None, None), + Pagination::Cursor { .. } => (None, None, None), }; TransactionSignatureList { total, @@ -108,7 +105,6 @@ pub fn build_transaction_signatures_response( page: page.map(|x| x as u32), before, after, - cursor, items, } } @@ -315,12 +311,12 @@ pub fn to_creators(creators: Vec) -> Vec { pub fn to_grouping( groups: Vec, - display_options: &DisplayOptions, + options: &Options, ) -> Result, DbErr> { let result: Vec = groups .iter() .filter_map(|model| { - let verified = match display_options.show_unverified_collections { + let verified = match options.show_unverified_collections { // Null verified indicates legacy data, meaning it is verified. true => Some(model.verified), false => None, @@ -352,7 +348,7 @@ pub fn get_interface(asset: &asset::Model) -> Result { } //TODO -> impl custom error type -pub fn asset_to_rpc(asset: FullAsset, display_options: &DisplayOptions) -> Result { +pub fn asset_to_rpc(asset: FullAsset, options: &Options) -> Result { let FullAsset { asset, data, @@ -362,7 +358,7 @@ pub fn asset_to_rpc(asset: FullAsset, display_options: &DisplayOptions) -> Resul } = asset; let rpc_authorities = to_authority(authorities); let rpc_creators = to_creators(creators); - let rpc_groups = to_grouping(groups, display_options)?; + let rpc_groups = to_grouping(groups, options)?; let interface = get_interface(&asset)?; let content = get_content(&asset, &data)?; let mut chain_data_selector_fn = jsonpath_lib::selector(&data.chain_data); @@ -381,8 +377,8 @@ pub fn asset_to_rpc(asset: FullAsset, display_options: &DisplayOptions) -> Resul compression: Some(Compression { eligible: asset.compressible, compressed: asset.compressed, - leaf_id: asset.nonce.unwrap_or(0 as i64), - seq: asset.seq.unwrap_or(0 as i64), + leaf_id: asset.nonce.unwrap_or(0), + seq: asset.seq.unwrap_or(0), tree: asset .tree_id .map(|s| bs58::encode(s).into_string()) @@ -393,11 +389,11 @@ pub fn asset_to_rpc(asset: FullAsset, display_options: &DisplayOptions) -> Resul .unwrap_or_default(), data_hash: asset .data_hash - .map(|e| e.trim().to_string()) + .map(|e| if asset.compressed { e.trim() } else { "" }.to_string()) .unwrap_or_default(), creator_hash: asset .creator_hash - .map(|e| e.trim().to_string()) + .map(|e| if asset.compressed { e.trim() } else { "" }.to_string()) .unwrap_or_default(), }), grouping: Some(rpc_groups), @@ -444,13 +440,13 @@ pub fn asset_to_rpc(asset: FullAsset, display_options: &DisplayOptions) -> Resul pub fn asset_list_to_rpc( asset_list: Vec, - display_options: &DisplayOptions, + options: &Options, ) -> (Vec, Vec) { asset_list .into_iter() .fold((vec![], vec![]), |(mut assets, mut errors), asset| { let id = bs58::encode(asset.asset.id.clone()).into_string(); - match asset_to_rpc(asset, display_options) { + match asset_to_rpc(asset, options) { Ok(rpc_asset) => assets.push(rpc_asset), Err(e) => errors.push(AssetError { id, diff --git a/digital_asset_types/src/dapi/get_asset.rs b/digital_asset_types/src/dapi/get_asset.rs index 6056d56eb..3740562c3 100644 --- a/digital_asset_types/src/dapi/get_asset.rs +++ b/digital_asset_types/src/dapi/get_asset.rs @@ -1,7 +1,7 @@ use super::common::{asset_to_rpc, build_asset_response}; use crate::{ dao::{scopes, Pagination}, - rpc::{display_options::DisplayOptions, Asset}, + rpc::{options::Options, Asset}, }; use sea_orm::{DatabaseConnection, DbErr}; use std::collections::HashMap; @@ -9,21 +9,21 @@ use std::collections::HashMap; pub async fn get_asset( db: &DatabaseConnection, id: Vec, - display_options: &DisplayOptions, + options: &Options, ) -> Result { let asset = scopes::asset::get_by_id(db, id, false).await?; - asset_to_rpc(asset, display_options) + asset_to_rpc(asset, options) } -pub async fn get_asset_batch( +pub async fn get_assets( db: &DatabaseConnection, ids: Vec>, limit: u64, - display_options: &DisplayOptions, + options: &Options, ) -> Result, DbErr> { let pagination = Pagination::Page { page: 1 }; - let assets = scopes::asset::get_asset_batch(db, ids, &pagination, limit).await?; - let asset_list = build_asset_response(assets, limit, &pagination, display_options); + let assets = scopes::asset::get_assets(db, ids, &pagination, limit).await?; + let asset_list = build_asset_response(assets, limit, &pagination, options); let asset_map = asset_list .items .into_iter() diff --git a/digital_asset_types/src/dapi/get_asset_signatures.rs b/digital_asset_types/src/dapi/get_asset_signatures.rs new file mode 100644 index 000000000..79250d911 --- /dev/null +++ b/digital_asset_types/src/dapi/get_asset_signatures.rs @@ -0,0 +1,35 @@ +use crate::dao::scopes; +use crate::dao::PageOptions; + +use crate::rpc::filter::AssetSortDirection; +use crate::rpc::response::TransactionSignatureList; +use sea_orm::DatabaseConnection; +use sea_orm::DbErr; + +use super::common::{build_transaction_signatures_response, create_pagination}; + +pub async fn get_asset_signatures( + db: &DatabaseConnection, + asset_id: Option>, + tree: Option>, + leaf_idx: Option, + page_options: PageOptions, + sort_direction: Option, +) -> Result { + let pagination = create_pagination(&page_options)?; + let transactions = scopes::asset::get_asset_signatures( + db, + asset_id, + tree, + leaf_idx, + &pagination, + page_options.limit, + sort_direction, + ) + .await?; + Ok(build_transaction_signatures_response( + transactions, + page_options.limit, + &pagination, + )) +} diff --git a/digital_asset_types/src/dapi/mod.rs b/digital_asset_types/src/dapi/mod.rs index 56591cfa4..e9481169a 100644 --- a/digital_asset_types/src/dapi/mod.rs +++ b/digital_asset_types/src/dapi/mod.rs @@ -3,15 +3,17 @@ mod assets_by_creator; mod assets_by_group; mod assets_by_owner; mod change_logs; -pub mod common; mod get_asset; +mod get_asset_signatures; mod search_assets; -mod signatures_for_asset; + +pub mod common; + pub use assets_by_authority::*; pub use assets_by_creator::*; pub use assets_by_group::*; pub use assets_by_owner::*; pub use change_logs::*; pub use get_asset::*; +pub use get_asset_signatures::*; pub use search_assets::*; -pub use signatures_for_asset::*; \ No newline at end of file diff --git a/digital_asset_types/src/dapi/search_assets.rs b/digital_asset_types/src/dapi/search_assets.rs index cd467ab8b..a7ee65509 100644 --- a/digital_asset_types/src/dapi/search_assets.rs +++ b/digital_asset_types/src/dapi/search_assets.rs @@ -1,7 +1,7 @@ use super::common::{build_asset_response, create_pagination, create_sorting}; use crate::{ dao::{scopes, PageOptions, SearchAssetsQuery}, - rpc::{display_options::DisplayOptions, filter::AssetSorting, response::AssetList}, + rpc::{filter::AssetSorting, options::Options, response::AssetList}, }; use sea_orm::{DatabaseConnection, DbErr}; @@ -10,9 +10,9 @@ pub async fn search_assets( search_assets_query: SearchAssetsQuery, sorting: AssetSorting, page_options: &PageOptions, - display_options: &DisplayOptions, + options: &Options, ) -> Result { - let pagination = create_pagination(&page_options)?; + let pagination = create_pagination(page_options)?; let (sort_direction, sort_column) = create_sorting(sorting); let (condition, joins) = search_assets_query.conditions()?; let assets = scopes::asset::get_assets_by_condition( @@ -23,13 +23,13 @@ pub async fn search_assets( sort_direction, &pagination, page_options.limit, - display_options.show_unverified_collections, + options.show_unverified_collections, ) .await?; Ok(build_asset_response( assets, page_options.limit, &pagination, - display_options, + options, )) } diff --git a/digital_asset_types/src/rpc/asset.rs b/digital_asset_types/src/rpc/asset.rs index cfbb02d40..415b63672 100644 --- a/digital_asset_types/src/rpc/asset.rs +++ b/digital_asset_types/src/rpc/asset.rs @@ -27,6 +27,8 @@ pub enum Interface { #[serde(rename = "V1_PRINT")] V1PRINT, #[serde(rename = "LEGACY_NFT")] + // TODO: change on version bump + #[allow(non_camel_case_types)] LEGACY_NFT, #[serde(rename = "V2_NFT")] Nft, @@ -56,9 +58,9 @@ impl From<(&SpecificationVersions, &SpecificationAssetClass)> for Interface { } } -impl Into<(SpecificationVersions, SpecificationAssetClass)> for Interface { - fn into(self) -> (SpecificationVersions, SpecificationAssetClass) { - match self { +impl From for (SpecificationVersions, SpecificationAssetClass) { + fn from(interface: Interface) -> (SpecificationVersions, SpecificationAssetClass) { + match interface { Interface::V1NFT => (SpecificationVersions::V1, SpecificationAssetClass::Nft), Interface::LEGACY_NFT => (SpecificationVersions::V0, SpecificationAssetClass::Nft), Interface::ProgrammableNFT => ( @@ -115,15 +117,15 @@ pub struct File { pub type Files = Vec; -#[derive(PartialEq, Eq, Debug, Clone, Deserialize, Serialize, JsonSchema)] +#[derive(Debug, Default, Clone, PartialEq, Eq, Deserialize, Serialize, JsonSchema)] pub struct MetadataMap(BTreeMap); impl MetadataMap { - pub fn new() -> Self { + pub const fn new() -> Self { Self(BTreeMap::new()) } - pub fn inner(&self) -> &BTreeMap { + pub const fn inner(&self) -> &BTreeMap { &self.0 } diff --git a/digital_asset_types/src/rpc/filter.rs b/digital_asset_types/src/rpc/filter.rs index 0de5574b7..a471f21fb 100644 --- a/digital_asset_types/src/rpc/filter.rs +++ b/digital_asset_types/src/rpc/filter.rs @@ -1,9 +1,8 @@ use schemars::JsonSchema; use serde::{Deserialize, Serialize}; -#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)] #[serde(rename_all = "camelCase")] - pub struct AssetSorting { pub sort_by: AssetSortBy, pub sort_direction: Option, @@ -12,13 +11,13 @@ pub struct AssetSorting { impl Default for AssetSorting { fn default() -> AssetSorting { AssetSorting { - sort_by: AssetSortBy::Created, + sort_by: AssetSortBy::Id, sort_direction: Some(AssetSortDirection::default()), } } } -#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)] +#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)] pub enum AssetSortBy { #[serde(rename = "id")] Id, @@ -32,21 +31,16 @@ pub enum AssetSortBy { None, } -#[derive(Debug, Clone, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)] +#[derive(Debug, Default, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize, JsonSchema)] pub enum AssetSortDirection { #[serde(rename = "asc")] Asc, #[serde(rename = "desc")] + #[default] Desc, } -impl Default for AssetSortDirection { - fn default() -> AssetSortDirection { - AssetSortDirection::Desc - } -} - -#[derive(Serialize, Deserialize, Clone, Debug, Eq, PartialEq, JsonSchema)] +#[derive(Serialize, Deserialize, Clone, Copy, Debug, Eq, PartialEq, JsonSchema)] pub enum SearchConditionType { #[serde(rename = "all")] All, diff --git a/digital_asset_types/src/rpc/mod.rs b/digital_asset_types/src/rpc/mod.rs index a27a904b5..37fb7d9f9 100644 --- a/digital_asset_types/src/rpc/mod.rs +++ b/digital_asset_types/src/rpc/mod.rs @@ -1,7 +1,7 @@ mod asset; -pub mod display_options; pub mod filter; +pub mod options; pub mod response; pub use asset::*; diff --git a/digital_asset_types/src/rpc/options.rs b/digital_asset_types/src/rpc/options.rs new file mode 100644 index 000000000..a1fafa2c4 --- /dev/null +++ b/digital_asset_types/src/rpc/options.rs @@ -0,0 +1,9 @@ +use schemars::JsonSchema; +use serde::{Deserialize, Serialize}; + +#[derive(Serialize, Deserialize, Clone, Debug, Eq, PartialEq, JsonSchema, Default)] +#[serde(deny_unknown_fields, rename_all = "camelCase")] +pub struct Options { + #[serde(default)] + pub show_unverified_collections: bool, +} diff --git a/digital_asset_types/src/rpc/response.rs b/digital_asset_types/src/rpc/response.rs index 2fe0bc6ae..53076c8b2 100644 --- a/digital_asset_types/src/rpc/response.rs +++ b/digital_asset_types/src/rpc/response.rs @@ -48,7 +48,5 @@ pub struct TransactionSignatureList { pub before: Option, #[serde(skip_serializing_if = "Option::is_none")] pub after: Option, - #[serde(skip_serializing_if = "Option::is_none")] - pub cursor: Option, - pub items: Vec<(String, Option)>, + pub items: Vec<(String, String)>, } diff --git a/digital_asset_types/tests/common.rs b/digital_asset_types/tests/common.rs index d4df10742..e486ef289 100644 --- a/digital_asset_types/tests/common.rs +++ b/digital_asset_types/tests/common.rs @@ -85,6 +85,7 @@ pub fn create_asset_data( reindex: None, raw_name: Some(metadata.name.into_bytes().to_vec().clone()), raw_symbol: Some(metadata.symbol.into_bytes().to_vec().clone()), + base_info_seq: Some(0), }, ) } @@ -155,8 +156,8 @@ pub fn create_asset( alt_id: None, creator_hash: None, owner_delegate_seq: Some(0), - was_decompressed: false, leaf_seq: Some(0), + base_info_seq: Some(0), }, ) } diff --git a/digital_asset_types/tests/get_asset_by_id.rs b/digital_asset_types/tests/get_asset_by_id.rs index 3a5bf14c6..f20b443d9 100644 --- a/digital_asset_types/tests/get_asset_by_id.rs +++ b/digital_asset_types/tests/get_asset_by_id.rs @@ -33,8 +33,7 @@ async fn get_asset_by_id() -> Result<(), DbErr> { address: creator_1, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; diff --git a/digital_asset_types/tests/get_assets_by_authority.rs b/digital_asset_types/tests/get_assets_by_authority.rs index 921bf7176..5796c6c55 100644 --- a/digital_asset_types/tests/get_assets_by_authority.rs +++ b/digital_asset_types/tests/get_assets_by_authority.rs @@ -44,8 +44,7 @@ async fn get_assets_by_owner() -> Result<(), DbErr> { address: creator_1, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -97,8 +96,7 @@ async fn get_assets_by_owner() -> Result<(), DbErr> { address: creator_2, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -157,8 +155,7 @@ async fn get_assets_by_owner() -> Result<(), DbErr> { share: 90, verified: true, }, - ] - .to_vec(), + ], seller_fee_basis_points: 100, }; diff --git a/digital_asset_types/tests/get_assets_by_creator.rs b/digital_asset_types/tests/get_assets_by_creator.rs index c282be6ad..6bcf85c9c 100644 --- a/digital_asset_types/tests/get_assets_by_creator.rs +++ b/digital_asset_types/tests/get_assets_by_creator.rs @@ -47,8 +47,7 @@ async fn get_assets_by_creator() -> Result<(), DbErr> { address: creator_1, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -100,8 +99,7 @@ async fn get_assets_by_creator() -> Result<(), DbErr> { address: creator_2, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -160,8 +158,7 @@ async fn get_assets_by_creator() -> Result<(), DbErr> { share: 90, verified: true, }, - ] - .to_vec(), + ], seller_fee_basis_points: 100, }; diff --git a/digital_asset_types/tests/get_assets_by_group.rs b/digital_asset_types/tests/get_assets_by_group.rs index 7788a1041..b8bdb35ad 100644 --- a/digital_asset_types/tests/get_assets_by_group.rs +++ b/digital_asset_types/tests/get_assets_by_group.rs @@ -49,8 +49,7 @@ async fn get_assets_by_group() -> Result<(), DbErr> { address: creator_1, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -102,8 +101,7 @@ async fn get_assets_by_group() -> Result<(), DbErr> { address: creator_2, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -164,8 +162,7 @@ async fn get_assets_by_group() -> Result<(), DbErr> { share: 90, verified: true, }, - ] - .to_vec(), + ], seller_fee_basis_points: 100, }; diff --git a/digital_asset_types/tests/get_assets_by_owner.rs b/digital_asset_types/tests/get_assets_by_owner.rs index 921bf7176..5796c6c55 100644 --- a/digital_asset_types/tests/get_assets_by_owner.rs +++ b/digital_asset_types/tests/get_assets_by_owner.rs @@ -44,8 +44,7 @@ async fn get_assets_by_owner() -> Result<(), DbErr> { address: creator_1, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -97,8 +96,7 @@ async fn get_assets_by_owner() -> Result<(), DbErr> { address: creator_2, share: 100, verified: true, - }] - .to_vec(), + }], seller_fee_basis_points: 100, }; @@ -157,8 +155,7 @@ async fn get_assets_by_owner() -> Result<(), DbErr> { share: 90, verified: true, }, - ] - .to_vec(), + ], seller_fee_basis_points: 100, }; diff --git a/digital_asset_types/tests/json_parsing.rs b/digital_asset_types/tests/json_parsing.rs index fcb133052..571bfc199 100644 --- a/digital_asset_types/tests/json_parsing.rs +++ b/digital_asset_types/tests/json_parsing.rs @@ -36,6 +36,7 @@ pub async fn parse_onchain_json(json: serde_json::Value) -> Content { reindex: None, raw_name: Some(String::from("Handalf").into_bytes().to_vec()), raw_symbol: Some(String::from("").into_bytes().to_vec()), + base_info_seq: Some(0), }; v1_content_from_json(&asset_data).unwrap() @@ -79,7 +80,6 @@ async fn simple_content() { ); assert_eq!( parsed - .clone() .links .unwrap() .get("external_url") @@ -130,7 +130,6 @@ async fn complex_content() { ); assert_eq!( parsed - .clone() .links .unwrap() .get("animation_url") diff --git a/metadata_json/Cargo.toml b/metadata_json/Cargo.toml index 325987dd0..39c5d3826 100644 --- a/metadata_json/Cargo.toml +++ b/metadata_json/Cargo.toml @@ -1,7 +1,9 @@ [package] name = "das-metadata-json" -version = "0.1.0" -edition = "2021" +version = { workspace = true } +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [lib] @@ -11,56 +13,56 @@ name = "das-metadata-json" [dependencies] +anyhow = { workspace = true } backon = "0.4.1" -log = "0.4.17" -env_logger = "0.10.0" -anyhow = "1.0.75" -derive_more = "0.99.17" -redis = { version = "0.22.3", features = [ +bs58 = { workspace = true } +cadence = { workspace = true } +cadence-macros = { workspace = true } +chrono = { workspace = true } +clap = { workspace = true, features = ["derive", "cargo", "env"] } +das-tree-backfiller = { workspace = true } +digital_asset_types = { workspace = true, features = [ + "json_types", + "sql_types", +] } +derive_more = { version = "0.99.17" } +env_logger = { workspace = true } +figment = { workspace = true, features = ["env", "toml", "yaml"] } +futures = { workspace = true } +indicatif = "0.17.5" +log = { workspace = true } +plerkle_messenger = { workspace = true, features = ['redis'] } +rand = { workspace = true } +redis = { workspace = true, features = [ "aio", "tokio-comp", "streams", "tokio-native-tls-comp", ] } -futures = { version = "0.3.25" } -indicatif = "0.17.5" -thiserror = "1.0.31" -serde_json = "1.0.81" -das-tree-backfiller = { path = "../tree_backfiller" } -tokio = { version = "1.26.0", features = ["full", "tracing"] } -sqlx = { version = "0.6.2", features = [ - "macros", - "runtime-tokio-rustls", - "postgres", - "uuid", - "offline", - "json", -] } -sea-orm = { version = "0.10.6", features = [ +reqwest = { workspace = true } +sea-orm = { workspace = true, features = [ "macros", "runtime-tokio-rustls", "sqlx-postgres", "with-chrono", "mock", ] } -sea-query = { version = "0.28.1", features = ["postgres-array"] } -chrono = "0.4.19" -cadence = "0.29.0" -cadence-macros = "0.29.0" -tokio-postgres = "0.7.7" -serde = "1.0.136" -bs58 = "0.4.0" -reqwest = "0.11.11" -plerkle_messenger = { version = "1.6.0", features = ['redis'] } -digital_asset_types = { path = "../digital_asset_types", features = [ - "json_types", - "sql_types", +sea-query = { workspace = true, features = ["postgres-array"] } +serde = { workspace = true } +serde_json = { workspace = true } +sqlx = { workspace = true, features = [ + "macros", + "runtime-tokio-rustls", + "postgres", + "uuid", + "offline", + "json", ] } -figment = { version = "0.10.6", features = ["env", "toml", "yaml"] } -rand = "0.8.5" -url = "2.3.1" -tokio-stream = "0.1.12" -clap = { version = "4.2.2", features = ["derive", "cargo", "env"] } +thiserror = { workspace = true } +tokio = { workspace = true, features = ["full", "tracing"] } +tokio-postgres = { workspace = true } +tokio-stream = { workspace = true } +url = { workspace = true } [lints] workspace = true diff --git a/metadata_json/src/stream/mod.rs b/metadata_json/src/stream/mod.rs index cebe18ccc..d4de571e6 100644 --- a/metadata_json/src/stream/mod.rs +++ b/metadata_json/src/stream/mod.rs @@ -2,6 +2,5 @@ pub mod receiver; pub mod sender; pub use receiver::*; -pub use sender::*; -pub const METADATA_JSON_STREAM: &'static str = "METADATA_JSON"; +pub const METADATA_JSON_STREAM: &str = "METADATA_JSON"; diff --git a/metadata_json/src/stream/receiver.rs b/metadata_json/src/stream/receiver.rs index ff17556c5..3b3d53037 100644 --- a/metadata_json/src/stream/receiver.rs +++ b/metadata_json/src/stream/receiver.rs @@ -3,7 +3,8 @@ use clap::Parser; use figment::value::{Dict, Value}; use plerkle_messenger::{select_messenger, Messenger, MessengerConfig, MessengerType, RecvData}; use rand::{distributions::Alphanumeric, thread_rng, Rng}; -use std::sync::{Arc, Mutex}; +use std::sync::Arc; +use tokio::sync::Mutex; #[derive(Clone, Debug, Parser)] pub struct ReceiverArgs { @@ -48,8 +49,6 @@ impl From for MessengerConfig { #[derive(thiserror::Error, Debug)] pub enum ReceiverError { - #[error("unable to acquire mutex lock")] - Lock, #[error("messenger: {0}")] Messenger(#[from] plerkle_messenger::MessengerError), } @@ -70,7 +69,7 @@ impl Receiver { } pub async fn recv(&self) -> Result, ReceiverError> { - let mut messenger = self.0.lock().map_err(|_| ReceiverError::Lock)?; + let mut messenger = self.0.lock().await; messenger .recv( @@ -82,7 +81,7 @@ impl Receiver { } pub async fn ack(&self, ids: &[String]) -> Result<(), ReceiverError> { - let mut messenger = self.0.lock().map_err(|_| ReceiverError::Lock)?; + let mut messenger = self.0.lock().await; messenger .ack_msg(METADATA_JSON_STREAM, ids) diff --git a/metadata_json/src/worker.rs b/metadata_json/src/worker.rs index 741a9af65..3c9eb732b 100644 --- a/metadata_json/src/worker.rs +++ b/metadata_json/src/worker.rs @@ -64,7 +64,7 @@ impl Worker { handlers.push(spawn_task(client, pool, asset_data)); } - while let Some(_) = handlers.next().await {} + while handlers.next().await.is_some() {} }); (tx, handle) @@ -198,11 +198,11 @@ async fn fetch_metadata_json( .map(StatusCode::Code) .unwrap_or(StatusCode::Unknown); - return Err(FetchMetadataJsonError::Response { + Err(FetchMetadataJsonError::Response { source, url, status, - }); + }) } } }) diff --git a/metaplex-rpc-proxy/Cargo.lock b/metaplex-rpc-proxy/Cargo.lock deleted file mode 100644 index a9632d483..000000000 --- a/metaplex-rpc-proxy/Cargo.lock +++ /dev/null @@ -1,234 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "ahash" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" -dependencies = [ - "getrandom", - "once_cell", - "version_check", -] - -[[package]] -name = "aho-corasick" -version = "0.7.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4f55bd91a0978cbfd91c457a164bab8b4001c833b7f323132c0a4e1922dd44e" -dependencies = [ - "memchr", -] - -[[package]] -name = "bumpalo" -version = "3.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "572f695136211188308f16ad2ca5c851a712c464060ae6974944458eb83880ba" - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "getrandom" -version = "0.2.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c05aeb6a22b8f62540c194aac980f2115af067bfe15a0734d7277a768d396b31" -dependencies = [ - "cfg-if", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" -dependencies = [ - "ahash", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.136" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55edcf6c0bb319052dea84732cf99db461780fd5e8d3eb46ab6ff312ab31f197" - -[[package]] -name = "log" -version = "0.4.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "memchr" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2dffe52ecf27772e601905b7522cb4ef790d2cc203488bbd0e2fe85fcb74566d" - -[[package]] -name = "metaplex-rpc-proxy" -version = "0.6.8" -dependencies = [ - "lazy_static", - "log", - "proxy-wasm", - "regex", - "wasi 0.7.0", - "wasm-bindgen", -] - -[[package]] -name = "once_cell" -version = "1.15.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e82dad04139b71a90c080c8463fe0dc7902db5192d939bd0950f074d014339e1" - -[[package]] -name = "proc-macro2" -version = "1.0.66" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18fb31db3f9bddb2ea821cde30a9f70117e3f119938b5ee630b7403aa6e2ead9" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "proxy-wasm" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3927081c2674366adadef4d5c5d34c4d849ab764a17bfe4ff2bd04436efb593d" -dependencies = [ - "hashbrown", - "log", -] - -[[package]] -name = "quote" -version = "1.0.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbe448f377a7d6961e30f5955f9b8d106c3f5e449d493ee1b125c1d43c2b5179" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "regex" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c4eb3267174b8c6c2f654116623910a0fef09c4753f8dd83db29c48a0df988b" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax", -] - -[[package]] -name = "regex-syntax" -version = "0.6.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3f87b73ce11b1619a3c6332f45341e0047173771e8b8b73f87bfeefb7b56244" - -[[package]] -name = "syn" -version = "1.0.103" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a864042229133ada95abf3b54fdc62ef5ccabe9515b64717bcb9a1919e59445d" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "unicode-ident" -version = "1.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ceab39d59e4c9499d4e5a8ee0e2735b891bb7308ac83dfb4e80cad195c9f6f3" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "wasi" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b89c3ce4ce14bdc6fb6beaf9ec7928ca331de5df7e5ea278375642a2f478570d" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaf9f5aceeec8be17c128b2e93e031fb8a4d469bb9c4ae2d7dc1888b26887268" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8ffb332579b0557b52d268b91feab8df3615f265d5270fec2a8c95b17c1142" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "052be0f94026e6cbc75cdefc9bae13fd6052cdcaf532fa6c45e7ae33a1e6c810" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07bc0c051dc5f23e307b13285f9d75df86bfdf816c5721e573dec1f9b8aa193c" -dependencies = [ - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c38c045535d93ec4f0b4defec448e4291638ee608530863b1e2ba115d4fff7f" diff --git a/metaplex-rpc-proxy/Cargo.toml b/metaplex-rpc-proxy/Cargo.toml index f48977d96..2e69785dd 100644 --- a/metaplex-rpc-proxy/Cargo.toml +++ b/metaplex-rpc-proxy/Cargo.toml @@ -1,16 +1,20 @@ [package] name = "metaplex-rpc-proxy" version = "0.6.8" -edition = "2021" -publish = false +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [lib] crate-type = ["cdylib"] [dependencies] -proxy-wasm = "0.2.0" -wasm-bindgen = "0.2.83" -lazy_static = "1.4.0" -regex = "1.6.0" -log = "0.4.17" -wasi = "0.7.0" +lazy_static = { workspace = true } +log = { workspace = true } +proxy-wasm = { workspace = true } +regex = { workspace = true } +wasi = { workspace = true } +wasm-bindgen = { workspace = true } + +[lints] +workspace = true diff --git a/metaplex-rpc-proxy/src/lib.rs b/metaplex-rpc-proxy/src/lib.rs index 625ffa460..24f60437e 100644 --- a/metaplex-rpc-proxy/src/lib.rs +++ b/metaplex-rpc-proxy/src/lib.rs @@ -3,7 +3,6 @@ use log::info; use proxy_wasm::traits::*; use proxy_wasm::types::*; use regex::{Regex, RegexBuilder}; -use std::env; use std::time::Duration; proxy_wasm::main! {{ @@ -35,9 +34,9 @@ struct RpcProxy { impl RpcProxy { fn new(path: Option) -> Self { - return Self { + Self { rpc_url_path: path.unwrap_or("/".to_string()), - }; + } } } @@ -103,7 +102,7 @@ impl HttpContext for RpcProxy { } else { let res = upstream_rpc_call(self, body); return match res { - Ok(res) => Action::Pause, + Ok(_) => Action::Pause, Err(e) => { info!("Error: {:?}", e); Action::Continue diff --git a/migration/Cargo.lock b/migration/Cargo.lock deleted file mode 100644 index 172118165..000000000 --- a/migration/Cargo.lock +++ /dev/null @@ -1,5767 +0,0 @@ -# This file is automatically @generated by Cargo. -# It is not intended for manual editing. -version = 3 - -[[package]] -name = "Inflector" -version = "0.11.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe438c63458706e03479442743baae6c88256498e6431708f6dfc520a26515d3" -dependencies = [ - "lazy_static", - "regex", -] - -[[package]] -name = "addr2line" -version = "0.21.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a30b2e23b9e17a9f90641c7ab1549cd9b44f296d3ccbf309d2863cfe398a0cb" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - -[[package]] -name = "aead" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b613b8e1e3cf911a086f53f03bf286f52fd7a7258e4fa606f0ef220d39d8877" -dependencies = [ - "generic-array", -] - -[[package]] -name = "aes" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e8b47f52ea9bae42228d07ec09eb676433d7c4ed1ebdf0f1d1c29ed446f1ab8" -dependencies = [ - "cfg-if", - "cipher", - "cpufeatures", - "opaque-debug", -] - -[[package]] -name = "aes-gcm-siv" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "589c637f0e68c877bbd59a4599bbe849cac8e5f3e4b5a3ebae8f528cd218dcdc" -dependencies = [ - "aead", - "aes", - "cipher", - "ctr", - "polyval", - "subtle", - "zeroize", -] - -[[package]] -name = "ahash" -version = "0.7.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" -dependencies = [ - "getrandom 0.2.10", - "once_cell", - "version_check", -] - -[[package]] -name = "ahash" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" -dependencies = [ - "cfg-if", - "getrandom 0.2.10", - "once_cell", - "version_check", -] - -[[package]] -name = "aho-corasick" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" -dependencies = [ - "memchr", -] - -[[package]] -name = "aliasable" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "250f629c0161ad8107cf89319e990051fae62832fd343083bea452d93e2205fd" - -[[package]] -name = "alloc-no-stdlib" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7bb162ec39d46ab1ca8c77bf72e890535becd1751bb45f64c597edb4c8c6b3" - -[[package]] -name = "alloc-stdlib" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94fb8275041c72129eb51b7d0322c29b8387a0386127718b096429201a5d6ece" -dependencies = [ - "alloc-no-stdlib", -] - -[[package]] -name = "allocator-api2" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" - -[[package]] -name = "anchor-attribute-access-control" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "faa5be5b72abea167f87c868379ba3c2be356bfca9e6f474fd055fa0f7eeb4f2" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "regex", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-account" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f468970344c7c9f9d03b4da854fd7c54f21305059f53789d0045c1dd803f0018" -dependencies = [ - "anchor-syn", - "anyhow", - "bs58 0.5.0", - "proc-macro2", - "quote", - "rustversion", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-constant" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59948e7f9ef8144c2aefb3f32a40c5fce2798baeec765ba038389e82301017ef" -dependencies = [ - "anchor-syn", - "proc-macro2", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-error" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fc753c9d1c7981cb8948cf7e162fb0f64558999c0413058e2d43df1df5448086" -dependencies = [ - "anchor-syn", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-event" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f38b4e172ba1b52078f53fdc9f11e3dc0668ad27997838a0aad2d148afac8c97" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-attribute-program" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4eebd21543606ab61e2d83d9da37d24d3886a49f390f9c43a1964735e8c0f0d5" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-derive-accounts" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec4720d899b3686396cced9508f23dab420f1308344456ec78ef76f98fda42af" -dependencies = [ - "anchor-syn", - "anyhow", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-derive-space" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f495e85480bd96ddeb77b71d499247c7d4e8b501e75ecb234e9ef7ae7bd6552a" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "anchor-lang" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d2d4b20100f1310a774aba3471ef268e5c4ba4d5c28c0bbe663c2658acbc414" -dependencies = [ - "anchor-attribute-access-control", - "anchor-attribute-account", - "anchor-attribute-constant", - "anchor-attribute-error", - "anchor-attribute-event", - "anchor-attribute-program", - "anchor-derive-accounts", - "anchor-derive-space", - "arrayref", - "base64 0.13.1", - "bincode", - "borsh 0.10.3", - "bytemuck", - "getrandom 0.2.10", - "solana-program", - "thiserror", -] - -[[package]] -name = "anchor-syn" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a125e4b0cc046cfec58f5aa25038e34cf440151d58f0db3afc55308251fe936d" -dependencies = [ - "anyhow", - "bs58 0.5.0", - "heck 0.3.3", - "proc-macro2", - "quote", - "serde", - "serde_json", - "sha2 0.10.8", - "syn 1.0.109", - "thiserror", -] - -[[package]] -name = "android-tzdata" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e999941b234f3131b00bc13c22d06e8c5ff726d1b6318ac7eb276997bbb4fef0" - -[[package]] -name = "android_system_properties" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "819e7219dbd41043ac279b19830f2efc897156490d7fd6ea916720117ee66311" -dependencies = [ - "libc", -] - -[[package]] -name = "anyhow" -version = "1.0.75" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4668cab20f66d8d020e1fbc0ebe47217433c1b6c8f2040faf858554e394ace6" - -[[package]] -name = "ark-bn254" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a22f4561524cd949590d78d7d4c5df8f592430d221f7f3c9497bbafd8972120f" -dependencies = [ - "ark-ec", - "ark-ff", - "ark-std", -] - -[[package]] -name = "ark-ec" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "defd9a439d56ac24968cca0571f598a61bc8c55f71d50a89cda591cb750670ba" -dependencies = [ - "ark-ff", - "ark-poly", - "ark-serialize", - "ark-std", - "derivative", - "hashbrown 0.13.2", - "itertools 0.10.5", - "num-traits", - "zeroize", -] - -[[package]] -name = "ark-ff" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec847af850f44ad29048935519032c33da8aa03340876d351dfab5660d2966ba" -dependencies = [ - "ark-ff-asm", - "ark-ff-macros", - "ark-serialize", - "ark-std", - "derivative", - "digest 0.10.7", - "itertools 0.10.5", - "num-bigint 0.4.4", - "num-traits", - "paste", - "rustc_version", - "zeroize", -] - -[[package]] -name = "ark-ff-asm" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ed4aa4fe255d0bc6d79373f7e31d2ea147bcf486cba1be5ba7ea85abdb92348" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-ff-macros" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" -dependencies = [ - "num-bigint 0.4.4", - "num-traits", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-poly" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d320bfc44ee185d899ccbadfa8bc31aab923ce1558716e1997a1e74057fe86bf" -dependencies = [ - "ark-ff", - "ark-serialize", - "ark-std", - "derivative", - "hashbrown 0.13.2", -] - -[[package]] -name = "ark-serialize" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adb7b85a02b83d2f22f89bd5cac66c9c89474240cb6207cb1efc16d098e822a5" -dependencies = [ - "ark-serialize-derive", - "ark-std", - "digest 0.10.7", - "num-bigint 0.4.4", -] - -[[package]] -name = "ark-serialize-derive" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae3281bc6d0fd7e549af32b52511e1302185bd688fd3359fa36423346ff682ea" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "ark-std" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94893f1e0c6eeab764ade8dc4c0db24caf4fe7cbbaafc0eba0a9030f447b5185" -dependencies = [ - "num-traits", - "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" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b4930d2cb77ce62f89ee5d5289b4ac049559b1c45539271f5ed4fdc7db34545" - -[[package]] -name = "arrayvec" -version = "0.7.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" - -[[package]] -name = "ascii" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eab1c04a571841102f5345a8fc0f6bb3d31c315dec879b5c6e42e40ce7ffa34e" - -[[package]] -name = "assert_matches" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b34d609dfbaf33d6889b2b7106d3ca345eacad44200913df5ba02bfd31d2ba9" - -[[package]] -name = "async-attributes" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3203e79f4dd9bdda415ed03cf14dae5a2bf775c683a00f94e9cd1faf0f596e5" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "async-channel" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" -dependencies = [ - "concurrent-queue", - "event-listener", - "futures-core", -] - -[[package]] -name = "async-compression" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb42b2197bf15ccb092b62c74515dbd8b86d0effd934795f6687c93b6e679a2c" -dependencies = [ - "brotli", - "flate2", - "futures-core", - "memchr", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "async-executor" -version = "1.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c1da3ae8dabd9c00f453a329dfe1fb28da3c0a72e2478cdcd93171740c20499" -dependencies = [ - "async-lock", - "async-task", - "concurrent-queue", - "fastrand 2.0.1", - "futures-lite", - "slab", -] - -[[package]] -name = "async-global-executor" -version = "2.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1b6f5d7df27bd294849f8eec66ecfc63d11814df7a4f5d74168a2394467b776" -dependencies = [ - "async-channel", - "async-executor", - "async-io", - "async-lock", - "blocking", - "futures-lite", - "once_cell", - "tokio", -] - -[[package]] -name = "async-io" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fc5b45d93ef0529756f812ca52e44c221b35341892d3dcc34132ac02f3dd2af" -dependencies = [ - "async-lock", - "autocfg", - "cfg-if", - "concurrent-queue", - "futures-lite", - "log", - "parking", - "polling", - "rustix 0.37.24", - "slab", - "socket2 0.4.9", - "waker-fn", -] - -[[package]] -name = "async-lock" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "287272293e9d8c41773cec55e365490fe034813a2f172f502d6ddcf75b2f582b" -dependencies = [ - "event-listener", -] - -[[package]] -name = "async-std" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62565bb4402e926b29953c785397c6dc0391b7b446e45008b0049eb43cec6f5d" -dependencies = [ - "async-attributes", - "async-channel", - "async-global-executor", - "async-io", - "async-lock", - "crossbeam-utils", - "futures-channel", - "futures-core", - "futures-io", - "futures-lite", - "gloo-timers", - "kv-log-macro", - "log", - "memchr", - "once_cell", - "pin-project-lite", - "pin-utils", - "slab", - "wasm-bindgen-futures", -] - -[[package]] -name = "async-stream" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd56dd203fef61ac097dd65721a419ddccb106b2d2b70ba60a6b529f03961a51" -dependencies = [ - "async-stream-impl", - "futures-core", - "pin-project-lite", -] - -[[package]] -name = "async-stream-impl" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "async-task" -version = "4.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9441c6b2fe128a7c2bf680a44c34d0df31ce09e5b7e401fcca3faa483dbc921" - -[[package]] -name = "async-trait" -version = "0.1.73" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc00ceb34980c03614e35a3a4e218276a0a824e911d07651cd0d858a51e8c0f0" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "atoi" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7c57d12312ff59c811c0643f4d80830505833c9ffaebd193d819392b265be8e" -dependencies = [ - "num-traits", -] - -[[package]] -name = "atomic-waker" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" - -[[package]] -name = "atty" -version = "0.2.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8" -dependencies = [ - "hermit-abi 0.1.19", - "libc", - "winapi", -] - -[[package]] -name = "autocfg" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" - -[[package]] -name = "backtrace" -version = "0.3.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2089b7e3f35b9dd2d0ed921ead4f6d318c27680d4a5bd167b3ee120edb105837" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - -[[package]] -name = "bae" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33b8de67cc41132507eeece2584804efcb15f85ba516e34c944b7667f480397a" -dependencies = [ - "heck 0.3.3", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "base64" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3441f0f7b02788e948e47f457ca01f1d7e6d92c693bc132c22b087d3141c03ff" - -[[package]] -name = "base64" -version = "0.13.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" - -[[package]] -name = "base64" -version = "0.21.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ba43ea6f343b788c8764558649e08df62f86c6ef251fdaeb1ffd010a9ae50a2" - -[[package]] -name = "bincode" -version = "1.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1f45e9417d87227c7a56d22e471c6206462cba514c7590c09aff4cf6d1ddcad" -dependencies = [ - "serde", -] - -[[package]] -name = "bitflags" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" - -[[package]] -name = "bitflags" -version = "2.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4682ae6287fcf752ecaabbfcc7b6f9b72aa33933dc23a554d853aea8eea8635" - -[[package]] -name = "bitmaps" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "031043d04099746d8db04daf1fa424b2bc8bd69d92b25962dcde24da39ab64a2" -dependencies = [ - "typenum", -] - -[[package]] -name = "bitvec" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bc2832c24239b0141d5674bb9174f9d68a8b5b3f2753311927c172ca46f7e9c" -dependencies = [ - "funty", - "radium", - "tap", - "wyz", -] - -[[package]] -name = "blake3" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0231f06152bf547e9c2b5194f247cd97aacf6dcd8b15d8e5ec0663f64580da87" -dependencies = [ - "arrayref", - "arrayvec", - "cc", - "cfg-if", - "constant_time_eq", - "digest 0.10.7", -] - -[[package]] -name = "block-buffer" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4152116fd6e9dadb291ae18fc1ec3575ed6d84c29642d97890f4b4a3417297e4" -dependencies = [ - "block-padding", - "generic-array", -] - -[[package]] -name = "block-buffer" -version = "0.10.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" -dependencies = [ - "generic-array", -] - -[[package]] -name = "block-padding" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d696c370c750c948ada61c69a0ee2cbbb9c50b1019ddb86d9317157a99c2cae" - -[[package]] -name = "blockbuster" -version = "0.9.0-beta.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56e0240c1218958c0d51284d783fa055f551d769bb8b7a4abf635b17fa9620dc" -dependencies = [ - "anchor-lang", - "async-trait", - "borsh 0.10.3", - "bs58 0.4.0", - "flatbuffers", - "lazy_static", - "log", - "mpl-bubblegum", - "mpl-candy-guard", - "mpl-candy-machine-core", - "mpl-token-metadata", - "plerkle_serialization", - "solana-sdk", - "spl-account-compression", - "spl-noop", - "spl-token 4.0.0", - "thiserror", -] - -[[package]] -name = "blocking" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c36a4d0d48574b3dd360b4b7d95cc651d2b6557b6402848a27d4b228a473e2a" -dependencies = [ - "async-channel", - "async-lock", - "async-task", - "fastrand 2.0.1", - "futures-io", - "futures-lite", - "piper", - "tracing", -] - -[[package]] -name = "borsh" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15bf3650200d8bffa99015595e10f1fbd17de07abbc25bb067da79e769939bfa" -dependencies = [ - "borsh-derive 0.9.3", - "hashbrown 0.11.2", -] - -[[package]] -name = "borsh" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4114279215a005bc675e386011e594e1d9b800918cea18fcadadcce864a2046b" -dependencies = [ - "borsh-derive 0.10.3", - "hashbrown 0.13.2", -] - -[[package]] -name = "borsh-derive" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6441c552f230375d18e3cc377677914d2ca2b0d36e52129fe15450a2dce46775" -dependencies = [ - "borsh-derive-internal 0.9.3", - "borsh-schema-derive-internal 0.9.3", - "proc-macro-crate 0.1.5", - "proc-macro2", - "syn 1.0.109", -] - -[[package]] -name = "borsh-derive" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0754613691538d51f329cce9af41d7b7ca150bc973056f1156611489475f54f7" -dependencies = [ - "borsh-derive-internal 0.10.3", - "borsh-schema-derive-internal 0.10.3", - "proc-macro-crate 0.1.5", - "proc-macro2", - "syn 1.0.109", -] - -[[package]] -name = "borsh-derive-internal" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5449c28a7b352f2d1e592a8a28bf139bc71afb0764a14f3c02500935d8c44065" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "borsh-derive-internal" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "afb438156919598d2c7bad7e1c0adf3d26ed3840dbc010db1a882a65583ca2fb" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "borsh-schema-derive-internal" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cdbd5696d8bfa21d53d9fe39a714a18538bad11492a42d066dbbc395fb1951c0" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "borsh-schema-derive-internal" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "634205cc43f74a1b9046ef87c4540ebda95696ec0f315024860cad7c5b0f5ccd" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "brotli" -version = "3.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "516074a47ef4bce09577a3b379392300159ce5b1ba2e501ff1c819950066100f" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", - "brotli-decompressor", -] - -[[package]] -name = "brotli-decompressor" -version = "2.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da74e2b81409b1b743f8f0c62cc6254afefb8b8e50bbfe3735550f7aeefa3448" -dependencies = [ - "alloc-no-stdlib", - "alloc-stdlib", -] - -[[package]] -name = "bs58" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "771fe0050b883fcc3ea2359b1a96bcfbc090b7116eae7c3c512c7a083fdf23d3" - -[[package]] -name = "bs58" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5353f36341f7451062466f0b755b96ac3a9547e4d7f6b70d603fc721a7d7896" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "bumpalo" -version = "3.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f30e7476521f6f8af1a1c4c0b8cc94f0bee37d91763d0ca2665f299b6cd8aec" - -[[package]] -name = "bv" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8834bb1d8ee5dc048ee3124f2c7c1afcc6bc9aed03f11e9dfd8c69470a5db340" -dependencies = [ - "feature-probe", - "serde", -] - -[[package]] -name = "bytecheck" -version = "0.6.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b6372023ac861f6e6dc89c8344a8f398fb42aaba2b5dbc649ca0c0e9dbcb627" -dependencies = [ - "bytecheck_derive", - "ptr_meta", - "simdutf8", -] - -[[package]] -name = "bytecheck_derive" -version = "0.6.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7ec4c6f261935ad534c0c22dbef2201b45918860eb1c574b972bd213a76af61" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "bytemuck" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "374d28ec25809ee0e23827c2ab573d729e293f281dfe393500e7ad618baa61c6" -dependencies = [ - "bytemuck_derive", -] - -[[package]] -name = "bytemuck_derive" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "965ab7eb5f8f97d2a083c799f3a1b994fc397b2fe2da5d1da1626ce15a39f2b1" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "byteorder" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" - -[[package]] -name = "bytes" -version = "1.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" - -[[package]] -name = "cc" -version = "1.0.83" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f1174fb0b6ec23863f8b971027804a42614e347eafb0a95bf0b12cdae21fc4d0" -dependencies = [ - "jobserver", - "libc", -] - -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - -[[package]] -name = "chrono" -version = "0.4.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f2c685bad3eb3d45a01354cedb7d5faa66194d1d58ba6e267a8de788f79db38" -dependencies = [ - "android-tzdata", - "iana-time-zone", - "js-sys", - "num-traits", - "serde", - "wasm-bindgen", - "windows-targets", -] - -[[package]] -name = "cipher" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ee52072ec15386f770805afd189a01c8841be8696bed250fa2f13c4c0d6dfb7" -dependencies = [ - "generic-array", -] - -[[package]] -name = "clap" -version = "3.2.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ea181bf566f71cb9a5d17a59e1871af638180a18fb0035c92ae62b705207123" -dependencies = [ - "atty", - "bitflags 1.3.2", - "clap_derive", - "clap_lex", - "indexmap 1.9.3", - "once_cell", - "strsim", - "termcolor", - "textwrap", -] - -[[package]] -name = "clap_derive" -version = "3.2.25" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae6371b8bdc8b7d3959e9cf7b22d4435ef3e79e138688421ec654acf8c81b008" -dependencies = [ - "heck 0.4.1", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "clap_lex" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2850f2f5a82cbf437dd5af4d49848fbdfc27c157c3d010345776f952765261c5" -dependencies = [ - "os_str_bytes", -] - -[[package]] -name = "combine" -version = "3.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da3da6baa321ec19e1cc41d31bf599f00c783d0517095cdaf0332e3fe8d20680" -dependencies = [ - "ascii", - "byteorder", - "either", - "memchr", - "unreachable", -] - -[[package]] -name = "concurrent-queue" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f057a694a54f12365049b0958a1685bb52d567f5593b355fbf685838e873d400" -dependencies = [ - "crossbeam-utils", -] - -[[package]] -name = "console_error_panic_hook" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a06aeb73f470f66dcdbf7223caeebb85984942f22f1adb2a088cf9668146bbbc" -dependencies = [ - "cfg-if", - "wasm-bindgen", -] - -[[package]] -name = "console_log" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e89f72f65e8501878b8a004d5a1afb780987e2ce2b4532c562e367a72c57499f" -dependencies = [ - "log", - "web-sys", -] - -[[package]] -name = "constant_time_eq" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7144d30dcf0fafbce74250a3963025d8d52177934239851c917d29f1df280c2" - -[[package]] -name = "core-foundation" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "194a7a9e6de53fa55116934067c844d9d749312f75c6f6d0980e8c252f8c2146" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "core-foundation-sys" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" - -[[package]] -name = "cpufeatures" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" -dependencies = [ - "libc", -] - -[[package]] -name = "crc" -version = "3.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86ec7a15cbe22e59248fc7eadb1907dab5ba09372595da4d73dd805ed4417dfe" -dependencies = [ - "crc-catalog", -] - -[[package]] -name = "crc-catalog" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cace84e55f07e7301bae1c519df89cdad8cc3cd868413d3fdbdeca9ff3db484" - -[[package]] -name = "crc32fast" -version = "1.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b540bd8bc810d3885c6ea91e2018302f68baba2129ab3e88f32389ee9370880d" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crossbeam-channel" -version = "0.5.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a33c2bf77f2df06183c3aa30d1e96c0695a313d4f9c453cc3762a6db39f99200" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-deque" -version = "0.8.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce6fd6f855243022dcecf8702fef0c297d4338e226845fe067f6341ad9fa0cef" -dependencies = [ - "cfg-if", - "crossbeam-epoch", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-epoch" -version = "0.9.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae211234986c545741a7dc064309f67ee1e5ad243d0e48335adc0484d960bcc7" -dependencies = [ - "autocfg", - "cfg-if", - "crossbeam-utils", - "memoffset", - "scopeguard", -] - -[[package]] -name = "crossbeam-queue" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1cfb3ea8a53f37c40dea2c7bedcbd88bdfae54f5e2175d6ecaff1c988353add" -dependencies = [ - "cfg-if", - "crossbeam-utils", -] - -[[package]] -name = "crossbeam-utils" -version = "0.8.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "crunchy" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a81dae078cea95a014a339291cec439d2f232ebe854a9d672b796c6afafa9b7" - -[[package]] -name = "crypto-common" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1bfb12502f3fc46cca1bb51ac28df9d618d813cdc3d2f25b9fe775a34af26bb3" -dependencies = [ - "generic-array", - "typenum", -] - -[[package]] -name = "crypto-mac" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b584a330336237c1eecd3e94266efb216c56ed91225d634cb2991c5f3fd1aeab" -dependencies = [ - "generic-array", - "subtle", -] - -[[package]] -name = "ctr" -version = "0.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "049bb91fb4aaf0e3c7efa6cd5ef877dbbbd15b39dad06d9948de4ec8a75761ea" -dependencies = [ - "cipher", -] - -[[package]] -name = "curve25519-dalek" -version = "3.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90f9d052967f590a76e62eb387bd0bbb1b000182c3cefe5364db6b7211651bc0" -dependencies = [ - "byteorder", - "digest 0.9.0", - "rand_core 0.5.1", - "serde", - "subtle", - "zeroize", -] - -[[package]] -name = "darling" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" -dependencies = [ - "darling_core 0.13.4", - "darling_macro 0.13.4", -] - -[[package]] -name = "darling" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" -dependencies = [ - "darling_core 0.20.3", - "darling_macro 0.20.3", -] - -[[package]] -name = "darling_core" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 1.0.109", -] - -[[package]] -name = "darling_core" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim", - "syn 2.0.38", -] - -[[package]] -name = "darling_macro" -version = "0.13.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" -dependencies = [ - "darling_core 0.13.4", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "darling_macro" -version = "0.20.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" -dependencies = [ - "darling_core 0.20.3", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "deranged" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2696e8a945f658fd14dc3b87242e6b80cd0f36ff04ea560fa39082368847946" -dependencies = [ - "serde", -] - -[[package]] -name = "derivation-path" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e5c37193a1db1d8ed868c03ec7b152175f26160a5b740e5e484143877e0adf0" - -[[package]] -name = "derivative" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "digest" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3dd60d1080a57a05ab032377049e0591415d2b31afd7028356dbf3cc6dcb066" -dependencies = [ - "generic-array", -] - -[[package]] -name = "digest" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" -dependencies = [ - "block-buffer 0.10.4", - "crypto-common", - "subtle", -] - -[[package]] -name = "digital_asset_types" -version = "0.7.2" -dependencies = [ - "async-trait", - "blockbuster", - "bs58 0.4.0", - "futures", - "indexmap 1.9.3", - "jsonpath_lib", - "log", - "mime_guess", - "num-derive 0.3.3", - "num-traits", - "reqwest", - "schemars", - "schemars_derive", - "sea-orm", - "sea-query 0.28.5", - "serde", - "serde_json", - "solana-sdk", - "spl-concurrent-merkle-tree", - "thiserror", - "tokio", - "url", -] - -[[package]] -name = "dirs" -version = "4.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3aa72a6f96ea37bbc5aa912f6788242832f75369bdfdadcb0e38423f100059" -dependencies = [ - "dirs-sys", -] - -[[package]] -name = "dirs-sys" -version = "0.3.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" -dependencies = [ - "libc", - "redox_users", - "winapi", -] - -[[package]] -name = "dotenvy" -version = "0.15.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" - -[[package]] -name = "dyn-clone" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23d2f3407d9a573d666de4b5bdf10569d73ca9478087346697dcbae6244bfbcd" - -[[package]] -name = "eager" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abe71d579d1812060163dff96056261deb5bf6729b100fa2e36a68b9649ba3d3" - -[[package]] -name = "ed25519" -version = "1.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91cff35c70bba8a626e3185d8cd48cc11b5437e1a5bcd15b9b5fa3c64b6dfee7" -dependencies = [ - "signature", -] - -[[package]] -name = "ed25519-dalek" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c762bae6dcaf24c4c84667b8579785430908723d5c889f469d76a41d59cc7a9d" -dependencies = [ - "curve25519-dalek", - "ed25519", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "zeroize", -] - -[[package]] -name = "ed25519-dalek-bip32" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d2be62a4061b872c8c0873ee4fc6f101ce7b889d039f019c5fa2af471a59908" -dependencies = [ - "derivation-path", - "ed25519-dalek", - "hmac 0.12.1", - "sha2 0.10.8", -] - -[[package]] -name = "either" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a26ae43d7bcc3b814de94796a5e736d4029efb0ee900c12e2d54c993ad1a1e07" - -[[package]] -name = "encoding_rs" -version = "0.8.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7268b386296a025e474d5140678f75d6de9493ae55a5d709eeb9dd08149945e1" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "enum-iterator" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7add3873b5dd076766ee79c8e406ad1a472c385476b9e38849f8eec24f1be689" -dependencies = [ - "enum-iterator-derive", -] - -[[package]] -name = "enum-iterator-derive" -version = "1.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eecf8589574ce9b895052fa12d69af7a233f99e6107f5cb8dd1044f2a17bfdcb" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "env_logger" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a12e6657c4c97ebab115a42dcee77225f7f482cdd841cf7088c657a42e9e00e7" -dependencies = [ - "atty", - "humantime", - "log", - "regex", - "termcolor", -] - -[[package]] -name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3e13f66a2f95e32a39eaa81f6b95d42878ca0e1db0c7543723dfe12557e860" -dependencies = [ - "libc", - "windows-sys", -] - -[[package]] -name = "event-listener" -version = "2.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0" - -[[package]] -name = "fastrand" -version = "1.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" -dependencies = [ - "instant", -] - -[[package]] -name = "fastrand" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" - -[[package]] -name = "feature-probe" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "835a3dc7d1ec9e75e2b5fb4ba75396837112d2060b03f7d43bc1897c7f7211da" - -[[package]] -name = "finl_unicode" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fcfdc7a0362c9f4444381a9e697c79d435fe65b52a37466fc2c1184cee9edc6" - -[[package]] -name = "flatbuffers" -version = "23.5.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dac53e22462d78c16d64a1cd22371b54cc3fe94aa15e7886a2fa6e5d1ab8640" -dependencies = [ - "bitflags 1.3.2", - "rustc_version", -] - -[[package]] -name = "flate2" -version = "1.0.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6c98ee8095e9d1dcbf2fcc6d95acccb90d1c81db1e44725c6a984b1dbdfb010" -dependencies = [ - "crc32fast", - "miniz_oxide", -] - -[[package]] -name = "fnv" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" - -[[package]] -name = "foreign-types" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" -dependencies = [ - "foreign-types-shared", -] - -[[package]] -name = "foreign-types-shared" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" - -[[package]] -name = "form_urlencoded" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "funty" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" - -[[package]] -name = "futures" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23342abe12aba583913b2e62f22225ff9c950774065e4bfb61a19cd9770fec40" -dependencies = [ - "futures-channel", - "futures-core", - "futures-executor", - "futures-io", - "futures-sink", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-channel" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" -dependencies = [ - "futures-core", - "futures-sink", -] - -[[package]] -name = "futures-core" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" - -[[package]] -name = "futures-executor" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" -dependencies = [ - "futures-core", - "futures-task", - "futures-util", -] - -[[package]] -name = "futures-intrusive" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a604f7a68fbf8103337523b1fadc8ade7361ee3f112f7c680ad179651616aed5" -dependencies = [ - "futures-core", - "lock_api", - "parking_lot 0.11.2", -] - -[[package]] -name = "futures-io" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" - -[[package]] -name = "futures-lite" -version = "1.13.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce" -dependencies = [ - "fastrand 1.9.0", - "futures-core", - "futures-io", - "memchr", - "parking", - "pin-project-lite", - "waker-fn", -] - -[[package]] -name = "futures-macro" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "futures-sink" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" - -[[package]] -name = "futures-task" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" - -[[package]] -name = "futures-util" -version = "0.3.28" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" -dependencies = [ - "futures-channel", - "futures-core", - "futures-io", - "futures-macro", - "futures-sink", - "futures-task", - "memchr", - "pin-project-lite", - "pin-utils", - "slab", -] - -[[package]] -name = "generic-array" -version = "0.14.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" -dependencies = [ - "serde", - "typenum", - "version_check", -] - -[[package]] -name = "gethostname" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1ebd34e35c46e00bb73e81363248d627782724609fe1b6396f553f68fe3862e" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "getrandom" -version = "0.1.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fc3cb4d91f53b50155bdcfd23f6a4c39ae1969c2ae85982b135750cccaf5fce" -dependencies = [ - "cfg-if", - "js-sys", - "libc", - "wasi 0.9.0+wasi-snapshot-preview1", - "wasm-bindgen", -] - -[[package]] -name = "getrandom" -version = "0.2.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" -dependencies = [ - "cfg-if", - "js-sys", - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "wasm-bindgen", -] - -[[package]] -name = "gimli" -version = "0.28.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6fb8d784f27acf97159b40fc4db5ecd8aa23b9ad5ef69cdd136d3bc80665f0c0" - -[[package]] -name = "gloo-timers" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b995a66bb87bebce9a0f4a95aed01daca4872c050bfcb21653361c03bc35e5c" -dependencies = [ - "futures-channel", - "futures-core", - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "goblin" -version = "0.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7666983ed0dd8d21a6f6576ee00053ca0926fb281a5522577a4dbd0f1b54143" -dependencies = [ - "log", - "plain", - "scroll", -] - -[[package]] -name = "h2" -version = "0.3.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "91fc23aa11be92976ef4729127f1a74adf36d8436f7816b185d18df956790833" -dependencies = [ - "bytes", - "fnv", - "futures-core", - "futures-sink", - "futures-util", - "http", - "indexmap 1.9.3", - "slab", - "tokio", - "tokio-util", - "tracing", -] - -[[package]] -name = "hash32" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0c35f58762feb77d74ebe43bdbc3210f09be9fe6742234d573bacc26ed92b67" -dependencies = [ - "byteorder", -] - -[[package]] -name = "hashbrown" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab5ef0d4909ef3724cc8cce6ccc8572c5c817592e9285f5464f8e86f8bd3726e" -dependencies = [ - "ahash 0.7.6", -] - -[[package]] -name = "hashbrown" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" -dependencies = [ - "ahash 0.7.6", -] - -[[package]] -name = "hashbrown" -version = "0.13.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43a3c133739dddd0d2990f9a4bdf8eb4b21ef50e4851ca85ab661199821d510e" -dependencies = [ - "ahash 0.8.3", -] - -[[package]] -name = "hashbrown" -version = "0.14.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dfda62a12f55daeae5015f81b0baea145391cb4520f86c248fc615d72640d12" -dependencies = [ - "ahash 0.8.3", - "allocator-api2", -] - -[[package]] -name = "hashlink" -version = "0.8.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8094feaf31ff591f651a2664fb9cfd92bba7a60ce3197265e9482ebe753c8f7" -dependencies = [ - "hashbrown 0.14.1", -] - -[[package]] -name = "heck" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "heck" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" -dependencies = [ - "unicode-segmentation", -] - -[[package]] -name = "hermit-abi" -version = "0.1.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d77f7ec81a6d05a3abb01ab6eb7590f6083d08449fe5a1c8b1e620283546ccb7" - -[[package]] -name = "hex" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" - -[[package]] -name = "hkdf" -version = "0.12.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "791a029f6b9fc27657f6f188ec6e5e43f6911f6f878e0dc5501396e09809d437" -dependencies = [ - "hmac 0.12.1", -] - -[[package]] -name = "hmac" -version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "126888268dcc288495a26bf004b38c5fdbb31682f992c84ceb046a1f0fe38840" -dependencies = [ - "crypto-mac", - "digest 0.9.0", -] - -[[package]] -name = "hmac" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "hmac-drbg" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17ea0a1394df5b6574da6e0c1ade9e78868c9fb0a4e5ef4428e32da4676b85b1" -dependencies = [ - "digest 0.9.0", - "generic-array", - "hmac 0.8.1", -] - -[[package]] -name = "http" -version = "0.2.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" -dependencies = [ - "bytes", - "fnv", - "itoa", -] - -[[package]] -name = "http-body" -version = "0.4.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5f38f16d184e36f2408a55281cd658ecbd3ca05cce6d6510a176eca393e26d1" -dependencies = [ - "bytes", - "http", - "pin-project-lite", -] - -[[package]] -name = "httparse" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d897f394bad6a705d5f4104762e116a75639e470d80901eed05a860a95cb1904" - -[[package]] -name = "httpdate" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" - -[[package]] -name = "humantime" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" - -[[package]] -name = "hyper" -version = "0.14.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" -dependencies = [ - "bytes", - "futures-channel", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "httparse", - "httpdate", - "itoa", - "pin-project-lite", - "socket2 0.4.9", - "tokio", - "tower-service", - "tracing", - "want", -] - -[[package]] -name = "hyper-rustls" -version = "0.24.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d78e1e73ec14cf7375674f74d7dde185c8206fd9dea6fb6295e8a98098aaa97" -dependencies = [ - "futures-util", - "http", - "hyper", - "rustls 0.21.7", - "tokio", - "tokio-rustls 0.24.1", -] - -[[package]] -name = "hyper-tls" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d6183ddfa99b85da61a140bea0efc93fdf56ceaa041b37d553518030827f9905" -dependencies = [ - "bytes", - "hyper", - "native-tls", - "tokio", - "tokio-native-tls", -] - -[[package]] -name = "iana-time-zone" -version = "0.1.57" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" -dependencies = [ - "android_system_properties", - "core-foundation-sys", - "iana-time-zone-haiku", - "js-sys", - "wasm-bindgen", - "windows", -] - -[[package]] -name = "iana-time-zone-haiku" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" -dependencies = [ - "cc", -] - -[[package]] -name = "ident_case" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" - -[[package]] -name = "idna" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" -dependencies = [ - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "im" -version = "15.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0acd33ff0285af998aaf9b57342af478078f53492322fafc47450e09397e0e9" -dependencies = [ - "bitmaps", - "rand_core 0.6.4", - "rand_xoshiro", - "rayon", - "serde", - "sized-chunks", - "typenum", - "version_check", -] - -[[package]] -name = "indexmap" -version = "1.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" -dependencies = [ - "autocfg", - "hashbrown 0.12.3", -] - -[[package]] -name = "indexmap" -version = "2.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8adf3ddd720272c6ea8bf59463c04e0f93d0bbf7c5439b691bca2987e0270897" -dependencies = [ - "equivalent", - "hashbrown 0.14.1", -] - -[[package]] -name = "instant" -version = "0.1.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a5bbe824c507c5da5956355e86a746d82e0e1464f65d862cc5e71da70e94b2c" -dependencies = [ - "cfg-if", -] - -[[package]] -name = "io-lifetimes" -version = "1.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" -dependencies = [ - "hermit-abi 0.3.3", - "libc", - "windows-sys", -] - -[[package]] -name = "ipnet" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" - -[[package]] -name = "itertools" -version = "0.10.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0fd2260e829bddf4cb6ea802289de2f86d6a7a690192fbe91b3f46e0f2c8473" -dependencies = [ - "either", -] - -[[package]] -name = "itertools" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57" -dependencies = [ - "either", -] - -[[package]] -name = "itoa" -version = "1.0.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" - -[[package]] -name = "jobserver" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "936cfd212a0155903bcbc060e316fb6cc7cbf2e1907329391ebadc1fe0ce77c2" -dependencies = [ - "libc", -] - -[[package]] -name = "js-sys" -version = "0.3.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" -dependencies = [ - "wasm-bindgen", -] - -[[package]] -name = "jsonpath_lib" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaa63191d68230cccb81c5aa23abd53ed64d83337cacbb25a7b8c7979523774f" -dependencies = [ - "log", - "serde", - "serde_json", -] - -[[package]] -name = "kaigan" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a26f49495f94a283312e7ef45a243540ef20c9356bb01c8d84a61ac8ba5339b" -dependencies = [ - "borsh 0.10.3", -] - -[[package]] -name = "keccak" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" -dependencies = [ - "cpufeatures", -] - -[[package]] -name = "kv-log-macro" -version = "1.0.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0de8b303297635ad57c9f5059fd9cee7a47f8e8daa09df0fcd07dd39fb22977f" -dependencies = [ - "log", -] - -[[package]] -name = "lazy_static" -version = "1.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" - -[[package]] -name = "libc" -version = "0.2.149" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a08173bc88b7955d1b3145aa561539096c421ac8debde8cbc3612ec635fee29b" - -[[package]] -name = "libsecp256k1" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9d220bc1feda2ac231cb78c3d26f27676b8cf82c96971f7aeef3d0cf2797c73" -dependencies = [ - "arrayref", - "base64 0.12.3", - "digest 0.9.0", - "hmac-drbg", - "libsecp256k1-core", - "libsecp256k1-gen-ecmult", - "libsecp256k1-gen-genmult", - "rand 0.7.3", - "serde", - "sha2 0.9.9", - "typenum", -] - -[[package]] -name = "libsecp256k1-core" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d0f6ab710cec28cef759c5f18671a27dae2a5f952cdaaee1d8e2908cb2478a80" -dependencies = [ - "crunchy", - "digest 0.9.0", - "subtle", -] - -[[package]] -name = "libsecp256k1-gen-ecmult" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ccab96b584d38fac86a83f07e659f0deafd0253dc096dab5a36d53efe653c5c3" -dependencies = [ - "libsecp256k1-core", -] - -[[package]] -name = "libsecp256k1-gen-genmult" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67abfe149395e3aa1c48a2beb32b068e2334402df8181f818d3aee2b304c4f5d" -dependencies = [ - "libsecp256k1-core", -] - -[[package]] -name = "linux-raw-sys" -version = "0.3.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" - -[[package]] -name = "linux-raw-sys" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da2479e8c062e40bf0066ffa0bc823de0a9368974af99c9f6df941d2c231e03f" - -[[package]] -name = "lock_api" -version = "0.4.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" -dependencies = [ - "autocfg", - "scopeguard", -] - -[[package]] -name = "log" -version = "0.4.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" -dependencies = [ - "value-bag", -] - -[[package]] -name = "matchers" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" -dependencies = [ - "regex-automata 0.1.10", -] - -[[package]] -name = "md-5" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf" -dependencies = [ - "cfg-if", - "digest 0.10.7", -] - -[[package]] -name = "memchr" -version = "2.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f665ee40bc4a3c5590afb1e9677db74a508659dfd71e126420da8274909a0167" - -[[package]] -name = "memmap2" -version = "0.5.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83faa42c0a078c393f6b29d5db232d8be22776a891f8f56e5284faee4a20b327" -dependencies = [ - "libc", -] - -[[package]] -name = "memoffset" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c" -dependencies = [ - "autocfg", -] - -[[package]] -name = "merlin" -version = "3.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58c38e2799fc0978b65dfff8023ec7843e2330bb462f19198840b34b6582397d" -dependencies = [ - "byteorder", - "keccak", - "rand_core 0.6.4", - "zeroize", -] - -[[package]] -name = "migration" -version = "0.7.2" -dependencies = [ - "async-std", - "digital_asset_types", - "enum-iterator", - "enum-iterator-derive", - "sea-orm-migration", -] - -[[package]] -name = "mime" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" - -[[package]] -name = "mime_guess" -version = "2.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4192263c238a5f0d0c6bfd21f336a313a4ce1c450542449ca191bb657b4642ef" -dependencies = [ - "mime", - "unicase", -] - -[[package]] -name = "minimal-lexical" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" - -[[package]] -name = "miniz_oxide" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" -dependencies = [ - "adler", -] - -[[package]] -name = "mio" -version = "0.8.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" -dependencies = [ - "libc", - "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys", -] - -[[package]] -name = "mpl-bubblegum" -version = "1.0.1-beta.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29346f26192bb7f73330196fde4c8cfb35675bf1a4b026cd088f7ca8fda69f3f" -dependencies = [ - "borsh 0.10.3", - "kaigan", - "num-derive 0.3.3", - "num-traits", - "solana-program", - "thiserror", -] - -[[package]] -name = "mpl-candy-guard" -version = "2.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59c5c2ffb233226e0c531f1cf800909e46120e98722eeb53dae68b0996303a38" -dependencies = [ - "anchor-lang", - "arrayref", - "mpl-candy-guard-derive", - "mpl-candy-machine-core", - "mpl-token-auth-rules", - "mpl-token-metadata", - "solana-gateway", - "solana-program", - "spl-associated-token-account", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", -] - -[[package]] -name = "mpl-candy-guard-derive" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18e4d3002ea881e94a238798faf87a006a687297a24bd4b3f810fbb63611173d" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "mpl-candy-machine-core" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4db99e1aac3bdebf907338aec5f1785701b8a82e6bdac5f42a270750d37c5264" -dependencies = [ - "anchor-lang", - "arrayref", - "mpl-token-auth-rules", - "mpl-token-metadata", - "solana-program", - "spl-associated-token-account", - "spl-token 4.0.0", -] - -[[package]] -name = "mpl-token-auth-rules" -version = "1.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66b1ec5ee0570f688cc84ff4624c5c50732f1a2bfc789f6b34af5b563428d971" -dependencies = [ - "borsh 0.10.3", - "bytemuck", - "mpl-token-metadata-context-derive 0.2.1", - "num-derive 0.3.3", - "num-traits", - "rmp-serde", - "serde", - "shank", - "solana-program", - "solana-zk-token-sdk", - "thiserror", -] - -[[package]] -name = "mpl-token-metadata" -version = "2.0.0-beta.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3545bd5fe73416f6514cd93899612e0e138619e72df8bc7d19906a12688c69e" -dependencies = [ - "arrayref", - "borsh 0.10.3", - "mpl-token-auth-rules", - "mpl-token-metadata-context-derive 0.3.0", - "mpl-utils", - "num-derive 0.3.3", - "num-traits", - "serde", - "serde_with 1.14.0", - "shank", - "solana-program", - "spl-associated-token-account", - "spl-token 4.0.0", - "thiserror", -] - -[[package]] -name = "mpl-token-metadata-context-derive" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "12989bc45715b0ee91944855130131479f9c772e198a910c3eb0ea327d5bffc3" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "mpl-token-metadata-context-derive" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5a739019e11d93661a64ef5fe108ab17c79b35961e944442ff6efdd460ad01a" -dependencies = [ - "quote", - "syn 1.0.109", -] - -[[package]] -name = "mpl-utils" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f2e4f92aec317d5853c0cc4c03c55f5178511c45bb3dbb441aea63117bf3dc9" -dependencies = [ - "arrayref", - "solana-program", - "spl-token-2022 0.6.1", -] - -[[package]] -name = "native-tls" -version = "0.2.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07226173c32f2926027b63cce4bcd8076c3552846cbe7925f3aaffeac0a3b92e" -dependencies = [ - "lazy_static", - "libc", - "log", - "openssl", - "openssl-probe", - "openssl-sys", - "schannel", - "security-framework", - "security-framework-sys", - "tempfile", -] - -[[package]] -name = "nom" -version = "7.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" -dependencies = [ - "memchr", - "minimal-lexical", -] - -[[package]] -name = "nu-ansi-term" -version = "0.46.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" -dependencies = [ - "overload", - "winapi", -] - -[[package]] -name = "num" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8536030f9fea7127f841b45bb6243b27255787fb4eb83958aa1ef9d2fdc0c36" -dependencies = [ - "num-bigint 0.2.6", - "num-complex", - "num-integer", - "num-iter", - "num-rational", - "num-traits", -] - -[[package]] -name = "num-bigint" -version = "0.2.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "090c7f9998ee0ff65aa5b723e4009f7b217707f1fb5ea551329cc4d6231fb304" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-bigint" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608e7659b5c3d7cba262d894801b9ec9d00de989e8a82bd4bef91d08da45cdc0" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-complex" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6b19411a9719e753aff12e5187b74d60d3dc449ec3f4dc21e3989c3f554bc95" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-derive" -version = "0.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "num-derive" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cfb77679af88f8b125209d354a202862602672222e7f2313fdd6dc349bad4712" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "num-integer" -version = "0.1.45" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "225d3389fb3509a24c93f5c29eb6bde2586b98d9f016636dff58d7c6f7569cd9" -dependencies = [ - "autocfg", - "num-traits", -] - -[[package]] -name = "num-iter" -version = "0.1.43" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d03e6c028c5dc5cac6e2dec0efda81fc887605bb3d884578bb6d6bf7514e252" -dependencies = [ - "autocfg", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-rational" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c000134b5dbf44adc5cb772486d335293351644b801551abe8f75c84cfa4aef" -dependencies = [ - "autocfg", - "num-bigint 0.2.6", - "num-integer", - "num-traits", -] - -[[package]] -name = "num-traits" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e3200413f237f41ab11ad6d161bc7239c84dcb631773ccd7de3dfe4b5c267c" -dependencies = [ - "autocfg", -] - -[[package]] -name = "num_cpus" -version = "1.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" -dependencies = [ - "hermit-abi 0.3.3", - "libc", -] - -[[package]] -name = "num_enum" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" -dependencies = [ - "num_enum_derive 0.5.11", -] - -[[package]] -name = "num_enum" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a015b430d3c108a207fd776d2e2196aaf8b1cf8cf93253e3a097ff3085076a1" -dependencies = [ - "num_enum_derive 0.6.1", -] - -[[package]] -name = "num_enum" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70bf6736f74634d299d00086f02986875b3c2d924781a6a2cb6c201e73da0ceb" -dependencies = [ - "num_enum_derive 0.7.0", -] - -[[package]] -name = "num_enum_derive" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" -dependencies = [ - "proc-macro-crate 1.3.1", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "num_enum_derive" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96667db765a921f7b295ffee8b60472b686a51d4f21c2ee4ffdb94c7013b65a6" -dependencies = [ - "proc-macro-crate 1.3.1", - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "num_enum_derive" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56ea360eafe1022f7cc56cd7b869ed57330fb2453d0c7831d99b74c65d2f5597" -dependencies = [ - "proc-macro-crate 1.3.1", - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "object" -version = "0.32.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9cf5f9dd3933bd50a9e1f149ec995f39ae2c496d31fd772c1fd45ebc27e902b0" -dependencies = [ - "memchr", -] - -[[package]] -name = "once_cell" -version = "1.18.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" - -[[package]] -name = "opaque-debug" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" - -[[package]] -name = "openssl" -version = "0.10.57" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bac25ee399abb46215765b1cb35bc0212377e58a061560d8b29b024fd0430e7c" -dependencies = [ - "bitflags 2.4.0", - "cfg-if", - "foreign-types", - "libc", - "once_cell", - "openssl-macros", - "openssl-sys", -] - -[[package]] -name = "openssl-macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "openssl-probe" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" - -[[package]] -name = "openssl-sys" -version = "0.9.93" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db4d56a4c0478783083cfafcc42493dd4a981d41669da64b4572a2a089b51b1d" -dependencies = [ - "cc", - "libc", - "pkg-config", - "vcpkg", -] - -[[package]] -name = "os_str_bytes" -version = "6.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d5d9eb14b174ee9aa2ef96dc2b94637a2d4b6e7cb873c7e171f0c20c6cf3eac" - -[[package]] -name = "ouroboros" -version = "0.15.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1358bd1558bd2a083fed428ffeda486fbfb323e698cdda7794259d592ca72db" -dependencies = [ - "aliasable", - "ouroboros_macro", -] - -[[package]] -name = "ouroboros_macro" -version = "0.15.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f7d21ccd03305a674437ee1248f3ab5d4b1db095cf1caf49f1713ddf61956b7" -dependencies = [ - "Inflector", - "proc-macro-error", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - -[[package]] -name = "parking" -version = "2.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e52c774a4c39359c1d1c52e43f73dd91a75a614652c825408eec30c95a9b2067" - -[[package]] -name = "parking_lot" -version = "0.11.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7d17b78036a60663b797adeaee46f5c9dfebb86948d1255007a1d6be0271ff99" -dependencies = [ - "instant", - "lock_api", - "parking_lot_core 0.8.6", -] - -[[package]] -name = "parking_lot" -version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" -dependencies = [ - "lock_api", - "parking_lot_core 0.9.8", -] - -[[package]] -name = "parking_lot_core" -version = "0.8.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60a2cfe6f0ad2bfc16aefa463b497d5c7a5ecd44a23efa72aa342d90177356dc" -dependencies = [ - "cfg-if", - "instant", - "libc", - "redox_syscall 0.2.16", - "smallvec", - "winapi", -] - -[[package]] -name = "parking_lot_core" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" -dependencies = [ - "cfg-if", - "libc", - "redox_syscall 0.3.5", - "smallvec", - "windows-targets", -] - -[[package]] -name = "paste" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" - -[[package]] -name = "pbkdf2" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "216eaa586a190f0a738f2f918511eecfa90f13295abec0e457cdebcceda80cbd" -dependencies = [ - "crypto-mac", -] - -[[package]] -name = "pbkdf2" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" -dependencies = [ - "digest 0.10.7", -] - -[[package]] -name = "percent-encoding" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" - -[[package]] -name = "percentage" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd23b938276f14057220b707937bcb42fa76dda7560e57a2da30cb52d557937" -dependencies = [ - "num", -] - -[[package]] -name = "pin-project-lite" -version = "0.2.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8afb450f006bf6385ca15ef45d71d2288452bc3683ce2e2cacc0d18e4be60b58" - -[[package]] -name = "pin-utils" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" - -[[package]] -name = "piper" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "668d31b1c4eba19242f2088b2bf3316b82ca31082a8335764db4e083db7485d4" -dependencies = [ - "atomic-waker", - "fastrand 2.0.1", - "futures-io", -] - -[[package]] -name = "pkg-config" -version = "0.3.27" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" - -[[package]] -name = "plain" -version = "0.2.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6" - -[[package]] -name = "plerkle_serialization" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f021e409a6a1ec8b7a325db27254e7fa3942e845cfe96f5f8f494977f2646a8" -dependencies = [ - "bs58 0.4.0", - "chrono", - "flatbuffers", - "serde", - "solana-sdk", - "solana-transaction-status", - "thiserror", -] - -[[package]] -name = "polling" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b2d323e8ca7996b3e23126511a523f7e62924d93ecd5ae73b333815b0eb3dce" -dependencies = [ - "autocfg", - "bitflags 1.3.2", - "cfg-if", - "concurrent-queue", - "libc", - "log", - "pin-project-lite", - "windows-sys", -] - -[[package]] -name = "polyval" -version = "0.5.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8419d2b623c7c0896ff2d5d96e2cb4ede590fed28fcc34934f4c33c036e620a1" -dependencies = [ - "cfg-if", - "cpufeatures", - "opaque-debug", - "universal-hash", -] - -[[package]] -name = "ppv-lite86" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" - -[[package]] -name = "proc-macro-crate" -version = "0.1.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d6ea3c4595b96363c13943497db34af4460fb474a95c43f4446ad341b8c9785" -dependencies = [ - "toml", -] - -[[package]] -name = "proc-macro-crate" -version = "1.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" -dependencies = [ - "once_cell", - "toml_edit", -] - -[[package]] -name = "proc-macro-error" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" -dependencies = [ - "proc-macro-error-attr", - "proc-macro2", - "quote", - "syn 1.0.109", - "version_check", -] - -[[package]] -name = "proc-macro-error-attr" -version = "1.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" -dependencies = [ - "proc-macro2", - "quote", - "version_check", -] - -[[package]] -name = "proc-macro2" -version = "1.0.69" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "134c189feb4956b20f6f547d2cf727d4c0fe06722b20a0eec87ed445a97f92da" -dependencies = [ - "unicode-ident", -] - -[[package]] -name = "ptr_meta" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0738ccf7ea06b608c10564b31debd4f5bc5e197fc8bfe088f68ae5ce81e7a4f1" -dependencies = [ - "ptr_meta_derive", -] - -[[package]] -name = "ptr_meta_derive" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16b845dbfca988fa33db069c0e230574d15a3088f147a87b64c7589eb662c9ac" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "qstring" -version = "0.7.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d464fae65fff2680baf48019211ce37aaec0c78e9264c84a3e484717f965104e" -dependencies = [ - "percent-encoding", -] - -[[package]] -name = "quote" -version = "1.0.33" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5267fca4496028628a95160fc423a33e8b2e6af8a5302579e322e4b520293cae" -dependencies = [ - "proc-macro2", -] - -[[package]] -name = "radium" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09" - -[[package]] -name = "rand" -version = "0.7.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a6b1679d49b24bbfe0c803429aa1874472f50d9b363131f0e89fc356b544d03" -dependencies = [ - "getrandom 0.1.16", - "libc", - "rand_chacha 0.2.2", - "rand_core 0.5.1", - "rand_hc", -] - -[[package]] -name = "rand" -version = "0.8.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34af8d1a0e25924bc5b7c43c079c942339d8f0a8b57c39049bef581b46327404" -dependencies = [ - "libc", - "rand_chacha 0.3.1", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_chacha" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4c8ed856279c9737206bf725bf36935d8666ead7aa69b52be55af369d193402" -dependencies = [ - "ppv-lite86", - "rand_core 0.5.1", -] - -[[package]] -name = "rand_chacha" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" -dependencies = [ - "ppv-lite86", - "rand_core 0.6.4", -] - -[[package]] -name = "rand_core" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bde5296fc891b0cef12a6d03ddccc162ce7b2aff54160af9338f8d40df6d19" -dependencies = [ - "getrandom 0.1.16", -] - -[[package]] -name = "rand_core" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" -dependencies = [ - "getrandom 0.2.10", -] - -[[package]] -name = "rand_hc" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca3129af7b92a17112d59ad498c6f81eaf463253766b90396d39ea7a39d6613c" -dependencies = [ - "rand_core 0.5.1", -] - -[[package]] -name = "rand_xoshiro" -version = "0.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f97cdb2a36ed4183de61b2f824cc45c9f1037f28afe0a322e9fff4c108b5aaa" -dependencies = [ - "rand_core 0.6.4", -] - -[[package]] -name = "rayon" -version = "1.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c27db03db7734835b3f53954b534c91069375ce6ccaa2e065441e07d9b6cdb1" -dependencies = [ - "either", - "rayon-core", -] - -[[package]] -name = "rayon-core" -version = "1.12.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ce3fb6ad83f861aac485e76e1985cd109d9a3713802152be56c3b1f0e0658ed" -dependencies = [ - "crossbeam-deque", - "crossbeam-utils", -] - -[[package]] -name = "redox_syscall" -version = "0.2.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" -dependencies = [ - "bitflags 1.3.2", -] - -[[package]] -name = "redox_syscall" -version = "0.3.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" -dependencies = [ - "bitflags 1.3.2", -] - -[[package]] -name = "redox_users" -version = "0.4.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" -dependencies = [ - "getrandom 0.2.10", - "redox_syscall 0.2.16", - "thiserror", -] - -[[package]] -name = "regex" -version = "1.9.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebee201405406dbf528b8b672104ae6d6d63e6d118cb10e4d51abbc7b58044ff" -dependencies = [ - "aho-corasick", - "memchr", - "regex-automata 0.3.9", - "regex-syntax 0.7.5", -] - -[[package]] -name = "regex-automata" -version = "0.1.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" -dependencies = [ - "regex-syntax 0.6.29", -] - -[[package]] -name = "regex-automata" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59b23e92ee4318893fa3fe3e6fb365258efbfe6ac6ab30f090cdcbb7aa37efa9" -dependencies = [ - "aho-corasick", - "memchr", - "regex-syntax 0.7.5", -] - -[[package]] -name = "regex-syntax" -version = "0.6.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" - -[[package]] -name = "regex-syntax" -version = "0.7.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dbb5fb1acd8a1a18b3dd5be62d25485eb770e05afb408a9627d14d451bae12da" - -[[package]] -name = "rend" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2571463863a6bd50c32f94402933f03457a3fbaf697a707c5be741e459f08fd" -dependencies = [ - "bytecheck", -] - -[[package]] -name = "reqwest" -version = "0.11.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "046cd98826c46c2ac8ddecae268eb5c2e58628688a5fc7a2643704a73faba95b" -dependencies = [ - "async-compression", - "base64 0.21.4", - "bytes", - "encoding_rs", - "futures-core", - "futures-util", - "h2", - "http", - "http-body", - "hyper", - "hyper-rustls", - "hyper-tls", - "ipnet", - "js-sys", - "log", - "mime", - "native-tls", - "once_cell", - "percent-encoding", - "pin-project-lite", - "rustls 0.21.7", - "rustls-pemfile", - "serde", - "serde_json", - "serde_urlencoded", - "system-configuration", - "tokio", - "tokio-native-tls", - "tokio-rustls 0.24.1", - "tokio-util", - "tower-service", - "url", - "wasm-bindgen", - "wasm-bindgen-futures", - "web-sys", - "webpki-roots 0.25.2", - "winreg", -] - -[[package]] -name = "ring" -version = "0.16.20" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3053cf52e236a3ed746dfc745aa9cacf1b791d846bdaf412f60a8d7d6e17c8fc" -dependencies = [ - "cc", - "libc", - "once_cell", - "spin 0.5.2", - "untrusted 0.7.1", - "web-sys", - "winapi", -] - -[[package]] -name = "ring" -version = "0.17.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "911b295d2d302948838c8ac142da1ee09fa7863163b44e6715bc9357905878b8" -dependencies = [ - "cc", - "getrandom 0.2.10", - "libc", - "spin 0.9.8", - "untrusted 0.9.0", - "windows-sys", -] - -[[package]] -name = "rkyv" -version = "0.7.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0200c8230b013893c0b2d6213d6ec64ed2b9be2e0e016682b7224ff82cff5c58" -dependencies = [ - "bitvec", - "bytecheck", - "hashbrown 0.12.3", - "ptr_meta", - "rend", - "rkyv_derive", - "seahash", - "tinyvec", - "uuid", -] - -[[package]] -name = "rkyv_derive" -version = "0.7.42" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2e06b915b5c230a17d7a736d1e2e63ee753c256a8614ef3f5147b13a4f5541d" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "rmp" -version = "0.8.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7f9860a6cc38ed1da53456442089b4dfa35e7cedaa326df63017af88385e6b20" -dependencies = [ - "byteorder", - "num-traits", - "paste", -] - -[[package]] -name = "rmp-serde" -version = "1.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bffea85eea980d8a74453e5d02a8d93028f3c34725de143085a844ebe953258a" -dependencies = [ - "byteorder", - "rmp", - "serde", -] - -[[package]] -name = "rust_decimal" -version = "1.32.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4c4216490d5a413bc6d10fa4742bd7d4955941d062c0ef873141d6b0e7b30fd" -dependencies = [ - "arrayvec", - "borsh 0.10.3", - "bytes", - "num-traits", - "rand 0.8.5", - "rkyv", - "serde", - "serde_json", -] - -[[package]] -name = "rustc-demangle" -version = "0.1.23" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" - -[[package]] -name = "rustc-hash" -version = "1.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" - -[[package]] -name = "rustc_version" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" -dependencies = [ - "semver", -] - -[[package]] -name = "rustix" -version = "0.37.24" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4279d76516df406a8bd37e7dff53fd37d1a093f997a3c34a5c21658c126db06d" -dependencies = [ - "bitflags 1.3.2", - "errno", - "io-lifetimes", - "libc", - "linux-raw-sys 0.3.8", - "windows-sys", -] - -[[package]] -name = "rustix" -version = "0.38.18" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a74ee2d7c2581cd139b42447d7d9389b889bdaad3a73f1ebb16f2a3237bb19c" -dependencies = [ - "bitflags 2.4.0", - "errno", - "libc", - "linux-raw-sys 0.4.10", - "windows-sys", -] - -[[package]] -name = "rustls" -version = "0.20.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b80e3dec595989ea8510028f30c408a4630db12c9cbb8de34203b89d6577e99" -dependencies = [ - "log", - "ring 0.16.20", - "sct", - "webpki", -] - -[[package]] -name = "rustls" -version = "0.21.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cd8d6c9f025a446bc4d18ad9632e69aec8f287aa84499ee335599fabd20c3fd8" -dependencies = [ - "log", - "ring 0.16.20", - "rustls-webpki", - "sct", -] - -[[package]] -name = "rustls-pemfile" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" -dependencies = [ - "base64 0.21.4", -] - -[[package]] -name = "rustls-webpki" -version = "0.101.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c7d5dece342910d9ba34d259310cae3e0154b873b35408b787b59bce53d34fe" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - -[[package]] -name = "rustversion" -version = "1.0.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" - -[[package]] -name = "ryu" -version = "1.0.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" - -[[package]] -name = "schannel" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c3733bf4cf7ea0880754e19cb5a462007c4a8c1914bff372ccc95b464f1df88" -dependencies = [ - "windows-sys", -] - -[[package]] -name = "schemars" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f7b0ce13155372a76ee2e1c5ffba1fe61ede73fbea5630d61eee6fac4929c0c" -dependencies = [ - "dyn-clone", - "schemars_derive", - "serde", - "serde_json", -] - -[[package]] -name = "schemars_derive" -version = "0.8.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e85e2a16b12bdb763244c69ab79363d71db2b4b918a2def53f80b02e0574b13c" -dependencies = [ - "proc-macro2", - "quote", - "serde_derive_internals", - "syn 1.0.109", -] - -[[package]] -name = "scopeguard" -version = "1.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" - -[[package]] -name = "scroll" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04c565b551bafbef4157586fa379538366e4385d42082f255bfd96e4fe8519da" -dependencies = [ - "scroll_derive", -] - -[[package]] -name = "scroll_derive" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1db149f81d46d2deba7cd3c50772474707729550221e69588478ebf9ada425ae" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "sct" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4" -dependencies = [ - "ring 0.16.20", - "untrusted 0.7.1", -] - -[[package]] -name = "sea-orm" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "88694d01b528a94f90ad87f8d2f546d060d070eee180315c67d158cb69476034" -dependencies = [ - "async-stream", - "async-trait", - "chrono", - "futures", - "futures-util", - "log", - "ouroboros", - "rust_decimal", - "sea-orm-macros", - "sea-query 0.27.2", - "sea-query-binder", - "sea-strum", - "serde", - "serde_json", - "sqlx", - "thiserror", - "time", - "tracing", - "url", - "uuid", -] - -[[package]] -name = "sea-orm-cli" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ebe1f820fe8949cf6a57272ba9ebd0be766e47c9b85c04b3cabea40ab9459b3" -dependencies = [ - "chrono", - "clap", - "dotenvy", - "regex", - "sea-schema", - "tracing", - "tracing-subscriber", - "url", -] - -[[package]] -name = "sea-orm-macros" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7216195de9c6b2474fd0efab486173dccd0eff21f28cc54aa4c0205d52fb3af0" -dependencies = [ - "bae", - "heck 0.3.3", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "sea-orm-migration" -version = "0.10.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ed3cdfa669e4c385922f902b9a58e0c2128782a4d0fe79c6c34f3b927565e5b" -dependencies = [ - "async-trait", - "clap", - "dotenvy", - "sea-orm", - "sea-orm-cli", - "sea-schema", - "tracing", - "tracing-subscriber", -] - -[[package]] -name = "sea-query" -version = "0.27.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4f0fc4d8e44e1d51c739a68d336252a18bc59553778075d5e32649be6ec92ed" -dependencies = [ - "chrono", - "rust_decimal", - "sea-query-derive 0.2.0", - "serde_json", - "time", - "uuid", -] - -[[package]] -name = "sea-query" -version = "0.28.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbab99b8cd878ab7786157b7eb8df96333a6807cc6e45e8888c85b51534b401a" -dependencies = [ - "sea-query-derive 0.3.0", -] - -[[package]] -name = "sea-query-binder" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c2585b89c985cfacfe0ec9fc9e7bb055b776c1a2581c4e3c6185af2b8bf8865" -dependencies = [ - "chrono", - "rust_decimal", - "sea-query 0.27.2", - "serde_json", - "sqlx", - "time", - "uuid", -] - -[[package]] -name = "sea-query-derive" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "34cdc022b4f606353fe5dc85b09713a04e433323b70163e81513b141c6ae6eb5" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "syn 1.0.109", - "thiserror", -] - -[[package]] -name = "sea-query-derive" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63f62030c60f3a691f5fe251713b4e220b306e50a71e1d6f9cce1f24bb781978" -dependencies = [ - "heck 0.4.1", - "proc-macro2", - "quote", - "syn 1.0.109", - "thiserror", -] - -[[package]] -name = "sea-schema" -version = "0.10.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d5fda574d980e9352b6c7abd6fc75697436fe0078cac2b548559b52643ad3b" -dependencies = [ - "futures", - "sea-query 0.27.2", - "sea-schema-derive", -] - -[[package]] -name = "sea-schema-derive" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56821b7076f5096b8f726e2791ad255a99c82498e08ec477a65a96c461ff1927" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "sea-strum" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "391d06a6007842cfe79ac6f7f53911b76dfd69fc9a6769f1cf6569d12ce20e1b" -dependencies = [ - "sea-strum_macros", -] - -[[package]] -name = "sea-strum_macros" -version = "0.23.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69b4397b825df6ccf1e98bcdabef3bbcfc47ff5853983467850eeab878384f21" -dependencies = [ - "heck 0.3.3", - "proc-macro2", - "quote", - "rustversion", - "syn 1.0.109", -] - -[[package]] -name = "seahash" -version = "4.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c107b6f4780854c8b126e228ea8869f4d7b71260f962fefb57b996b8959ba6b" - -[[package]] -name = "security-framework" -version = "2.9.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05b64fb303737d99b81884b2c63433e9ae28abebe5eb5045dcdd175dc2ecf4de" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "core-foundation-sys", - "libc", - "security-framework-sys", -] - -[[package]] -name = "security-framework-sys" -version = "2.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e932934257d3b408ed8f30db49d85ea163bfe74961f017f405b025af298f0c7a" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "semver" -version = "1.0.19" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad977052201c6de01a8ef2aa3378c4bd23217a056337d1d6da40468d267a4fb0" - -[[package]] -name = "serde" -version = "1.0.188" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf9e0fcba69a370eed61bcf2b728575f726b50b55cba78064753d708ddc7549e" -dependencies = [ - "serde_derive", -] - -[[package]] -name = "serde_bytes" -version = "0.11.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab33ec92f677585af6d88c65593ae2375adde54efdbf16d597f2cbc7a6d368ff" -dependencies = [ - "serde", -] - -[[package]] -name = "serde_derive" -version = "1.0.188" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4eca7ac642d82aa35b60049a6eccb4be6be75e599bd2e9adb5f875a737654af2" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "serde_derive_internals" -version = "0.26.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85bf8229e7920a9f636479437026331ce11aa132b4dde37d121944a44d6e5f3c" -dependencies = [ - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "serde_json" -version = "1.0.107" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b420ce6e3d8bd882e9b243c6eed35dbc9a6110c9769e74b584e0d68d1f20c65" -dependencies = [ - "indexmap 2.0.2", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_urlencoded" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" -dependencies = [ - "form_urlencoded", - "itoa", - "ryu", - "serde", -] - -[[package]] -name = "serde_with" -version = "1.14.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "678b5a069e50bf00ecd22d0cd8ddf7c236f68581b03db652061ed5eb13a312ff" -dependencies = [ - "serde", - "serde_with_macros 1.5.2", -] - -[[package]] -name = "serde_with" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07ff71d2c147a7b57362cead5e22f772cd52f6ab31cfcd9edcd7f6aeb2a0afbe" -dependencies = [ - "serde", - "serde_with_macros 2.3.3", -] - -[[package]] -name = "serde_with_macros" -version = "1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" -dependencies = [ - "darling 0.13.4", - "proc-macro2", - "quote", - "syn 1.0.109", -] - -[[package]] -name = "serde_with_macros" -version = "2.3.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "881b6f881b17d13214e5d494c939ebab463d01264ce1811e9d4ac3a882e7695f" -dependencies = [ - "darling 0.20.3", - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "sha1" -version = "0.10.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e3bf829a2d51ab4a5ddf1352d8470c140cadc8301b2ae1789db023f01cedd6ba" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha2" -version = "0.9.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4d58a1e1bf39749807d89cf2d98ac2dfa0ff1cb3faa38fbb64dd88ac8013d800" -dependencies = [ - "block-buffer 0.9.0", - "cfg-if", - "cpufeatures", - "digest 0.9.0", - "opaque-debug", -] - -[[package]] -name = "sha2" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "793db75ad2bcafc3ffa7c68b215fee268f537982cd901d132f89c6343f3a3dc8" -dependencies = [ - "cfg-if", - "cpufeatures", - "digest 0.10.7", -] - -[[package]] -name = "sha3" -version = "0.9.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f81199417d4e5de3f04b1e871023acea7389672c4135918f05aa9cbf2f2fa809" -dependencies = [ - "block-buffer 0.9.0", - "digest 0.9.0", - "keccak", - "opaque-debug", -] - -[[package]] -name = "sha3" -version = "0.10.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75872d278a8f37ef87fa0ddbda7802605cb18344497949862c0d4dcb291eba60" -dependencies = [ - "digest 0.10.7", - "keccak", -] - -[[package]] -name = "shank" -version = "0.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b63e565b5e95ad88ab38f312e89444c749360641c509ef2de0093b49f55974a5" -dependencies = [ - "shank_macro", -] - -[[package]] -name = "shank_macro" -version = "0.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "63927d22a1e8b74bda98cc6e151fcdf178b7abb0dc6c4f81e0bbf5ffe2fc4ec8" -dependencies = [ - "proc-macro2", - "quote", - "shank_macro_impl", - "syn 1.0.109", -] - -[[package]] -name = "shank_macro_impl" -version = "0.0.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40ce03403df682f80f4dc1efafa87a4d0cb89b03726d0565e6364bdca5b9a441" -dependencies = [ - "anyhow", - "proc-macro2", - "quote", - "serde", - "syn 1.0.109", -] - -[[package]] -name = "sharded-slab" -version = "0.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" -dependencies = [ - "lazy_static", -] - -[[package]] -name = "signal-hook-registry" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" -dependencies = [ - "libc", -] - -[[package]] -name = "signature" -version = "1.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" - -[[package]] -name = "simdutf8" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f27f6278552951f1f2b8cf9da965d10969b2efdea95a6ec47987ab46edfe263a" - -[[package]] -name = "sized-chunks" -version = "0.6.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16d69225bde7a69b235da73377861095455d298f2b970996eec25ddbb42b3d1e" -dependencies = [ - "bitmaps", - "typenum", -] - -[[package]] -name = "slab" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f92a496fb766b417c996b9c5e57daf2f7ad3b0bebe1ccfca4856390e3d3bb67" -dependencies = [ - "autocfg", -] - -[[package]] -name = "smallvec" -version = "1.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "942b4a808e05215192e39f4ab80813e599068285906cc91aa64f923db842bd5a" - -[[package]] -name = "socket2" -version = "0.4.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" -dependencies = [ - "libc", - "winapi", -] - -[[package]] -name = "socket2" -version = "0.5.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4031e820eb552adee9295814c0ced9e5cf38ddf1e8b7d566d6de8e2538ea989e" -dependencies = [ - "libc", - "windows-sys", -] - -[[package]] -name = "solana-account-decoder" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f52aec62a85932e26d1085864b0f7b99b31934aec8dd132429bfef6d7fb1d3a6" -dependencies = [ - "Inflector", - "base64 0.21.4", - "bincode", - "bs58 0.4.0", - "bv", - "lazy_static", - "serde", - "serde_derive", - "serde_json", - "solana-address-lookup-table-program", - "solana-config-program", - "solana-sdk", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", - "spl-token-metadata-interface", - "thiserror", - "zstd", -] - -[[package]] -name = "solana-address-lookup-table-program" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee0bd25f4ba0a15fc16c57b41b1e1b14f5271b83214fda158fdedb58758d394e" -dependencies = [ - "bincode", - "bytemuck", - "log", - "num-derive 0.3.3", - "num-traits", - "rustc_version", - "serde", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-program", - "solana-program-runtime", - "solana-sdk", - "thiserror", -] - -[[package]] -name = "solana-config-program" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7fd0fc1efb91a1661aeb1ff6a691156c3b1bffdaed0aa096589499dd83f9e50b" -dependencies = [ - "bincode", - "chrono", - "serde", - "serde_derive", - "solana-program-runtime", - "solana-sdk", -] - -[[package]] -name = "solana-frozen-abi" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02eb4f0ed3eade20f4abdcc0031167344237cd6e16808bd0f33945f9db7861fe" -dependencies = [ - "ahash 0.8.3", - "blake3", - "block-buffer 0.10.4", - "bs58 0.4.0", - "bv", - "byteorder", - "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", - "serde_derive", - "serde_json", - "sha2 0.10.8", - "solana-frozen-abi-macro", - "subtle", - "thiserror", -] - -[[package]] -name = "solana-frozen-abi-macro" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f28514761a285944cbad5b3d7930546369b80a713ba37d84bcf6ed2753611765" -dependencies = [ - "proc-macro2", - "quote", - "rustc_version", - "syn 2.0.38", -] - -[[package]] -name = "solana-gateway" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d148eb75d0799f6825dc2a840b85c065e3d6d12212845add3e059163f98770e" -dependencies = [ - "borsh 0.10.3", - "num-derive 0.4.1", - "num-traits", - "solana-program", - "thiserror", -] - -[[package]] -name = "solana-logger" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2c310c6749435ce1ea25a9ae3edfb2fd2c2aed2aa4d4f7e0487a8077a0b1ee30" -dependencies = [ - "env_logger", - "lazy_static", - "log", -] - -[[package]] -name = "solana-measure" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d171357580e62aa4ca19c780e25f4e74de064e2780cb8b9f6b6901d986fcd23" -dependencies = [ - "log", - "solana-sdk", -] - -[[package]] -name = "solana-metrics" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "013cbb3c82588278d2be18d3317ece5286cb54a3a06d5d38fc31e2a76a6d5e2d" -dependencies = [ - "crossbeam-channel", - "gethostname", - "lazy_static", - "log", - "reqwest", - "solana-sdk", -] - -[[package]] -name = "solana-program" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cff2aa5434a77413e9d43e971ceb47bdb003f2e8bbc0365a25b684aca2605c25" -dependencies = [ - "ark-bn254", - "ark-ec", - "ark-ff", - "ark-serialize", - "array-bytes", - "base64 0.21.4", - "bincode", - "bitflags 1.3.2", - "blake3", - "borsh 0.10.3", - "borsh 0.9.3", - "bs58 0.4.0", - "bv", - "bytemuck", - "cc", - "console_error_panic_hook", - "console_log", - "curve25519-dalek", - "getrandom 0.2.10", - "itertools 0.10.5", - "js-sys", - "lazy_static", - "libc", - "libsecp256k1", - "log", - "memoffset", - "num-bigint 0.4.4", - "num-derive 0.3.3", - "num-traits", - "parking_lot 0.12.1", - "rand 0.7.3", - "rand_chacha 0.2.2", - "rustc_version", - "rustversion", - "serde", - "serde_bytes", - "serde_derive", - "serde_json", - "sha2 0.10.8", - "sha3 0.10.8", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-sdk-macro", - "thiserror", - "tiny-bip39", - "wasm-bindgen", - "zeroize", -] - -[[package]] -name = "solana-program-runtime" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9d1832fefc2187142dac169812518ec20da68b09abad86e4a78f8ae1787e4f56" -dependencies = [ - "base64 0.21.4", - "bincode", - "eager", - "enum-iterator", - "itertools 0.10.5", - "libc", - "log", - "num-derive 0.3.3", - "num-traits", - "percentage", - "rand 0.7.3", - "rustc_version", - "serde", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-measure", - "solana-metrics", - "solana-sdk", - "solana_rbpf", - "thiserror", -] - -[[package]] -name = "solana-sdk" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8b1002048941cedbd7dd6a96fdaa3dc5238b998aaa70b81946b1e3ec108cc2be" -dependencies = [ - "assert_matches", - "base64 0.21.4", - "bincode", - "bitflags 1.3.2", - "borsh 0.10.3", - "bs58 0.4.0", - "bytemuck", - "byteorder", - "chrono", - "derivation-path", - "digest 0.10.7", - "ed25519-dalek", - "ed25519-dalek-bip32", - "generic-array", - "hmac 0.12.1", - "itertools 0.10.5", - "js-sys", - "lazy_static", - "libsecp256k1", - "log", - "memmap2", - "num-derive 0.3.3", - "num-traits", - "num_enum 0.6.1", - "pbkdf2 0.11.0", - "qstring", - "rand 0.7.3", - "rand_chacha 0.2.2", - "rustc_version", - "rustversion", - "serde", - "serde_bytes", - "serde_derive", - "serde_json", - "serde_with 2.3.3", - "sha2 0.10.8", - "sha3 0.10.8", - "solana-frozen-abi", - "solana-frozen-abi-macro", - "solana-logger", - "solana-program", - "solana-sdk-macro", - "thiserror", - "uriparse", - "wasm-bindgen", -] - -[[package]] -name = "solana-sdk-macro" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b41b63b2da4a37ce323aba108db21f4c7bfa638dd1bf58fdc870f83bdce48ba" -dependencies = [ - "bs58 0.4.0", - "proc-macro2", - "quote", - "rustversion", - "syn 2.0.38", -] - -[[package]] -name = "solana-transaction-status" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db0b811793e78a908119cc02edca3ff8b54d5660104ebd06cc0e2e7e2f66900b" -dependencies = [ - "Inflector", - "base64 0.21.4", - "bincode", - "borsh 0.10.3", - "bs58 0.4.0", - "lazy_static", - "log", - "serde", - "serde_derive", - "serde_json", - "solana-account-decoder", - "solana-address-lookup-table-program", - "solana-sdk", - "spl-associated-token-account", - "spl-memo 4.0.0", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", - "thiserror", -] - -[[package]] -name = "solana-zk-token-sdk" -version = "1.16.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d1fe77918563768a65fd5d6cd2fa06cf0aeb11e529a1ef8c230b0fe018600e3" -dependencies = [ - "aes-gcm-siv", - "base64 0.21.4", - "bincode", - "bytemuck", - "byteorder", - "curve25519-dalek", - "getrandom 0.1.16", - "itertools 0.10.5", - "lazy_static", - "merlin", - "num-derive 0.3.3", - "num-traits", - "rand 0.7.3", - "serde", - "serde_json", - "sha3 0.9.1", - "solana-program", - "solana-sdk", - "subtle", - "thiserror", - "zeroize", -] - -[[package]] -name = "solana_rbpf" -version = "0.6.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "17d4ba1e58947346e360fabde0697029d36ba83c42f669199b16a8931313cf29" -dependencies = [ - "byteorder", - "combine", - "goblin", - "hash32", - "libc", - "log", - "rand 0.8.5", - "rustc-demangle", - "scroll", - "thiserror", - "winapi", -] - -[[package]] -name = "spin" -version = "0.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e63cff320ae2c57904679ba7cb63280a3dc4613885beafb148ee7bf9aa9042d" - -[[package]] -name = "spin" -version = "0.9.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" - -[[package]] -name = "spl-account-compression" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df052fd79e45c75c84ef20f5f2dcf037aeed230d0f2400bf68fa388cc0ece240" -dependencies = [ - "anchor-lang", - "bytemuck", - "spl-concurrent-merkle-tree", - "spl-noop", -] - -[[package]] -name = "spl-associated-token-account" -version = "2.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "385e31c29981488f2820b2022d8e731aae3b02e6e18e2fd854e4c9a94dc44fc3" -dependencies = [ - "assert_matches", - "borsh 0.10.3", - "num-derive 0.4.1", - "num-traits", - "solana-program", - "spl-token 4.0.0", - "spl-token-2022 0.9.0", - "thiserror", -] - -[[package]] -name = "spl-concurrent-merkle-tree" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "141eaea58588beae81b71d101373a53f096737739873de42d6b1368bc2b8fc30" -dependencies = [ - "bytemuck", - "solana-program", - "thiserror", -] - -[[package]] -name = "spl-discriminator" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cce5d563b58ef1bb2cdbbfe0dfb9ffdc24903b10ae6a4df2d8f425ece375033f" -dependencies = [ - "bytemuck", - "solana-program", - "spl-discriminator-derive", -] - -[[package]] -name = "spl-discriminator-derive" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fadbefec4f3c678215ca72bd71862697bb06b41fd77c0088902dd3203354387b" -dependencies = [ - "quote", - "spl-discriminator-syn", - "syn 2.0.38", -] - -[[package]] -name = "spl-discriminator-syn" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0e5f2044ca42c8938d54d1255ce599c79a1ffd86b677dfab695caa20f9ffc3f2" -dependencies = [ - "proc-macro2", - "quote", - "sha2 0.10.8", - "syn 2.0.38", - "thiserror", -] - -[[package]] -name = "spl-memo" -version = "3.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd0dc6f70db6bacea7ff25870b016a65ba1d1b6013536f08e4fd79a8f9005325" -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-noop" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6dd67ea3d0070a12ff141f5da46f9695f49384a03bce1203a5608f5739437950" -dependencies = [ - "solana-program", -] - -[[package]] -name = "spl-pod" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2881dddfca792737c0706fa0175345ab282b1b0879c7d877bad129645737c079" -dependencies = [ - "borsh 0.10.3", - "bytemuck", - "solana-program", - "solana-zk-token-sdk", - "spl-program-error", -] - -[[package]] -name = "spl-program-error" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "249e0318493b6bcf27ae9902600566c689b7dfba9f1bdff5893e92253374e78c" -dependencies = [ - "num-derive 0.4.1", - "num-traits", - "solana-program", - "spl-program-error-derive", - "thiserror", -] - -[[package]] -name = "spl-program-error-derive" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab5269c8e868da17b6552ef35a51355a017bd8e0eae269c201fef830d35fa52c" -dependencies = [ - "proc-macro2", - "quote", - "sha2 0.10.8", - "syn 2.0.38", -] - -[[package]] -name = "spl-tlv-account-resolution" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "062e148d3eab7b165582757453632ffeef490c02c86a48bfdb4988f63eefb3b9" -dependencies = [ - "bytemuck", - "solana-program", - "spl-discriminator", - "spl-pod", - "spl-program-error", - "spl-type-length-value", -] - -[[package]] -name = "spl-token" -version = "3.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e85e168a785e82564160dcb87b2a8e04cee9bfd1f4d488c729d53d6a4bd300d" -dependencies = [ - "arrayref", - "bytemuck", - "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" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0043b590232c400bad5ee9eb983ced003d15163c4c5d56b090ac6d9a57457b47" -dependencies = [ - "arrayref", - "bytemuck", - "num-derive 0.3.3", - "num-traits", - "num_enum 0.5.11", - "solana-program", - "solana-zk-token-sdk", - "spl-memo 3.0.1", - "spl-token 3.5.0", - "thiserror", -] - -[[package]] -name = "spl-token-2022" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4abf34a65ba420584a0c35f3903f8d727d1f13ababbdc3f714c6b065a686e86" -dependencies = [ - "arrayref", - "bytemuck", - "num-derive 0.4.1", - "num-traits", - "num_enum 0.7.0", - "solana-program", - "solana-zk-token-sdk", - "spl-memo 4.0.0", - "spl-pod", - "spl-token 4.0.0", - "spl-token-metadata-interface", - "spl-transfer-hook-interface", - "spl-type-length-value", - "thiserror", -] - -[[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.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "051d31803f873cabe71aec3c1b849f35248beae5d19a347d93a5c9cccc5d5a9b" -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.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a468e6f6371f9c69aae760186ea9f1a01c2908351b06a5e0026d21cfc4d7ecac" -dependencies = [ - "bytemuck", - "solana-program", - "spl-discriminator", - "spl-pod", - "spl-program-error", -] - -[[package]] -name = "sqlformat" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6b7b278788e7be4d0d29c0f39497a0eef3fba6bbc8e70d8bf7fde46edeaa9e85" -dependencies = [ - "itertools 0.11.0", - "nom", - "unicode_categories", -] - -[[package]] -name = "sqlx" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8de3b03a925878ed54a954f621e64bf55a3c1bd29652d0d1a17830405350188" -dependencies = [ - "sqlx-core", - "sqlx-macros", -] - -[[package]] -name = "sqlx-core" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa8241483a83a3f33aa5fff7e7d9def398ff9990b2752b6c6112b83c6d246029" -dependencies = [ - "ahash 0.7.6", - "atoi", - "base64 0.13.1", - "bitflags 1.3.2", - "byteorder", - "bytes", - "chrono", - "crc", - "crossbeam-queue", - "dirs", - "dotenvy", - "either", - "event-listener", - "futures-channel", - "futures-core", - "futures-intrusive", - "futures-util", - "hashlink", - "hex", - "hkdf", - "hmac 0.12.1", - "indexmap 1.9.3", - "itoa", - "libc", - "log", - "md-5", - "memchr", - "num-bigint 0.4.4", - "once_cell", - "paste", - "percent-encoding", - "rand 0.8.5", - "rust_decimal", - "rustls 0.20.9", - "rustls-pemfile", - "serde", - "serde_json", - "sha1", - "sha2 0.10.8", - "smallvec", - "sqlformat", - "sqlx-rt", - "stringprep", - "thiserror", - "time", - "tokio-stream", - "url", - "uuid", - "webpki-roots 0.22.6", - "whoami", -] - -[[package]] -name = "sqlx-macros" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9966e64ae989e7e575b19d7265cb79d7fc3cbbdf179835cb0d716f294c2049c9" -dependencies = [ - "dotenvy", - "either", - "heck 0.4.1", - "once_cell", - "proc-macro2", - "quote", - "serde_json", - "sha2 0.10.8", - "sqlx-core", - "sqlx-rt", - "syn 1.0.109", - "url", -] - -[[package]] -name = "sqlx-rt" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "804d3f245f894e61b1e6263c84b23ca675d96753b5abfd5cc8597d86806e8024" -dependencies = [ - "once_cell", - "tokio", - "tokio-rustls 0.23.4", -] - -[[package]] -name = "stringprep" -version = "0.1.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb41d74e231a107a1b4ee36bd1214b11285b77768d2e3824aedafa988fd36ee6" -dependencies = [ - "finl_unicode", - "unicode-bidi", - "unicode-normalization", -] - -[[package]] -name = "strsim" -version = "0.10.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" - -[[package]] -name = "subtle" -version = "2.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" - -[[package]] -name = "syn" -version = "1.0.109" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "syn" -version = "2.0.38" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e96b79aaa137db8f61e26363a0c9b47d8b4ec75da28b7d1d614c2303e232408b" -dependencies = [ - "proc-macro2", - "quote", - "unicode-ident", -] - -[[package]] -name = "system-configuration" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" -dependencies = [ - "bitflags 1.3.2", - "core-foundation", - "system-configuration-sys", -] - -[[package]] -name = "system-configuration-sys" -version = "0.5.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" -dependencies = [ - "core-foundation-sys", - "libc", -] - -[[package]] -name = "tap" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" - -[[package]] -name = "tempfile" -version = "3.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb94d2f3cc536af71caac6b6fcebf65860b347e7ce0cc9ebe8f70d3e521054ef" -dependencies = [ - "cfg-if", - "fastrand 2.0.1", - "redox_syscall 0.3.5", - "rustix 0.38.18", - "windows-sys", -] - -[[package]] -name = "termcolor" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6093bad37da69aab9d123a8091e4be0aa4a03e4d601ec641c327398315f62b64" -dependencies = [ - "winapi-util", -] - -[[package]] -name = "textwrap" -version = "0.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" - -[[package]] -name = "thiserror" -version = "1.0.49" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1177e8c6d7ede7afde3585fd2513e611227efd6481bd78d2e82ba1ce16557ed4" -dependencies = [ - "thiserror-impl", -] - -[[package]] -name = "thiserror-impl" -version = "1.0.49" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10712f02019e9288794769fba95cd6847df9874d49d871d062172f9dd41bc4cc" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "thread_local" -version = "1.1.7" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" -dependencies = [ - "cfg-if", - "once_cell", -] - -[[package]] -name = "time" -version = "0.3.29" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "426f806f4089c493dcac0d24c29c01e2c38baf8e30f1b716ee37e83d200b18fe" -dependencies = [ - "deranged", - "itoa", - "serde", - "time-core", - "time-macros", -] - -[[package]] -name = "time-core" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" - -[[package]] -name = "time-macros" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ad70d68dba9e1f8aceda7aa6711965dfec1cac869f311a51bd08b3a2ccbce20" -dependencies = [ - "time-core", -] - -[[package]] -name = "tiny-bip39" -version = "0.8.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffc59cb9dfc85bb312c3a78fd6aa8a8582e310b0fa885d5bb877f6dcc601839d" -dependencies = [ - "anyhow", - "hmac 0.8.1", - "once_cell", - "pbkdf2 0.4.0", - "rand 0.7.3", - "rustc-hash", - "sha2 0.9.9", - "thiserror", - "unicode-normalization", - "wasm-bindgen", - "zeroize", -] - -[[package]] -name = "tinyvec" -version = "1.6.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cc5ceb3875bb20c2890005a4e226a4651264a5c75edb2421b52861a0a0cb50" -dependencies = [ - "tinyvec_macros", -] - -[[package]] -name = "tinyvec_macros" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" - -[[package]] -name = "tokio" -version = "1.33.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f38200e3ef7995e5ef13baec2f432a6da0aa9ac495b2c0e8f3b7eec2c92d653" -dependencies = [ - "backtrace", - "bytes", - "libc", - "mio", - "num_cpus", - "parking_lot 0.12.1", - "pin-project-lite", - "signal-hook-registry", - "socket2 0.5.4", - "tokio-macros", - "windows-sys", -] - -[[package]] -name = "tokio-macros" -version = "2.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "tokio-native-tls" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" -dependencies = [ - "native-tls", - "tokio", -] - -[[package]] -name = "tokio-rustls" -version = "0.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", - "tokio", -] - -[[package]] -name = "tokio-stream" -version = "0.1.14" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" -dependencies = [ - "futures-core", - "pin-project-lite", - "tokio", -] - -[[package]] -name = "tokio-util" -version = "0.7.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d68074620f57a0b21594d9735eb2e98ab38b17f80d3fcb189fca266771ca60d" -dependencies = [ - "bytes", - "futures-core", - "futures-sink", - "pin-project-lite", - "tokio", - "tracing", -] - -[[package]] -name = "toml" -version = "0.5.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f4f7f0dd8d50a853a531c426359045b1998f04219d88799810762cd4ad314234" -dependencies = [ - "serde", -] - -[[package]] -name = "toml_datetime" -version = "0.6.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" - -[[package]] -name = "toml_edit" -version = "0.19.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" -dependencies = [ - "indexmap 2.0.2", - "toml_datetime", - "winnow", -] - -[[package]] -name = "tower-service" -version = "0.3.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6bc1c9ce2b5135ac7f93c72918fc37feb872bdc6a5533a8b85eb4b86bfdae52" - -[[package]] -name = "tracing" -version = "0.1.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ce8c33a8d48bd45d624a6e523445fd21ec13d3653cd51f681abf67418f54eb8" -dependencies = [ - "cfg-if", - "log", - "pin-project-lite", - "tracing-attributes", - "tracing-core", -] - -[[package]] -name = "tracing-attributes" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "tracing-core" -version = "0.1.31" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0955b8137a1df6f1a2e9a37d8a6656291ff0297c1a97c24e0d8425fe2312f79a" -dependencies = [ - "once_cell", - "valuable", -] - -[[package]] -name = "tracing-log" -version = "0.1.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78ddad33d2d10b1ed7eb9d1f518a5674713876e97e5bb9b7345a7984fbb4f922" -dependencies = [ - "lazy_static", - "log", - "tracing-core", -] - -[[package]] -name = "tracing-subscriber" -version = "0.3.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" -dependencies = [ - "matchers", - "nu-ansi-term", - "once_cell", - "regex", - "sharded-slab", - "smallvec", - "thread_local", - "tracing", - "tracing-core", - "tracing-log", -] - -[[package]] -name = "try-lock" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed" - -[[package]] -name = "typenum" -version = "1.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42ff0bf0c66b8238c6f3b578df37d0b7848e55df8577b3f74f92a69acceeb825" - -[[package]] -name = "unicase" -version = "2.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7d2d4dafb69621809a81864c9c1b864479e1235c0dd4e199924b9742439ed89" -dependencies = [ - "version_check", -] - -[[package]] -name = "unicode-bidi" -version = "0.3.13" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" - -[[package]] -name = "unicode-ident" -version = "1.0.12" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" - -[[package]] -name = "unicode-normalization" -version = "0.1.22" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c5713f0fc4b5db668a2ac63cdb7bb4469d8c9fed047b1d0292cc7b0ce2ba921" -dependencies = [ - "tinyvec", -] - -[[package]] -name = "unicode-segmentation" -version = "1.10.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" - -[[package]] -name = "unicode_categories" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e" - -[[package]] -name = "universal-hash" -version = "0.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f214e8f697e925001e66ec2c6e37a4ef93f0f78c2eed7814394e10c62025b05" -dependencies = [ - "generic-array", - "subtle", -] - -[[package]] -name = "unreachable" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "382810877fe448991dfc7f0dd6e3ae5d58088fd0ea5e35189655f84e6814fa56" -dependencies = [ - "void", -] - -[[package]] -name = "untrusted" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" - -[[package]] -name = "untrusted" -version = "0.9.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" - -[[package]] -name = "uriparse" -version = "0.6.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0200d0fc04d809396c2ad43f3c95da3582a2556eba8d453c1087f4120ee352ff" -dependencies = [ - "fnv", - "lazy_static", -] - -[[package]] -name = "url" -version = "2.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "143b538f18257fac9cad154828a57c6bf5157e1aa604d4816b5995bf6de87ae5" -dependencies = [ - "form_urlencoded", - "idna", - "percent-encoding", -] - -[[package]] -name = "uuid" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79daa5ed5740825c40b389c5e50312b9c86df53fccd33f281df655642b43869d" -dependencies = [ - "getrandom 0.2.10", - "serde", -] - -[[package]] -name = "valuable" -version = "0.1.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" - -[[package]] -name = "value-bag" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d92ccd67fb88503048c01b59152a04effd0782d035a83a6d256ce6085f08f4a3" - -[[package]] -name = "vcpkg" -version = "0.2.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" - -[[package]] -name = "version_check" -version = "0.9.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" - -[[package]] -name = "void" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" - -[[package]] -name = "waker-fn" -version = "1.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3c4517f54858c779bbcbf228f4fca63d121bf85fbecb2dc578cdf4a39395690" - -[[package]] -name = "want" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" -dependencies = [ - "try-lock", -] - -[[package]] -name = "wasi" -version = "0.9.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cccddf32554fecc6acb585f82a32a72e28b48f8c4c1883ddfeeeaa96f7d8e519" - -[[package]] -name = "wasi" -version = "0.11.0+wasi-snapshot-preview1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" - -[[package]] -name = "wasm-bindgen" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" -dependencies = [ - "cfg-if", - "wasm-bindgen-macro", -] - -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" -dependencies = [ - "bumpalo", - "log", - "once_cell", - "proc-macro2", - "quote", - "syn 2.0.38", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-futures" -version = "0.4.37" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" -dependencies = [ - "cfg-if", - "js-sys", - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "wasm-bindgen-macro" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" -dependencies = [ - "quote", - "wasm-bindgen-macro-support", -] - -[[package]] -name = "wasm-bindgen-macro-support" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", - "wasm-bindgen-backend", - "wasm-bindgen-shared", -] - -[[package]] -name = "wasm-bindgen-shared" -version = "0.2.87" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" - -[[package]] -name = "web-sys" -version = "0.3.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" -dependencies = [ - "js-sys", - "wasm-bindgen", -] - -[[package]] -name = "webpki" -version = "0.22.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed63aea5ce73d0ff405984102c42de94fc55a6b75765d621c65262469b3c9b53" -dependencies = [ - "ring 0.17.2", - "untrusted 0.9.0", -] - -[[package]] -name = "webpki-roots" -version = "0.22.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b6c71e40d7d2c34a5106301fb632274ca37242cd0c9d3e64dbece371a40a2d87" -dependencies = [ - "webpki", -] - -[[package]] -name = "webpki-roots" -version = "0.25.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "14247bb57be4f377dfb94c72830b8ce8fc6beac03cf4bf7b9732eadd414123fc" - -[[package]] -name = "whoami" -version = "1.4.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22fc3756b8a9133049b26c7f61ab35416c130e8c09b660f5b3958b446f52cc50" -dependencies = [ - "wasm-bindgen", - "web-sys", -] - -[[package]] -name = "winapi" -version = "0.3.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419" -dependencies = [ - "winapi-i686-pc-windows-gnu", - "winapi-x86_64-pc-windows-gnu", -] - -[[package]] -name = "winapi-i686-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" - -[[package]] -name = "winapi-util" -version = "0.1.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f29e6f9198ba0d26b4c9f07dbe6f9ed633e1f3d5b8b414090084349e46a52596" -dependencies = [ - "winapi", -] - -[[package]] -name = "winapi-x86_64-pc-windows-gnu" -version = "0.4.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" - -[[package]] -name = "windows" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e686886bc078bc1b0b600cac0147aadb815089b6e4da64016cbd754b6342700f" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-sys" -version = "0.48.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" -dependencies = [ - "windows-targets", -] - -[[package]] -name = "windows-targets" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" -dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc", - "windows_i686_gnu", - "windows_i686_msvc", - "windows_x86_64_gnu", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc", -] - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" - -[[package]] -name = "windows_i686_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" - -[[package]] -name = "windows_i686_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.48.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" - -[[package]] -name = "winnow" -version = "0.5.16" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "037711d82167854aff2018dfd193aa0fef5370f456732f0d5a0c59b0f1b4b907" -dependencies = [ - "memchr", -] - -[[package]] -name = "winreg" -version = "0.50.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "524e57b2c537c0f9b1e69f1965311ec12182b4122e45035b1508cd24d2adadb1" -dependencies = [ - "cfg-if", - "windows-sys", -] - -[[package]] -name = "wyz" -version = "0.5.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed" -dependencies = [ - "tap", -] - -[[package]] -name = "zeroize" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4756f7db3f7b5574938c3eb1c117038b8e07f95ee6718c0efad4ac21508f1efd" -dependencies = [ - "zeroize_derive", -] - -[[package]] -name = "zeroize_derive" -version = "1.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" -dependencies = [ - "proc-macro2", - "quote", - "syn 2.0.38", -] - -[[package]] -name = "zstd" -version = "0.11.2+zstd.1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20cc960326ece64f010d2d2107537f26dc589a6573a316bd5b1dba685fa5fde4" -dependencies = [ - "zstd-safe", -] - -[[package]] -name = "zstd-safe" -version = "5.0.2+zstd.1.5.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d2a5585e04f9eea4b2a3d1eca508c4dee9592a89ef6f450c11719da0726f4db" -dependencies = [ - "libc", - "zstd-sys", -] - -[[package]] -name = "zstd-sys" -version = "2.0.8+zstd.1.5.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5556e6ee25d32df2586c098bbfa278803692a20d0ab9565e049480d52707ec8c" -dependencies = [ - "cc", - "libc", - "pkg-config", -] diff --git a/migration/Cargo.toml b/migration/Cargo.toml index a7f6a9f94..c0202ffdd 100644 --- a/migration/Cargo.toml +++ b/migration/Cargo.toml @@ -1,22 +1,15 @@ [package] name = "migration" -version = "0.7.2" -edition = "2021" -publish = false - -[lib] -name = "migration" -path = "src/lib.rs" +version = { workspace = true } +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -async-std = { version = "^1", features = ["attributes", "tokio1", ] } -digital_asset_types = { path = "../digital_asset_types", features = ["json_types", "sql_types"] } -enum-iterator = "1.2.0" -enum-iterator-derive = "1.1.0" +async-std = { workspace = true, features = ["attributes", "tokio1"] } +enum-iterator = { workspace = true } +enum-iterator-derive = { workspace = true } +sea-orm-migration = { workspace = true, features = ["runtime-tokio-rustls", "sqlx-postgres"] } -[dependencies.sea-orm-migration] -version = "0.10.6" -features = [ - "runtime-tokio-rustls", - "sqlx-postgres", -] +[lints] +workspace = true diff --git a/migration/src/lib.rs b/migration/src/lib.rs index f30bea3ae..55b5e46dc 100644 --- a/migration/src/lib.rs +++ b/migration/src/lib.rs @@ -31,9 +31,13 @@ mod m20230726_013107_remove_not_null_constraint_from_group_value; mod m20230908_160822_add_cl_audits_v2; mod m20230918_182123_add_raw_name_symbol; mod m20230919_072154_cl_audits; -mod m20231101_120101_add_instruction_into_cl_audit; -mod m20231101_120101_cl_audit_table_index; -mod m20231222_110618_add_indices_to_cl_audits_v2; +mod m20231019_120101_add_seq_numbers_bgum_update_metadata; +mod m20231206_120101_remove_was_decompressed; +mod m20240104_203133_add_cl_audits_v2; +mod m20240104_203328_remove_cl_audits; +mod m20240116_130744_add_update_metadata_ix; + +pub mod model; pub struct Migrator; @@ -72,9 +76,11 @@ impl MigratorTrait for Migrator { Box::new(m20230908_160822_add_cl_audits_v2::Migration), Box::new(m20230918_182123_add_raw_name_symbol::Migration), Box::new(m20230919_072154_cl_audits::Migration), - Box::new(m20231101_120101_add_instruction_into_cl_audit::Migration), - Box::new(m20231101_120101_cl_audit_table_index::Migration), - Box::new(m20231222_110618_add_indices_to_cl_audits_v2::Migration), + Box::new(m20231019_120101_add_seq_numbers_bgum_update_metadata::Migration), + Box::new(m20231206_120101_remove_was_decompressed::Migration), + Box::new(m20240104_203133_add_cl_audits_v2::Migration), + Box::new(m20240104_203328_remove_cl_audits::Migration), + Box::new(m20240116_130744_add_update_metadata_ix::Migration), ] } } diff --git a/migration/src/m20221020_052135_add_asset_hashes.rs b/migration/src/m20221020_052135_add_asset_hashes.rs index b2fe6f4c2..bf0a41f6a 100644 --- a/migration/src/m20221020_052135_add_asset_hashes.rs +++ b/migration/src/m20221020_052135_add_asset_hashes.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset; use sea_orm_migration::prelude::*; +use crate::model::table::Asset; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,24 +11,16 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) - .add_column( - ColumnDef::new(Alias::new("data_hash")) - .string() - .char_len(50), - ) + .table(Asset::Table) + .add_column(ColumnDef::new(Asset::DataHash).string().char_len(50)) .to_owned(), ) .await?; manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) - .add_column( - ColumnDef::new(Alias::new("creator_hash")) - .string() - .char_len(50), - ) + .table(Asset::Table) + .add_column(ColumnDef::new(Asset::CreatorHash).string().char_len(50)) .to_owned(), ) .await?; @@ -38,16 +31,16 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) - .drop_column(Alias::new("data_hash")) + .table(Asset::Table) + .drop_column(Asset::DataHash) .to_owned(), ) .await?; manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) - .drop_column(Alias::new("creator_hash")) + .table(Asset::Table) + .drop_column(Asset::CreatorHash) .to_owned(), ) .await?; diff --git a/migration/src/m20221022_140350_add_creator_asset_unique_index.rs b/migration/src/m20221022_140350_add_creator_asset_unique_index.rs index 72deb33d9..6f4c21142 100644 --- a/migration/src/m20221022_140350_add_creator_asset_unique_index.rs +++ b/migration/src/m20221022_140350_add_creator_asset_unique_index.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_creators; use sea_orm_migration::prelude::*; +use crate::model::table::AssetCreators; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,16 +12,16 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("asset_creator") - .table(asset_creators::Entity) + .table(AssetCreators::Table) .to_owned(), ) .await?; manager .alter_table( Table::alter() - .table(asset_creators::Entity) + .table(AssetCreators::Table) .add_column( - ColumnDef::new(Alias::new("position")) + ColumnDef::new(AssetCreators::Position) .small_integer() .not_null() .default(-1), @@ -33,9 +34,9 @@ impl MigrationTrait for Migration { Index::create() .unique() .name("asset_creator_unique") - .col(asset_creators::Column::AssetId) - .col(asset_creators::Column::Creator) - .table(asset_creators::Entity) + .col(AssetCreators::AssetId) + .col(AssetCreators::Creator) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -44,9 +45,9 @@ impl MigrationTrait for Migration { Index::create() .unique() .name("asset_creator_pos_unique") - .col(asset_creators::Column::AssetId) - .col(Alias::new("position")) - .table(asset_creators::Entity) + .col(AssetCreators::AssetId) + .col(AssetCreators::Position) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -58,7 +59,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("asset_creator_unique") - .table(asset_creators::Entity) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -66,7 +67,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("asset_creator_pos_unique") - .table(asset_creators::Entity) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -74,9 +75,9 @@ impl MigrationTrait for Migration { .create_index( sea_query::Index::create() .name("asset_creator") - .col(asset_creators::Column::AssetId) - .col(asset_creators::Column::Creator) - .table(asset_creators::Entity) + .col(AssetCreators::AssetId) + .col(AssetCreators::Creator) + .table(AssetCreators::Table) .to_owned(), ) .await?; diff --git a/migration/src/m20221025_182127_remove_creator_error_unique_index.rs b/migration/src/m20221025_182127_remove_creator_error_unique_index.rs index 37d7f4b93..fdc32a218 100644 --- a/migration/src/m20221025_182127_remove_creator_error_unique_index.rs +++ b/migration/src/m20221025_182127_remove_creator_error_unique_index.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_creators; use sea_orm_migration::prelude::*; +use crate::model::table::AssetCreators; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -12,7 +13,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("asset_creators_asset_id") - .table(asset_creators::Entity) + .table(AssetCreators::Table) .to_owned(), ) .await?; diff --git a/migration/src/m20221026_155220_add_bg_tasks.rs b/migration/src/m20221026_155220_add_bg_tasks.rs index 3debeaf9b..8586a6013 100644 --- a/migration/src/m20221026_155220_add_bg_tasks.rs +++ b/migration/src/m20221026_155220_add_bg_tasks.rs @@ -1,4 +1,3 @@ - use enum_iterator::{all, Sequence}; use sea_orm_migration::prelude::extension::postgres::Type; use sea_orm_migration::prelude::*; @@ -32,12 +31,7 @@ impl MigrationTrait for Migration { .col(ColumnDef::new(Tasks::Data).json_binary().not_null()) .col( ColumnDef::new(Tasks::Status) - .enumeration( - Tasks::TaskStatus, - all::() - .map(|e| e) - .collect::>(), - ) + .enumeration(Tasks::TaskStatus, all::().collect::>()) .not_null(), ) .col(ColumnDef::new(Tasks::CreatedAt).date_time().not_null()) diff --git a/migration/src/m20221104_094327_add_backfiller_failed.rs b/migration/src/m20221104_094327_add_backfiller_failed.rs index a5972ad46..20fed6e4d 100644 --- a/migration/src/m20221104_094327_add_backfiller_failed.rs +++ b/migration/src/m20221104_094327_add_backfiller_failed.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::backfill_items; use sea_orm_migration::prelude::*; +use crate::model::table::BackfillItems; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,9 +12,9 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(backfill_items::Entity) + .table(BackfillItems::Table) .add_column( - ColumnDef::new(Alias::new("failed")) + ColumnDef::new(BackfillItems::Failed) .boolean() .not_null() .default(false), @@ -28,8 +29,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(backfill_items::Entity) - .drop_column(Alias::new("failed")) + .table(BackfillItems::Table) + .drop_column(BackfillItems::Failed) .to_owned(), ) .await diff --git a/migration/src/m20221114_173041_add_collection_info.rs b/migration/src/m20221114_173041_add_collection_info.rs index d48b890c3..c4f210bff 100644 --- a/migration/src/m20221114_173041_add_collection_info.rs +++ b/migration/src/m20221114_173041_add_collection_info.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset; use sea_orm_migration::prelude::*; +use crate::model::table::Asset; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,7 +11,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .add_column(ColumnDef::new(Alias::new("collection")).binary()) .to_owned(), ) @@ -19,7 +20,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .add_column( ColumnDef::new(Alias::new("collection_verified")) .boolean() @@ -37,7 +38,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .drop_column(Alias::new("collection")) .to_owned(), ) @@ -45,7 +46,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .drop_column(Alias::new("collection_verified")) .to_owned(), ) diff --git a/migration/src/m20221115_165700_add_backfiller_locked.rs b/migration/src/m20221115_165700_add_backfiller_locked.rs index 0d5955c7d..aca1e33d7 100644 --- a/migration/src/m20221115_165700_add_backfiller_locked.rs +++ b/migration/src/m20221115_165700_add_backfiller_locked.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::backfill_items; use sea_orm_migration::prelude::*; +use crate::model::table::BackfillItems; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,9 +12,9 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(backfill_items::Entity) + .table(BackfillItems::Table) .add_column( - ColumnDef::new(Alias::new("locked")) + ColumnDef::new(BackfillItems::Locked) .boolean() .not_null() .default(false), @@ -28,8 +29,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(backfill_items::Entity) - .drop_column(Alias::new("locked")) + .table(BackfillItems::Table) + .drop_column(BackfillItems::Locked) .to_owned(), ) .await diff --git a/migration/src/m20221116_110500_add_backfiller_failed_and_locked_indeces.rs b/migration/src/m20221116_110500_add_backfiller_failed_and_locked_indeces.rs index 605568ff2..3db51dd53 100644 --- a/migration/src/m20221116_110500_add_backfiller_failed_and_locked_indeces.rs +++ b/migration/src/m20221116_110500_add_backfiller_failed_and_locked_indeces.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::backfill_items; use sea_orm_migration::prelude::*; +use crate::model::table::BackfillItems; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,8 +12,8 @@ impl MigrationTrait for Migration { .create_index( Index::create() .name("backfill_items_failed_idx") - .col(backfill_items::Column::Failed) - .table(backfill_items::Entity) + .col(BackfillItems::Failed) + .table(BackfillItems::Table) .to_owned(), ) .await?; @@ -20,9 +21,9 @@ impl MigrationTrait for Migration { .create_index( Index::create() .name("backfill_items_tree_failed_idx") - .col(backfill_items::Column::Tree) - .col(backfill_items::Column::Failed) - .table(backfill_items::Entity) + .col(BackfillItems::Tree) + .col(BackfillItems::Failed) + .table(BackfillItems::Table) .to_owned(), ) .await?; @@ -30,8 +31,8 @@ impl MigrationTrait for Migration { .create_index( Index::create() .name("backfill_items_locked_idx") - .col(backfill_items::Column::Locked) - .table(backfill_items::Entity) + .col(BackfillItems::Locked) + .table(BackfillItems::Table) .to_owned(), ) .await?; @@ -39,9 +40,9 @@ impl MigrationTrait for Migration { .create_index( Index::create() .name("backfill_items_tree_locked_idx") - .col(backfill_items::Column::Tree) - .col(backfill_items::Column::Locked) - .table(backfill_items::Entity) + .col(BackfillItems::Tree) + .col(BackfillItems::Locked) + .table(BackfillItems::Table) .to_owned(), ) .await?; @@ -54,7 +55,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("backfill_items_failed_idx") - .table(backfill_items::Entity) + .table(BackfillItems::Table) .to_owned(), ) .await?; @@ -62,7 +63,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("backfill_items_tree_failed_idx") - .table(backfill_items::Entity) + .table(BackfillItems::Table) .to_owned(), ) .await?; @@ -70,7 +71,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("backfill_items_locked_idx") - .table(backfill_items::Entity) + .table(BackfillItems::Table) .to_owned(), ) .await?; @@ -78,7 +79,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("backfill_items_tree_locked_idx") - .table(backfill_items::Entity) + .table(BackfillItems::Table) .to_owned(), ) .await?; diff --git a/migration/src/m20230105_160722_drop_collection_info.rs b/migration/src/m20230105_160722_drop_collection_info.rs index 833b91caa..907a9eff5 100644 --- a/migration/src/m20230105_160722_drop_collection_info.rs +++ b/migration/src/m20230105_160722_drop_collection_info.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset; use sea_orm_migration::prelude::*; +use crate::model::table::Asset; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,7 +11,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .drop_column(Alias::new("collection")) .to_owned(), ) @@ -18,7 +19,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .drop_column(Alias::new("collection_verified")) .to_owned(), ) @@ -31,7 +32,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .add_column(ColumnDef::new(Alias::new("collection")).binary()) .to_owned(), ) @@ -40,7 +41,7 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset::Entity) + .table(Asset::Table) .add_column( ColumnDef::new(Alias::new("collection_verified")) .boolean() diff --git a/migration/src/m20230106_051135_unique_groupings.rs b/migration/src/m20230106_051135_unique_groupings.rs index 5caa14c5c..b538cb195 100644 --- a/migration/src/m20230106_051135_unique_groupings.rs +++ b/migration/src/m20230106_051135_unique_groupings.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_grouping; use sea_orm_migration::prelude::*; +use crate::model::table::AssetGrouping; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,7 +12,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("asset_grouping_value") - .table(asset_grouping::Entity) + .table(AssetGrouping::Table) .to_owned(), ) .await?; @@ -20,9 +21,9 @@ impl MigrationTrait for Migration { Index::create() .unique() .name("asset_grouping_key_unique") - .col(asset_grouping::Column::AssetId) - .col(asset_grouping::Column::GroupKey) - .table(asset_grouping::Entity) + .col(AssetGrouping::AssetId) + .col(AssetGrouping::GroupKey) + .table(AssetGrouping::Table) .to_owned(), ) .await?; @@ -34,18 +35,18 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("asset_grouping_key_unique") - .table(asset_grouping::Entity) + .table(AssetGrouping::Table) .to_owned(), ) .await?; - + manager .create_index( sea_query::Index::create() .name("asset_grouping_value") - .col(asset_grouping::Column::AssetId) - .col(asset_grouping::Column::GroupKey) - .table(asset_grouping::Entity) + .col(AssetGrouping::AssetId) + .col(AssetGrouping::GroupKey) + .table(AssetGrouping::Table) .to_owned(), ) .await?; diff --git a/migration/src/m20230131_140613_change_token_account_indexes.rs b/migration/src/m20230131_140613_change_token_account_indexes.rs index 81a6925af..3d28256cf 100644 --- a/migration/src/m20230131_140613_change_token_account_indexes.rs +++ b/migration/src/m20230131_140613_change_token_account_indexes.rs @@ -1,8 +1,9 @@ -use digital_asset_types::dao::token_accounts; use sea_orm_migration::{ prelude::*, sea_orm::{ConnectionTrait, DatabaseBackend, Statement}, }; + +use crate::model::table::TokenAccounts; #[derive(DeriveMigrationName)] pub struct Migration; @@ -13,7 +14,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("ta_amount") - .table(token_accounts::Entity) + .table(TokenAccounts::Table) .to_owned(), ) .await?; @@ -22,7 +23,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("ta_amount_del") - .table(token_accounts::Entity) + .table(TokenAccounts::Table) .to_owned(), ) .await?; @@ -31,7 +32,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("ta_slot_updated_idx") - .table(token_accounts::Entity) + .table(TokenAccounts::Table) .to_owned(), ) .await?; @@ -59,8 +60,8 @@ impl MigrationTrait for Migration { sea_query::Index::create() .name("ta_amount") .index_type(sea_query::IndexType::BTree) - .col(token_accounts::Column::Amount) - .table(token_accounts::Entity) + .col(TokenAccounts::Amount) + .table(TokenAccounts::Table) .to_owned(), ) .await?; @@ -70,8 +71,8 @@ impl MigrationTrait for Migration { sea_query::Index::create() .name("ta_amount_del") .index_type(sea_query::IndexType::BTree) - .col(token_accounts::Column::DelegatedAmount) - .table(token_accounts::Entity) + .col(TokenAccounts::DelegatedAmount) + .table(TokenAccounts::Table) .to_owned(), ) .await?; @@ -81,16 +82,10 @@ impl MigrationTrait for Migration { sea_query::Index::create() .name("ta_slot_updated_idx") .index_type(sea_query::IndexType::BTree) - .table(token_accounts::Entity) + .table(TokenAccounts::Table) .to_owned(), ) .await?; Ok(()) } } - -/// Learn more at https://docs.rs/sea-query#iden -#[derive(Iden)] -enum Index { - BRIN, -} diff --git a/migration/src/m20230203_205959_improve_upsert_perf.rs b/migration/src/m20230203_205959_improve_upsert_perf.rs index 1e3272689..584f8ab47 100644 --- a/migration/src/m20230203_205959_improve_upsert_perf.rs +++ b/migration/src/m20230203_205959_improve_upsert_perf.rs @@ -1,8 +1,9 @@ -use digital_asset_types::dao::{asset_data, tokens}; use sea_orm_migration::{ prelude::*, sea_orm::{ConnectionTrait, DatabaseBackend, Statement}, }; + +use crate::model::table::{AssetData, Tokens}; #[derive(DeriveMigrationName)] pub struct Migration; @@ -13,7 +14,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("t_slot_updated_idx") - .table(tokens::Entity) + .table(Tokens::Table) .to_owned(), ) .await?; @@ -22,7 +23,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("t_supply") - .table(tokens::Entity) + .table(Tokens::Table) .to_owned(), ) .await?; @@ -31,7 +32,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("t_decimals") - .table(tokens::Entity) + .table(Tokens::Table) .to_owned(), ) .await?; @@ -52,19 +53,19 @@ impl MigrationTrait for Migration { )) .await?; - manager + manager .get_connection() .execute(Statement::from_string( DatabaseBackend::Postgres, "ALTER TABLE asset SET (fillfactor = 85);".to_string(), )) - .await?; + .await?; manager .drop_index( sea_query::Index::drop() .name("slot_updated_idx") - .table(asset_data::Entity) + .table(AssetData::Table) .to_owned(), ) .await?; diff --git a/migration/src/m20230224_093722_performance_improvements.rs b/migration/src/m20230224_093722_performance_improvements.rs index a577d9223..18320dfdc 100644 --- a/migration/src/m20230224_093722_performance_improvements.rs +++ b/migration/src/m20230224_093722_performance_improvements.rs @@ -1,4 +1,3 @@ - use sea_orm_migration::{ prelude::*, sea_orm::{ConnectionTrait, DatabaseBackend, Statement}, diff --git a/migration/src/m20230310_162227_add_indexes_to_bg.rs b/migration/src/m20230310_162227_add_indexes_to_bg.rs index b8f9a501f..2100ec552 100644 --- a/migration/src/m20230310_162227_add_indexes_to_bg.rs +++ b/migration/src/m20230310_162227_add_indexes_to_bg.rs @@ -1,9 +1,10 @@ -use digital_asset_types::dao::tasks; use sea_orm_migration::{ prelude::*, sea_orm::{ConnectionTrait, DatabaseBackend, Statement}, }; +use crate::model::table::Tasks; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -15,7 +16,7 @@ impl MigrationTrait for Migration { .execute(Statement::from_string( DatabaseBackend::Postgres, "CREATE INDEX IF NOT EXISTS tasks_created_at ON tasks USING BRIN(created_at);" - .to_string(), + .to_string(), )) .await?; manager @@ -23,7 +24,7 @@ impl MigrationTrait for Migration { .execute(Statement::from_string( DatabaseBackend::Postgres, "CREATE INDEX IF NOT EXISTS tasks_locked_until ON tasks USING BRIN(locked_until);" - .to_string(), + .to_string(), )) .await?; manager @@ -31,15 +32,14 @@ impl MigrationTrait for Migration { .execute(Statement::from_string( DatabaseBackend::Postgres, "CREATE INDEX IF NOT EXISTS task_attempts ON tasks USING BRIN(attempts);" - .to_string(), + .to_string(), )) .await?; manager .get_connection() .execute(Statement::from_string( DatabaseBackend::Postgres, - "CREATE INDEX IF NOT EXISTS task_status ON tasks (status);" - .to_string(), + "CREATE INDEX IF NOT EXISTS task_status ON tasks (status);".to_string(), )) .await?; Ok(()) @@ -51,7 +51,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("tasks_created_at") - .table(tasks::Entity) + .table(Tasks::Table) .to_owned(), ) .await?; @@ -59,7 +59,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("tasks_locked_until") - .table(tasks::Entity) + .table(Tasks::Table) .to_owned(), ) .await?; @@ -67,7 +67,7 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("task_attempts") - .table(tasks::Entity) + .table(Tasks::Table) .to_owned(), ) .await?; @@ -75,10 +75,10 @@ impl MigrationTrait for Migration { .drop_index( sea_query::Index::drop() .name("task_status") - .table(tasks::Entity) + .table(Tasks::Table) .to_owned(), ) .await?; Ok(()) } -} \ No newline at end of file +} diff --git a/migration/src/m20230317_121944_remove_indexes_for_perf.rs b/migration/src/m20230317_121944_remove_indexes_for_perf.rs index 1643b8cea..bda6d757f 100644 --- a/migration/src/m20230317_121944_remove_indexes_for_perf.rs +++ b/migration/src/m20230317_121944_remove_indexes_for_perf.rs @@ -1,7 +1,5 @@ use sea_orm_migration::prelude::*; -use sea_orm_migration::{ - sea_orm::{ConnectionTrait, DatabaseBackend, Statement}, -}; +use sea_orm_migration::sea_orm::{ConnectionTrait, DatabaseBackend, Statement}; #[derive(DeriveMigrationName)] pub struct Migration; diff --git a/migration/src/m20230510_183736_add_indices_to_assets.rs b/migration/src/m20230510_183736_add_indices_to_assets.rs index 3a7e58f1d..7b66de18a 100644 --- a/migration/src/m20230510_183736_add_indices_to_assets.rs +++ b/migration/src/m20230510_183736_add_indices_to_assets.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::{asset_authority, asset_creators}; use sea_orm_migration::prelude::*; +use crate::model::table::{AssetAuthority, AssetCreators}; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,8 +12,8 @@ impl MigrationTrait for Migration { .create_index( Index::create() .name("idx_asset_creators_asset_id") - .col(asset_creators::Column::AssetId) - .table(asset_creators::Entity) + .col(AssetCreators::AssetId) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -21,8 +22,8 @@ impl MigrationTrait for Migration { .create_index( Index::create() .name("idx_asset_creators_creator") - .col(asset_creators::Column::Creator) - .table(asset_creators::Entity) + .col(AssetCreators::Creator) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -31,8 +32,8 @@ impl MigrationTrait for Migration { .create_index( Index::create() .name("idx_asset_authority_authority") - .col(asset_authority::Column::Authority) - .table(asset_authority::Entity) + .col(AssetAuthority::Authority) + .table(AssetAuthority::Table) .to_owned(), ) .await?; @@ -44,7 +45,7 @@ impl MigrationTrait for Migration { .drop_index( Index::drop() .name("idx_asset_creators_asset_id") - .table(asset_creators::Entity) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -53,7 +54,7 @@ impl MigrationTrait for Migration { .drop_index( Index::drop() .name("idx_asset_creators_creator") - .table(asset_creators::Entity) + .table(AssetCreators::Table) .to_owned(), ) .await?; @@ -62,7 +63,7 @@ impl MigrationTrait for Migration { .drop_index( Index::drop() .name("idx_asset_authority_authority") - .table(asset_authority::Entity) + .table(AssetAuthority::Table) .to_owned(), ) .await?; diff --git a/migration/src/m20230516_185005_add_reindex_to_assets.rs b/migration/src/m20230516_185005_add_reindex_to_assets.rs index 81d339701..ce5a86725 100644 --- a/migration/src/m20230516_185005_add_reindex_to_assets.rs +++ b/migration/src/m20230516_185005_add_reindex_to_assets.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_data; use sea_orm_migration::prelude::*; +use crate::model::table::AssetData; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,12 +11,8 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset_data::Entity) - .add_column( - ColumnDef::new(Alias::new("reindex")) - .boolean() - .default(false), - ) + .table(AssetData::Table) + .add_column(ColumnDef::new(AssetData::Reindex).boolean().default(false)) .to_owned(), ) .await?; @@ -26,8 +23,8 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset_data::Entity) - .drop_column(Alias::new("reindex")) + .table(AssetData::Table) + .drop_column(AssetData::Reindex) .to_owned(), ) .await?; diff --git a/migration/src/m20230526_120101_add_owner_delegate_sequence_number.rs b/migration/src/m20230526_120101_add_owner_delegate_sequence_number.rs index 330629abd..312ab84d0 100644 --- a/migration/src/m20230526_120101_add_owner_delegate_sequence_number.rs +++ b/migration/src/m20230526_120101_add_owner_delegate_sequence_number.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset; use sea_orm_migration::prelude::*; +use crate::model::table::Asset; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,8 +11,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset::Entity) - .add_column(ColumnDef::new(Alias::new("owner_delegate_seq")).big_integer()) + .table(Asset::Table) + .add_column(ColumnDef::new(Asset::OwnerDelegateSeq).big_integer()) .to_owned(), ) .await?; @@ -23,8 +24,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset::Entity) - .drop_column(Alias::new("owner_delegate_seq")) + .table(Asset::Table) + .drop_column(Asset::OwnerDelegateSeq) .to_owned(), ) .await?; diff --git a/migration/src/m20230620_120101_add_was_decompressed.rs b/migration/src/m20230620_120101_add_was_decompressed.rs index f2abae13c..beefe7cc7 100644 --- a/migration/src/m20230620_120101_add_was_decompressed.rs +++ b/migration/src/m20230620_120101_add_was_decompressed.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset; use sea_orm_migration::prelude::*; +use crate::model::table::Asset; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,7 +11,7 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset::Entity) + .table(Asset::Table) .add_column( ColumnDef::new(Alias::new("was_decompressed")) .boolean() @@ -28,7 +29,7 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset::Entity) + .table(Asset::Table) .drop_column(Alias::new("was_decompressed")) .to_owned(), ) diff --git a/migration/src/m20230623_120101_add_leaf_sequence_number.rs b/migration/src/m20230623_120101_add_leaf_sequence_number.rs index 6ffee258d..95ba4cb91 100644 --- a/migration/src/m20230623_120101_add_leaf_sequence_number.rs +++ b/migration/src/m20230623_120101_add_leaf_sequence_number.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset; use sea_orm_migration::prelude::*; +use crate::model::table::Asset; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,8 +11,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset::Entity) - .add_column(ColumnDef::new(Alias::new("leaf_seq")).big_integer()) + .table(Asset::Table) + .add_column(ColumnDef::new(Asset::LeafSeq).big_integer()) .to_owned(), ) .await?; @@ -23,8 +24,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset::Entity) - .drop_column(Alias::new("leaf_seq")) + .table(Asset::Table) + .drop_column(Asset::LeafSeq) .to_owned(), ) .await?; diff --git a/migration/src/m20230720_120101_add_asset_grouping_verified.rs b/migration/src/m20230720_120101_add_asset_grouping_verified.rs index 8f1cfd4cc..801d379bd 100644 --- a/migration/src/m20230720_120101_add_asset_grouping_verified.rs +++ b/migration/src/m20230720_120101_add_asset_grouping_verified.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_grouping; use sea_orm_migration::prelude::*; +use crate::model::table::AssetGrouping; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,9 +12,9 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset_grouping::Entity) + .table(AssetGrouping::Table) .add_column( - ColumnDef::new(Alias::new("verified")) + ColumnDef::new(AssetGrouping::Verified) .boolean() .not_null() .default(false), @@ -28,8 +29,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset_grouping::Entity) - .drop_column(Alias::new("verified")) + .table(AssetGrouping::Table) + .drop_column(AssetGrouping::Verified) .to_owned(), ) .await diff --git a/migration/src/m20230724_120101_add_group_info_seq.rs b/migration/src/m20230724_120101_add_group_info_seq.rs index 89f2414a5..131bb208e 100644 --- a/migration/src/m20230724_120101_add_group_info_seq.rs +++ b/migration/src/m20230724_120101_add_group_info_seq.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_grouping; use sea_orm_migration::prelude::*; +use crate::model::table::AssetGrouping; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,8 +12,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset_grouping::Entity) - .add_column(ColumnDef::new(Alias::new("group_info_seq")).big_integer()) + .table(AssetGrouping::Table) + .add_column(ColumnDef::new(AssetGrouping::GroupInfoSeq).big_integer()) .to_owned(), ) .await?; @@ -25,8 +26,8 @@ impl MigrationTrait for Migration { manager .alter_table( Table::alter() - .table(asset_grouping::Entity) - .drop_column(Alias::new("group_info_seq")) + .table(AssetGrouping::Table) + .drop_column(AssetGrouping::GroupInfoSeq) .to_owned(), ) .await?; diff --git a/migration/src/m20230726_013107_remove_not_null_constraint_from_group_value.rs b/migration/src/m20230726_013107_remove_not_null_constraint_from_group_value.rs index 2ed0879ee..6a2098779 100644 --- a/migration/src/m20230726_013107_remove_not_null_constraint_from_group_value.rs +++ b/migration/src/m20230726_013107_remove_not_null_constraint_from_group_value.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_grouping; use sea_orm_migration::prelude::*; +use crate::model::table::AssetGrouping; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,8 +11,8 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset_grouping::Entity) - .modify_column(ColumnDef::new(asset_grouping::Column::GroupValue).null()) + .table(AssetGrouping::Table) + .modify_column(ColumnDef::new(AssetGrouping::GroupValue).null()) .to_owned(), ) .await?; @@ -25,8 +26,8 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset_grouping::Entity) - .modify_column(ColumnDef::new(asset_grouping::Column::GroupValue).not_null()) + .table(AssetGrouping::Table) + .modify_column(ColumnDef::new(AssetGrouping::GroupValue).not_null()) .to_owned(), ) .await?; diff --git a/migration/src/m20230908_160822_add_cl_audits_v2.rs b/migration/src/m20230908_160822_add_cl_audits_v2.rs index 5998e290e..2a0a1bbbd 100644 --- a/migration/src/m20230908_160822_add_cl_audits_v2.rs +++ b/migration/src/m20230908_160822_add_cl_audits_v2.rs @@ -14,7 +14,7 @@ impl MigrationTrait for Migration { .create_type( Type::create() .as_enum(BubblegumInstruction::Table) - .values(all::().map(|e| e).collect::>()) + .values(all::().collect::>()) .to_owned(), ) .await?; @@ -44,7 +44,7 @@ impl MigrationTrait for Migration { .col( ColumnDef::new(ClAuditsV2::Instruction) .custom(BubblegumInstruction::Table) - .not_null() + .not_null(), ) .to_owned(), ) @@ -60,7 +60,7 @@ impl MigrationTrait for Migration { } async fn down(&self, manager: &SchemaManager) -> Result<(), DbErr> { - manager + manager .drop_type( Type::drop() .if_exists() @@ -108,4 +108,4 @@ enum BubblegumInstruction { SetAndVerifyCollection, MintToCollectionV1, CreateTree, -} \ No newline at end of file +} diff --git a/migration/src/m20230918_182123_add_raw_name_symbol.rs b/migration/src/m20230918_182123_add_raw_name_symbol.rs index 6851e871e..5915ecac8 100644 --- a/migration/src/m20230918_182123_add_raw_name_symbol.rs +++ b/migration/src/m20230918_182123_add_raw_name_symbol.rs @@ -1,6 +1,7 @@ -use digital_asset_types::dao::asset_data; use sea_orm_migration::prelude::*; +use crate::model::table::AssetData; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -10,16 +11,16 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset_data::Entity) - .add_column(ColumnDef::new(Alias::new("raw_name")).binary()) + .table(AssetData::Table) + .add_column(ColumnDef::new(AssetData::RawName).binary()) .to_owned(), ) .await?; manager .alter_table( sea_query::Table::alter() - .table(asset_data::Entity) - .add_column(ColumnDef::new(Alias::new("raw_symbol")).binary()) + .table(AssetData::Table) + .add_column(ColumnDef::new(AssetData::RawSymbol).binary()) .to_owned(), ) .await?; @@ -30,8 +31,8 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset_data::Entity) - .drop_column(Alias::new("raw_name")) + .table(AssetData::Table) + .drop_column(AssetData::RawName) .to_owned(), ) .await?; @@ -39,8 +40,8 @@ impl MigrationTrait for Migration { manager .alter_table( sea_query::Table::alter() - .table(asset_data::Entity) - .drop_column(Alias::new("raw_symbol")) + .table(AssetData::Table) + .drop_column(AssetData::RawSymbol) .to_owned(), ) .await?; @@ -49,6 +50,7 @@ impl MigrationTrait for Migration { } /// Learn more at https://docs.rs/sea-query#iden +#[allow(dead_code)] #[derive(Iden)] enum Post { Table, diff --git a/migration/src/m20230919_072154_cl_audits.rs b/migration/src/m20230919_072154_cl_audits.rs index b9fd6e214..a3efecb27 100644 --- a/migration/src/m20230919_072154_cl_audits.rs +++ b/migration/src/m20230919_072154_cl_audits.rs @@ -1,5 +1,7 @@ use sea_orm_migration::prelude::*; +use crate::model::table::ClAudits; + #[derive(DeriveMigrationName)] pub struct Migration; @@ -11,14 +13,25 @@ impl MigrationTrait for Migration { Table::create() .table(ClAudits::Table) .if_not_exists() - .col(ColumnDef::new(ClAudits::Id).big_integer().not_null().primary_key().auto_increment()) + .col( + ColumnDef::new(ClAudits::Id) + .big_integer() + .not_null() + .primary_key() + .auto_increment(), + ) .col(ColumnDef::new(ClAudits::Tree).binary().not_null()) .col(ColumnDef::new(ClAudits::NodeIdx).big_integer().not_null()) .col(ColumnDef::new(ClAudits::LeafIdx).big_integer()) .col(ColumnDef::new(ClAudits::Seq).big_integer().not_null()) .col(ColumnDef::new(ClAudits::Level).big_integer().not_null()) .col(ColumnDef::new(ClAudits::Hash).binary().not_null()) - .col(ColumnDef::new(ClAudits::CreatedAt).date_time().default(SimpleExpr::Keyword(Keyword::CurrentTimestamp)).not_null()) + .col( + ColumnDef::new(ClAudits::CreatedAt) + .date_time() + .default(SimpleExpr::Keyword(Keyword::CurrentTimestamp)) + .not_null(), + ) .col(ColumnDef::new(ClAudits::Tx).string().not_null()) .to_owned(), ) @@ -31,18 +44,3 @@ impl MigrationTrait for Migration { .await } } - -/// Learn more at https://docs.rs/sea-query#iden -#[derive(Iden)] -enum ClAudits { - Table, - Id, - Tree, - NodeIdx, - LeafIdx, - Seq, - Level, - Hash, - CreatedAt, - Tx, -} diff --git a/migration/src/m20231019_120101_add_seq_numbers_bgum_update_metadata.rs b/migration/src/m20231019_120101_add_seq_numbers_bgum_update_metadata.rs new file mode 100644 index 000000000..29161637a --- /dev/null +++ b/migration/src/m20231019_120101_add_seq_numbers_bgum_update_metadata.rs @@ -0,0 +1,53 @@ +use sea_orm_migration::prelude::*; + +use crate::model::table::{Asset, AssetData}; + +#[derive(DeriveMigrationName)] +pub struct Migration; + +#[async_trait::async_trait] +impl MigrationTrait for Migration { + async fn up(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .alter_table( + Table::alter() + .table(AssetData::Table) + .add_column(ColumnDef::new(AssetData::BaseInfoSeq).big_integer()) + .to_owned(), + ) + .await?; + + manager + .alter_table( + Table::alter() + .table(Asset::Table) + .add_column(ColumnDef::new(Asset::BaseInfoSeq).big_integer()) + .to_owned(), + ) + .await?; + + Ok(()) + } + + async fn down(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .alter_table( + Table::alter() + .table(AssetData::Table) + .drop_column(AssetData::BaseInfoSeq) + .to_owned(), + ) + .await?; + + manager + .alter_table( + Table::alter() + .table(Asset::Table) + .drop_column(Asset::BaseInfoSeq) + .to_owned(), + ) + .await?; + + Ok(()) + } +} diff --git a/migration/src/m20231206_120101_remove_was_decompressed.rs b/migration/src/m20231206_120101_remove_was_decompressed.rs new file mode 100644 index 000000000..ea6cf7c22 --- /dev/null +++ b/migration/src/m20231206_120101_remove_was_decompressed.rs @@ -0,0 +1,40 @@ +use sea_orm_migration::prelude::*; + +use crate::model::table::Asset; + +#[derive(DeriveMigrationName)] +pub struct Migration; + +#[async_trait::async_trait] +impl MigrationTrait for Migration { + async fn up(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .alter_table( + Table::alter() + .table(Asset::Table) + .drop_column(Asset::WasDecompressed) + .to_owned(), + ) + .await?; + + Ok(()) + } + + async fn down(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .alter_table( + Table::alter() + .table(Asset::Table) + .add_column( + ColumnDef::new(Asset::WasDecompressed) + .boolean() + .not_null() + .default(false), + ) + .to_owned(), + ) + .await?; + + Ok(()) + } +} diff --git a/migration/src/m20240104_203133_add_cl_audits_v2.rs b/migration/src/m20240104_203133_add_cl_audits_v2.rs new file mode 100644 index 000000000..85e5d7665 --- /dev/null +++ b/migration/src/m20240104_203133_add_cl_audits_v2.rs @@ -0,0 +1,80 @@ +use enum_iterator::all; +use sea_orm_migration::prelude::*; +use sea_orm_migration::sea_orm::{ConnectionTrait, DatabaseBackend, Statement}; +use sea_orm_migration::sea_query::extension::postgres::Type; + +use crate::model::r#enum::BubblegumInstruction; +use crate::model::table::ClAuditsV2; + +#[derive(DeriveMigrationName)] +pub struct Migration; + +#[async_trait::async_trait] +impl MigrationTrait for Migration { + async fn up(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .create_type( + Type::create() + .as_enum(ClAuditsV2::Instruction) + .values(all::().collect::>()) + .to_owned(), + ) + .await?; + manager + .create_table( + Table::create() + .table(ClAuditsV2::Table) + .if_not_exists() + .col( + ColumnDef::new(ClAuditsV2::Id) + .big_integer() + .not_null() + .auto_increment() + .primary_key(), + ) + .col(ColumnDef::new(ClAuditsV2::Tree).binary().not_null()) + .col(ColumnDef::new(ClAuditsV2::LeafIdx).big_integer().not_null()) + .col(ColumnDef::new(ClAuditsV2::Seq).big_integer().not_null()) + .col( + ColumnDef::new(ClAuditsV2::CreatedAt) + .date_time() + .default(SimpleExpr::Keyword(Keyword::CurrentTimestamp)) + .not_null(), + ) + .col(ColumnDef::new(ClAuditsV2::Tx).binary().not_null()) + .col( + ColumnDef::new(ClAuditsV2::Instruction) + .enumeration( + ClAuditsV2::Instruction, + all::().collect::>(), + ) + .not_null(), + ) + .to_owned(), + ) + .await?; + + manager + .get_connection() + .execute(Statement::from_string( + DatabaseBackend::Postgres, + "ALTER TABLE cl_audits_v2 ADD CONSTRAINT unique_tree_leafidx_seq UNIQUE (tree, leaf_idx, seq);".to_string(), + )) + .await?; + Ok(()) + } + + async fn down(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .get_connection() + .execute(Statement::from_string( + DatabaseBackend::Postgres, + "ALTER TABLE cl_audits DROP CONSTRAINT unique_tree_leafidx_seq_tx;".to_string(), + )) + .await?; + manager + .drop_table(Table::drop().table(ClAuditsV2::Table).to_owned()) + .await?; + Ok(()) + } +} diff --git a/migration/src/m20240104_203328_remove_cl_audits.rs b/migration/src/m20240104_203328_remove_cl_audits.rs new file mode 100644 index 000000000..0a10302f4 --- /dev/null +++ b/migration/src/m20240104_203328_remove_cl_audits.rs @@ -0,0 +1,57 @@ +use sea_orm::Statement; +use sea_orm_migration::prelude::*; +use sea_orm_migration::sea_orm::{ConnectionTrait, DatabaseBackend}; + +use crate::model::table::ClAudits; + +#[derive(DeriveMigrationName)] +pub struct Migration; + +#[async_trait::async_trait] +impl MigrationTrait for Migration { + async fn up(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .get_connection() + .execute(Statement::from_string( + DatabaseBackend::Postgres, + " + DROP TABLE IF EXISTS cl_audits; + " + .to_string(), + )) + .await?; + Ok(()) + } + + async fn down(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .create_table( + Table::create() + .table(ClAudits::Table) + .if_not_exists() + .col( + ColumnDef::new(ClAudits::Id) + .big_integer() + .not_null() + .auto_increment(), + ) + .col(ColumnDef::new(ClAudits::Tree).binary().not_null()) + .col(ColumnDef::new(ClAudits::NodeIdx).big_integer().not_null()) + .col(ColumnDef::new(ClAudits::LeafIdx).big_integer()) + .col(ColumnDef::new(ClAudits::Seq).big_integer().not_null()) + .col(ColumnDef::new(ClAudits::Level).big_integer().not_null()) + .col(ColumnDef::new(ClAudits::Hash).binary().not_null()) + .col( + ColumnDef::new(ClAudits::CreatedAt) + .date_time() + .default(SimpleExpr::Keyword(Keyword::CurrentTimestamp)) + .not_null(), + ) + .col(ColumnDef::new(ClAudits::Tx).string().not_null()) + .to_owned(), + ) + .await?; + + Ok(()) + } +} diff --git a/migration/src/m20240116_130744_add_update_metadata_ix.rs b/migration/src/m20240116_130744_add_update_metadata_ix.rs new file mode 100644 index 000000000..7f35f8b48 --- /dev/null +++ b/migration/src/m20240116_130744_add_update_metadata_ix.rs @@ -0,0 +1,25 @@ +use sea_orm_migration::{prelude::*, sea_query::extension::postgres::Type}; + +use crate::model::table::ClAuditsV2; + +#[derive(DeriveMigrationName)] +pub struct Migration; + +#[async_trait::async_trait] +impl MigrationTrait for Migration { + async fn up(&self, manager: &SchemaManager) -> Result<(), DbErr> { + manager + .alter_type( + Type::alter() + .name(ClAuditsV2::Instruction) + .add_value(Alias::new("update_metadata")) + .to_owned(), + ) + .await + } + + async fn down(&self, _manager: &SchemaManager) -> Result<(), DbErr> { + // cannot rollback altering a type + Ok(()) + } +} diff --git a/migration/src/model/enum.rs b/migration/src/model/enum.rs new file mode 100644 index 000000000..4479367b0 --- /dev/null +++ b/migration/src/model/enum.rs @@ -0,0 +1,31 @@ +use enum_iterator::Sequence; +use sea_orm_migration::{prelude::*, sea_orm::EnumIter}; + +#[derive(Copy, Clone, Iden, EnumIter)] +pub enum Mutability { + Immutable, + Mutable, + Unknown, +} + +#[derive(Iden, Debug, PartialEq, Sequence)] +pub enum BubblegumInstruction { + Unknown, + MintV1, + Redeem, + CancelRedeem, + Transfer, + Delegate, + DecompressV1, + Compress, + Burn, + VerifyCreator, + UnverifyCreator, + VerifyCollection, + UnverifyCollection, + SetAndVerifyCollection, + MintToCollectionV1, + // Any new values cannot be added here, or else they will be added twice by the migrator (which will fail). + // We need to use an alias instead. + // UpdateMetadata, +} diff --git a/migration/src/model/mod.rs b/migration/src/model/mod.rs new file mode 100644 index 000000000..581e012a3 --- /dev/null +++ b/migration/src/model/mod.rs @@ -0,0 +1,2 @@ +pub mod r#enum; +pub mod table; diff --git a/migration/src/model/table.rs b/migration/src/model/table.rs new file mode 100644 index 000000000..a77e4abc0 --- /dev/null +++ b/migration/src/model/table.rs @@ -0,0 +1,168 @@ +use sea_orm_migration::prelude::*; + +#[derive(Copy, Clone, Iden)] +pub enum AssetCreators { + Table, + Id, + AssetId, + Creator, + Position, + Share, + Verified, + Seq, +} + +#[derive(Copy, Clone, Iden)] +pub enum AssetAuthority { + Table, + Id, + AssetId, + Authority, + SlotUpdated, + Seq, +} + +#[derive(Copy, Clone, Iden)] +pub enum AssetGrouping { + Table, + Id, + AssetId, + GroupKey, + GroupValue, + Seq, + SlotUpdated, + Verified, + GroupInfoSeq, +} + +#[derive(Copy, Clone, Iden)] +pub enum BackfillItems { + Table, + Id, + Tree, + Seq, + Slot, + ForceChk, + Backfilled, + Failed, + Locked, +} + +#[derive(Copy, Clone, Iden)] +pub enum Asset { + Table, + Id, + AltId, + SpecificationVersion, + SpecificationAssetClass, + Owner, + OwnerType, + Delegate, + Frozen, + Supply, + SupplyMint, + Compressed, + Compressible, + Seq, + TreeId, + Leaf, + Nonce, + RoyaltyTargetType, + RoyaltyTarget, + RoyaltyAmount, + AssetData, + CreatedAt, + Burnt, + SlotUpdated, + DataHash, + CreatorHash, + OwnerDelegateSeq, + WasDecompressed, + LeafSeq, + BaseInfoSeq, +} + +#[derive(Copy, Clone, Iden)] +pub enum AssetData { + Table, + Id, + ChainDataMutability, + ChainData, + MetadataUrl, + MetadataMutability, + Metadata, + SlotUpdated, + Reindex, + RawName, + RawSymbol, + BaseInfoSeq, +} + +#[derive(Copy, Clone, Iden)] +pub enum Tasks { + Table, + TaskType, + Data, + Status, + CreatedAt, + LockedUntil, + LockedBy, + MaxAttempts, + Attempts, + Duration, + Errors, +} + +#[derive(Copy, Clone, Iden)] +pub enum TokenAccounts { + Table, + Pubkey, + Mint, + Amount, + Owner, + Frozen, + CloseAuthority, + Delegate, + DelegatedAmount, + SlotUpdated, + TokenProgram, +} + +#[derive(Copy, Clone, Iden)] +pub enum Tokens { + Table, + Mint, + Supply, + Decimals, + TokenProgram, + MintAuthority, + FreezeAuthority, + CloseAuthority, + SlotUpdated, +} + +#[derive(Copy, Clone, Iden)] +pub enum ClAudits { + Table, + Id, + Tree, + NodeIdx, + LeafIdx, + Seq, + Level, + Hash, + CreatedAt, + Tx, +} + +#[derive(Copy, Clone, Iden)] +pub enum ClAuditsV2 { + Table, + Id, + Tree, + LeafIdx, + Seq, + CreatedAt, + Tx, + Instruction, +} diff --git a/nft_ingester/Cargo.toml b/nft_ingester/Cargo.toml index 44d593ab2..b38483698 100644 --- a/nft_ingester/Cargo.toml +++ b/nft_ingester/Cargo.toml @@ -1,87 +1,88 @@ [package] name = "nft_ingester" -version = "0.7.2" -edition = "2021" -publish = false +version = { workspace = true } +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -hex = "0.4.3" -log = "0.4.17" -env_logger = "0.10.0" -redis = { version = "0.22.3", features = [ +anchor-lang = { workspace = true } +async-trait = { workspace = true } +base64 = { workspace = true } +blockbuster = { workspace = true } +borsh = { workspace = true } +bs58 = { workspace = true } +cadence = { workspace = true } +cadence-macros = { workspace = true } +chrono = { workspace = true } +clap = { workspace = true, features = ["derive", "cargo"] } +das-metadata-json = { workspace = true } +digital_asset_types = { workspace = true, features = [ + "json_types", + "sql_types", +] } +env_logger = { workspace = true } +figment = { workspace = true, features = ["env", "toml", "yaml"] } +flatbuffers = { workspace = true } +futures = { workspace = true } +futures-util = { workspace = true } +hex = { workspace = true } +lazy_static = { workspace = true } +log = { workspace = true } +mpl-bubblegum = { workspace = true } +num-integer = { workspace = true } +num-traits = { workspace = true } +plerkle_messenger = { workspace = true, features = ["redis"] } +plerkle_serialization = { workspace = true } +rand = { workspace = true } +redis = { workspace = true, features = [ "aio", "tokio-comp", "streams", "tokio-native-tls-comp", ] } -futures = { version = "0.3.25" } -futures-util = "0.3.27" -base64 = "0.21.0" -thiserror = "1.0.31" -serde_json = "1.0.81" -tokio = { version = "1.26.0", features = ["full", "tracing"] } -sqlx = { version = "0.6.2", features = [ - "macros", - "runtime-tokio-rustls", - "postgres", - "uuid", - "offline", - "json", -] } -sea-orm = { version = "0.10.6", features = [ +regex = { workspace = true } +reqwest = { workspace = true } +rust-crypto = { workspace = true } +sea-orm = { workspace = true, features = [ "macros", "runtime-tokio-rustls", "sqlx-postgres", "with-chrono", "mock", ] } -das-metadata-json = { path = "../metadata_json" } -sea-query = { version = "0.28.1", features = ["postgres-array"] } -chrono = "0.4.19" -tokio-postgres = "0.7.7" -serde = "1.0.136" -bs58 = "0.4.0" -reqwest = "0.11.11" -plerkle_messenger = { version = "1.6.0", features = ['redis'] } -plerkle_serialization = { version = "1.6.0" } -flatbuffers = "23.1.21" -lazy_static = "1.4.0" -regex = "1.5.5" -digital_asset_types = { path = "../digital_asset_types", features = [ - "json_types", - "sql_types", +sea-query = { workspace = true, features = ["postgres-array"] } +serde = { workspace = true } +serde_json = { workspace = true } +solana-account-decoder = { workspace = true } +solana-client = { workspace = true } +solana-geyser-plugin-interface = { workspace = true } +solana-sdk = { workspace = true } +solana-sdk-macro = { workspace = true } +solana-transaction-status = { workspace = true } +spl-account-compression = { workspace = true, features = ["no-entrypoint"] } +spl-concurrent-merkle-tree = { workspace = true } +spl-token = { workspace = true, features = ["no-entrypoint"] } +sqlx = { workspace = true, features = [ + "macros", + "runtime-tokio-rustls", + "postgres", + "uuid", + "offline", + "json", ] } -mpl-bubblegum = "1.0.1-beta.3" -spl-account-compression = { version = "0.2.0", features = ["no-entrypoint"] } -spl-concurrent-merkle-tree = "0.2.0" -uuid = "1.0.0" -async-trait = "0.1.53" -num-traits = "0.2.15" -blockbuster = "0.9.0-beta.1" -figment = { version = "0.10.6", features = ["env", "toml", "yaml"] } -cadence = "0.29.0" -cadence-macros = "0.29.0" -solana-sdk = "~1.16.16" -solana-client = "~1.16.16" -spl-token = { version = ">= 3.5.0, < 5.0", features = ["no-entrypoint"] } -solana-transaction-status = "~1.16.16" -solana-account-decoder = "~1.16.16" -solana-geyser-plugin-interface = "~1.16.16" -solana-sdk-macro = "~1.16.16" -rand = "0.8.5" -rust-crypto = "0.2.36" -url = "2.3.1" -anchor-lang = "0.28.0" -borsh = "~0.10.3" -stretto = { version = "0.7", features = ["async"] } -tokio-stream = "0.1.12" -tracing-subscriber = { version = "0.3.16", features = [ +stretto = { workspace = true, features = ["async"] } +thiserror = { workspace = true } +tokio = { workspace = true, features = ["tracing"] } +tokio-postgres = { workspace = true } +tokio-stream = { workspace = true } +tracing-subscriber = { workspace = true, features = [ "json", "env-filter", "ansi", ] } -clap = { version = "4.2.2", features = ["derive", "cargo"] } +url = { workspace = true } +uuid = { workspace = true } -[dependencies.num-integer] -version = "0.1.44" -default-features = false +[lints] +workspace = true diff --git a/nft_ingester/src/account_updates.rs b/nft_ingester/src/account_updates.rs index ca949ca56..68b6c83a0 100644 --- a/nft_ingester/src/account_updates.rs +++ b/nft_ingester/src/account_updates.rs @@ -25,9 +25,8 @@ pub fn account_worker( ) -> JoinHandle<()> { tokio::spawn(async move { let source = T::new(config).await; - if let Ok(mut msg) = source { - let manager = Arc::new(ProgramTransformer::new(pool, bg_task_sender)); + let manager = Arc::new(ProgramTransformer::new(pool, bg_task_sender, false)); loop { let e = msg.recv(stream_key, consumption_type.clone()).await; let mut tasks = JoinSet::new(); @@ -49,14 +48,12 @@ pub fn account_worker( } } while let Some(res) = tasks.join_next().await { - if let Ok(id) = res { - if let Some(id) = id { - let send = ack_channel.send((stream_key, id)); - if let Err(err) = send { - metric! { + if let Ok(Some(id)) = res { + let send = ack_channel.send((stream_key, id)); + if let Err(err) = send { + metric! { error!("Account stream ack error: {}", err); statsd_count!("ingester.stream.ack_error", 1, "stream" => stream_key); - } } } } diff --git a/nft_ingester/src/ack.rs b/nft_ingester/src/ack.rs index 9c0f0c91b..5601b7ec4 100644 --- a/nft_ingester/src/ack.rs +++ b/nft_ingester/src/ack.rs @@ -29,7 +29,7 @@ pub fn ack_worker( } let len = acks.len(); for (stream, msgs) in acks.iter_mut() { - if let Err(e) = msg.ack_msg(&stream, &msgs).await { + if let Err(e) = msg.ack_msg(stream, msgs).await { error!("Error acking message: {}", e); } metric! { @@ -41,7 +41,7 @@ pub fn ack_worker( } Some(msg) = rx.recv() => { let (stream, msg) = msg; - let ackstream = acks.entry(stream).or_insert_with(Vec::::new); + let ackstream = acks.entry(stream).or_default(); ackstream.push(msg); } } diff --git a/nft_ingester/src/backfiller.rs b/nft_ingester/src/backfiller.rs index 3733d556a..95d641564 100644 --- a/nft_ingester/src/backfiller.rs +++ b/nft_ingester/src/backfiller.rs @@ -142,11 +142,12 @@ struct MissingTree { struct BackfillTree { unique_tree: UniqueTree, backfill_from_seq_1: bool, + #[allow(dead_code)] slot: u64, } impl BackfillTree { - fn new(unique_tree: UniqueTree, backfill_from_seq_1: bool, slot: u64) -> Self { + const fn new(unique_tree: UniqueTree, backfill_from_seq_1: bool, slot: u64) -> Self { Self { unique_tree, backfill_from_seq_1, @@ -176,7 +177,7 @@ struct GapInfo { } impl GapInfo { - fn new(prev: SimpleBackfillItem, curr: SimpleBackfillItem) -> Self { + const fn new(prev: SimpleBackfillItem, curr: SimpleBackfillItem) -> Self { Self { prev, curr } } } @@ -256,7 +257,7 @@ impl<'a, T: Messenger> Backfiller<'a, T> { let rpc_client = RpcClient::new_with_commitment(rpc_url, rpc_commitment); // Instantiate messenger. - let mut messenger = T::new(config.get_messneger_client_config()).await.unwrap(); + let mut messenger = T::new(config.get_messenger_client_config()).await.unwrap(); messenger .add_stream(TRANSACTION_BACKFILL_STREAM) .await @@ -513,7 +514,7 @@ impl<'a, T: Messenger> Backfiller<'a, T> { .into_iter() .map(|(k, s)| MissingTree { tree: k, slot: s.0 }) .collect::>(); - if missing_trees.len() > 0 { + if !missing_trees.is_empty() { info!("Number of Missing local trees: {}", missing_trees.len()); } else { debug!("No missing trees"); @@ -627,7 +628,15 @@ impl<'a, T: Messenger> Backfiller<'a, T> { &mut self, btree: &BackfillTree, ) -> Result, IngesterError> { - let address = Pubkey::new(btree.unique_tree.tree.as_slice()); + let address = match Pubkey::try_from(btree.unique_tree.tree.as_slice()) { + Ok(pubkey) => pubkey, + Err(error) => { + return Err(IngesterError::DeserializationError(format!( + "failed to parse pubkey: {error:?}" + ))) + } + }; + let slots = self.find_slots_via_address(&address).await?; let address = btree.unique_tree.tree.clone(); for slot in slots { @@ -692,6 +701,7 @@ impl<'a, T: Messenger> Backfiller<'a, T> { Ok(Vec::from_iter(slots)) } + #[allow(dead_code)] async fn get_max_seq(&self, tree: &[u8]) -> Result, DbErr> { let query = backfill_items::Entity::find() .select_only() @@ -734,34 +744,21 @@ impl<'a, T: Messenger> Backfiller<'a, T> { let mut list = HashMap::with_capacity(results.len()); for r in results.into_iter() { let (pubkey, mut account) = r; - let (mut header_bytes, rest) = account + let (header_bytes, rest) = account .data .split_at_mut(CONCURRENT_MERKLE_TREE_HEADER_SIZE_V1); - let header = match ConcurrentMerkleTreeHeader::try_from_slice(&mut header_bytes) { - Ok(header) => header, - Err(e) => { - error!("Failed to parse header: {}", e); - continue; - } - }; + let header: ConcurrentMerkleTreeHeader = + ConcurrentMerkleTreeHeader::try_from_slice(header_bytes) + .map_err(|e| IngesterError::RpcGetDataError(e.to_string()))?; let auth = Pubkey::find_program_address(&[pubkey.as_ref()], &mpl_bubblegum::ID).0; - let merkle_tree_size = match merkle_tree_get_size(&header) { - Ok(size) => size, - Err(e) => { - error!("Failed to get size: {}", e); - continue; - } - }; + let merkle_tree_size = merkle_tree_get_size(&header) + .map_err(|e| IngesterError::RpcGetDataError(e.to_string()))?; let (tree_bytes, _canopy_bytes) = rest.split_at_mut(merkle_tree_size); - let seq_bytes = match tree_bytes[0..8].try_into() { - Ok(bytes) => bytes, - Err(_e) => { - error!("Failed to convert seq bytes to array"); - continue; - } - }; + let seq_bytes = tree_bytes[0..8].try_into().map_err(|_e| { + IngesterError::RpcGetDataError("Failed to convert seq bytes to array".to_string()) + })?; let seq = u64::from_le_bytes(seq_bytes); list.insert(pubkey, SlotSeq(header.get_creation_slot(), seq)); @@ -883,7 +880,7 @@ impl<'a, T: Messenger> Backfiller<'a, T> { debug!("Fetching block {} from RPC", slot); let block = EncodedConfirmedBlock::from( self.rpc_client - .get_block_with_config(slot as u64, self.rpc_block_config) + .get_block_with_config(slot, self.rpc_block_config) .await .map_err(|e| IngesterError::RpcGetDataError(e.to_string()))?, ); diff --git a/nft_ingester/src/config.rs b/nft_ingester/src/config.rs index 1f6b4387d..44bc403b4 100644 --- a/nft_ingester/src/config.rs +++ b/nft_ingester/src/config.rs @@ -1,4 +1,4 @@ -use das_metadata_json::SenderArgs; +use das_metadata_json::sender::SenderArgs; use figment::{ providers::{Env, Format, Yaml}, value::Value, @@ -28,16 +28,26 @@ pub struct IngesterConfig { pub backfiller_trees: Option>, pub role: Option, pub max_postgres_connections: Option, - pub account_stream_worker_count: Option, - pub account_backfill_stream_worker_count: Option, - pub transaction_stream_worker_count: Option, - pub transaction_backfill_stream_worker_count: Option, + pub worker_config: Option>, pub code_version: Option<&'static str>, pub background_task_runner_config: Option, pub cl_audits: Option, // save transaction logs for compressed nfts pub metadata_json_sender: Option, } +#[derive(Deserialize, PartialEq, Debug, Clone)] +pub struct WorkerConfig { + pub stream_name: String, + pub worker_type: WorkerType, + pub worker_count: u32, +} + +#[derive(Deserialize, PartialEq, Debug, Clone)] +pub enum WorkerType { + Account, + Transaction, +} + impl IngesterConfig { /// Get the db url out of the dict, this is built a a dict so that future extra db parameters can be easily shoved in. /// this panics if the key is not present @@ -61,27 +71,38 @@ impl IngesterConfig { .unwrap() } - pub fn get_messneger_client_config(&self) -> MessengerConfig { + pub fn get_messenger_client_config(&self) -> MessengerConfig { let mut mc = self.messenger_config.clone(); mc.connection_config .insert("consumer_id".to_string(), Value::from(rand_string())); mc } - pub fn get_account_stream_worker_count(&self) -> u32 { - self.account_stream_worker_count.unwrap_or(2) - } - - pub fn get_account_backfill_stream_worker_count(&self) -> u32 { - self.account_backfill_stream_worker_count.unwrap_or(0) - } - - pub fn get_transaction_stream_worker_count(&self) -> u32 { - self.transaction_stream_worker_count.unwrap_or(2) + pub fn get_worker_config(&self) -> Vec { + if let Some(wc) = &self.worker_config { + wc.to_vec() + } else { + vec![ + WorkerConfig { + stream_name: "ACC".to_string(), + worker_count: 2, + worker_type: WorkerType::Account, + }, + WorkerConfig { + stream_name: "TXN".to_string(), + worker_count: 2, + worker_type: WorkerType::Transaction, + }, + ] + } } - pub fn get_transaction_backfill_stream_worker_count(&self) -> u32 { - self.transaction_backfill_stream_worker_count.unwrap_or(0) + pub fn get_worker_count(&self) -> u32 { + let mut count = 0; + for wc in self.get_worker_config() { + count += wc.worker_count; + } + count } } @@ -97,20 +118,15 @@ pub const RPC_URL_KEY: &str = "url"; pub const RPC_COMMITMENT_KEY: &str = "commitment"; pub const CODE_VERSION: &str = env!("CARGO_PKG_VERSION"); -#[derive(Deserialize, PartialEq, Eq, Debug, Clone)] +#[derive(Deserialize, Default, PartialEq, Eq, Debug, Clone)] pub enum IngesterRole { + #[default] All, Backfiller, BackgroundTaskRunner, Ingester, } -impl Default for IngesterRole { - fn default() -> Self { - IngesterRole::All - } -} - impl Display for IngesterRole { fn fmt(&self, f: &mut Formatter<'_>) -> std::fmt::Result { match self { @@ -148,9 +164,7 @@ pub fn setup_config(config_file: Option<&PathBuf>) -> IngesterConfig { } pub fn init_logger() { - let env_filter = env::var("RUST_LOG") - .or::>(Ok("info".to_string())) - .unwrap(); + let env_filter = env::var("RUST_LOG").unwrap_or("info".to_string()); let t = tracing_subscriber::fmt().with_env_filter(env_filter); t.event_format(fmt::format::json()).init(); } diff --git a/nft_ingester/src/database.rs b/nft_ingester/src/database.rs index 578f58cbc..11ff72483 100644 --- a/nft_ingester/src/database.rs +++ b/nft_ingester/src/database.rs @@ -1,15 +1,19 @@ -use sqlx::{postgres::{PgPoolOptions, PgConnectOptions}, PgPool, ConnectOptions}; - -use crate::{ - config::{IngesterConfig, IngesterRole}, +use sqlx::{ + postgres::{PgConnectOptions, PgPoolOptions}, + ConnectOptions, PgPool, }; + +use crate::config::{IngesterConfig, IngesterRole}; const BARE_MINIMUM_CONNECTIONS: u32 = 5; const DEFAULT_MAX: u32 = 125; pub async fn setup_database(config: IngesterConfig) -> PgPool { let max = config.max_postgres_connections.unwrap_or(DEFAULT_MAX); if config.role == Some(IngesterRole::All) || config.role == Some(IngesterRole::Ingester) { - let relative_max = - config.get_account_stream_worker_count() + config.get_transaction_stream_worker_count(); + let relative_max: u32 = config + .get_worker_config() + .iter() + .map(|c| c.worker_count) + .sum(); let should_be_at_least = relative_max * 5; if should_be_at_least > max { panic!("Please increase max_postgres_connections to at least {}, at least 5 connections per worker process should be given", should_be_at_least); @@ -19,13 +23,15 @@ pub async fn setup_database(config: IngesterConfig) -> PgPool { let mut options: PgConnectOptions = url.parse().unwrap(); options.log_statements(log::LevelFilter::Trace); - options.log_slow_statements(log::LevelFilter::Debug, std::time::Duration::from_millis(500)); - - let pool = PgPoolOptions::new() + options.log_slow_statements( + log::LevelFilter::Debug, + std::time::Duration::from_millis(500), + ); + + PgPoolOptions::new() .min_connections(BARE_MINIMUM_CONNECTIONS) .max_connections(max) .connect_with(options) .await - .unwrap(); - pool + .unwrap() } diff --git a/nft_ingester/src/error/mod.rs b/nft_ingester/src/error/mod.rs index ad9e17a84..37ed5f24b 100644 --- a/nft_ingester/src/error/mod.rs +++ b/nft_ingester/src/error/mod.rs @@ -52,16 +52,6 @@ pub enum IngesterError { HttpError { status_code: String }, #[error("AssetIndex Error {0}")] AssetIndexError(String), - #[error("TryFromInt Error {0}")] - TryFromInt(#[from] std::num::TryFromIntError), - #[error("Chrono FixedOffset Error")] - ChronoFixedOffset, - #[error("Pubkey parse")] - ParsePubkey, - #[error("Signature parse")] - ParseSignature(#[from] solana_sdk::signature::ParseSignatureError), - #[error("Missing Path at index for change log event")] - MissingChangeLogPath, } impl From for IngesterError { diff --git a/nft_ingester/src/main.rs b/nft_ingester/src/main.rs index 9f2bde4c1..7ca42f933 100644 --- a/nft_ingester/src/main.rs +++ b/nft_ingester/src/main.rs @@ -14,7 +14,7 @@ use crate::{ account_updates::account_worker, ack::ack_worker, backfiller::setup_backfiller, - config::{init_logger, rand_string, setup_config, IngesterRole}, + config::{init_logger, rand_string, setup_config, IngesterRole, WorkerType}, database::setup_database, error::IngesterError, metrics::setup_metrics, @@ -25,13 +25,8 @@ use crate::{ use cadence_macros::{is_global_default_set, statsd_count}; use chrono::Duration; use clap::{arg, command, value_parser}; -use das_metadata_json::{SenderPool, METADATA_JSON_STREAM}; -use futures_util::sink::Send; use log::{error, info}; -use plerkle_messenger::{ - redis_messenger::RedisMessenger, ConsumptionType, ACCOUNT_BACKFILL_STREAM, ACCOUNT_STREAM, - TRANSACTION_BACKFILL_STREAM, TRANSACTION_STREAM, -}; +use plerkle_messenger::{redis_messenger::RedisMessenger, ConsumptionType}; use std::{path::PathBuf, time}; use tokio::{signal, task::JoinSet}; @@ -89,18 +84,16 @@ pub async fn main() -> Result<(), IngesterError> { task_runner_config.timeout.unwrap_or(3), )), })]; - let sender_pool = if let Some(args) = config.metadata_json_sender.clone() { - Some(SenderPool::try_from_config(args).await.unwrap()) - } else { - None - }; - let mut background_task_manager = TaskManager::new( + let mut background_task_manager = TaskManager::try_new_async( rand_string(), database_pool.clone(), - sender_pool, + config.metadata_json_sender.clone(), bg_task_definitions, - ); + ) + .await + .unwrap(); + // This is how we send new bg tasks let bg_task_listener = background_task_manager .start_listener(role == IngesterRole::BackgroundTaskRunner || role == IngesterRole::All); @@ -109,107 +102,58 @@ pub async fn main() -> Result<(), IngesterError> { if role != IngesterRole::BackgroundTaskRunner { tasks.spawn(bg_task_listener); } - let mut timer_acc = StreamSizeTimer::new( - stream_metrics_timer, - config.messenger_config.clone(), - ACCOUNT_STREAM, - )?; - let mut timer_backfiller_acc = StreamSizeTimer::new( - stream_metrics_timer, - config.messenger_config.clone(), - ACCOUNT_BACKFILL_STREAM, - )?; - let mut timer_txn = StreamSizeTimer::new( - stream_metrics_timer, - config.messenger_config.clone(), - TRANSACTION_STREAM, - )?; - let mut timer_backfiller_txn = StreamSizeTimer::new( - stream_metrics_timer, - config.messenger_config.clone(), - TRANSACTION_BACKFILL_STREAM, - )?; - let mut timer_metadata_json = StreamSizeTimer::new( - stream_metrics_timer, - config.messenger_config.clone(), - METADATA_JSON_STREAM, - )?; - - if let Some(t) = timer_acc.start::().await { - tasks.spawn(t); - } - if let Some(t) = timer_backfiller_acc.start::().await { - tasks.spawn(t); - } - if let Some(t) = timer_txn.start::().await { - tasks.spawn(t); - } - if let Some(t) = timer_backfiller_txn.start::().await { - tasks.spawn(t); - } - if let Some(t) = timer_metadata_json.start::().await { - tasks.spawn(t); - } // Stream Consumers Setup ------------------------------------- if role == IngesterRole::Ingester || role == IngesterRole::All { + let workers = config.get_worker_config().clone(); + let (_ack_task, ack_sender) = - ack_worker::(config.get_messneger_client_config()); - for i in 0..config.get_account_stream_worker_count() { - let _account = account_worker::( - database_pool.clone(), - config.get_messneger_client_config(), - bg_task_sender.clone(), - ack_sender.clone(), - if i == 0 { - ConsumptionType::Redeliver - } else { - ConsumptionType::New - }, - ACCOUNT_STREAM, - ); - } - for i in 0..config.get_account_backfill_stream_worker_count() { - let _account_backfill = account_worker::( - database_pool.clone(), - config.get_messneger_client_config(), - bg_task_sender.clone(), - ack_sender.clone(), - if i == 0 { - ConsumptionType::Redeliver - } else { - ConsumptionType::New - }, - ACCOUNT_BACKFILL_STREAM, - ); - } - for i in 0..config.get_transaction_stream_worker_count() { - let _txn = transaction_worker::( - database_pool.clone(), - config.get_messneger_client_config(), - bg_task_sender.clone(), - ack_sender.clone(), - if i == 0 { - ConsumptionType::Redeliver - } else { - ConsumptionType::New - }, - TRANSACTION_STREAM, - ); - } - for i in 0..config.get_transaction_backfill_stream_worker_count() { - let _txn_backfill = transaction_worker::( - database_pool.clone(), - config.get_messneger_client_config(), - bg_task_sender.clone(), - ack_sender.clone(), - if i == 0 { - ConsumptionType::Redeliver - } else { - ConsumptionType::New - }, - TRANSACTION_BACKFILL_STREAM, - ); + ack_worker::(config.get_messenger_client_config()); + + // iterate all the workers + for worker in workers { + let stream_name = Box::leak(Box::new(worker.stream_name.to_owned())); + + let mut timer_worker = StreamSizeTimer::new( + stream_metrics_timer, + config.messenger_config.clone(), + stream_name.as_str(), + )?; + + if let Some(t) = timer_worker.start::().await { + tasks.spawn(t); + } + + for i in 0..worker.worker_count { + if worker.worker_type == WorkerType::Account { + let _account = account_worker::( + database_pool.clone(), + config.get_messenger_client_config(), + bg_task_sender.clone(), + ack_sender.clone(), + if i == 0 { + ConsumptionType::Redeliver + } else { + ConsumptionType::New + }, + stream_name, + ); + } else if worker.worker_type == WorkerType::Transaction { + let _txn = transaction_worker::( + database_pool.clone(), + config.get_messenger_client_config(), + bg_task_sender.clone(), + ack_sender.clone(), + if i == 0 { + ConsumptionType::Redeliver + } else { + ConsumptionType::New + }, + config.cl_audits.unwrap_or(false), + stream_name, + ); + } + } } } // Stream Size Timers ---------------------------------------- diff --git a/nft_ingester/src/metrics.rs b/nft_ingester/src/metrics.rs index 0e44d69c7..2e4ebb0d8 100644 --- a/nft_ingester/src/metrics.rs +++ b/nft_ingester/src/metrics.rs @@ -5,10 +5,7 @@ use cadence_macros::{is_global_default_set, set_global_default, statsd_count, st use log::{error, warn}; use tokio::time::Instant; -use crate::{ - config::IngesterConfig, - error::IngesterError, -}; +use crate::{config::IngesterConfig, error::IngesterError}; #[macro_export] macro_rules! metric { @@ -32,17 +29,16 @@ pub fn setup_metrics(config: &IngesterConfig) { let udp_sink = BufferedUdpMetricSink::from(host, socket).unwrap(); let queuing_sink = QueuingMetricSink::from(udp_sink); let builder = StatsdClient::builder("das_ingester", queuing_sink); - let client = builder - .with_tag("env", env) - .build(); + let client = builder.with_tag("env", env).build(); set_global_default(client); } } // Returns a boolean indicating whether the redis message should be ACK'd. // If the message is not ACK'd, it will be retried as long as it is under the retry limit. +#[allow(clippy::too_many_arguments)] pub fn capture_result( - id: String, + _id: String, stream: &str, label: (&str, &str), tries: usize, @@ -51,32 +47,31 @@ pub fn capture_result( txn_sig: Option<&str>, account: Option, ) -> bool { - let mut should_ack = false; match res { Ok(_) => { metric! { - statsd_time!("ingester.proc_time", proc.elapsed().as_millis() as u64, label.0 => &label.1, "stream" => stream); + statsd_time!("ingester.proc_time", proc.elapsed().as_millis() as u64, label.0 => label.1, "stream" => stream); } if tries == 0 { metric! { - statsd_count!("ingester.ingest_success", 1, label.0 => &label.1, "stream" => stream); + statsd_count!("ingester.ingest_success", 1, label.0 => label.1, "stream" => stream); } } else { metric! { - statsd_count!("ingester.redeliver_success", 1, label.0 => &label.1, "stream" => stream); + statsd_count!("ingester.redeliver_success", 1, label.0 => label.1, "stream" => stream); } } - should_ack = true; + true } - Err(err) if err == IngesterError::NotImplemented => { + Err(IngesterError::NotImplemented) => { metric! { - statsd_count!("ingester.not_implemented", 1, label.0 => &label.1, "stream" => stream, "error" => "ni"); + statsd_count!("ingester.not_implemented", 1, label.0 => label.1, "stream" => stream, "error" => "ni"); } - should_ack = true; + true } Err(IngesterError::DeserializationError(e)) => { metric! { - statsd_count!("ingester.ingest_error", 1, label.0 => &label.1, "stream" => stream, "error" => "de"); + statsd_count!("ingester.ingest_error", 1, label.0 => label.1, "stream" => stream, "error" => "de"); } if let Some(sig) = txn_sig { warn!("Error deserializing txn {}: {:?}", sig, e); @@ -86,11 +81,11 @@ pub fn capture_result( warn!("{}", e); } // Non-retryable error. - should_ack = true; + true } Err(IngesterError::ParsingError(e)) => { metric! { - statsd_count!("ingester.ingest_error", 1, label.0 => &label.1, "stream" => stream, "error" => "parse"); + statsd_count!("ingester.ingest_error", 1, label.0 => label.1, "stream" => stream, "error" => "parse"); } if let Some(sig) = txn_sig { warn!("Error parsing txn {}: {:?}", sig, e); @@ -100,29 +95,29 @@ pub fn capture_result( warn!("{}", e); } // Non-retryable error. - should_ack = true; + true } Err(IngesterError::DatabaseError(e)) => { metric! { - statsd_count!("ingester.database_error", 1, label.0 => &label.1, "stream" => stream, "error" => "db"); + statsd_count!("ingester.database_error", 1, label.0 => label.1, "stream" => stream, "error" => "db"); } if let Some(sig) = txn_sig { warn!("Error database txn {}: {:?}", sig, e); } else { warn!("{}", e); } - should_ack = false; + false } Err(IngesterError::AssetIndexError(e)) => { metric! { - statsd_count!("ingester.index_error", 1, label.0 => &label.1, "stream" => stream, "error" => "index"); + statsd_count!("ingester.index_error", 1, label.0 => label.1, "stream" => stream, "error" => "index"); } if let Some(sig) = txn_sig { warn!("Error indexing transaction {}: {:?}", sig, e); } else { warn!("Error indexing account: {:?}", e); } - should_ack = false; + false } Err(err) => { if let Some(sig) = txn_sig { @@ -133,10 +128,9 @@ pub fn capture_result( error!("Error handling update: {:?}", err); } metric! { - statsd_count!("ingester.ingest_update_error", 1, label.0 => &label.1, "stream" => stream, "error" => "u"); + statsd_count!("ingester.ingest_update_error", 1, label.0 => label.1, "stream" => stream, "error" => "u"); } - should_ack = false; + false } } - should_ack } diff --git a/nft_ingester/src/program_transformers/bubblegum/burn.rs b/nft_ingester/src/program_transformers/bubblegum/burn.rs index b3898d87c..11d4e0500 100644 --- a/nft_ingester/src/program_transformers/bubblegum/burn.rs +++ b/nft_ingester/src/program_transformers/bubblegum/burn.rs @@ -18,12 +18,14 @@ pub async fn burn<'c, T>( bundle: &InstructionBundle<'c>, txn: &'c T, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { if let Some(cl) = &parsing_result.tree_update { - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; let leaf_index = cl.index; let (asset_id, _) = Pubkey::find_program_address( &[ @@ -42,20 +44,25 @@ where ..Default::default() }; - // Upsert asset table `burnt` column. + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + + // Upsert asset table `burnt` column. Note we don't check for decompression (asset.seq = 0) + // because we know if the item was burnt it could not have been decompressed later. let query = asset::Entity::insert(asset_model) .on_conflict( OnConflict::columns([asset::Column::Id]) - .update_columns([ - asset::Column::Burnt, - //TODO maybe handle slot updated. - ]) + .update_columns([asset::Column::Burnt]) .to_owned(), ) .build(DbBackend::Postgres); - txn.execute(query).await?; + multi_txn.execute(query).await?; + + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await?; + multi_txn.commit().await?; return Ok(()); } diff --git a/nft_ingester/src/program_transformers/bubblegum/cancel_redeem.rs b/nft_ingester/src/program_transformers/bubblegum/cancel_redeem.rs index 8be305094..8491163b2 100644 --- a/nft_ingester/src/program_transformers/bubblegum/cancel_redeem.rs +++ b/nft_ingester/src/program_transformers/bubblegum/cancel_redeem.rs @@ -16,14 +16,15 @@ pub async fn cancel_redeem<'c, T>( bundle: &InstructionBundle<'c>, txn: &'c T, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { if let (Some(le), Some(cl)) = (&parsing_result.leaf_update, &parsing_result.tree_update) { - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; - #[allow(unreachable_patterns)] - return match le.schema { + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; + match le.schema { LeafSchema::V1 { id, owner, @@ -40,9 +41,14 @@ where let tree_id = cl.id.to_bytes(); let nonce = cl.index as i64; + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + // Partial update of asset table with just leaf. upsert_asset_with_leaf_info( - txn, + &multi_txn, id_bytes.to_vec(), nonce, tree_id.to_vec(), @@ -50,13 +56,12 @@ where le.schema.data_hash(), le.schema.creator_hash(), seq as i64, - false, ) .await?; // Partial update of asset table with just leaf owner and delegate. upsert_asset_with_owner_and_delegate_info( - txn, + &multi_txn, id_bytes.to_vec(), owner_bytes, delegate, @@ -64,9 +69,13 @@ where ) .await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; + + multi_txn.commit().await?; + + return Ok(()); } - }; + } } Err(IngesterError::ParsingError( "Ix not parsed correctly".to_string(), diff --git a/nft_ingester/src/program_transformers/bubblegum/collection_verification.rs b/nft_ingester/src/program_transformers/bubblegum/collection_verification.rs index 7db002c86..c35be49c2 100644 --- a/nft_ingester/src/program_transformers/bubblegum/collection_verification.rs +++ b/nft_ingester/src/program_transformers/bubblegum/collection_verification.rs @@ -14,6 +14,7 @@ pub async fn process<'c, T>( bundle: &InstructionBundle<'c>, txn: &'c T, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, @@ -26,7 +27,7 @@ where let (collection, verify) = match payload { Payload::CollectionVerification { collection, verify, .. - } => (collection.clone(), verify.clone()), + } => (collection, verify), _ => { return Err(IngesterError::ParsingError( "Ix not parsed correctly".to_string(), @@ -37,16 +38,23 @@ where "Handling collection verification event for {} (verify: {}): {}", collection, verify, bundle.txn_id ); - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; let id_bytes = match le.schema { LeafSchema::V1 { id, .. } => id.to_bytes().to_vec(), }; + let tree_id = cl.id.to_bytes(); let nonce = cl.index as i64; + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + // Partial update of asset table with just leaf. upsert_asset_with_leaf_info( - txn, + &multi_txn, id_bytes.to_vec(), nonce, tree_id.to_vec(), @@ -54,24 +62,25 @@ where le.schema.data_hash(), le.schema.creator_hash(), seq as i64, - false, ) .await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await?; + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; upsert_collection_info( - txn, + &multi_txn, id_bytes.to_vec(), Some(Collection { - key: collection.clone(), - verified: verify, + key: *collection, + verified: *verify, }), bundle.slot as i64, seq as i64, ) .await?; + multi_txn.commit().await?; + return Ok(()); }; Err(IngesterError::ParsingError( diff --git a/nft_ingester/src/program_transformers/bubblegum/creator_verification.rs b/nft_ingester/src/program_transformers/bubblegum/creator_verification.rs index c6348118f..2a254a2b8 100644 --- a/nft_ingester/src/program_transformers/bubblegum/creator_verification.rs +++ b/nft_ingester/src/program_transformers/bubblegum/creator_verification.rs @@ -1,8 +1,8 @@ use crate::{ error::IngesterError, program_transformers::bubblegum::{ - save_changelog_event, upsert_asset_with_leaf_info, - upsert_asset_with_owner_and_delegate_info, upsert_asset_with_seq, upsert_creator_verified, + save_changelog_event, upsert_asset_creators, upsert_asset_with_leaf_info, + upsert_asset_with_owner_and_delegate_info, upsert_asset_with_seq, }, }; use blockbuster::{ @@ -10,14 +10,15 @@ use blockbuster::{ programs::bubblegum::{BubblegumInstruction, LeafSchema, Payload}, }; use log::debug; +use mpl_bubblegum::types::Creator; use sea_orm::{ConnectionTrait, TransactionTrait}; pub async fn process<'c, T>( parsing_result: &BubblegumInstruction, bundle: &InstructionBundle<'c>, txn: &'c T, - value: bool, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, @@ -27,10 +28,26 @@ where &parsing_result.tree_update, &parsing_result.payload, ) { - let (creator, verify) = match payload { + let (updated_creators, creator, verify) = match payload { Payload::CreatorVerification { - creator, verify, .. - } => (creator, verify), + metadata, + creator, + verify, + } => { + let updated_creators: Vec = metadata + .creators + .iter() + .map(|c| { + let mut c = c.clone(); + if c.address == *creator { + c.verified = *verify + }; + c + }) + .collect(); + + (updated_creators, creator, verify) + } _ => { return Err(IngesterError::ParsingError( "Ix not parsed correctly".to_string(), @@ -41,9 +58,10 @@ where "Handling creator verification event for creator {} (verify: {}): {}", creator, verify, bundle.txn_id ); - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; - let asset_id_bytes = match le.schema { + match le.schema { LeafSchema::V1 { id, owner, @@ -51,6 +69,7 @@ where .. } => { let id_bytes = id.to_bytes(); + let owner_bytes = owner.to_bytes().to_vec(); let delegate = if owner == delegate || delegate.to_bytes() == [0; 32] { None @@ -60,9 +79,14 @@ where let tree_id = cl.id.to_bytes(); let nonce = cl.index as i64; + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + // Partial update of asset table with just leaf info. upsert_asset_with_leaf_info( - txn, + &multi_txn, id_bytes.to_vec(), nonce, tree_id.to_vec(), @@ -70,13 +94,12 @@ where le.schema.data_hash(), le.schema.creator_hash(), seq as i64, - false, ) .await?; // Partial update of asset table with just leaf owner and delegate. upsert_asset_with_owner_and_delegate_info( - txn, + &multi_txn, id_bytes.to_vec(), owner_bytes, delegate, @@ -84,21 +107,22 @@ where ) .await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await?; + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; - id_bytes.to_vec() + // Upsert creators to `asset_creators` table. + upsert_asset_creators( + &multi_txn, + id_bytes.to_vec(), + &updated_creators, + bundle.slot as i64, + seq as i64, + ) + .await?; + + multi_txn.commit().await?; } }; - upsert_creator_verified( - txn, - asset_id_bytes, - creator.to_bytes().to_vec(), - value, - seq as i64, - ) - .await?; - return Ok(()); } Err(IngesterError::ParsingError( diff --git a/nft_ingester/src/program_transformers/bubblegum/db.rs b/nft_ingester/src/program_transformers/bubblegum/db.rs index ca615e5cc..0a4bafa16 100644 --- a/nft_ingester/src/program_transformers/bubblegum/db.rs +++ b/nft_ingester/src/program_transformers/bubblegum/db.rs @@ -1,64 +1,56 @@ use crate::error::IngesterError; use digital_asset_types::dao::{ - asset, asset_creators, asset_grouping, cl_audits_v2, cl_items, - sea_orm_active_enums::BubblegumInstruction, + asset, asset_authority, asset_creators, asset_data, asset_grouping, backfill_items, + cl_audits_v2, cl_items, + sea_orm_active_enums::{ + ChainMutability, Instruction, Mutability, OwnerType, RoyaltyTargetType, + SpecificationAssetClass, SpecificationVersions, + }, }; use log::{debug, error, info}; -use mpl_bubblegum::types::Collection; +use mpl_bubblegum::types::{Collection, Creator}; use sea_orm::{ - query::*, sea_query::OnConflict, ActiveModelTrait, ActiveValue::Set, ColumnTrait, DbBackend, - EntityTrait, + query::*, sea_query::OnConflict, ActiveValue::Set, ColumnTrait, DbBackend, EntityTrait, }; -use solana_sdk::signature::Signature; use spl_account_compression::events::ChangeLogEventV1; -use std::convert::From; -use std::str::FromStr; - pub async fn save_changelog_event<'c, T>( change_log_event: &ChangeLogEventV1, + slot: u64, txn_id: &str, txn: &T, instruction: &str, + cl_audits: bool, ) -> Result where T: ConnectionTrait + TransactionTrait, { - insert_change_log(change_log_event, txn_id, txn, instruction).await?; + insert_change_log(change_log_event, slot, txn_id, txn, instruction, cl_audits).await?; Ok(change_log_event.seq) } -fn node_idx_to_leaf_idx(index: i64, tree_height: u32) -> i64 { +const fn node_idx_to_leaf_idx(index: i64, tree_height: u32) -> i64 { index - 2i64.pow(tree_height) } pub async fn insert_change_log<'c, T>( change_log_event: &ChangeLogEventV1, + slot: u64, txn_id: &str, txn: &T, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { + let mut i: i64 = 0; let depth = change_log_event.path.len() - 1; let tree_id = change_log_event.id.as_ref(); - let signature = Signature::from_str(txn_id)?; - let leaf_idx = node_idx_to_leaf_idx( - i64::from( - change_log_event - .path - .get(0) - .ok_or(IngesterError::MissingChangeLogPath)? - .index, - ), - u32::try_from(depth)?, - ); - - for (i, p) in change_log_event.path.iter().enumerate() { + for p in change_log_event.path.iter() { let node_idx = p.index as i64; - info!( - "seq {}, index {} level {}, node {}, txn {}, instruction {}", + debug!( + "seq {}, index {} level {}, node {:?}, txn: {:?}, instruction {}", change_log_event.seq, p.index, i, @@ -66,11 +58,15 @@ where txn_id, instruction ); - let leaf_idx = if i == 0 { Some(leaf_idx) } else { None }; + let leaf_idx = if i == 0 { + Some(node_idx_to_leaf_idx(node_idx, depth as u32)) + } else { + None + }; let item = cl_items::ActiveModel { tree: Set(tree_id.to_vec()), - level: Set(i64::try_from(i)?), + level: Set(i), node_idx: Set(node_idx), hash: Set(p.node.as_ref().to_vec()), seq: Set(change_log_event.seq as i64), @@ -78,6 +74,7 @@ where ..Default::default() }; + i += 1; let mut query = cl_items::Entity::insert(item) .on_conflict( OnConflict::columns([cl_items::Column::Tree, cl_items::Column::NodeIdx]) @@ -96,35 +93,77 @@ where .map_err(|db_err| IngesterError::StorageWriteError(db_err.to_string()))?; } - let cl_audit = cl_audits_v2::ActiveModel { - tree: Set(tree_id.to_vec()), - leaf_idx: Set(leaf_idx), - seq: Set(i64::try_from(change_log_event.seq)?), - tx: Set(signature.as_ref().to_vec()), - instruction: Set(BubblegumInstruction::from_str(instruction)?), - ..Default::default() - }; + // Insert the audit item after the insert into cl_items have been completed + if cl_audits { + let tx_id_bytes = bs58::decode(txn_id) + .into_vec() + .map_err(|_e| IngesterError::ChangeLogEventMalformed)?; + let ix = Instruction::from(instruction); + if ix == Instruction::Unknown { + error!("Unknown instruction: {}", instruction); + } + let audit_item_v2 = cl_audits_v2::ActiveModel { + tree: Set(tree_id.to_vec()), + leaf_idx: Set(change_log_event.index as i64), + seq: Set(change_log_event.seq as i64), + tx: Set(tx_id_bytes), + instruction: Set(ix), + ..Default::default() + }; + let query = cl_audits_v2::Entity::insert(audit_item_v2) + .on_conflict( + OnConflict::columns([ + cl_audits_v2::Column::Tree, + cl_audits_v2::Column::LeafIdx, + cl_audits_v2::Column::Seq, + ]) + .do_nothing() + .to_owned(), + ) + .build(DbBackend::Postgres); + match txn.execute(query).await { + Ok(_) => {} + Err(e) => { + error!("Error while inserting into cl_audits_v2: {:?}", e); + } + } + } - let query = cl_audits_v2::Entity::insert(cl_audit) - .on_conflict( - OnConflict::columns([ - cl_audits_v2::Column::Tree, - cl_audits_v2::Column::LeafIdx, - cl_audits_v2::Column::Seq, - ]) - .do_nothing() - .to_owned(), - ) - .build(DbBackend::Postgres); + // If and only if the entire path of nodes was inserted into the `cl_items` table, then insert + // a single row into the `backfill_items` table. This way if an incomplete path was inserted + // into `cl_items` due to an error, a gap will be created for the tree and the backfiller will + // fix it. + if i - 1 == depth as i64 { + // See if the tree already exists in the `backfill_items` table. + let rows = backfill_items::Entity::find() + .filter(backfill_items::Column::Tree.eq(tree_id)) + .limit(1) + .all(txn) + .await?; + + // If the tree does not exist in `backfill_items` and the sequence number is greater than 1, + // then we know we will need to backfill the tree from sequence number 1 up to the current + // sequence number. So in this case we set at flag to force checking the tree. + let force_chk = rows.is_empty() && change_log_event.seq > 1; + + info!("Adding to backfill_items table at level {}", i - 1); + let item = backfill_items::ActiveModel { + tree: Set(tree_id.to_vec()), + seq: Set(change_log_event.seq as i64), + slot: Set(slot as i64), + force_chk: Set(force_chk), + backfilled: Set(false), + failed: Set(false), + ..Default::default() + }; - txn.execute(query) - .await - .map_err(|db_err| IngesterError::StorageWriteError(db_err.to_string()))?; + backfill_items::Entity::insert(item).exec(txn).await?; + } Ok(()) - //TODO -> set maximum size of path and break into multiple statements } +#[allow(clippy::too_many_arguments)] pub async fn upsert_asset_with_leaf_info( txn: &T, id: Vec, @@ -134,7 +173,6 @@ pub async fn upsert_asset_with_leaf_info( data_hash: [u8; 32], creator_hash: [u8; 32], seq: i64, - was_decompressed: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, @@ -159,63 +197,21 @@ where asset::Column::Nonce, asset::Column::TreeId, asset::Column::Leaf, - asset::Column::LeafSeq, asset::Column::DataHash, asset::Column::CreatorHash, + asset::Column::LeafSeq, ]) .to_owned(), ) .build(DbBackend::Postgres); - // If we are indexing decompression we will update the leaf regardless of if we have previously - // indexed decompression and regardless of seq. - if !was_decompressed { - query.sql = format!( - "{} WHERE (NOT asset.was_decompressed) AND (excluded.leaf_seq >= asset.leaf_seq OR asset.leaf_seq IS NULL)", - query.sql - ); - } - - txn.execute(query) - .await - .map_err(|db_err| IngesterError::StorageWriteError(db_err.to_string()))?; - - Ok(()) -} + // Do not overwrite changes that happened after decompression (asset.seq = 0). + // Do not overwrite changes from a later Bubblegum instruction. + query.sql = format!( + "{} WHERE (asset.seq != 0 OR asset.seq IS NULL) AND (excluded.leaf_seq >= asset.leaf_seq OR asset.leaf_seq IS NULL)", + query.sql + ); -pub async fn upsert_asset_with_leaf_info_for_decompression( - txn: &T, - id: Vec, -) -> Result<(), IngesterError> -where - T: ConnectionTrait + TransactionTrait, -{ - let model = asset::ActiveModel { - id: Set(id), - leaf: Set(None), - nonce: Set(Some(0)), - leaf_seq: Set(None), - data_hash: Set(None), - creator_hash: Set(None), - tree_id: Set(None), - seq: Set(Some(0)), - ..Default::default() - }; - let query = asset::Entity::insert(model) - .on_conflict( - OnConflict::column(asset::Column::Id) - .update_columns([ - asset::Column::Leaf, - asset::Column::LeafSeq, - asset::Column::Nonce, - asset::Column::DataHash, - asset::Column::CreatorHash, - asset::Column::TreeId, - asset::Column::Seq, - ]) - .to_owned(), - ) - .build(DbBackend::Postgres); txn.execute(query) .await .map_err(|db_err| IngesterError::StorageWriteError(db_err.to_string()))?; @@ -237,7 +233,7 @@ where id: Set(id), owner: Set(Some(owner)), delegate: Set(delegate), - owner_delegate_seq: Set(Some(seq)), // gummyroll seq + owner_delegate_seq: Set(Some(seq)), ..Default::default() }; @@ -252,8 +248,11 @@ where .to_owned(), ) .build(DbBackend::Postgres); + + // Do not overwrite changes that happened after decompression (asset.seq = 0). + // Do not overwrite changes from a later Bubblegum instruction. query.sql = format!( - "{} WHERE excluded.owner_delegate_seq >= asset.owner_delegate_seq OR asset.owner_delegate_seq IS NULL", + "{} WHERE (asset.seq != 0 OR asset.seq IS NULL) AND (excluded.owner_delegate_seq >= asset.owner_delegate_seq OR asset.owner_delegate_seq IS NULL)", query.sql ); @@ -271,7 +270,6 @@ pub async fn upsert_asset_with_compression_info( compressible: bool, supply: i64, supply_mint: Option>, - was_decompressed: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, @@ -282,7 +280,6 @@ where compressible: Set(compressible), supply: Set(supply), supply_mint: Set(supply_mint), - was_decompressed: Set(was_decompressed), ..Default::default() }; @@ -294,12 +291,13 @@ where asset::Column::Compressible, asset::Column::Supply, asset::Column::SupplyMint, - asset::Column::WasDecompressed, ]) .to_owned(), ) .build(DbBackend::Postgres); - query.sql = format!("{} WHERE NOT asset.was_decompressed", query.sql); + + // Do not overwrite changes that happened after decompression (asset.seq = 0). + query.sql = format!("{} WHERE asset.seq != 0 OR asset.seq IS NULL", query.sql); txn.execute(query).await?; Ok(()) @@ -323,8 +321,10 @@ where ) .build(DbBackend::Postgres); + // Do not overwrite changes that happened after decompression (asset.seq = 0). + // Do not overwrite changes from a later Bubblegum instruction. query.sql = format!( - "{} WHERE (NOT asset.was_decompressed) AND (excluded.seq >= asset.seq OR asset.seq IS NULL)", + "{} WHERE (asset.seq != 0 AND excluded.seq >= asset.seq) OR asset.seq IS NULL", query.sql ); @@ -335,40 +335,50 @@ where Ok(()) } -pub async fn upsert_creator_verified( +pub async fn upsert_collection_info( txn: &T, asset_id: Vec, - creator: Vec, - verified: bool, + collection: Option, + slot_updated: i64, seq: i64, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { - let model = asset_creators::ActiveModel { + let (group_value, verified) = match collection { + Some(c) => (Some(c.key.to_string()), c.verified), + None => (None, false), + }; + + let model = asset_grouping::ActiveModel { asset_id: Set(asset_id), - creator: Set(creator), + group_key: Set("collection".to_string()), + group_value: Set(group_value), verified: Set(verified), - seq: Set(Some(seq)), + slot_updated: Set(Some(slot_updated)), + group_info_seq: Set(Some(seq)), ..Default::default() }; - let mut query = asset_creators::Entity::insert(model) + let mut query = asset_grouping::Entity::insert(model) .on_conflict( OnConflict::columns([ - asset_creators::Column::AssetId, - asset_creators::Column::Creator, + asset_grouping::Column::AssetId, + asset_grouping::Column::GroupKey, ]) .update_columns([ - asset_creators::Column::Verified, - asset_creators::Column::Seq, + asset_grouping::Column::GroupValue, + asset_grouping::Column::Verified, + asset_grouping::Column::SlotUpdated, + asset_grouping::Column::GroupInfoSeq, ]) .to_owned(), ) .build(DbBackend::Postgres); + // Do not overwrite changes that happened after decompression (asset_grouping.group_info_seq = 0). query.sql = format!( - "{} WHERE excluded.seq >= asset_creators.seq OR asset_creators.seq is NULL", + "{} WHERE (asset_grouping.group_info_seq != 0 AND excluded.group_info_seq >= asset_grouping.group_info_seq) OR asset_grouping.group_info_seq IS NULL", query.sql ); @@ -379,55 +389,237 @@ where Ok(()) } -pub async fn upsert_collection_info( +#[allow(clippy::too_many_arguments)] +pub async fn upsert_asset_data( txn: &T, - asset_id: Vec, - collection: Option, + id: Vec, + chain_data_mutability: ChainMutability, + chain_data: JsonValue, + metadata_url: String, + metadata_mutability: Mutability, + metadata: JsonValue, slot_updated: i64, + reindex: Option, + raw_name: Vec, + raw_symbol: Vec, seq: i64, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { - let (group_value, verified) = match collection { - Some(c) => (Some(c.key.to_string()), c.verified), - None => (None, false), + let model = asset_data::ActiveModel { + id: Set(id.clone()), + chain_data_mutability: Set(chain_data_mutability), + chain_data: Set(chain_data), + metadata_url: Set(metadata_url), + metadata_mutability: Set(metadata_mutability), + metadata: Set(metadata), + slot_updated: Set(slot_updated), + reindex: Set(reindex), + raw_name: Set(Some(raw_name)), + raw_symbol: Set(Some(raw_symbol)), + base_info_seq: Set(Some(seq)), }; - let model = asset_grouping::ActiveModel { - asset_id: Set(asset_id), - group_key: Set("collection".to_string()), - group_value: Set(group_value), - verified: Set(verified), + let mut query = asset_data::Entity::insert(model) + .on_conflict( + OnConflict::columns([asset_data::Column::Id]) + .update_columns([ + asset_data::Column::ChainDataMutability, + asset_data::Column::ChainData, + asset_data::Column::MetadataUrl, + asset_data::Column::MetadataMutability, + // Don't update asset_data::Column::Metadata if it already exists. Even if we + // are indexing `update_metadata`` and there's a new URI, the new background + // task will overwrite it. + asset_data::Column::SlotUpdated, + asset_data::Column::Reindex, + asset_data::Column::RawName, + asset_data::Column::RawSymbol, + asset_data::Column::BaseInfoSeq, + ]) + .to_owned(), + ) + .build(DbBackend::Postgres); + + // Do not overwrite changes that happened after decompression (asset_data.base_info_seq = 0). + // Do not overwrite changes from a later Bubblegum instruction. + query.sql = format!( + "{} WHERE (asset_data.base_info_seq != 0 AND excluded.base_info_seq >= asset_data.base_info_seq) OR asset_data.base_info_seq IS NULL", + query.sql + ); + txn.execute(query) + .await + .map_err(|db_err| IngesterError::StorageWriteError(db_err.to_string()))?; + + Ok(()) +} + +#[allow(clippy::too_many_arguments)] +pub async fn upsert_asset_base_info( + txn: &T, + id: Vec, + owner_type: OwnerType, + frozen: bool, + specification_version: SpecificationVersions, + specification_asset_class: SpecificationAssetClass, + royalty_target_type: RoyaltyTargetType, + royalty_target: Option>, + royalty_amount: i32, + slot_updated: i64, + seq: i64, +) -> Result<(), IngesterError> +where + T: ConnectionTrait + TransactionTrait, +{ + // Set base info for asset. + let asset_model = asset::ActiveModel { + id: Set(id.clone()), + owner_type: Set(owner_type), + frozen: Set(frozen), + specification_version: Set(Some(specification_version)), + specification_asset_class: Set(Some(specification_asset_class)), + royalty_target_type: Set(royalty_target_type), + royalty_target: Set(royalty_target), + royalty_amount: Set(royalty_amount), + asset_data: Set(Some(id.clone())), slot_updated: Set(Some(slot_updated)), - group_info_seq: Set(Some(seq)), + base_info_seq: Set(Some(seq)), ..Default::default() }; - let mut query = asset_grouping::Entity::insert(model) + // Upsert asset table base info. + let mut query = asset::Entity::insert(asset_model) + .on_conflict( + OnConflict::columns([asset::Column::Id]) + .update_columns([ + asset::Column::OwnerType, + asset::Column::Frozen, + asset::Column::SpecificationVersion, + asset::Column::SpecificationAssetClass, + asset::Column::RoyaltyTargetType, + asset::Column::RoyaltyTarget, + asset::Column::RoyaltyAmount, + asset::Column::AssetData, + asset::Column::SlotUpdated, + asset::Column::BaseInfoSeq, + ]) + .to_owned(), + ) + .build(DbBackend::Postgres); + query.sql = format!( + "{} WHERE (asset.seq != 0 OR asset.seq IS NULL) AND (excluded.base_info_seq >= asset.base_info_seq OR asset.base_info_seq IS NULL)", + query.sql + ); + + txn.execute(query) + .await + .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; + + Ok(()) +} + +#[allow(clippy::too_many_arguments)] +pub async fn upsert_asset_creators( + txn: &T, + id: Vec, + creators: &Vec, + slot_updated: i64, + seq: i64, +) -> Result<(), IngesterError> +where + T: ConnectionTrait + TransactionTrait, +{ + let db_creators = if creators.is_empty() { + // If creators are empty, insert an empty creator with the current sequence. + // This prevents accidental errors during out-of-order updates. + vec![asset_creators::ActiveModel { + asset_id: Set(id.clone()), + position: Set(0), + creator: Set(vec![]), + share: Set(100), + verified: Set(false), + slot_updated: Set(Some(slot_updated)), + seq: Set(Some(seq)), + ..Default::default() + }] + } else { + creators + .iter() + .enumerate() + .map(|(i, c)| asset_creators::ActiveModel { + asset_id: Set(id.clone()), + position: Set(i as i16), + creator: Set(c.address.to_bytes().to_vec()), + share: Set(c.share as i32), + verified: Set(c.verified), + slot_updated: Set(Some(slot_updated)), + seq: Set(Some(seq)), + ..Default::default() + }) + .collect() + }; + + // This statement will update base information for each creator. + let mut query = asset_creators::Entity::insert_many(db_creators) .on_conflict( OnConflict::columns([ - asset_grouping::Column::AssetId, - asset_grouping::Column::GroupKey, + asset_creators::Column::AssetId, + asset_creators::Column::Position, ]) .update_columns([ - asset_grouping::Column::GroupValue, - asset_grouping::Column::Verified, - asset_grouping::Column::SlotUpdated, - asset_grouping::Column::GroupInfoSeq, + asset_creators::Column::Creator, + asset_creators::Column::Share, + asset_creators::Column::Verified, + asset_creators::Column::Seq, + asset_creators::Column::SlotUpdated, ]) .to_owned(), ) .build(DbBackend::Postgres); query.sql = format!( - "{} WHERE excluded.group_info_seq >= asset_grouping.group_info_seq OR asset_grouping.group_info_seq IS NULL", + "{} WHERE (asset_creators.seq != 0 AND excluded.seq >= asset_creators.seq) OR asset_creators.seq IS NULL", query.sql ); + txn.execute(query).await?; + + Ok(()) +} + +pub async fn upsert_asset_authority( + txn: &T, + asset_id: Vec, + authority: Vec, + slot_updated: i64, + seq: i64, +) -> Result<(), IngesterError> +where + T: ConnectionTrait + TransactionTrait, +{ + let model = asset_authority::ActiveModel { + asset_id: Set(asset_id), + authority: Set(authority), + seq: Set(seq), + slot_updated: Set(slot_updated), + ..Default::default() + }; + + // This value is only written during `mint_V1`` or after an item is decompressed, so do not + // attempt to modify any existing values: + // `ON CONFLICT ('asset_id') DO NOTHING`. + let query = asset_authority::Entity::insert(model) + .on_conflict( + OnConflict::columns([asset_authority::Column::AssetId]) + .do_nothing() + .to_owned(), + ) + .build(DbBackend::Postgres); + txn.execute(query) .await - .map_err(|db_err| IngesterError::StorageWriteError(db_err.to_string()))?; + .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; Ok(()) } diff --git a/nft_ingester/src/program_transformers/bubblegum/decompress.rs b/nft_ingester/src/program_transformers/bubblegum/decompress.rs deleted file mode 100644 index a024d5ebe..000000000 --- a/nft_ingester/src/program_transformers/bubblegum/decompress.rs +++ /dev/null @@ -1,32 +0,0 @@ -use crate::{ - error::IngesterError, - program_transformers::bubblegum::upsert_asset_with_leaf_info_for_decompression, -}; -use blockbuster::{instruction::InstructionBundle, programs::bubblegum::BubblegumInstruction}; -use sea_orm::{query::*, ConnectionTrait}; - -use super::upsert_asset_with_compression_info; - -pub async fn decompress<'c, T>( - _parsing_result: &BubblegumInstruction, - bundle: &InstructionBundle<'c>, - txn: &'c T, -) -> Result<(), IngesterError> -where - T: ConnectionTrait + TransactionTrait, -{ - let id_bytes = bundle.keys.get(3).unwrap().0.as_slice(); - - // Partial update of asset table with just leaf. - upsert_asset_with_leaf_info_for_decompression(txn, id_bytes.to_vec()).await?; - upsert_asset_with_compression_info( - txn, - id_bytes.to_vec(), - false, - false, - 1, - Some(id_bytes.to_vec()), - true, - ) - .await -} diff --git a/nft_ingester/src/program_transformers/bubblegum/delegate.rs b/nft_ingester/src/program_transformers/bubblegum/delegate.rs index 62a3a0021..8df0de3d8 100644 --- a/nft_ingester/src/program_transformers/bubblegum/delegate.rs +++ b/nft_ingester/src/program_transformers/bubblegum/delegate.rs @@ -16,13 +16,15 @@ pub async fn delegate<'c, T>( bundle: &InstructionBundle<'c>, txn: &'c T, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { if let (Some(le), Some(cl)) = (&parsing_result.leaf_update, &parsing_result.tree_update) { - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; - return match le.schema { + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; + match le.schema { LeafSchema::V1 { id, owner, @@ -38,9 +40,14 @@ where }; let tree_id = cl.id.to_bytes(); + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + // Partial update of asset table with just leaf. upsert_asset_with_leaf_info( - txn, + &multi_txn, id_bytes.to_vec(), cl.index as i64, tree_id.to_vec(), @@ -48,13 +55,12 @@ where le.schema.data_hash(), le.schema.creator_hash(), seq as i64, - false, ) .await?; // Partial update of asset table with just leaf owner and delegate. upsert_asset_with_owner_and_delegate_info( - txn, + &multi_txn, id_bytes.to_vec(), owner_bytes, delegate, @@ -62,9 +68,13 @@ where ) .await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; + + multi_txn.commit().await?; + + return Ok(()); } - }; + } } Err(IngesterError::ParsingError( "Ix not parsed correctly".to_string(), diff --git a/nft_ingester/src/program_transformers/bubblegum/mint_v1.rs b/nft_ingester/src/program_transformers/bubblegum/mint_v1.rs index f572f4ea8..25a69d472 100644 --- a/nft_ingester/src/program_transformers/bubblegum/mint_v1.rs +++ b/nft_ingester/src/program_transformers/bubblegum/mint_v1.rs @@ -1,55 +1,55 @@ use crate::{ error::IngesterError, program_transformers::bubblegum::{ - save_changelog_event, upsert_asset_with_compression_info, upsert_asset_with_leaf_info, - upsert_asset_with_owner_and_delegate_info, upsert_asset_with_seq, upsert_collection_info, + save_changelog_event, upsert_asset_authority, upsert_asset_base_info, + upsert_asset_creators, upsert_asset_data, upsert_asset_with_compression_info, + upsert_asset_with_leaf_info, upsert_asset_with_owner_and_delegate_info, + upsert_asset_with_seq, upsert_collection_info, }, tasks::{DownloadMetadata, IntoTaskData, TaskData}, }; use blockbuster::{ instruction::InstructionBundle, programs::bubblegum::{BubblegumInstruction, LeafSchema, Payload}, - token_metadata::{ - pda::find_master_edition_account, - state::{TokenStandard, UseMethod, Uses}, - }, + token_metadata::state::{TokenStandard, UseMethod, Uses}, }; use chrono::Utc; use digital_asset_types::{ - dao::{ - asset, asset_authority, asset_creators, asset_data, asset_v1_account_attachments, - sea_orm_active_enums::{ChainMutability, Mutability, OwnerType, RoyaltyTargetType}, + dao::sea_orm_active_enums::{ + ChainMutability, Mutability, OwnerType, RoyaltyTargetType, SpecificationAssetClass, + SpecificationVersions, }, json::ChainDataV1, }; use log::warn; use num_traits::FromPrimitive; -use sea_orm::{ - entity::*, query::*, sea_query::OnConflict, ConnectionTrait, DbBackend, EntityTrait, JsonValue, -}; -use std::collections::HashSet; - -use digital_asset_types::dao::sea_orm_active_enums::{ - SpecificationAssetClass, SpecificationVersions, V1AccountAttachments, -}; - -// TODO -> consider moving structs into these functions to avoid clone +use sea_orm::{query::*, ConnectionTrait, JsonValue}; pub async fn mint_v1<'c, T>( parsing_result: &BubblegumInstruction, bundle: &InstructionBundle<'c>, txn: &'c T, instruction: &str, + cl_audits: bool, ) -> Result, IngesterError> where T: ConnectionTrait + TransactionTrait, { - if let (Some(le), Some(cl), Some(Payload::MintV1 { args })) = ( + if let ( + Some(le), + Some(cl), + Some(Payload::MintV1 { + args, + authority, + tree_id, + }), + ) = ( &parsing_result.leaf_update, &parsing_result.tree_update, &parsing_result.payload, ) { - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; let metadata = args; #[allow(unreachable_patterns)] return match le.schema { @@ -60,7 +60,6 @@ where nonce, .. } => { - let (edition_attachment_address, _) = find_master_edition_account(&id); let id_bytes = id.to_bytes(); let slot_i = bundle.slot as i64; let uri = metadata.uri.replace('\0', ""); @@ -86,124 +85,77 @@ where false => ChainMutability::Immutable, }; - let data = asset_data::ActiveModel { - id: Set(id_bytes.to_vec()), - chain_data_mutability: Set(chain_mutability), - chain_data: Set(chain_data_json), - metadata_url: Set(uri.clone()), - metadata: Set(JsonValue::String("processing".to_string())), - metadata_mutability: Set(Mutability::Mutable), - slot_updated: Set(slot_i), - reindex: Set(Some(true)), - raw_name: Set(Some(name.to_vec())), - raw_symbol: Set(Some(symbol.to_vec())), - ..Default::default() - }; + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; - let mut query = asset_data::Entity::insert(data) - .on_conflict( - OnConflict::columns([asset_data::Column::Id]) - .update_columns([ - asset_data::Column::ChainDataMutability, - asset_data::Column::ChainData, - asset_data::Column::MetadataUrl, - asset_data::Column::MetadataMutability, - asset_data::Column::SlotUpdated, - asset_data::Column::Reindex, - asset_data::Column::RawName, - asset_data::Column::RawSymbol, - ]) - .to_owned(), - ) - .build(DbBackend::Postgres); - query.sql = format!( - "{} WHERE excluded.slot_updated > asset_data.slot_updated", - query.sql - ); - txn.execute(query) - .await - .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; - // Insert into `asset` table. + upsert_asset_data( + &multi_txn, + id_bytes.to_vec(), + chain_mutability, + chain_data_json, + uri.clone(), + Mutability::Mutable, + JsonValue::String("processing".to_string()), + slot_i, + Some(true), + name.to_vec(), + symbol.to_vec(), + seq as i64, + ) + .await?; + + // Upsert `asset` table base info. let delegate = if owner == delegate || delegate.to_bytes() == [0; 32] { None } else { Some(delegate.to_bytes().to_vec()) }; - let tree_id = bundle.keys.get(3).unwrap().0.to_vec(); - // Set initial mint info. - let asset_model = asset::ActiveModel { - id: Set(id_bytes.to_vec()), - owner_type: Set(OwnerType::Single), - frozen: Set(false), - tree_id: Set(Some(tree_id.clone())), - specification_version: Set(Some(SpecificationVersions::V1)), - specification_asset_class: Set(Some(SpecificationAssetClass::Nft)), - nonce: Set(Some(nonce as i64)), - royalty_target_type: Set(RoyaltyTargetType::Creators), - royalty_target: Set(None), - royalty_amount: Set(metadata.seller_fee_basis_points as i32), //basis points - asset_data: Set(Some(id_bytes.to_vec())), - slot_updated: Set(Some(slot_i)), - ..Default::default() - }; - - // Upsert asset table base info. - let mut query = asset::Entity::insert(asset_model) - .on_conflict( - OnConflict::columns([asset::Column::Id]) - .update_columns([ - asset::Column::OwnerType, - asset::Column::Frozen, - asset::Column::SpecificationVersion, - asset::Column::SpecificationAssetClass, - asset::Column::RoyaltyTargetType, - asset::Column::RoyaltyTarget, - asset::Column::RoyaltyAmount, - asset::Column::AssetData, - ]) - .to_owned(), - ) - .build(DbBackend::Postgres); - - // Do not overwrite changes that happened after the asset was decompressed. - query.sql = format!( - "{} WHERE excluded.slot_updated > asset.slot_updated OR asset.slot_updated IS NULL", - query.sql - ); - txn.execute(query) - .await - .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; + // Upsert `asset` table base info and `asset_creators` table. + upsert_asset_base_info( + &multi_txn, + id_bytes.to_vec(), + OwnerType::Single, + false, + SpecificationVersions::V1, + SpecificationAssetClass::Nft, + RoyaltyTargetType::Creators, + None, + metadata.seller_fee_basis_points as i32, + slot_i, + seq as i64, + ) + .await?; // Partial update of asset table with just compression info elements. upsert_asset_with_compression_info( - txn, + &multi_txn, id_bytes.to_vec(), true, false, 1, None, - false, ) .await?; // Partial update of asset table with just leaf. upsert_asset_with_leaf_info( - txn, + &multi_txn, id_bytes.to_vec(), nonce as i64, - tree_id, + tree_id.to_vec(), le.leaf_hash.to_vec(), le.schema.data_hash(), le.schema.creator_hash(), seq as i64, - false, ) .await?; // Partial update of asset table with just leaf owner and delegate. upsert_asset_with_owner_and_delegate_info( - txn, + &multi_txn, id_bytes.to_vec(), owner.to_bytes().to_vec(), delegate, @@ -211,127 +163,32 @@ where ) .await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await?; + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; - let attachment = asset_v1_account_attachments::ActiveModel { - id: Set(edition_attachment_address.to_bytes().to_vec()), - slot_updated: Set(slot_i), - attachment_type: Set(V1AccountAttachments::MasterEditionV2), - ..Default::default() - }; - - let query = asset_v1_account_attachments::Entity::insert(attachment) - .on_conflict( - OnConflict::columns([asset_v1_account_attachments::Column::Id]) - .do_nothing() - .to_owned(), - ) - .build(DbBackend::Postgres); - txn.execute(query) - .await - .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; - - // Insert into `asset_creators` table. - let creators = &metadata.creators; - if !creators.is_empty() { - // Vec to hold base creator information. - let mut db_creator_infos = Vec::with_capacity(creators.len()); - - // Vec to hold info on whether a creator is verified. This info is protected by `seq` number. - let mut db_creator_verified_infos = Vec::with_capacity(creators.len()); - - // Set to prevent duplicates. - let mut creators_set = HashSet::new(); - - for (i, c) in creators.iter().enumerate() { - if creators_set.contains(&c.address) { - continue; - } - db_creator_infos.push(asset_creators::ActiveModel { - asset_id: Set(id_bytes.to_vec()), - creator: Set(c.address.to_bytes().to_vec()), - position: Set(i as i16), - share: Set(c.share as i32), - slot_updated: Set(Some(slot_i)), - ..Default::default() - }); - - db_creator_verified_infos.push(asset_creators::ActiveModel { - asset_id: Set(id_bytes.to_vec()), - creator: Set(c.address.to_bytes().to_vec()), - verified: Set(c.verified), - seq: Set(Some(seq as i64)), - ..Default::default() - }); - - creators_set.insert(c.address); - } - - // This statement will update base information for each creator. - let query = asset_creators::Entity::insert_many(db_creator_infos) - .on_conflict( - OnConflict::columns([ - asset_creators::Column::AssetId, - asset_creators::Column::Creator, - ]) - .update_columns([ - asset_creators::Column::Position, - asset_creators::Column::Share, - asset_creators::Column::SlotUpdated, - ]) - .to_owned(), - ) - .build(DbBackend::Postgres); - txn.execute(query).await?; - - // This statement will update whether the creator is verified and the `seq` - // number. `seq` is used to protect the `verified` field, allowing for `mint` - // and `verifyCreator` to be processed out of order. - let mut query = asset_creators::Entity::insert_many(db_creator_verified_infos) - .on_conflict( - OnConflict::columns([ - asset_creators::Column::AssetId, - asset_creators::Column::Creator, - ]) - .update_columns([ - asset_creators::Column::Verified, - asset_creators::Column::Seq, - ]) - .to_owned(), - ) - .build(DbBackend::Postgres); - query.sql = format!( - "{} WHERE excluded.seq > asset_creators.seq OR asset_creators.seq IS NULL", - query.sql - ); - txn.execute(query).await?; - } + // Upsert creators to `asset_creators` table. + upsert_asset_creators( + &multi_txn, + id_bytes.to_vec(), + &metadata.creators, + slot_i, + seq as i64, + ) + .await?; // Insert into `asset_authority` table. - let model = asset_authority::ActiveModel { - asset_id: Set(id_bytes.to_vec()), - authority: Set(bundle.keys.get(0).unwrap().0.to_vec()), //TODO - we need to rem,ove the optional bubblegum signer logic - seq: Set(seq as i64), - slot_updated: Set(slot_i), - ..Default::default() - }; - - // Do not attempt to modify any existing values: - // `ON CONFLICT ('asset_id') DO NOTHING`. - let query = asset_authority::Entity::insert(model) - .on_conflict( - OnConflict::columns([asset_authority::Column::AssetId]) - .do_nothing() - .to_owned(), - ) - .build(DbBackend::Postgres); - txn.execute(query) - .await - .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; + //TODO - we need to remove the optional bubblegum signer logic + upsert_asset_authority( + &multi_txn, + id_bytes.to_vec(), + authority.to_vec(), + seq as i64, + slot_i, + ) + .await?; // Upsert into `asset_grouping` table with base collection info. upsert_collection_info( - txn, + &multi_txn, id_bytes.to_vec(), metadata.collection.clone(), slot_i, @@ -339,6 +196,8 @@ where ) .await?; + multi_txn.commit().await?; + if uri.is_empty() { warn!( "URI is empty for mint {}. Skipping background task.", @@ -349,7 +208,7 @@ where let mut task = DownloadMetadata { asset_data_id: id_bytes.to_vec(), - uri: metadata.uri.clone(), + uri, created_at: Some(Utc::now().naive_utc()), }; task.sanitize(); diff --git a/nft_ingester/src/program_transformers/bubblegum/mod.rs b/nft_ingester/src/program_transformers/bubblegum/mod.rs index 173c0131d..4a4484f12 100644 --- a/nft_ingester/src/program_transformers/bubblegum/mod.rs +++ b/nft_ingester/src/program_transformers/bubblegum/mod.rs @@ -12,11 +12,11 @@ mod cancel_redeem; mod collection_verification; mod creator_verification; mod db; -mod decompress; mod delegate; mod mint_v1; mod redeem; mod transfer; +mod update_metadata; pub use db::*; @@ -27,6 +27,7 @@ pub async fn handle_bubblegum_instruction<'c, T>( bundle: &'c InstructionBundle<'c>, txn: &T, task_manager: &UnboundedSender, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, @@ -52,50 +53,58 @@ where InstructionName::VerifyCollection => "VerifyCollection", InstructionName::UnverifyCollection => "UnverifyCollection", InstructionName::SetAndVerifyCollection => "SetAndVerifyCollection", - InstructionName::SetDecompressibleState | InstructionName::UpdateMetadata => todo!(), + InstructionName::SetDecompressibleState => "SetDecompressibleState", + InstructionName::UpdateMetadata => "UpdateMetadata", }; info!("BGUM instruction txn={:?}: {:?}", ix_str, bundle.txn_id); match ix_type { InstructionName::Transfer => { - transfer::transfer(parsing_result, bundle, txn, ix_str).await?; + transfer::transfer(parsing_result, bundle, txn, ix_str, cl_audits).await?; } InstructionName::Burn => { - burn::burn(parsing_result, bundle, txn, ix_str).await?; + burn::burn(parsing_result, bundle, txn, ix_str, cl_audits).await?; } InstructionName::Delegate => { - delegate::delegate(parsing_result, bundle, txn, ix_str).await?; + delegate::delegate(parsing_result, bundle, txn, ix_str, cl_audits).await?; } InstructionName::MintV1 | InstructionName::MintToCollectionV1 => { - let task = mint_v1::mint_v1(parsing_result, bundle, txn, ix_str).await?; + let task = mint_v1::mint_v1(parsing_result, bundle, txn, ix_str, cl_audits).await?; if let Some(t) = task { task_manager.send(t)?; } } InstructionName::Redeem => { - redeem::redeem(parsing_result, bundle, txn, ix_str).await?; + redeem::redeem(parsing_result, bundle, txn, ix_str, cl_audits).await?; } InstructionName::CancelRedeem => { - cancel_redeem::cancel_redeem(parsing_result, bundle, txn, ix_str).await?; + cancel_redeem::cancel_redeem(parsing_result, bundle, txn, ix_str, cl_audits).await?; } InstructionName::DecompressV1 => { - decompress::decompress(parsing_result, bundle, txn).await?; + debug!("No action necessary for decompression") } - InstructionName::VerifyCreator => { - creator_verification::process(parsing_result, bundle, txn, true, ix_str).await?; - } - InstructionName::UnverifyCreator => { - creator_verification::process(parsing_result, bundle, txn, false, ix_str).await?; + InstructionName::VerifyCreator | InstructionName::UnverifyCreator => { + creator_verification::process(parsing_result, bundle, txn, ix_str, cl_audits).await?; } InstructionName::VerifyCollection | InstructionName::UnverifyCollection | InstructionName::SetAndVerifyCollection => { - collection_verification::process(parsing_result, bundle, txn, ix_str).await?; + collection_verification::process(parsing_result, bundle, txn, ix_str, cl_audits) + .await?; + } + InstructionName::SetDecompressibleState => (), // Nothing to index. + InstructionName::UpdateMetadata => { + let task = + update_metadata::update_metadata(parsing_result, bundle, txn, ix_str, cl_audits) + .await?; + + if let Some(t) = task { + task_manager.send(t)?; + } } _ => debug!("Bubblegum: Not Implemented Instruction"), } - Ok(()) } diff --git a/nft_ingester/src/program_transformers/bubblegum/redeem.rs b/nft_ingester/src/program_transformers/bubblegum/redeem.rs index 19c070470..8d1944412 100644 --- a/nft_ingester/src/program_transformers/bubblegum/redeem.rs +++ b/nft_ingester/src/program_transformers/bubblegum/redeem.rs @@ -15,12 +15,14 @@ pub async fn redeem<'c, T>( bundle: &InstructionBundle<'c>, txn: &'c T, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { if let Some(cl) = &parsing_result.tree_update { - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; let leaf_index = cl.index; let (asset_id, _) = Pubkey::find_program_address( &[ @@ -35,9 +37,14 @@ where let tree_id = cl.id.to_bytes(); let nonce = cl.index as i64; + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + // Partial update of asset table with just leaf. upsert_asset_with_leaf_info( - txn, + &multi_txn, id_bytes.to_vec(), nonce, tree_id.to_vec(), @@ -45,11 +52,12 @@ where [0; 32], [0; 32], seq as i64, - false, ) .await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await?; + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; + + multi_txn.commit().await?; return Ok(()); } diff --git a/nft_ingester/src/program_transformers/bubblegum/transfer.rs b/nft_ingester/src/program_transformers/bubblegum/transfer.rs index 1b14e0d94..42351df2b 100644 --- a/nft_ingester/src/program_transformers/bubblegum/transfer.rs +++ b/nft_ingester/src/program_transformers/bubblegum/transfer.rs @@ -17,14 +17,15 @@ pub async fn transfer<'c, T>( bundle: &InstructionBundle<'c>, txn: &'c T, instruction: &str, + cl_audits: bool, ) -> Result<(), IngesterError> where T: ConnectionTrait + TransactionTrait, { if let (Some(le), Some(cl)) = (&parsing_result.leaf_update, &parsing_result.tree_update) { - let seq = save_changelog_event(cl, bundle.txn_id, txn, instruction).await?; - #[allow(unreachable_patterns)] - return match le.schema { + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; + match le.schema { LeafSchema::V1 { id, owner, @@ -41,9 +42,14 @@ where let tree_id = cl.id.to_bytes(); let nonce = cl.index as i64; + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + // Partial update of asset table with just leaf. upsert_asset_with_leaf_info( - txn, + &multi_txn, id_bytes.to_vec(), nonce, tree_id.to_vec(), @@ -51,13 +57,12 @@ where le.schema.data_hash(), le.schema.creator_hash(), seq as i64, - false, ) .await?; // Partial update of asset table with just leaf owner and delegate. upsert_asset_with_owner_and_delegate_info( - txn, + &multi_txn, id_bytes.to_vec(), owner_bytes, delegate, @@ -65,9 +70,13 @@ where ) .await?; - upsert_asset_with_seq(txn, id_bytes.to_vec(), seq as i64).await + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; + + multi_txn.commit().await?; + + return Ok(()); } - }; + } } Err(IngesterError::ParsingError( "Ix not parsed correctly".to_string(), diff --git a/nft_ingester/src/program_transformers/bubblegum/update_metadata.rs b/nft_ingester/src/program_transformers/bubblegum/update_metadata.rs new file mode 100644 index 000000000..54f1b87e0 --- /dev/null +++ b/nft_ingester/src/program_transformers/bubblegum/update_metadata.rs @@ -0,0 +1,210 @@ +use crate::{ + error::IngesterError, + program_transformers::bubblegum::{ + save_changelog_event, upsert_asset_base_info, upsert_asset_creators, upsert_asset_data, + upsert_asset_with_leaf_info, upsert_asset_with_seq, + }, + tasks::{DownloadMetadata, IntoTaskData, TaskData}, +}; +use blockbuster::{ + instruction::InstructionBundle, + programs::bubblegum::{BubblegumInstruction, LeafSchema, Payload}, + token_metadata::state::{TokenStandard, UseMethod, Uses}, +}; +use chrono::Utc; +use digital_asset_types::{ + dao::sea_orm_active_enums::{ + ChainMutability, Mutability, OwnerType, RoyaltyTargetType, SpecificationAssetClass, + SpecificationVersions, + }, + json::ChainDataV1, +}; +use log::warn; +use num_traits::FromPrimitive; +use sea_orm::{query::*, ConnectionTrait, JsonValue}; + +pub async fn update_metadata<'c, T>( + parsing_result: &BubblegumInstruction, + bundle: &InstructionBundle<'c>, + txn: &'c T, + instruction: &str, + cl_audits: bool, +) -> Result, IngesterError> +where + T: ConnectionTrait + TransactionTrait, +{ + if let ( + Some(le), + Some(cl), + Some(Payload::UpdateMetadata { + current_metadata, + update_args, + tree_id, + }), + ) = ( + &parsing_result.leaf_update, + &parsing_result.tree_update, + &parsing_result.payload, + ) { + let seq = save_changelog_event(cl, bundle.slot, bundle.txn_id, txn, instruction, cl_audits) + .await?; + + #[allow(unreachable_patterns)] + return match le.schema { + LeafSchema::V1 { id, nonce, .. } => { + let id_bytes = id.to_bytes(); + let slot_i = bundle.slot as i64; + + let uri = if let Some(uri) = &update_args.uri { + uri.replace('\0', "") + } else { + current_metadata.uri.replace('\0', "") + }; + if uri.is_empty() { + return Err(IngesterError::DeserializationError( + "URI is empty".to_string(), + )); + } + + let name = if let Some(name) = update_args.name.clone() { + name + } else { + current_metadata.name.clone() + }; + + let symbol = if let Some(symbol) = update_args.symbol.clone() { + symbol + } else { + current_metadata.symbol.clone() + }; + + let primary_sale_happened = + if let Some(primary_sale_happened) = update_args.primary_sale_happened { + primary_sale_happened + } else { + current_metadata.primary_sale_happened + }; + + let mut chain_data = ChainDataV1 { + name: name.clone(), + symbol: symbol.clone(), + edition_nonce: current_metadata.edition_nonce, + primary_sale_happened, + token_standard: Some(TokenStandard::NonFungible), + uses: current_metadata.uses.clone().map(|u| Uses { + use_method: UseMethod::from_u8(u.use_method as u8).unwrap(), + remaining: u.remaining, + total: u.total, + }), + }; + chain_data.sanitize(); + let chain_data_json = serde_json::to_value(chain_data) + .map_err(|e| IngesterError::DeserializationError(e.to_string()))?; + + let is_mutable = if let Some(is_mutable) = update_args.is_mutable { + is_mutable + } else { + current_metadata.is_mutable + }; + + let chain_mutability = if is_mutable { + ChainMutability::Mutable + } else { + ChainMutability::Immutable + }; + + // Begin a transaction. If the transaction goes out of scope (i.e. one of the executions has + // an error and this function returns it using the `?` operator), then the transaction is + // automatically rolled back. + let multi_txn = txn.begin().await?; + + upsert_asset_data( + &multi_txn, + id_bytes.to_vec(), + chain_mutability, + chain_data_json, + uri.clone(), + Mutability::Mutable, + JsonValue::String("processing".to_string()), + slot_i, + Some(true), + name.into_bytes().to_vec(), + symbol.into_bytes().to_vec(), + seq as i64, + ) + .await?; + + // Upsert `asset` table base info. + let seller_fee_basis_points = + if let Some(seller_fee_basis_points) = update_args.seller_fee_basis_points { + seller_fee_basis_points + } else { + current_metadata.seller_fee_basis_points + }; + + let creators = if let Some(creators) = &update_args.creators { + creators + } else { + ¤t_metadata.creators + }; + + upsert_asset_base_info( + &multi_txn, + id_bytes.to_vec(), + OwnerType::Single, + false, + SpecificationVersions::V1, + SpecificationAssetClass::Nft, + RoyaltyTargetType::Creators, + None, + seller_fee_basis_points as i32, + slot_i, + seq as i64, + ) + .await?; + + // Partial update of asset table with just leaf. + upsert_asset_with_leaf_info( + &multi_txn, + id_bytes.to_vec(), + nonce as i64, + tree_id.to_vec(), + le.leaf_hash.to_vec(), + le.schema.data_hash(), + le.schema.creator_hash(), + seq as i64, + ) + .await?; + + upsert_asset_with_seq(&multi_txn, id_bytes.to_vec(), seq as i64).await?; + + // Upsert creators to `asset_creators` table. + upsert_asset_creators(&multi_txn, id_bytes.to_vec(), creators, slot_i, seq as i64) + .await?; + + multi_txn.commit().await?; + + if uri.is_empty() { + warn!( + "URI is empty for mint {}. Skipping background task.", + bs58::encode(id).into_string() + ); + return Ok(None); + } + + let mut task = DownloadMetadata { + asset_data_id: id_bytes.to_vec(), + uri, + created_at: Some(Utc::now().naive_utc()), + }; + task.sanitize(); + let t = task.into_task_data()?; + Ok(Some(t)) + } + _ => Err(IngesterError::NotImplemented), + }; + } + Err(IngesterError::ParsingError( + "Ix not parsed correctly".to_string(), + )) +} diff --git a/nft_ingester/src/program_transformers/mod.rs b/nft_ingester/src/program_transformers/mod.rs index 8eabcb656..14e262b0f 100644 --- a/nft_ingester/src/program_transformers/mod.rs +++ b/nft_ingester/src/program_transformers/mod.rs @@ -29,10 +29,11 @@ pub struct ProgramTransformer { task_sender: UnboundedSender, matchers: HashMap>, key_set: HashSet, + cl_audits: bool, } impl ProgramTransformer { - pub fn new(pool: PgPool, task_sender: UnboundedSender) -> Self { + pub fn new(pool: PgPool, task_sender: UnboundedSender, cl_audits: bool) -> Self { let mut matchers: HashMap> = HashMap::with_capacity(1); let bgum = BubblegumParser {}; let token_metadata = TokenMetadataParser {}; @@ -50,6 +51,7 @@ impl ProgramTransformer { task_sender, matchers, key_set: hs, + cl_audits, } } @@ -61,8 +63,15 @@ impl ProgramTransformer { order_instructions(ref_set, tx) } + #[allow(clippy::borrowed_box)] pub fn match_program(&self, key: &FBPubkey) -> Option<&Box> { - self.matchers.get(&Pubkey::new(key.0.as_slice())) + match Pubkey::try_from(key.0.as_slice()) { + Ok(pubkey) => self.matchers.get(&pubkey), + Err(_error) => { + log::warn!("failed to parse key: {key:?}"); + None + } + } } pub async fn handle_transaction<'a>( @@ -71,7 +80,7 @@ impl ProgramTransformer { ) -> Result<(), IngesterError> { let sig: Option<&str> = tx.signature(); info!("Handling Transaction: {:?}", sig); - let instructions = self.break_transaction(&tx); + let instructions = self.break_transaction(tx); let accounts = tx.account_keys().unwrap_or_default(); let slot = tx.slot(); let txn_id = tx.signature().unwrap_or(""); @@ -106,7 +115,7 @@ impl ProgramTransformer { acc }); let ix = InstructionBundle { - txn_id: txn_id, + txn_id, program, instruction: Some(instruction), inner_ix, @@ -125,6 +134,7 @@ impl ProgramTransformer { &ix, &self.storage, &self.task_sender, + self.cl_audits, ) .await .map_err(|err| { @@ -132,7 +142,7 @@ impl ProgramTransformer { "Failed to handle bubblegum instruction for txn {:?}: {:?}", sig, err ); - return err; + err })?; } _ => { diff --git a/nft_ingester/src/program_transformers/token/mod.rs b/nft_ingester/src/program_transformers/token/mod.rs index e3a963cac..12589dc5e 100644 --- a/nft_ingester/src/program_transformers/token/mod.rs +++ b/nft_ingester/src/program_transformers/token/mod.rs @@ -1,7 +1,6 @@ -use crate::{error::IngesterError, metric, tasks::TaskData}; +use crate::{error::IngesterError, tasks::TaskData}; use blockbuster::programs::token_account::TokenProgramAccount; -use cadence_macros::{is_global_default_set, statsd_count}; -use digital_asset_types::dao::{asset, token_accounts, tokens}; +use digital_asset_types::dao::{asset, sea_orm_active_enums::OwnerType, token_accounts, tokens}; use plerkle_serialization::AccountInfo; use sea_orm::{ entity::*, query::*, sea_query::OnConflict, ActiveValue::Set, ConnectionTrait, @@ -27,10 +26,7 @@ pub async fn handle_token_program_account<'a, 'b, 'c>( COption::Some(d) => Some(d.to_bytes().to_vec()), COption::None => None, }; - let frozen = match ta.state { - AccountState::Frozen => true, - _ => false, - }; + let frozen = matches!(ta.state, AccountState::Frozen); let owner = ta.owner.to_bytes().to_vec(); let model = token_accounts::ActiveModel { pubkey: Set(key_bytes), @@ -125,20 +121,38 @@ pub async fn handle_token_program_account<'a, 'b, 'c>( ) .build(DbBackend::Postgres); query.sql = format!( - "{} WHERE excluded.slot_updated > tokens.slot_updated", + "{} WHERE excluded.slot_updated >= tokens.slot_updated", query.sql ); db.execute(query).await?; + let asset_update: Option = asset::Entity::find_by_id(key_bytes.clone()) - .filter(asset::Column::OwnerType.eq("single")) + .filter( + asset::Column::OwnerType + .eq(OwnerType::Single) + .or(asset::Column::OwnerType + .eq(OwnerType::Unknown) + .and(asset::Column::Supply.eq(1))), + ) .one(db) .await?; if let Some(asset) = asset_update { - let mut active: asset::ActiveModel = asset.into(); + let mut active: asset::ActiveModel = asset.clone().into(); active.supply = Set(m.supply as i64); active.supply_mint = Set(Some(key_bytes)); + + // Update owner_type based on the supply. + if asset.owner_type == OwnerType::Unknown { + active.owner_type = match m.supply.cmp(&1) { + std::cmp::Ordering::Equal => Set(OwnerType::Single), + std::cmp::Ordering::Greater => Set(OwnerType::Token), + _ => NotSet, + } + } + active.save(db).await?; } + Ok(()) } _ => Err(IngesterError::NotImplemented), diff --git a/nft_ingester/src/program_transformers/token_metadata/master_edition.rs b/nft_ingester/src/program_transformers/token_metadata/master_edition.rs index 4e30970b6..ebb3ad942 100644 --- a/nft_ingester/src/program_transformers/token_metadata/master_edition.rs +++ b/nft_ingester/src/program_transformers/token_metadata/master_edition.rs @@ -1,7 +1,7 @@ use crate::error::IngesterError; use blockbuster::token_metadata::state::{Key, MasterEditionV1, MasterEditionV2}; use digital_asset_types::dao::{ - asset, asset_v1_account_attachments, + asset, asset_v1_account_attachments, extensions, sea_orm_active_enums::{SpecificationAssetClass, V1AccountAttachments}, }; use plerkle_serialization::Pubkey as FBPubkey; @@ -57,7 +57,10 @@ pub async fn save_master_edition( let master_edition: Option<(asset_v1_account_attachments::Model, Option)> = asset_v1_account_attachments::Entity::find_by_id(id.0.to_vec()) .find_also_related(asset::Entity) - .join(JoinType::InnerJoin, asset::Relation::AssetData.def()) + .join( + JoinType::InnerJoin, + extensions::asset::Relation::AssetData.def(), + ) .one(txn) .await?; let ser = serde_json::to_value(me_data) diff --git a/nft_ingester/src/program_transformers/token_metadata/mod.rs b/nft_ingester/src/program_transformers/token_metadata/mod.rs index 10ab9a74c..b6b548900 100644 --- a/nft_ingester/src/program_transformers/token_metadata/mod.rs +++ b/nft_ingester/src/program_transformers/token_metadata/mod.rs @@ -33,7 +33,7 @@ pub async fn handle_token_metadata_account<'a, 'b, 'c>( Ok(()) } TokenMetadataAccountData::MetadataV1(m) => { - let task = save_v1_asset(db, m.mint.as_ref().into(), account_update.slot(), m).await?; + let task = save_v1_asset(db, m, account_update.slot()).await?; if let Some(task) = task { task_manager.send(task)?; } diff --git a/nft_ingester/src/program_transformers/token_metadata/v1_asset.rs b/nft_ingester/src/program_transformers/token_metadata/v1_asset.rs index f1b01e590..9c5b0c71a 100644 --- a/nft_ingester/src/program_transformers/token_metadata/v1_asset.rs +++ b/nft_ingester/src/program_transformers/token_metadata/v1_asset.rs @@ -1,31 +1,36 @@ -use crate::{error::IngesterError, tasks::TaskData}; +use crate::tasks::{DownloadMetadata, IntoTaskData}; +use crate::{error::IngesterError, metric, tasks::TaskData}; use blockbuster::token_metadata::{ pda::find_master_edition_account, state::{Metadata, TokenStandard, UseMethod, Uses}, }; +use cadence_macros::{is_global_default_set, statsd_count}; use chrono::Utc; +use digital_asset_types::dao::{asset_authority, asset_data, asset_grouping, token_accounts}; use digital_asset_types::{ dao::{ - asset, asset_authority, asset_creators, asset_data, asset_grouping, - asset_v1_account_attachments, + asset, asset_creators, asset_v1_account_attachments, sea_orm_active_enums::{ ChainMutability, Mutability, OwnerType, RoyaltyTargetType, SpecificationAssetClass, SpecificationVersions, V1AccountAttachments, }, - token_accounts, tokens, + tokens, }, json::ChainDataV1, }; - -use crate::tasks::{DownloadMetadata, IntoTaskData}; +use lazy_static::lazy_static; use log::warn; use num_traits::FromPrimitive; use plerkle_serialization::Pubkey as FBPubkey; use sea_orm::{ entity::*, query::*, sea_query::OnConflict, ActiveValue::Set, ConnectionTrait, DbBackend, - DbErr, EntityTrait, FromQueryResult, JoinType, JsonValue, + DbErr, EntityTrait, JsonValue, }; -use std::collections::HashSet; +use solana_sdk::pubkey::Pubkey; + +use std::str::FromStr; +use std::time::Duration; +use tokio::time::sleep; pub async fn burn_v1_asset( conn: &T, @@ -54,74 +59,128 @@ pub async fn burn_v1_asset( Ok(()) } +const RETRY_INTERVALS: &[u64] = &[0, 5, 10]; +const WSOL_ADDRESS: &str = "So11111111111111111111111111111111111111112"; + +lazy_static! { + static ref WSOL_PUBKEY: Pubkey = + Pubkey::from_str(WSOL_ADDRESS).expect("Invalid public key format"); +} + pub async fn save_v1_asset( conn: &T, - id: FBPubkey, - slot: u64, metadata: &Metadata, + slot: u64, ) -> Result, IngesterError> { let metadata = metadata.clone(); let data = metadata.data; - let meta_mint_pubkey = metadata.mint; - let (edition_attachment_address, _) = find_master_edition_account(&meta_mint_pubkey); - let mint = metadata.mint.to_bytes().to_vec(); + let mint_pubkey = metadata.mint; + let mint_pubkey_array = mint_pubkey.to_bytes(); + let mint_pubkey_vec = mint_pubkey_array.to_vec(); + + let (edition_attachment_address, _) = find_master_edition_account(&mint_pubkey); + let authority = metadata.update_authority.to_bytes().to_vec(); - let id = id.0; let slot_i = slot as i64; let uri = data.uri.trim().replace('\0', ""); let _spec = SpecificationVersions::V1; - let class = match metadata.token_standard { + let mut class = match metadata.token_standard { Some(TokenStandard::NonFungible) => SpecificationAssetClass::Nft, Some(TokenStandard::FungibleAsset) => SpecificationAssetClass::FungibleAsset, Some(TokenStandard::Fungible) => SpecificationAssetClass::FungibleToken, + Some(TokenStandard::NonFungibleEdition) => SpecificationAssetClass::Nft, + Some(TokenStandard::ProgrammableNonFungible) => SpecificationAssetClass::ProgrammableNft, + Some(TokenStandard::ProgrammableNonFungibleEdition) => { + SpecificationAssetClass::ProgrammableNft + } _ => SpecificationAssetClass::Unknown, }; - let ownership_type = match class { + let mut ownership_type = match class { SpecificationAssetClass::FungibleAsset => OwnerType::Token, SpecificationAssetClass::FungibleToken => OwnerType::Token, - // FIX: SPL tokens with associated metadata that do not set the token standard are incorrectly marked as single ownership. - _ => OwnerType::Single, + SpecificationAssetClass::Nft | SpecificationAssetClass::ProgrammableNft => { + OwnerType::Single + } + _ => OwnerType::Unknown, }; - // gets the token and token account for the mint to populate the asset. This is required when the token and token account are indexed, but not the metadata account. - // If the metadata account is indexed, then the token and the ingester will update the asset with the correct data + // Wrapped Solana is a special token that has supply 0 (infinite). + // It's a fungible token with a metadata account, but without any token standard, meaning the code above will misabel it as an NFT. + if mint_pubkey == *WSOL_PUBKEY { + ownership_type = OwnerType::Token; + class = SpecificationAssetClass::FungibleToken; + } - let (token, token_account): (Option, Option) = - match ownership_type { - OwnerType::Single => { - let token: Option = - tokens::Entity::find_by_id(mint.clone()).one(conn).await?; - // query for token account associated with mint with amount of 1 since single ownership is a token account with amount of 1. - // In the case of a transfer the current owner's token account amount is deducted by 1 and the new owner's token account amount for the mint is incremented by 1. - let token_account: Option = token_accounts::Entity::find() - .filter(token_accounts::Column::Mint.eq(mint.clone())) - .filter(token_accounts::Column::Amount.eq(1)) - .one(conn) - .await?; - Ok((token, token_account)) - } - _ => { - let token = tokens::Entity::find_by_id(mint.clone()).one(conn).await?; - Ok((token, None)) - } - } - .map_err(|e: DbErr| IngesterError::DatabaseError(e.to_string()))?; + // Gets the token and token account for the mint to populate the asset. + // This is required when the token and token account are indexed, but not the metadata account. + // If the metadata account is indexed, then the token and ta ingester will update the asset with the correct data. + let token: Option = find_model_with_retry( + conn, + "token", + &tokens::Entity::find_by_id(mint_pubkey_vec.clone()), + RETRY_INTERVALS, + ) + .await?; // get supply of token, default to 1 since most cases will be NFTs. Token mint ingester will properly set supply if token_result is None let (supply, supply_mint) = match token { - Some(t) => (Set(t.supply), Set(Some(t.mint))), - None => (Set(1), NotSet), + Some(t) => (t.supply, Some(t.mint)), + None => { + warn!( + target: "Account not found", + "Token/Mint not found in 'tokens' table for mint {}", + bs58::encode(&mint_pubkey_vec).into_string() + ); + (1, None) + } + }; + + // Map unknown ownership types based on the supply. + if ownership_type == OwnerType::Unknown { + ownership_type = match supply.cmp(&1) { + std::cmp::Ordering::Equal => OwnerType::Single, + std::cmp::Ordering::Greater => OwnerType::Token, + _ => OwnerType::Unknown, + } + } + + let token_account: Option = match ownership_type { + OwnerType::Single | OwnerType::Unknown => { + // query for token account associated with mint with positive balance with latest slot + let token_account: Option = find_model_with_retry( + conn, + "token_accounts", + &token_accounts::Entity::find() + .filter(token_accounts::Column::Mint.eq(mint_pubkey_vec.clone())) + .filter(token_accounts::Column::Amount.gt(0)) + .order_by(token_accounts::Column::SlotUpdated, Order::Desc), + RETRY_INTERVALS, + ) + .await + .map_err(|e: DbErr| IngesterError::DatabaseError(e.to_string()))?; + + token_account + } + _ => None, }; // owner and delegate should be from the token account with the mint let (owner, delegate) = match token_account { Some(ta) => (Set(Some(ta.owner)), Set(ta.delegate)), - None => (NotSet, NotSet), + None => { + if supply == 1 && ownership_type == OwnerType::Single { + warn!( + target: "Account not found", + "Token acc not found in 'token_accounts' table for mint {}", + bs58::encode(&mint_pubkey_vec).into_string() + ); + } + (NotSet, NotSet) + } }; let name = data.name.clone().into_bytes(); let symbol = data.symbol.clone().into_bytes(); - let mut chain_data = ChainDataV1 { name: data.name.clone(), symbol: data.symbol.clone(), @@ -149,9 +208,10 @@ pub async fn save_v1_asset( metadata_mutability: Set(Mutability::Mutable), slot_updated: Set(slot_i), reindex: Set(Some(true)), - id: Set(id.to_vec()), + id: Set(mint_pubkey_vec.clone()), raw_name: Set(Some(name.to_vec())), raw_symbol: Set(Some(symbol.to_vec())), + base_info_seq: Set(Some(0)), }; let txn = conn.begin().await?; let mut query = asset_data::Entity::insert(asset_data_model) @@ -166,6 +226,7 @@ pub async fn save_v1_asset( asset_data::Column::Reindex, asset_data::Column::RawName, asset_data::Column::RawSymbol, + asset_data::Column::BaseInfoSeq, ]) .to_owned(), ) @@ -177,26 +238,29 @@ pub async fn save_v1_asset( txn.execute(query) .await .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; + let model = asset::ActiveModel { - id: Set(id.to_vec()), + id: Set(mint_pubkey_vec.clone()), owner, owner_type: Set(ownership_type), delegate, frozen: Set(false), - supply, - supply_mint, + supply: Set(supply), + supply_mint: Set(supply_mint), specification_version: Set(Some(SpecificationVersions::V1)), specification_asset_class: Set(Some(class)), tree_id: Set(None), nonce: Set(Some(0)), seq: Set(Some(0)), leaf: Set(None), + data_hash: Set(None), + creator_hash: Set(None), compressed: Set(false), compressible: Set(false), royalty_target_type: Set(RoyaltyTargetType::Creators), royalty_target: Set(None), royalty_amount: Set(data.seller_fee_basis_points as i32), //basis points - asset_data: Set(Some(id.to_vec())), + asset_data: Set(Some(mint_pubkey_vec.clone())), slot_updated: Set(Some(slot_i)), burnt: Set(false), ..Default::default() @@ -217,6 +281,8 @@ pub async fn save_v1_asset( asset::Column::Nonce, asset::Column::Seq, asset::Column::Leaf, + asset::Column::DataHash, + asset::Column::CreatorHash, asset::Column::Compressed, asset::Column::Compressible, asset::Column::RoyaltyTargetType, @@ -230,12 +296,13 @@ pub async fn save_v1_asset( ) .build(DbBackend::Postgres); query.sql = format!( - "{} WHERE excluded.slot_updated > asset.slot_updated", + "{} WHERE excluded.slot_updated >= asset.slot_updated OR asset.slot_updated IS NULL", query.sql ); txn.execute(query) .await .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; + let attachment = asset_v1_account_attachments::ActiveModel { id: Set(edition_attachment_address.to_bytes().to_vec()), slot_updated: Set(slot_i), @@ -252,8 +319,9 @@ pub async fn save_v1_asset( txn.execute(query) .await .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; + let model = asset_authority::ActiveModel { - asset_id: Set(id.to_vec()), + asset_id: Set(mint_pubkey_vec.clone()), authority: Set(authority), seq: Set(0), slot_updated: Set(slot_i), @@ -277,13 +345,14 @@ pub async fn save_v1_asset( txn.execute(query) .await .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; + if let Some(c) = &metadata.collection { let model = asset_grouping::ActiveModel { - asset_id: Set(id.to_vec()), + asset_id: Set(mint_pubkey_vec.clone()), group_key: Set("collection".to_string()), group_value: Set(Some(c.key.to_string())), verified: Set(c.verified), - seq: Set(None), + group_info_seq: Set(Some(0)), slot_updated: Set(Some(slot_i)), ..Default::default() }; @@ -294,10 +363,10 @@ pub async fn save_v1_asset( asset_grouping::Column::GroupKey, ]) .update_columns([ - asset_grouping::Column::GroupKey, asset_grouping::Column::GroupValue, - asset_grouping::Column::Seq, + asset_grouping::Column::Verified, asset_grouping::Column::SlotUpdated, + asset_grouping::Column::GroupInfoSeq, ]) .to_owned(), ) @@ -310,83 +379,61 @@ pub async fn save_v1_asset( .await .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; } - txn.commit().await?; - let creators = data.creators.unwrap_or_default(); + + let creators = data + .creators + .unwrap_or_default() + .iter() + .enumerate() + .map(|(i, creator)| asset_creators::ActiveModel { + asset_id: Set(mint_pubkey_vec.clone()), + position: Set(i as i16), + creator: Set(creator.address.to_bytes().to_vec()), + share: Set(creator.share as i32), + verified: Set(creator.verified), + slot_updated: Set(Some(slot_i)), + seq: Set(Some(0)), + ..Default::default() + }) + .collect::>(); + if !creators.is_empty() { - let mut creators_set = HashSet::new(); - let existing_creators: Vec = asset_creators::Entity::find() - .filter( - Condition::all() - .add(asset_creators::Column::AssetId.eq(id.to_vec())) - .add(asset_creators::Column::SlotUpdated.lt(slot_i)), + let mut query = asset_creators::Entity::insert_many(creators) + .on_conflict( + OnConflict::columns([ + asset_creators::Column::AssetId, + asset_creators::Column::Position, + ]) + .update_columns([ + asset_creators::Column::Creator, + asset_creators::Column::Share, + asset_creators::Column::Verified, + asset_creators::Column::Seq, + asset_creators::Column::SlotUpdated, + ]) + .to_owned(), ) - .all(conn) - .await?; - if !existing_creators.is_empty() { - let mut db_creators = Vec::with_capacity(creators.len()); - for (i, c) in creators.into_iter().enumerate() { - if creators_set.contains(&c.address) { - continue; - } - db_creators.push(asset_creators::ActiveModel { - asset_id: Set(id.to_vec()), - creator: Set(c.address.to_bytes().to_vec()), - share: Set(c.share as i32), - verified: Set(c.verified), - seq: Set(Some(0)), - slot_updated: Set(Some(slot_i)), - position: Set(i as i16), - ..Default::default() - }); - creators_set.insert(c.address); - } - let txn = conn.begin().await?; - asset_creators::Entity::delete_many() - .filter( - Condition::all() - .add(asset_creators::Column::AssetId.eq(id.to_vec())) - .add(asset_creators::Column::SlotUpdated.lt(slot_i)), - ) - .exec(&txn) - .await?; - if db_creators.len() > 0 { - let mut query = asset_creators::Entity::insert_many(db_creators) - .on_conflict( - OnConflict::columns([ - asset_creators::Column::AssetId, - asset_creators::Column::Position, - ]) - .update_columns([ - asset_creators::Column::Creator, - asset_creators::Column::Share, - asset_creators::Column::Verified, - asset_creators::Column::Seq, - asset_creators::Column::SlotUpdated, - ]) - .to_owned(), - ) - .build(DbBackend::Postgres); - query.sql = format!( - "{} WHERE excluded.slot_updated > asset_creators.slot_updated", - query.sql - ); - txn.execute(query) - .await - .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; - } - txn.commit().await?; - } + .build(DbBackend::Postgres); + query.sql = format!( + "{} WHERE excluded.slot_updated >= asset_creators.slot_updated OR asset_creators.slot_updated is NULL", + query.sql + ); + txn.execute(query) + .await + .map_err(|db_err| IngesterError::AssetIndexError(db_err.to_string()))?; } + txn.commit().await?; + if uri.is_empty() { warn!( "URI is empty for mint {}. Skipping background task.", - bs58::encode(mint).into_string() + bs58::encode(mint_pubkey_vec).into_string() ); return Ok(None); } let mut task = DownloadMetadata { - asset_data_id: id.to_vec(), + asset_data_id: mint_pubkey_vec.clone(), uri, created_at: Some(Utc::now().naive_utc()), }; @@ -394,3 +441,36 @@ pub async fn save_v1_asset( let t = task.into_task_data()?; Ok(Some(t)) } + +async fn find_model_with_retry( + conn: &T, + model_name: &str, + select: &Select, + retry_intervals: &[u64], +) -> Result, DbErr> { + let mut retries = 0; + let metric_name = format!("{}_found", model_name); + + for interval in retry_intervals { + let interval_duration = Duration::from_millis(interval.to_owned()); + sleep(interval_duration).await; + + let model = select.clone().one(conn).await?; + if let Some(m) = model { + record_metric(&metric_name, true, retries); + return Ok(Some(m)); + } + retries += 1; + } + + record_metric(&metric_name, false, retries - 1); + Ok(None) +} + +fn record_metric(metric_name: &str, success: bool, retries: u32) { + let retry_count = &retries.to_string(); + let success = if success { "true" } else { "false" }; + metric! { + statsd_count!(metric_name, 1, "success" => success, "retry_count" => retry_count); + } +} diff --git a/nft_ingester/src/stream.rs b/nft_ingester/src/stream.rs index e5db78d33..34d2293e8 100644 --- a/nft_ingester/src/stream.rs +++ b/nft_ingester/src/stream.rs @@ -15,21 +15,21 @@ pub struct StreamSizeTimer { } impl StreamSizeTimer { - pub fn new( - interval_time: Duration, + pub const fn new( + interval: Duration, messenger_config: MessengerConfig, stream: &'static str, ) -> Result { Ok(Self { - interval: interval_time, + interval, stream, - messenger_config: messenger_config, + messenger_config, }) } pub async fn start(&mut self) -> Option> { metric! { - let i = self.interval.clone(); + let i = self.interval; let messenger_config = self.messenger_config.clone(); let stream = self.stream; diff --git a/nft_ingester/src/tasks/common/mod.rs b/nft_ingester/src/tasks/common/mod.rs index bf39e455d..c10fd9ee3 100644 --- a/nft_ingester/src/tasks/common/mod.rs +++ b/nft_ingester/src/tasks/common/mod.rs @@ -75,6 +75,11 @@ impl DownloadMetadataTask { } } +#[derive(FromQueryResult, Debug, Default, Clone, Eq, PartialEq)] +struct MetadataUrl { + pub metadata_url: String, +} + #[async_trait] impl BgTask for DownloadMetadataTask { fn name(&self) -> &'static str { @@ -106,6 +111,30 @@ impl BgTask for DownloadMetadataTask { } _ => serde_json::Value::String("Invalid Uri".to_string()), //TODO -> enumize this. }; + + let query = asset_data::Entity::find_by_id(download_metadata.asset_data_id.clone()) + .select_only() + .column(asset_data::Column::MetadataUrl) + .build(DbBackend::Postgres); + + match MetadataUrl::find_by_statement(query).one(db).await? { + Some(asset) => { + if asset.metadata_url != download_metadata.uri { + debug!( + "skipping download metadata of old URI for {:?}", + bs58::encode(download_metadata.asset_data_id.clone()).into_string() + ); + return Ok(()); + } + } + None => { + return Err(IngesterError::UnrecoverableTaskError(format!( + "failed to find URI in database for {:?}", + bs58::encode(download_metadata.asset_data_id.clone()).into_string() + ))); + } + } + let model = asset_data::ActiveModel { id: Unchanged(download_metadata.asset_data_id.clone()), metadata: Set(body), @@ -118,6 +147,10 @@ impl BgTask for DownloadMetadataTask { ); asset_data::Entity::update(model) .filter(asset_data::Column::Id.eq(download_metadata.asset_data_id.clone())) + .filter( + Condition::all() + .add(asset_data::Column::MetadataUrl.eq(download_metadata.uri.clone())), + ) .exec(db) .await .map(|_| ()) diff --git a/nft_ingester/src/tasks/mod.rs b/nft_ingester/src/tasks/mod.rs index 9e29658d6..83759e7ac 100644 --- a/nft_ingester/src/tasks/mod.rs +++ b/nft_ingester/src/tasks/mod.rs @@ -3,7 +3,7 @@ use async_trait::async_trait; use cadence_macros::{is_global_default_set, statsd_count, statsd_histogram}; use chrono::{Duration, NaiveDateTime, Utc}; use crypto::{digest::Digest, sha2::Sha256}; -use das_metadata_json::SenderPool; +use das_metadata_json::sender::{SenderArgs, SenderPool}; use digital_asset_types::dao::{sea_orm_active_enums::TaskStatus, tasks}; use log::{debug, error, info, warn}; use sea_orm::{ @@ -98,12 +98,13 @@ pub trait IntoTaskData: Sized { pub struct TaskManager { instance_name: String, pool: Pool, - metadata_json_sender: Option, producer: Option>, + metadata_json_sender: Option, registered_task_types: Arc>>, } impl TaskManager { + #[allow(clippy::borrowed_box)] async fn execute_task( db: &DatabaseConnection, task_def: &Box, @@ -125,7 +126,7 @@ impl TaskManager { }?; let start = Utc::now(); - let res = task_def.task(&db, *data_json).await; + let res = task_def.task(db, *data_json).await; let end = Utc::now(); task.duration = Set(Some( ((end.timestamp_millis() - start.timestamp_millis()) / 1000) as i32, @@ -233,23 +234,34 @@ impl TaskManager { task.locked_by = Set(Some(instance_name)); } - pub fn new( + pub async fn try_new_async( instance_name: String, pool: Pool, - metadata_json_sender: Option, + metadata_json_sender_config: Option, task_defs: Vec>, - ) -> Self { + ) -> Result { let mut tasks = HashMap::new(); for task in task_defs { tasks.insert(task.name().to_string(), task); } - TaskManager { + + let metadata_json_sender = if let Some(config) = metadata_json_sender_config { + Some(SenderPool::try_from_config(config).await.map_err(|_| { + IngesterError::TaskManagerError( + "Failed to connect to metadata json sender".to_string(), + ) + })?) + } else { + None + }; + + Ok(TaskManager { instance_name, pool, producer: None, metadata_json_sender, registered_task_types: Arc::new(tasks), - } + }) } pub fn new_task_handler( @@ -306,20 +318,10 @@ impl TaskManager { .map_err(|e| e.into()) } - async fn save_task( - txn: &A, - task: tasks::ActiveModel, - ) -> Result - where - A: ConnectionTrait, - { - let act: tasks::ActiveModel = task; - act.save(txn).await.map_err(|e| e.into()) - } pub fn start_listener(&mut self, process_on_receive: bool) -> JoinHandle<()> { let (producer, mut receiver) = mpsc::unbounded_channel::(); self.producer = Some(producer); - let task_map = self.registered_task_types.clone(); + let task_map = Arc::clone(&self.registered_task_types); let pool = self.pool.clone(); let instance_name = self.instance_name.clone(); let sender_pool = self.metadata_json_sender.clone(); @@ -343,9 +345,10 @@ impl TaskManager { let download_metadata_task = DownloadMetadata::from_task_data(task); if let Ok(download_metadata_task) = download_metadata_task { - if let Err(_) = sender_pool + if sender_pool .push(&download_metadata_task.asset_data_id) .await + .is_err() { metric! { statsd_count!("ingester.metadata_json.send.failed", 1); @@ -383,7 +386,7 @@ impl TaskManager { pool.clone(), instance_name, task, - task_map.clone(), + Arc::clone(&task_map), process_on_receive, ); @@ -395,8 +398,19 @@ impl TaskManager { }) } + async fn save_task( + txn: &A, + task: tasks::ActiveModel, + ) -> Result + where + A: ConnectionTrait, + { + let act: tasks::ActiveModel = task; + act.save(txn).await.map_err(|e| e.into()) + } + pub fn start_runner(&self, config: Option) -> JoinHandle<()> { - let task_map = self.registered_task_types.clone(); + let task_map = Arc::clone(&self.registered_task_types); let instance_name = self.instance_name.clone(); // Load the config values @@ -464,22 +478,18 @@ impl TaskManager { match tasks_res { Ok(tasks) => { debug!("tasks that need to be executed: {}", tasks.len()); - let _task_map_clone = task_map.clone(); - let instance_name = instance_name.clone(); for task in tasks { - let task_map_clone = task_map.clone(); - let instance_name_clone = instance_name.clone(); + let task_map = Arc::clone(&task_map); + let instance_name = instance_name.clone(); let pool = pool.clone(); tokio::task::spawn(async move { - if let Some(task_executor) = - task_map_clone.clone().get(&*task.task_type) - { + if let Some(task_executor) = task_map.get(&*task.task_type) { let conn = SqlxPostgresConnector::from_sqlx_postgres_pool(pool); let mut active_model: tasks::ActiveModel = task.into(); TaskManager::lock_task( &mut active_model, Duration::seconds(task_executor.lock_duration()), - instance_name_clone, + instance_name, ); // can ignore as txn will bubble up errors let active_model = diff --git a/nft_ingester/src/transaction_notifications.rs b/nft_ingester/src/transaction_notifications.rs index 99470d32e..02aa5d971 100644 --- a/nft_ingester/src/transaction_notifications.rs +++ b/nft_ingester/src/transaction_notifications.rs @@ -22,12 +22,13 @@ pub fn transaction_worker( bg_task_sender: UnboundedSender, ack_channel: UnboundedSender<(&'static str, String)>, consumption_type: ConsumptionType, + cl_audits: bool, stream_key: &'static str, ) -> JoinHandle<()> { tokio::spawn(async move { let source = T::new(config).await; if let Ok(mut msg) = source { - let manager = Arc::new(ProgramTransformer::new(pool, bg_task_sender)); + let manager = Arc::new(ProgramTransformer::new(pool, bg_task_sender, cl_audits)); loop { let e = msg.recv(stream_key, consumption_type.clone()).await; let mut tasks = JoinSet::new(); @@ -49,14 +50,12 @@ pub fn transaction_worker( } } while let Some(res) = tasks.join_next().await { - if let Ok(id) = res { - if let Some(id) = id { - let send = ack_channel.send((stream_key, id)); - if let Err(err) = send { - metric! { + if let Ok(Some(id)) = res { + let send = ack_channel.send((stream_key, id)); + if let Err(err) = send { + metric! { error!("Txn stream ack error: {}", err); statsd_count!("ingester.stream.ack_error", 1, "stream" => stream_key); - } } } } diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 469626eac..eb84afdfc 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,2 +1,5 @@ [toolchain] -channel = "1.70.0" \ No newline at end of file +channel = "1.75.0" +components = ["clippy", "rustfmt"] +targets = [] +profile = "minimal" diff --git a/tools/acc_forwarder/Cargo.toml b/tools/acc_forwarder/Cargo.toml index 04e0ee842..edd45ca81 100644 --- a/tools/acc_forwarder/Cargo.toml +++ b/tools/acc_forwarder/Cargo.toml @@ -1,29 +1,33 @@ [package] name = "acc_forwarder" version = "0.7.12" -edition = "2021" -publish = false +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -anyhow = "1.0.70" -bs58 = "0.4.0" -clap = { version = "4.1.4", features = ["derive"] } -env_logger = "0.10.0" -figment = "0.10.8" -flatbuffers = "23.1.21" -futures = "0.3.28" -lazy_static = "1.4.0" -log = "0.4.17" -mpl-token-metadata = "=2.0.0-beta.1" -plerkle_serialization = { version = "1.6.0" } -plerkle_messenger = { version = "1.6.0", features = ['redis'] } -prometheus = "0.13.3" -reqwest = { version = "0.11", features = ["json"] } -serde_json = "1.0.81" -solana-account-decoder = "~1.16.16" -solana-client = "~1.16.16" -solana-sdk = "~1.16.16" -solana-transaction-status = "~1.16.16" -spl-token = { version = ">= 3.5.0, < 5.0", features = ["no-entrypoint"] } -tokio = { version = "1.23.0", features = ["macros", "rt-multi-thread", "time"] } -txn_forwarder = { path = "../txn_forwarder" } +anyhow = { workspace = true } +bs58 = { workspace = true } +clap = { workspace = true, features = ["derive"] } +env_logger = { workspace = true } +figment = { workspace = true } +flatbuffers = { workspace = true } +futures = { workspace = true } +lazy_static = { workspace = true } +log = { workspace = true } +mpl-token-metadata = { workspace = true } +plerkle_messenger = { workspace = true, features = ['redis'] } +plerkle_serialization = { workspace = true } +prometheus = { workspace = true } +reqwest = { workspace = true, features = ["json"] } +serde_json = { workspace = true } +solana-account-decoder = { workspace = true } +solana-client = { workspace = true } +solana-sdk = { workspace = true } +solana-transaction-status = { workspace = true } +spl-token = { workspace = true, features = ["no-entrypoint"] } +tokio = { workspace = true, features = ["macros", "rt-multi-thread", "time"] } +txn_forwarder = { workspace = true } + +[lints] +workspace = true diff --git a/tools/acc_forwarder/src/main.rs b/tools/acc_forwarder/src/main.rs index 61349a8fb..f90655c16 100644 --- a/tools/acc_forwarder/src/main.rs +++ b/tools/acc_forwarder/src/main.rs @@ -19,7 +19,7 @@ use { }, solana_sdk::{ account::Account, - borsh::try_from_slice_unchecked, + borsh0_10::try_from_slice_unchecked, commitment_config::{CommitmentConfig, CommitmentLevel}, pubkey::Pubkey, signature::Signature, @@ -416,7 +416,11 @@ async fn send_account( let fbb = serialize_account(fbb, &account_info, slot, is_startup); let bytes = fbb.finished_data(); - messenger.lock().await.send(ACCOUNT_BACKFILL_STREAM, bytes).await?; + messenger + .lock() + .await + .send(ACCOUNT_BACKFILL_STREAM, bytes) + .await?; info!("sent account {} to stream", pubkey); ACC_FORWARDER_SENT.inc(); diff --git a/tools/bgtask_creator/Cargo.toml b/tools/bgtask_creator/Cargo.toml index da9fae591..7011185e5 100644 --- a/tools/bgtask_creator/Cargo.toml +++ b/tools/bgtask_creator/Cargo.toml @@ -1,44 +1,25 @@ [package] name = "bgtask_creator" version = "0.7.12" -edition = "2021" -publish = false +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -anyhow = "1.0.70" -clap = { version = "4.1.4", features = ["derive", "cargo"] } -digital_asset_types = { path = "../../digital_asset_types", features = [ - "json_types", - "sql_types", -] } -futures = "0.3.25" -indicatif = "0.17.5" -lazy_static = "1.4.0" -log = "0.4.17" -nft_ingester = { path = "../../nft_ingester" } -prometheus = "0.13.3" -reqwest = "0.11.13" -serde = "1.0.136" -bs58 = "0.4.0" -serde_json = "1.0.81" -thiserror = "1.0.31" -sea-orm = { version = "0.10.6", features = [ - "macros", - "runtime-tokio-rustls", - "sqlx-postgres", - "with-chrono", - "mock", -] } -sea-query = { version = "0.28.1", features = ["postgres-array"] } -solana-sdk = "~1.16.16" -sqlx = { version = "0.6.2", features = [ - "macros", - "runtime-tokio-rustls", - "postgres", - "uuid", - "offline", - "json", -] } -tokio = { version = "1.23.0", features = ["macros", "rt-multi-thread"] } -txn_forwarder = { path = "../txn_forwarder" } -das-tree-backfiller = { path = "../../tree_backfiller" } +anyhow = { workspace = true } +clap = { workspace = true, features = ["derive", "cargo"] } +digital_asset_types = { workspace = true, features = ["json_types", "sql_types"] } +futures = { workspace = true } +lazy_static = { workspace = true } +log = { workspace = true } +nft_ingester = { workspace = true } +prometheus = { workspace = true } +sea-orm = { workspace = true, features = ["macros", "runtime-tokio-rustls", "sqlx-postgres", "with-chrono", "mock"] } +sea-query = { workspace = true, features = ["postgres-array"] } +solana-sdk = { workspace = true } +sqlx = { workspace = true, features = ["macros", "runtime-tokio-rustls", "postgres", "uuid", "offline", "json"] } +tokio = { workspace = true, features = ["macros", "rt-multi-thread"] } +txn_forwarder = { workspace = true } + +[lints] +workspace = true diff --git a/tools/bgtask_creator/src/main.rs b/tools/bgtask_creator/src/main.rs index 3cc7161b6..082873da4 100644 --- a/tools/bgtask_creator/src/main.rs +++ b/tools/bgtask_creator/src/main.rs @@ -1,4 +1,4 @@ -use reqwest::Client; +use digital_asset_types::dao::extensions; use { clap::{value_parser, Arg, ArgAction, Command}, @@ -12,6 +12,7 @@ use { config::{init_logger, rand_string, setup_config}, database::setup_database, error::IngesterError, + metrics::setup_metrics, tasks::{BgTask, DownloadMetadata, DownloadMetadataTask, IntoTaskData, TaskManager}, }, prometheus::{IntGaugeVec, Opts, Registry}, @@ -21,7 +22,7 @@ use { solana_sdk::pubkey::Pubkey, sqlx::types::chrono::Utc, std::{collections::HashMap, path::PathBuf, str::FromStr, sync::Arc, time}, - time::Duration, + tokio::time::Duration, txn_forwarder::save_metrics, }; @@ -157,6 +158,9 @@ async fn main() -> anyhow::Result<()> { // Pull Env variables into config struct let config = setup_config(config_path); + // Optionally setup metrics if config demands it + setup_metrics(&config); + // One pool many clones, this thing is thread safe and send sync let database_pool = setup_database(config.clone()).await; @@ -197,8 +201,8 @@ async fn main() -> anyhow::Result<()> { ad.metadata=to_jsonb('processing'::text); */ - match matches.subcommand() { - Some(("reindex", _)) => { + match matches.subcommand_name() { + Some("reindex") => { let exec_res = conn .execute(Statement::from_string( DbBackend::Postgres, @@ -216,7 +220,7 @@ WHERE .await; info!("Updated {:?} assets", exec_res.unwrap().rows_affected()); } - Some(("show", _)) => { + Some("show") => { // Check the total number of assets in the DB let condition_found = asset_data::Column::Metadata.ne(JsonValue::String("processing".to_string())); @@ -282,7 +286,7 @@ WHERE .with_label_values(&[tp, "total"]) .set(total_assets as i64); } - Some(("delete", _)) => { + Some("delete") => { println!("Deleting all existing tasks"); // Delete all existing tasks @@ -300,7 +304,7 @@ WHERE } } } - Some(("create", _)) => { + Some("create") => { // @TODO : add a delete option that first deletes all matching tasks to the criteria or condition let condition = asset_data::Column::Reindex.eq(true); @@ -330,7 +334,7 @@ WHERE let name = instance_name.clone(); if let Ok(hash) = task_data.hash() { let database_pool = database_pool.clone(); - let task_map = task_map.clone(); + let task_map = Arc::clone(&task_map); let name = name.clone(); let tp = asset_data.1.clone(); let new_task = tokio::task::spawn(async move { @@ -357,7 +361,7 @@ WHERE database_pool.clone(), name.clone(), task_data, - task_map.clone(), + Arc::clone(&task_map), false, ) .await; @@ -405,46 +409,6 @@ WHERE metrics_jh.await } -#[derive(thiserror::Error, Debug)] -enum MetadataJsonTaskError { - #[error("reqwest: {0}")] - Reqwest(#[from] reqwest::Error), - #[error("sea orm: {0}")] - SeaOrm(#[from] sea_orm::DbErr), -} - -async fn perform_metadata_json_task( - client: &Arc, - pool: sqlx::PgPool, - asset_data: asset_data::Model, -) -> Result { - let metadata = fetch_metadata_json(client, &asset_data.metadata_url).await?; - let conn = SqlxPostgresConnector::from_sqlx_postgres_pool(pool); - let asset_data_active_model = asset_data::ActiveModel { - id: Set(asset_data.id), - metadata: Set(metadata), - reindex: Set(Some(false)), - ..Default::default() - }; - - asset_data_active_model - .update(&conn) - .await - .map_err(Into::into) -} - -async fn fetch_metadata_json( - client: &Arc, - uri: &str, -) -> Result { - client - .get(uri) - .send() - .await? - .json::() - .await -} - fn find_by_type<'a>( authority: Option<&'a String>, collection: Option<&'a String>, @@ -513,7 +477,10 @@ fn find_by_type<'a>( ( asset_data::Entity::find() - .join(JoinType::InnerJoin, asset_data::Relation::Asset.def()) + .join( + JoinType::InnerJoin, + extensions::asset_data::Relation::Asset.def(), + ) .join_rev( JoinType::InnerJoin, tokens::Entity::belongs_to(asset::Entity) diff --git a/tools/fetch_trees/Cargo.toml b/tools/fetch_trees/Cargo.toml index 4035014ca..eb4f33460 100644 --- a/tools/fetch_trees/Cargo.toml +++ b/tools/fetch_trees/Cargo.toml @@ -1,17 +1,21 @@ [package] name = "fetch_trees" version = "0.7.12" -edition = "2021" -publish = false +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -anyhow = "1.0.70" -async-trait = "0.1.53" -borsh = "~0.10.3" -clap = { version = "4.2.2", features = ["derive", "cargo"] } -mpl-bubblegum = "1.0.1-beta.3" -solana-account-decoder = "~1.16.16" -solana-client = "~1.16.16" -solana-sdk = "~1.16.16" -spl-account-compression = { version = "0.2.0", features = ["no-entrypoint"] } -tokio = { version = "1.26.0", features = ["full", "tracing"] } +anyhow = { workspace = true } +async-trait = { workspace = true } +borsh = { workspace = true } +clap = { workspace = true, features = ["derive", "cargo"] } +mpl-bubblegum = { workspace = true } +solana-account-decoder = { workspace = true } +solana-client = { workspace = true } +solana-sdk = { workspace = true } +spl-account-compression = { workspace = true, features = ["no-entrypoint"] } +tokio = { workspace = true, features = ["tracing"] } + +[lints] +workspace = true diff --git a/tools/load_generation/Cargo.toml b/tools/load_generation/Cargo.toml index 2f9452300..bd7b0de3b 100644 --- a/tools/load_generation/Cargo.toml +++ b/tools/load_generation/Cargo.toml @@ -1,16 +1,20 @@ [package] name = "load_generation" version = "0.7.12" -edition = "2021" -publish = false +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -fake = "2.5.0" -mpl-token-metadata = "=2.0.0-beta.1" -rand = "0.8.5" -solana-client = "~1.16.16" -solana-program = "~1.16.16" -solana-sdk = "~1.16.16" -spl-associated-token-account = { version = ">= 1.1.3, < 3.0", features = ["no-entrypoint"] } -spl-token = { version = ">= 3.5.0, < 5.0", features = ["no-entrypoint"] } -tokio = { version ="1.25.0", features = ["macros", "rt-multi-thread"] } +fake = { workspace = true } +mpl-token-metadata = { workspace = true } +rand = { workspace = true } +solana-client = { workspace = true } +solana-program = { workspace = true } +solana-sdk = { workspace = true } +spl-associated-token-account = { workspace = true, features = ["no-entrypoint"] } +spl-token = { workspace = true, features = ["no-entrypoint"] } +tokio = { workspace = true, features = ["macros", "rt-multi-thread"] } + +[lints] +workspace = true diff --git a/tools/load_generation/src/main.rs b/tools/load_generation/src/main.rs index b2b52f99b..d6bf340bf 100644 --- a/tools/load_generation/src/main.rs +++ b/tools/load_generation/src/main.rs @@ -36,19 +36,28 @@ async fn main() { ); let kp_new = Arc::new(Keypair::new()); let semaphore = Arc::new(Semaphore::new(carnage)); - let _ = check_balance(le_blockchain.clone(), kp.clone(), network != "mainnet").await; - let nft_collection_thing = - make_a_nft_thing(le_blockchain.clone(), kp.clone(), kp.clone(), None) - .await - .unwrap(); + let _ = check_balance( + Arc::clone(&le_blockchain), + Arc::clone(&kp), + network != "mainnet", + ) + .await; + let nft_collection_thing = make_a_nft_thing( + Arc::clone(&le_blockchain), + Arc::clone(&kp), + Arc::clone(&kp), + None, + ) + .await + .unwrap(); println!("NFT Collection Thing: {:?}", nft_collection_thing); loop { let mut tasks = vec![]; for _ in 0..carnage { - let kp = kp.clone(); - let kp_new = kp_new.clone(); - let le_clone = le_blockchain.clone(); - let semaphore = semaphore.clone(); + let kp = Arc::clone(&kp); + let kp_new = Arc::clone(&kp_new); + let le_clone = Arc::clone(&le_blockchain); + let semaphore = Arc::clone(&semaphore); tasks.push(tokio::spawn(async move { let _permit = semaphore.acquire().await.unwrap(); //wait for le government to allow le action // MINT A MASTER EDITION: @@ -68,7 +77,12 @@ async fn main() { } } } - let _ = check_balance(le_blockchain.clone(), kp.clone(), network != "mainnet").await; + let _ = check_balance( + Arc::clone(&le_blockchain), + Arc::clone(&kp), + network != "mainnet", + ) + .await; } } @@ -150,8 +164,13 @@ pub async fn make_a_nft_thing( owner: Arc, collection_mint: Option, ) -> Result { - let (mint, _token_account) = - make_a_token_thing(solana_client.clone(), payer.clone(), owner.clone(), 1).await?; + let (mint, _token_account) = make_a_token_thing( + Arc::clone(&solana_client), + Arc::clone(&payer), + Arc::clone(&owner), + 1, + ) + .await?; let prg_uid = mpl_token_metadata::id(); let _metadata_seeds = &[ mpl_token_metadata::state::PREFIX.as_bytes(), diff --git a/tools/tree-status/Cargo.toml b/tools/tree-status/Cargo.toml index 52abc07e5..da8ccc058 100644 --- a/tools/tree-status/Cargo.toml +++ b/tools/tree-status/Cargo.toml @@ -2,31 +2,35 @@ name = "tree-status" version = "0.7.12" authors = ["Triton One"] -edition = "2021" +edition = { workspace = true } description = "Test state of the sprcified tree" -publish = false +repository = { workspace = true } +publish = { workspace = true } [dependencies] -anchor-client = "0.28.0" -anyhow = "1.0.70" -bs58 = "0.4.0" -clap = { version = "4.1.4", features = ["derive"] } -digital_asset_types = { path = "../../digital_asset_types", features = ["json_types", "sql_types"] } -env_logger = "0.10.0" -flatbuffers = "23.1.21" -futures = "0.3.28" -hex = "0.4.3" -lazy_static = "1.4.0" -log = "0.4.17" -prometheus = "0.13.3" -sea-orm = { version = "0.10.6", features = ["macros", "runtime-tokio-rustls", "sqlx-postgres", "with-chrono", "mock"] } -serde_json = "1.0.81" -solana-client = "~1.16.16" -solana-sdk = "~1.16.16" -solana-transaction-status = "~1.16.16" -spl-account-compression = { version = "0.2.0", features = ["no-entrypoint"] } -spl-noop = { version = "0.2.0", features = ["no-entrypoint"] } -sqlx = { version = "0.6.2", features = ["macros", "runtime-tokio-rustls", "postgres", "uuid", "offline", "json"] } -thiserror = "1.0.31" -tokio = { version = "1.23.0", features = ["fs", "macros", "rt-multi-thread", "sync", "time"] } -txn_forwarder = { path = "../txn_forwarder" } +anchor-client = { workspace = true } +anyhow = { workspace = true } +bs58 = { workspace = true } +clap = { workspace = true, features = ["derive"] } +digital_asset_types = { workspace = true, features = ["json_types", "sql_types"] } +env_logger = { workspace = true } +flatbuffers = { workspace = true } +futures = { workspace = true } +hex = { workspace = true } +lazy_static = { workspace = true } +log = { workspace = true } +prometheus = { workspace = true } +sea-orm = { workspace = true, features = ["macros", "runtime-tokio-rustls", "sqlx-postgres", "with-chrono", "mock"] } +serde_json = { workspace = true } +solana-client = { workspace = true } +solana-sdk = { workspace = true } +solana-transaction-status = { workspace = true } +spl-account-compression = { workspace = true, features = ["no-entrypoint"] } +spl-noop = { workspace = true, features = ["no-entrypoint"] } +sqlx = { workspace = true, features = ["macros", "runtime-tokio-rustls", "postgres", "uuid", "offline", "json"] } +thiserror = { workspace = true } +tokio = { workspace = true, features = ["fs", "macros", "rt-multi-thread", "sync", "time"] } +txn_forwarder = { workspace = true } + +[lints] +workspace = true diff --git a/tools/tree-status/src/main.rs b/tools/tree-status/src/main.rs index e829bcb4c..675a390f2 100644 --- a/tools/tree-status/src/main.rs +++ b/tools/tree-status/src/main.rs @@ -794,7 +794,7 @@ fn parse_tx_sequence( AccountCompressionEvent::try_from_slice(&data) { let ChangeLogEvent::V1(cl_data) = cl_data; - let leaf = cl_data.path.get(0).map(|node| LeafNode { + let leaf = cl_data.path.first().map(|node| LeafNode { leaf: node.node.to_vec(), index: node_idx_to_leaf_idx( node.index as i64, @@ -815,6 +815,6 @@ fn parse_tx_sequence( Ok(seq_updates) } -fn node_idx_to_leaf_idx(index: i64, tree_height: u32) -> i64 { +const fn node_idx_to_leaf_idx(index: i64, tree_height: u32) -> i64 { index - 2i64.pow(tree_height) } diff --git a/tools/txn_forwarder/Cargo.toml b/tools/txn_forwarder/Cargo.toml index f66f27bd6..c9f5ca999 100644 --- a/tools/txn_forwarder/Cargo.toml +++ b/tools/txn_forwarder/Cargo.toml @@ -1,26 +1,30 @@ [package] name = "txn_forwarder" version = "0.7.12" -edition = "2021" -publish = false +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } [dependencies] -anyhow = "1" -clap = { version = "4.1.4", features = ["derive"] } -env_logger = "0.10.0" -figment = "0.10.8" -flatbuffers = "23.1.21" -futures = "0.3.28" -lazy_static = "1.4.0" -log = "0.4.17" -plerkle_serialization = { version = "1.6.0" } -plerkle_messenger = { version = "1.6.0", features = ['redis'] } -prometheus = "0.13.3" -serde = "1.0.162" -serde_json = "1.0.81" -solana-client = "~1.16.16" -solana-sdk = "~1.16.16" -solana-transaction-status = "~1.16.16" -thiserror = "1.0.31" -tokio = { version = "1.23.0", features = ["macros", "rt-multi-thread", "sync", "time", "fs"] } -tokio-stream = { version = "0.1.14", features = ["io-util"] } +anyhow = { workspace = true } +clap = { workspace = true, features = ["derive"] } +env_logger = { workspace = true } +figment = { workspace = true } +flatbuffers = { workspace = true } +futures = { workspace = true } +lazy_static = { workspace = true } +log = { workspace = true } +plerkle_messenger = { workspace = true, features = ['redis'] } +plerkle_serialization = { workspace = true } +prometheus = { workspace = true } +serde = { workspace = true } +serde_json = { workspace = true } +solana-client = { workspace = true } +solana-sdk = { workspace = true } +solana-transaction-status = { workspace = true } +thiserror = { workspace = true } +tokio = { workspace = true, features = ["macros", "rt-multi-thread", "sync", "time", "fs"] } +tokio-stream = { workspace = true, features = ["io-util"] } + +[lints] +workspace = true diff --git a/tools/txn_forwarder/bubblegum_tests/run-bubblegum-sequences.sh b/tools/txn_forwarder/bubblegum_tests/run-bubblegum-sequences.sh new file mode 100755 index 000000000..137158455 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/run-bubblegum-sequences.sh @@ -0,0 +1,179 @@ +#!/bin/bash + +# Pass `reverse` to run scenarios in reverse. +if [ "$1" = "reverse" ]; then + REVERSE="true" +else + REVERSE="false" +fi + +SCENARIOS=("mint_transfer_burn.scenario" \ +"mint_redeem_decompress.scenario" +"mint_redeem_cancel_redeem_redeem_decompress.scenario" \ +"mint_transfer_transfer.scenario" \ +"mint_delegate_transfer.scenario" \ +"mint_verify_creator.scenario" \ +"mint_verify_collection.scenario" \ +"mint_verify_collection_unverify_collection.scenario" \ +"mint_set_and_verify_collection.scenario" \ +"mint_to_collection_unverify_collection.scenario" +) + +TEST_SCENARIO_DATA_DIR="test_scenario_data" + +# Output text in colors. +# $1 is output text. +RED() { echo $'\e[1;31m'$1$'\e[0m'; } +GRN() { echo $'\e[1;32m'$1$'\e[0m'; } + +# Read from database using psql and compare to expected value. +# $1 is SQL command. +# $2 extra CLI args to send to psql. +# $3 is expected value. +# $4 is topic for the pass/fail message. +# Returns 0 if database value matches expected value, otherwise returns 1. +CHECK_DATABASE() { + local DATABASE_VAL=$(PGPASSWORD=solana psql -h localhost -U solana "$2" --command="$1") + # Remove `created_at` since the date changes for `asset` table entries. + local DATABASE_VAL=$(sed '/^created_at/d' <<< "$DATABASE_VAL") + if [ "$3" = "$DATABASE_VAL" ]; then + echo $(GRN "${SCENARIOS[$i]} $4 passed") >&2 + return 0 + else + echo $(RED "${SCENARIOS[$i]} $4 failed") >&2 + echo "Asset ID: $ASSET_ID" >&2 + echo "Expected:" >&2 + echo "$3" >&2 + echo "" + echo "Actual:" >&2 + echo "$DATABASE_VAL" >&2 + return 1 + fi +} + +# Read in expected data from test data file. If the $REVERSE flag is set to "true" then first +# look for a file with the `_reverse` suffix. If one does not exist, use the default filename +# for that suffix. +# $1 is scenario file to use as a base name. +# $2 is the suffix for the type of test data, i.e. "asset", "cl_items", etc. +# If successful, prints contents of file on stdout and returns 0, otherwise returns 1. +READ_IN_EXPECTED_DATA() { + local BASE_NAME=$(basename "$1" .scenario) + if [ "$REVERSE" = "true" ]; then + local EXPECTED_DATA_FILE_BW="$TEST_SCENARIO_DATA_DIR/${BASE_NAME}_"$2"_reverse.txt" + if [ -f "$EXPECTED_DATA_FILE_BW" ]; then + cat "$EXPECTED_DATA_FILE_BW" + return 0 + fi + fi + + local EXPECTED_DATA_FILE="$TEST_SCENARIO_DATA_DIR/${BASE_NAME}_"$2".txt" + if [ -f "$EXPECTED_DATA_FILE" ]; then + cat "$EXPECTED_DATA_FILE" + return 0 + else + echo $(RED "$1 missing $2 file") >&2 + return 1 + fi +} + +if [ "$REVERSE" = "true" ]; then + echo "Running ${#SCENARIOS[@]} scenarios in reverse" +else + echo "Running ${#SCENARIOS[@]} scenarios forwards" +fi + +# 0 is pass, 1 is fail. +STATUS=0 + +# Run each scenario and check for expected database result. +for i in ${!SCENARIOS[@]}; do + # Read in the expected database data for this scenario. + EXPECTED_ASSET_VALUE=$(READ_IN_EXPECTED_DATA "${SCENARIOS[$i]}" "asset") || { STATUS=1; continue; } + EXPECTED_ASSET_CREATORS=$(READ_IN_EXPECTED_DATA "${SCENARIOS[$i]}" "asset_creators") || { STATUS=1; continue; } + EXPECTED_ASSET_GROUPING=$(READ_IN_EXPECTED_DATA "${SCENARIOS[$i]}" "asset_grouping") || { STATUS=1; continue; } + EXPECTED_CL_ITEMS=$(READ_IN_EXPECTED_DATA "${SCENARIOS[$i]}" "cl_items") || { STATUS=1; continue; } + + # Parse out the asset ID. + ASSET_ID=$(echo "$EXPECTED_ASSET_VALUE" | grep -oP '^(?!tree_id).*id\s+\|\s+\K[^ ]+') + if [ ${#ASSET_ID} -ne 66 ]; then + echo $(RED "${SCENARIOS[$i]} incorrect asset ID parsing") + echo "Asset ID: $ASSET_ID" + STATUS=1 + continue + fi + + # Parse out the tree ID. + TREE_ID=$(echo "$EXPECTED_CL_ITEMS" | grep -oP '^\s*\K\\x[0-9a-f]+' | head -n 1) + if [ ${#TREE_ID} -ne 66 ]; then + echo $(RED "${SCENARIOS[$i]} incorrect asset ID parsing") + echo "Tree ID: $TREE_ID" + STATUS=1 + continue + fi + + # Initially this asset should not be in any database tables. + ASSET_SQL="SELECT * FROM asset WHERE id = '$ASSET_ID';" + CHECK_DATABASE "$ASSET_SQL" "-x" "(0 rows)" "initial asset table state" || STATUS=1 + + ASSET_CREATORS_SQL="SELECT asset_id, creator, share, verified, seq, slot_updated, position \ + FROM asset_creators \ + WHERE asset_id = '$ASSET_ID' \ + ORDER BY position;" + CHECK_DATABASE "$ASSET_CREATORS_SQL" "-x" "(0 rows)" "initial asset_creators table state" || STATUS=1 + + ASSET_GROUPING_SQL="SELECT asset_id, group_key, group_value, seq, slot_updated, verified, group_info_seq \ + FROM asset_grouping \ + WHERE asset_id = '$ASSET_ID';" + CHECK_DATABASE "$ASSET_GROUPING_SQL" "-x" "(0 rows)" "initial asset_grouping table state" || STATUS=1 + + CL_ITEMS_SQL="select tree, node_idx, leaf_idx, seq, level, hash from cl_items where tree = '$TREE_ID' order by level;" + CHECK_DATABASE "$CL_ITEMS_SQL" "-x" "(0 rows)" "initial cl_items table state" || STATUS=1 + + # Run the scenario file that indexes the asset. These are done with separate calls to the `txn_forwarder` + # in order to enforce order. Just calling the `txn_forwarder` with the file results in random ordering. + readarray -t TXS < "$TEST_SCENARIO_DATA_DIR/${SCENARIOS[$i]}" + + # Reverse transactions if necessary. + if [ "$REVERSE" = "true" ]; then + REVERSED_TXS=() + for ((j = ${#TXS[@]} - 1; j >= 0; j--)); do + REVERSED_TXS+=("${TXS[j]}") + done + TXS=("${REVERSED_TXS[@]}") + fi + + for TX in ${TXS[@]}; do + (cd .. && \ + cargo run -- \ + --redis-url 'redis://localhost/' \ + --rpc-url 'https://api.devnet.solana.com' \ + single \ + --txn "$TX" \ + 2>&1 | grep -v "Group already exists: BUSYGROUP: Consumer Group name already exists") + done + + sleep 2 + + # Asset should now be in the database and all fields match (except `created_at` in `asset`` table). + CHECK_DATABASE "$ASSET_SQL" "-x" "$EXPECTED_ASSET_VALUE" "asset table" || STATUS=1 + CHECK_DATABASE "$ASSET_CREATORS_SQL" "-x" "$EXPECTED_ASSET_CREATORS" "asset_creators table" || STATUS=1 + CHECK_DATABASE "$ASSET_GROUPING_SQL" "-x" "$EXPECTED_ASSET_GROUPING" "asset_grouping table" || STATUS=1 + CHECK_DATABASE "$CL_ITEMS_SQL" "" "$EXPECTED_CL_ITEMS" "cl_items table" || STATUS=1 + + echo "" +done + +if [ "$REVERSE" = "true" ]; then + SUFFIX="IN REVERSE" +else + SUFFIX="FORWARDS" +fi + +if [ $STATUS -eq 1 ]; then + echo $(RED "SOME TESTS FAILED $SUFFIX!") +else + echo $(GRN "ALL TESTS PASSED $SUFFIX!") +fi + +exit $STATUS diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer.scenario new file mode 100644 index 000000000..0a1c8b6a8 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer.scenario @@ -0,0 +1,3 @@ +KNWsAYPo3mm1HuFxRyEwBBMUZ2hqTnFXjoPVFo7WxGTfmfRwz6K8eERc4dnJpHyuoDkAZu1czK55iB1SbtCsdW2 +3B1sASkuToCWuGFRG47axQDm1SpgLi8qDDGnRFeR7LB6oa5C3ZmkEuX98373gdMTBXED44FkwT227kBBAGSw7e8M +5Q8TAMMkMTHEM2BHyD2fp2sVdYKByFeATzM2mHF6Xbbar33WaeuygPKGYCWiDEt3MZU1mUrq1ePnT9o4Pa318p8w diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset.txt new file mode 100644 index 000000000..3d0d3cd1e --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x5aed3f1d3faf9f5f4664f98055d25627d59d0351ee8f0802ebbb33ccd8220d67 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xbd44aea35a84cb4ef1a03d3f66896abab67932a7fb812d6f583ef4099f59843a +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 3 +tree_id | \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c +leaf | \xa23d2bea8c65587f7f9fc627e3799ad8ffd0e222ccfda60e4327e07c51b8be3e +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x5aed3f1d3faf9f5f4664f98055d25627d59d0351ee8f0802ebbb33ccd8220d67 +burnt | f +slot_updated | 226274127 +data_hash | F5iDDHxd2DVZa5eZCqE2a91QLadea4ygJwM18UUut6dj +creator_hash | EF57j46BT5Cynwija675rq59iDN1ZapYsJDnMHqta463 +owner_delegate_seq | 3 +leaf_seq | 3 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset_creators.txt new file mode 100644 index 000000000..6e62570fa --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x5aed3f1d3faf9f5f4664f98055d25627d59d0351ee8f0802ebbb33ccd8220d67 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 226274127 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x5aed3f1d3faf9f5f4664f98055d25627d59d0351ee8f0802ebbb33ccd8220d67 +creator | \xe3dc3480d88f714c38827aada3064e8d212a91e3fdb67f22438c1ed89318a0e5 +share | 45 +verified | f +seq | 1 +slot_updated | 226274127 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset_grouping.txt new file mode 100644 index 000000000..4b0e51667 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x5aed3f1d3faf9f5f4664f98055d25627d59d0351ee8f0802ebbb33ccd8220d67 +group_key | collection +group_value | +seq | +slot_updated | 226274127 +verified | f +group_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_cl_items.txt new file mode 100644 index 000000000..5414959ca --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_delegate_transfer_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 16384 | 0 | 3 | 0 | \xa23d2bea8c65587f7f9fc627e3799ad8ffd0e222ccfda60e4327e07c51b8be3e + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 8192 | | 3 | 1 | \xe9152e451cbd119ea3bab38afbf6b4711199c73fdb385e44b06c2e707f8ca243 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 4096 | | 3 | 2 | \x111573f71f36e611641839e7e560bb73b680309841360c514965d168a4389a51 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 2048 | | 3 | 3 | \x4f64ec2a0d08484ec567cc0b4060dbfbceb9fa665d8a17dc8af9ebece7f01d9b + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 1024 | | 3 | 4 | \x4989debb3a21bd71c16a74d766abbd699650ee1aeae315fdda79a1728746da95 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 512 | | 3 | 5 | \x418f8841080e45b9b7cf09a3caaefd42976708bf0257c6c0806bb16ead54cf53 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 256 | | 3 | 6 | \xd4935ac4cb16da1b52198a0dac6d2609c14430ef5212809e294652ec25d9ef59 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 128 | | 3 | 7 | \xd26ec1beefbb64d05cc4c976c617485d82c240033e94e747129975b40638e111 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 64 | | 3 | 8 | \x3542d0fba80dd3681e3933f0ecd2ebd344a0ad96f23c8f2574099c7318c533e7 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 32 | | 3 | 9 | \x9d39b564f68ed8b88e6357f64e5cd0c82ca6d534aa2dab975d9666c8f56725d5 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 16 | | 3 | 10 | \x36d934448197c94e7d45f0863811edc196ed987620c41227e9f6ef1035c5934b + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 8 | | 3 | 11 | \x4637695dc219619cf5226f28ab04cb718f1140377ad01a5fff4fcd0fe2623be5 + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 4 | | 3 | 12 | \x12374d301a2a513f3b23b3645c1c1c7789bf8c9c15ef80caf9cf46351dc53dcb + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 2 | | 3 | 13 | \x4e9fe09b7aa626a863a95c6b9808a2c63ec6cc685993bd43a0b1a347c18d920f + \x1163033de45ffcf58694abca011d79e5c3682c00c65caf710490650c151b7c4c | 1 | | 3 | 14 | \x5f6a8668430a4bc94b280cdbba44efeb8847d9654ff034ffc1f537a66c120fb1 +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress.scenario new file mode 100644 index 000000000..c9ddfd90e --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress.scenario @@ -0,0 +1,5 @@ +3uzWoVgLGVd9cGXaF3JW7znpWgKse3obCa2Vvdoe59kaziX84mEXTwecUoZ49PkJDjReRMSXksKzyfj7pf3ekAGR +49bJ8U3cK9htmLvA1mhXXcjKdpV2YN5JQBrb3Quh7wxENz1BP9F8fE9CKsje41aMbZwzgomnkXirKx2Xpdvprtak +32FpSe6r9jnFNjjvbx2PPQdZqs5KpMoF6yawiRW1F6ctu1kmx2B4sLDBGjsthVQtmnhaJVrqdtmUP893FwXCbqY5 +3HqVaL9xgroAVYehnrk98dju4Ck3v8TqB4nfwnFCaNWKueaAVZcB3841jv5km1KpnubbUDoJAGv4ZMeLfAmdN18f +3s3EN8gTthjjSXq5aV6imtBB58DQ1UGLch9dyzaACid4tAEDvqcEXoE3ibiAqxTaR5XSAArzPHgXtFM6FWvN7oDr diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset.txt new file mode 100644 index 000000000..339fcbb80 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +compressed | f +compressible | f +seq | 0 +tree_id | +leaf | +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +burnt | f +slot_updated | 224494461 +data_hash | +creator_hash | +owner_delegate_seq | 3 +leaf_seq | +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_creators.txt new file mode 100644 index 000000000..a4e23a106 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 224494461 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +creator | \xe6cd5c15dc19a877bc4bdf888a32145bd007f3a6ad52243937ffe41e3c2e7c3e +share | 45 +verified | f +seq | 1 +slot_updated | 224494461 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_grouping.txt new file mode 100644 index 000000000..c59e77739 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +group_key | collection +group_value | +seq | +slot_updated | 224494461 +verified | f +group_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_reverse.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_reverse.txt new file mode 100644 index 000000000..d0b1eaaef --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_asset_reverse.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +alt_id | +specification_version | +specification_asset_class | +owner | +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | \x4302561a2799244936a3b020569bf90f58cd9b406af4cd084a82a2cf6415a8f0 +compressed | f +compressible | f +seq | 0 +tree_id | +leaf | +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | +burnt | f +slot_updated | +data_hash | +creator_hash | +owner_delegate_seq | +leaf_seq | +base_info_seq | \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_cl_items.txt new file mode 100644 index 000000000..d200b2ec8 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_cancel_redeem_redeem_decompress_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 16384 | 0 | 4 | 0 | \x0000000000000000000000000000000000000000000000000000000000000000 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 8192 | | 4 | 1 | \xad3228b676f7d3cd4284a5443f17f1962b36e491b30a40b2405849e597ba5fb5 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 4096 | | 4 | 2 | \xb4c11951957c6f8f642c4af61cd6b24640fec6dc7fc607ee8206a99e92410d30 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 2048 | | 4 | 3 | \x21ddb9a356815c3fac1026b6dec5df3124afbadb485c9ba5a3e3398a04b7ba85 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 1024 | | 4 | 4 | \xe58769b32a1beaf1ea27375a44095a0d1fb664ce2dd358e7fcbfb78c26a19344 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 512 | | 4 | 5 | \x0eb01ebfc9ed27500cd4dfc979272d1f0913cc9f66540d7e8005811109e1cf2d + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 256 | | 4 | 6 | \x887c22bd8750d34016ac3c66b5ff102dacdd73f6b014e710b51e8022af9a1968 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 128 | | 4 | 7 | \xffd70157e48063fc33c97a050f7f640233bf646cc98d9524c6b92bcf3ab56f83 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 64 | | 4 | 8 | \x9867cc5f7f196b93bae1e27e6320742445d290f2263827498b54fec539f756af + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 32 | | 4 | 9 | \xcefad4e508c098b9a7e1d8feb19955fb02ba9675585078710969d3440f5054e0 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 16 | | 4 | 10 | \xf9dc3e7fe016e050eff260334f18a5d4fe391d82092319f5964f2e2eb7c1c3a5 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 8 | | 4 | 11 | \xf8b13a49e282f609c317a833fb8d976d11517c571d1221a265d25af778ecf892 + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 4 | | 4 | 12 | \x3490c6ceeb450aecdc82e28293031d10c7d73bf85e57bf041a97360aa2c5d99c + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 2 | | 4 | 13 | \xc1df82d9c4b87413eae2ef048f94b4d3554cea73d92b0f7af96e0271c691e2bb + \xf8bf1069ff226eb41797417535cc5510ec75ffd006155dbda2371b5fee88bf7d | 1 | | 4 | 14 | \x5c67add7c6caf302256adedf7ab114da0acfe870d449a3a489f781d659e8becc +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress.scenario new file mode 100644 index 000000000..111eed691 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress.scenario @@ -0,0 +1,3 @@ +4DBsuEnL1sZgEV7AHYeD8wsuKKhhNnZPgDKrzLxQXDhizdPRWvfKJp6e8f3uTdhA9wGCkdMxPBCpwqXnTQdrCcqv +4Qvu5MAaACFKmPmFndTBBzVP6wPvBKdraaG7tRaQMQeSzL499x3AMuH1bmyPn6YFpQ5ZKMjmB8ybQNPBS8qeebXc +2EeCLqYKWRggMurkSWh7Co7W5BJs6uyZ7ierA2BW3q8CpejWYdv8mbDARmNYbnSuFsF8s2EAw8T8pgnMZW1EanVd diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset.txt new file mode 100644 index 000000000..3218c44f8 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +compressed | f +compressible | f +seq | 0 +tree_id | +leaf | +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +burnt | f +slot_updated | 224069842 +data_hash | +creator_hash | +owner_delegate_seq | 1 +leaf_seq | +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_creators.txt new file mode 100644 index 000000000..6e2798b0f --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 224069842 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +creator | \xfcd064cd56ad840b463ca2ee1f6e13b6181cbb7464699dbfe18fe989e71def89 +share | 45 +verified | f +seq | 1 +slot_updated | 224069842 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_grouping.txt new file mode 100644 index 000000000..0a8de5453 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +group_key | collection +group_value | +seq | +slot_updated | 224069842 +verified | f +group_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_reverse.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_reverse.txt new file mode 100644 index 000000000..0b7b6deef --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_asset_reverse.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +alt_id | +specification_version | +specification_asset_class | +owner | +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | \x4582ef313005487b924213937300a3c5cef8502646c8c182a2a9e1188adb196b +compressed | f +compressible | f +seq | 0 +tree_id | +leaf | +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | +burnt | f +slot_updated | +data_hash | +creator_hash | +owner_delegate_seq | +leaf_seq | +base_info_seq | \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_cl_items.txt new file mode 100644 index 000000000..6367b022f --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_redeem_decompress_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 16384 | 0 | 2 | 0 | \x0000000000000000000000000000000000000000000000000000000000000000 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 8192 | | 2 | 1 | \xad3228b676f7d3cd4284a5443f17f1962b36e491b30a40b2405849e597ba5fb5 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 4096 | | 2 | 2 | \xb4c11951957c6f8f642c4af61cd6b24640fec6dc7fc607ee8206a99e92410d30 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 2048 | | 2 | 3 | \x21ddb9a356815c3fac1026b6dec5df3124afbadb485c9ba5a3e3398a04b7ba85 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 1024 | | 2 | 4 | \xe58769b32a1beaf1ea27375a44095a0d1fb664ce2dd358e7fcbfb78c26a19344 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 512 | | 2 | 5 | \x0eb01ebfc9ed27500cd4dfc979272d1f0913cc9f66540d7e8005811109e1cf2d + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 256 | | 2 | 6 | \x887c22bd8750d34016ac3c66b5ff102dacdd73f6b014e710b51e8022af9a1968 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 128 | | 2 | 7 | \xffd70157e48063fc33c97a050f7f640233bf646cc98d9524c6b92bcf3ab56f83 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 64 | | 2 | 8 | \x9867cc5f7f196b93bae1e27e6320742445d290f2263827498b54fec539f756af + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 32 | | 2 | 9 | \xcefad4e508c098b9a7e1d8feb19955fb02ba9675585078710969d3440f5054e0 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 16 | | 2 | 10 | \xf9dc3e7fe016e050eff260334f18a5d4fe391d82092319f5964f2e2eb7c1c3a5 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 8 | | 2 | 11 | \xf8b13a49e282f609c317a833fb8d976d11517c571d1221a265d25af778ecf892 + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 4 | | 2 | 12 | \x3490c6ceeb450aecdc82e28293031d10c7d73bf85e57bf041a97360aa2c5d99c + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 2 | | 2 | 13 | \xc1df82d9c4b87413eae2ef048f94b4d3554cea73d92b0f7af96e0271c691e2bb + \x85de015db25b997c2c2dc80baa680016bf82c1d748a1c69361a54daee5c4e561 | 1 | | 2 | 14 | \x5c67add7c6caf302256adedf7ab114da0acfe870d449a3a489f781d659e8becc +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection.scenario new file mode 100644 index 000000000..fec625aef --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection.scenario @@ -0,0 +1,2 @@ +63xhs5bXcuMR3uMACXWkkFMm7BJ9Thknh7WNMPzV8HJBNwpyxJTr98NrLFHnTZDHdSUFD42VFQx8rjSaGynWbaRs +5ZKjPxm3WAZzuqqkCDjgKpm9b5XjB9cuvv68JvXxWThvJaJxcMJgpSbYs4gDA9dGJyeLzsgNtnS6oubANF1KbBmt diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset.txt new file mode 100644 index 000000000..9a54a14fa --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x1679ec700d2cf85da62294237cedf6b7c57ea3a28940ec152c3c6a65c271f9a3 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 2 +tree_id | \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d +leaf | \xbaff0b3bfa1cbe7b2f4f5e835cc3837b4c2b042d5042d09aba0527cdb86b9e49 +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x1679ec700d2cf85da62294237cedf6b7c57ea3a28940ec152c3c6a65c271f9a3 +burnt | f +slot_updated | 232170413 +data_hash | 5qnPtMuhWzj8rRviKV1YRitUxgt4iFqFkpvyuBn5rTKW +creator_hash | FM4zS99NvwRZm5UGgcJW1pQEWDtpgH4jaiCaTkMn6mxD +owner_delegate_seq | 1 +leaf_seq | 2 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset_creators.txt new file mode 100644 index 000000000..69eb99418 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x1679ec700d2cf85da62294237cedf6b7c57ea3a28940ec152c3c6a65c271f9a3 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 232170413 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x1679ec700d2cf85da62294237cedf6b7c57ea3a28940ec152c3c6a65c271f9a3 +creator | \x762cfc08d3cd38537a7e610d93288350dd0b39fb530512230ffd0aee29238fdc +share | 45 +verified | f +seq | 1 +slot_updated | 232170413 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset_grouping.txt new file mode 100644 index 000000000..69b52aec8 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x1679ec700d2cf85da62294237cedf6b7c57ea3a28940ec152c3c6a65c271f9a3 +group_key | collection +group_value | 4zapNXifB7Lz5XGUtsYQ3gsEujK2dqFw4mE9NY57NrtD +seq | +slot_updated | 232170416 +verified | t +group_info_seq | 2 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_cl_items.txt new file mode 100644 index 000000000..1743e0c68 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_set_and_verify_collection_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 16384 | 0 | 2 | 0 | \xbaff0b3bfa1cbe7b2f4f5e835cc3837b4c2b042d5042d09aba0527cdb86b9e49 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 8192 | | 2 | 1 | \xf1dec0e2954753f944bab7070461e62cc5d7ecd1e08251e635f8f739a03267b5 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 4096 | | 2 | 2 | \x4e483b3e0eeac96dd1cee947708ff44a86d86d6836f68eedd885c641a1e574fd + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 2048 | | 2 | 3 | \x6c0a6b99fcd38aab086faaa90e239ff8ef0b3fe3c063b081ad7f3983b55f924b + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 1024 | | 2 | 4 | \x6d491b940d2a449ded3a13a6e1e4a68cb9f4487256f46d470d3c0b2e5009e8e2 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 512 | | 2 | 5 | \xe74605586038af7c4156228834d4cca0030f075e7df71e13ec3200e7fb401ac6 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 256 | | 2 | 6 | \x9ee71499317d35ee7e1c63bda5f94950f7abfac94ba1eac13645ec9f0c07290d + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 128 | | 2 | 7 | \x69c82b7a5ec22ae612da8d754eaf1eb408f95470744102df7748ae89e2c2cffb + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 64 | | 2 | 8 | \xb7a855980446bc5c998ad8c827799e250e376350df8b86646b447c3cfc1d56c1 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 32 | | 2 | 9 | \xda3c1ed8903739bfba96e16b262d20babfdc16d60332a6c3b14531d726c74915 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 16 | | 2 | 10 | \xf3131a32c3524e825036d0e704ec75fd44e4f843ed32a8bd219753c9caaa8b42 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 8 | | 2 | 11 | \x0777f200acfeee73ce73ab8a13cc5f7bb28de7d880a6ca5349ec8948ef2563af + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 4 | | 2 | 12 | \x90b801463c1614468d210b2a14a7080e15c992604fb7fb50c729658051f76440 + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 2 | | 2 | 13 | \xe29ffdf48e9270a9e9cd9391ccabf7cc0381fe3ac1a0423498ace002b8f114ac + \xd1b9bbe9ece797ea5db10e674caaf8cf59604cea8e386307b51839795663a42d | 1 | | 2 | 14 | \x914743a17cc0078161eb98560e7833eb9b6079f58140a06c96331746e06d2dd9 +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection.scenario new file mode 100644 index 000000000..2f1a47700 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection.scenario @@ -0,0 +1,2 @@ +tzXASugk8578bmtA3JAFQLEfcVQp3Np3rU9fyFas2Svk8nyBHXJnf7PdqebGNsSTwx6CEWpDCP5oLoCDcmbP35B +7nK9a2DSDZ4Gh6DatmxGJmuLiDEswaY9bYSSPTtQppk7PtLKXYE84jWzm7AC4G1fpa831GaXuXcn5n5ybWqB4e5 diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset.txt new file mode 100644 index 000000000..59f0eb755 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x18e8b7e61a39441667dc71c6c44b0a7966612af1428740bb00dcce262ba00673 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 2 +tree_id | \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 +leaf | \x141f160c6f7454ae734e756841611f30a92cc21f0e2348ad414b3735a3f1ff3f +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x18e8b7e61a39441667dc71c6c44b0a7966612af1428740bb00dcce262ba00673 +burnt | f +slot_updated | 232178646 +data_hash | 8M8DpVvA1aGNMV6xMViDyEF9oS89VKqbWsxBfUNkGGQ9 +creator_hash | 4q4TdVGLUpKPvHqZT57xM66gZyAjViQdPPsZKoHPRZni +owner_delegate_seq | 1 +leaf_seq | 2 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset_creators.txt new file mode 100644 index 000000000..d62d5e4a8 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x18e8b7e61a39441667dc71c6c44b0a7966612af1428740bb00dcce262ba00673 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 232178646 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x18e8b7e61a39441667dc71c6c44b0a7966612af1428740bb00dcce262ba00673 +creator | \xb1a13104bb97088dae4656d8ffa064b9dc032f914a6f6e53aa99db1a9c7a698a +share | 45 +verified | f +seq | 1 +slot_updated | 232178646 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset_grouping.txt new file mode 100644 index 000000000..72b43d773 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x18e8b7e61a39441667dc71c6c44b0a7966612af1428740bb00dcce262ba00673 +group_key | collection +group_value | DdyrHTfN4wskbqTm3NDbAvRDsqiewzkuMboMRYJmNG6A +seq | +slot_updated | 232178649 +verified | f +group_info_seq | 2 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_cl_items.txt new file mode 100644 index 000000000..5f46389e7 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_to_collection_unverify_collection_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 16384 | 0 | 2 | 0 | \x141f160c6f7454ae734e756841611f30a92cc21f0e2348ad414b3735a3f1ff3f + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 8192 | | 2 | 1 | \x42c4bbeaf8a0f58b61145079fc1c0cd777c2d6bf63a7456ee1aecd57beb4e5da + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 4096 | | 2 | 2 | \x8d4b3619905066948dc391c8d0783f144999b5a4ef618921e0d6c266f8d513b4 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 2048 | | 2 | 3 | \x8e3266f479bc71d6e272fd7884aebf1a1adb5687bb8d2d7e442b7da3f499e665 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 1024 | | 2 | 4 | \xb81f5707fbde5887d32a20454bd68871516166511f69da5c3b734faa6054f10d + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 512 | | 2 | 5 | \x6f22edcbbdf13845a678146c53a4ee282ddf4ee39098b90a92f1779521a2a48b + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 256 | | 2 | 6 | \x4b940b307dee07066e114216c1fc8e495004251b8e64033eadc5af1ee1620ef4 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 128 | | 2 | 7 | \x7f0293e8806809fca1ce681a5f3771d402ba57b17bfa39be0c724fd840a8641c + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 64 | | 2 | 8 | \x7d5c360f403e54db57ccf79d4eba614477dc570124f29f410e20138c11439b11 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 32 | | 2 | 9 | \x2def95027d82ba70b28a524a7e869fd11ec9b999b8bb1e5ab8c5081e60a71c6f + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 16 | | 2 | 10 | \xfb7ae96ce567baf3bc1dd64127005074e4d6b97a0016f8427a44b26aedf50084 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 8 | | 2 | 11 | \x76390000c0c3912f5ad6a0f172a2629c0a347a5d8479b98b40610bd4fd29fb51 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 4 | | 2 | 12 | \x500cf50ef2d2c482fbc609f97b6e214951b3f5893cbc6d8940ff9ce53cf3e566 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 2 | | 2 | 13 | \x4232ac08f864fe179bd15d13f9f1a6026361aad50da14cc8a4aa3f864932ffe2 + \xadeec96ee34d67ca663c90e0504014f8688f336c09509707c27556a2abceaa63 | 1 | | 2 | 14 | \x9c4a749767da0b84013f6404f88411ee3f4b1b34564b6db953463e9f8e8c6786 +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn.scenario new file mode 100644 index 000000000..0ef217664 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn.scenario @@ -0,0 +1,3 @@ +5coWPFty37s7haT3SVyMf6PkTaABEnhCRhfDjXeMNS58czHB5dCFPY6VrsZNwxBnqypmNic1LbLp1j5qjbdnZAc8 +k6jmJcurgBQ6F2bVa86Z1vGb7ievzxwRZ8GAqzFEG8HicDizxceYPUm1KTzWZ3QKtGgy1EuFWUGCRqBeKU9SAoJ +KHNhLijkAMeKeKm6kpbk3go6q9uMF3zmfCoYSBgERe8qJDW8q5ANpnkyBuyVkychXCeWzRY8i5EtKfeGaDDU23w diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset.txt new file mode 100644 index 000000000..71b09ea4c --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x75d2c89f62f8a50ed994309655bbd27de2c5f0b3da4cf8c329320016b47aa3d1 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \x98f51858ebca2d4fbe5a791f8ac3be5247af748d4e10c82ca22dfcfc6a17ad80 +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 3 +tree_id | \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c +leaf | \x32c1a03c769943e075b2767a0ed09ea6f0a93f096f03f1498da795634f63c6f6 +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x75d2c89f62f8a50ed994309655bbd27de2c5f0b3da4cf8c329320016b47aa3d1 +burnt | t +slot_updated | 221559431 +data_hash | GFsq2BCwZdQaErGkQD5my36tpC8Cg38HFuMvbM6ShC2h +creator_hash | 2ct1dcDUbFDHfpdtuZ5vdkPB1ewjFg9pxRi58Yj4huCj +owner_delegate_seq | 2 +leaf_seq | 2 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset_creators.txt new file mode 100644 index 000000000..5a372fa30 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x75d2c89f62f8a50ed994309655bbd27de2c5f0b3da4cf8c329320016b47aa3d1 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 221559431 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x75d2c89f62f8a50ed994309655bbd27de2c5f0b3da4cf8c329320016b47aa3d1 +creator | \xab4ea130077985e7bae2df6a4aa90c94a2918c7bec1ccf44ab994c6803f5e8d2 +share | 45 +verified | f +seq | 1 +slot_updated | 221559431 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset_grouping.txt new file mode 100644 index 000000000..528b49831 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x75d2c89f62f8a50ed994309655bbd27de2c5f0b3da4cf8c329320016b47aa3d1 +group_key | collection +group_value | +seq | +slot_updated | 221559431 +verified | f +group_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_cl_items.txt new file mode 100644 index 000000000..8bea6e8a1 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_burn_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 16384 | 0 | 3 | 0 | \x0000000000000000000000000000000000000000000000000000000000000000 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 8192 | | 3 | 1 | \xad3228b676f7d3cd4284a5443f17f1962b36e491b30a40b2405849e597ba5fb5 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 4096 | | 3 | 2 | \xb4c11951957c6f8f642c4af61cd6b24640fec6dc7fc607ee8206a99e92410d30 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 2048 | | 3 | 3 | \x21ddb9a356815c3fac1026b6dec5df3124afbadb485c9ba5a3e3398a04b7ba85 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 1024 | | 3 | 4 | \xe58769b32a1beaf1ea27375a44095a0d1fb664ce2dd358e7fcbfb78c26a19344 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 512 | | 3 | 5 | \x0eb01ebfc9ed27500cd4dfc979272d1f0913cc9f66540d7e8005811109e1cf2d + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 256 | | 3 | 6 | \x887c22bd8750d34016ac3c66b5ff102dacdd73f6b014e710b51e8022af9a1968 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 128 | | 3 | 7 | \xffd70157e48063fc33c97a050f7f640233bf646cc98d9524c6b92bcf3ab56f83 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 64 | | 3 | 8 | \x9867cc5f7f196b93bae1e27e6320742445d290f2263827498b54fec539f756af + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 32 | | 3 | 9 | \xcefad4e508c098b9a7e1d8feb19955fb02ba9675585078710969d3440f5054e0 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 16 | | 3 | 10 | \xf9dc3e7fe016e050eff260334f18a5d4fe391d82092319f5964f2e2eb7c1c3a5 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 8 | | 3 | 11 | \xf8b13a49e282f609c317a833fb8d976d11517c571d1221a265d25af778ecf892 + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 4 | | 3 | 12 | \x3490c6ceeb450aecdc82e28293031d10c7d73bf85e57bf041a97360aa2c5d99c + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 2 | | 3 | 13 | \xc1df82d9c4b87413eae2ef048f94b4d3554cea73d92b0f7af96e0271c691e2bb + \xaf03fe8e86529fb13bdd87e100da8fd5e3cba075941c4cd7f8f747db7b25532c | 1 | | 3 | 14 | \x5c67add7c6caf302256adedf7ab114da0acfe870d449a3a489f781d659e8becc +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer.scenario new file mode 100644 index 000000000..ffcf676a4 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer.scenario @@ -0,0 +1,3 @@ +5bq936UgGs4RnxM78iXp1PwVhr8sTYoEsHCWpr8QBFtc2YtS3ieYHcsPG46G2ikwrS3tXYnUK93PzseT52AR81RR +5VC3Jqr5X1N8NB8zuSahHpayekLVozYkDiPjJLqU6H5M6fq9ExVLGYYKKCPbeksMPXTjy65sdEQGPzDWAYPs8QjP +34xjcNf3rZFKz381hKpFLqxpojaDgXEpCqH5qcpTXLaJnDbtqRz35wiuMF1cAgvJGLzYYrwaMvCK1D7LxYsdpMU1 diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset.txt new file mode 100644 index 000000000..ae5441231 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \xca35c69cd4d5bb853a93e4e76526be26cf5951982653cf653d9dddac5e5ac797 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \x6f8ed9b39d43793a5371d49634f9299098c7a8de514bf052598e4fc3303b19af +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 3 +tree_id | \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 +leaf | \x45912e7b9afad71c6095cdda1383a8c49bc3283f5bdb35bbfc411e4ca44a8f7d +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \xca35c69cd4d5bb853a93e4e76526be26cf5951982653cf653d9dddac5e5ac797 +burnt | f +slot_updated | 224501105 +data_hash | 68ZcMZF52Bv3mayj4AjPFdVoMhrE9Ap18CQRuUhB2pWu +creator_hash | 2RsQnw2DXTrKWT2GAd7LEnvgHuL8gZ8C2wk89dcW31yb +owner_delegate_seq | 3 +leaf_seq | 3 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset_creators.txt new file mode 100644 index 000000000..35a05174a --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \xca35c69cd4d5bb853a93e4e76526be26cf5951982653cf653d9dddac5e5ac797 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 224501105 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \xca35c69cd4d5bb853a93e4e76526be26cf5951982653cf653d9dddac5e5ac797 +creator | \x900de0b94569cfed833ae4c2ca61ba796f44334823c57a58be5661585fd8f2e2 +share | 45 +verified | f +seq | 1 +slot_updated | 224501105 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset_grouping.txt new file mode 100644 index 000000000..e3aeb62ff --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \xca35c69cd4d5bb853a93e4e76526be26cf5951982653cf653d9dddac5e5ac797 +group_key | collection +group_value | +seq | +slot_updated | 224501105 +verified | f +group_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_cl_items.txt new file mode 100644 index 000000000..3bce5b5a9 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_transfer_transfer_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 16384 | 0 | 3 | 0 | \x45912e7b9afad71c6095cdda1383a8c49bc3283f5bdb35bbfc411e4ca44a8f7d + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 8192 | | 3 | 1 | \xd801cca361f2a89de3378a9a2aa13a1fa35d592ffcba4898cf29ad349cb49127 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 4096 | | 3 | 2 | \x8f9213e54cc7cdc05550c636db2636d7208f553b4e4e3ac18536e3957bf116b7 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 2048 | | 3 | 3 | \x5753eae6594777fbd7559f87ada77dc9d8d0ab1e7af9210122310bd181a3f2b3 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 1024 | | 3 | 4 | \x9456b1fb4ecba0a6463ab6b3cb0903f46fc81c2bc26f963aea4736dee78f32bc + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 512 | | 3 | 5 | \x436352dbb7b693f62518a507761229a8eccbc16cc4c045edba7d7c0dc5812dc9 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 256 | | 3 | 6 | \xfdfc08110a0934b10ecd0abfe7d5e3e9a376a814ae13606df63a1f575b1b09e4 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 128 | | 3 | 7 | \x11e6008ee0ba4beee8583c2b1657822cdcd5ea247a91110da38ee871d6706039 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 64 | | 3 | 8 | \x41bdd22b61376b15eb09f7448e82c06f60e9555360517f8204c97065b62f23c8 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 32 | | 3 | 9 | \x1292b3d58d066207d7574635c2296ffa0cfec8cdbf740695ad53864f1df041d3 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 16 | | 3 | 10 | \x639701cdaf796e69a292ca73c23e34ea390b4e54b3e5c9a0eb8fe5ed59a61e07 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 8 | | 3 | 11 | \x40779dc87591eaf7ee59002d73c8bef5daa4c6d87b70dbeeacebf59e8fa10d35 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 4 | | 3 | 12 | \xcadcb3afb2bdc362f845f8b733e0da6975335ff3ddbd182609a5bcb935990510 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 2 | | 3 | 13 | \xf4d64147487fb8e1a4a2537ca86c4d9fd3612d824950b007bdd36acb9ffda324 + \x8f072ea46368429371d5f51dd048498a14998fc9bed718cdab5e281a325c0023 | 1 | | 3 | 14 | \x2e32f5af4f4c051605810841aa7ee61008581d0d6f719a08a8bc9a4e9f79e6c7 +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection.scenario new file mode 100644 index 000000000..3824000ce --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection.scenario @@ -0,0 +1,2 @@ +5Az2Ts9mXesVk5spzS6myopV5BFn2dnTVX3ooKtbNJDXqhku9tuQ5ELX9xBeTH93ceoDoAtiWfcFTVdxdKAGSRp9 +5PadSM5ENNsqgb9dTdG728mCeciYg9QTbzm7WGwjJaxFeenVE4xzmi2tjKrswojJDBcJe2z8bx43A6tGyEsu9WTJ diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset.txt new file mode 100644 index 000000000..d26b30315 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x03b8abdca02da73970dd4e2ba783224108acff30f31db83c40d5638ce67fc102 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 2 +tree_id | \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 +leaf | \x869e0d7e57274e1a00964a751dfc885f583b768ffbbe8f33b1bb8c945b0fe115 +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x03b8abdca02da73970dd4e2ba783224108acff30f31db83c40d5638ce67fc102 +burnt | f +slot_updated | 227661765 +data_hash | 8KQ45EBtVc6WrT4m4Zh52pRP27ZnvHbw4wrnx5nSBsVu +creator_hash | GJCkiiVATMT4o8n5Tv8bE5eFXo5DdTkZhRspfxigp8ZB +owner_delegate_seq | 1 +leaf_seq | 2 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset_creators.txt new file mode 100644 index 000000000..34d202fbb --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x03b8abdca02da73970dd4e2ba783224108acff30f31db83c40d5638ce67fc102 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 227661765 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x03b8abdca02da73970dd4e2ba783224108acff30f31db83c40d5638ce67fc102 +creator | \x5f081d909d1e178f2219c808d4b8fa24f22cac66eef92714f880bca72f8d6641 +share | 45 +verified | f +seq | 1 +slot_updated | 227661765 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset_grouping.txt new file mode 100644 index 000000000..7683f1002 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x03b8abdca02da73970dd4e2ba783224108acff30f31db83c40d5638ce67fc102 +group_key | collection +group_value | 5SqxHDvZ5yji5fr2v8MXkiT5QHSxnTjEw7feeds9EfDW +seq | +slot_updated | 227661768 +verified | t +group_info_seq | 2 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_cl_items.txt new file mode 100644 index 000000000..98c949449 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 16384 | 0 | 2 | 0 | \x869e0d7e57274e1a00964a751dfc885f583b768ffbbe8f33b1bb8c945b0fe115 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 8192 | | 2 | 1 | \x49afc4198598c508073bea7bdeb6b4cdf2c24808a0e5d8f8c88b5bfd6c5baea1 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 4096 | | 2 | 2 | \x15938cca95120f1b49b1f6ae837ad575749e1fb6c815c17ee1a3d6970d0b8f23 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 2048 | | 2 | 3 | \x2eabfdb34b5065ae920c30526c6a324b02970e2cc93bd5eaf9736de69ab60d30 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 1024 | | 2 | 4 | \xa5bf6fc08506ba0f750826f725a147bdb9bce9e51376f4420ac9dc4ae0e0f8ec + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 512 | | 2 | 5 | \xe3995eeee8bf65819dbc2076ac2b8f614ae1d9eec81e16e3d288834005e9d71b + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 256 | | 2 | 6 | \x5e3fb324a4a9315f2899bf9a830a3b715cedf856cf9f7597b4bb6c87a56153de + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 128 | | 2 | 7 | \xae5658127500d0298ab7d06b978361c2787c9705c41c2d06f82b176569d8ee72 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 64 | | 2 | 8 | \x0f759720f10b760132a2341f5d33581f0eca3d3bce394d5deba4ee837e5a2f05 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 32 | | 2 | 9 | \xe4b269ff839c09d341ee592b3fd3edb2e304c4556364eba09e04d416500e8e8b + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 16 | | 2 | 10 | \x0c85c94fdbd81ad2e80d6cad7d67ca6072d3d9546d5e11276c41d6f71b87997f + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 8 | | 2 | 11 | \x231ed9314365b7e6adee7efb8de03e2becd7b9ae1eca8bcc25b00b1e17b29964 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 4 | | 2 | 12 | \x05fde99ac00a91540024d82731ea6eb18434e497d6d3ae4641f4d989af50ffa7 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 2 | | 2 | 13 | \x31ee82d19bc8ef39f86427013854fafde8ffdb2375deb9aeb9538f23be666736 + \x9043c3758809749b31418338a2f6d142c6e7b1a314549b9edb8617a7c04e17e8 | 1 | | 2 | 14 | \xb53d2998178b73cb8d4eca4588e1b37bd4f994cc5eabb4466014ad891df7afd2 +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection.scenario new file mode 100644 index 000000000..dff9bb6ae --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection.scenario @@ -0,0 +1,3 @@ +5uWXt8JAhuP2XQ2nYJTq8Ndp34fdG3vmJ7DJnb3bE6iyrZZ6jeuN9w5jZvKrduMDu4zKyQU7A3JtswhKxE3hjKBk +4hQQsDKgDx5PpZR7nGvxKsLSvX4J7voaiJC3ag7dPuu4HY5kbvaqD2gyeHbdja1f22ypmzouRNpuo6sbyGDSSgya +5k71fZRpRagY45ZYu13Q8C3Bmw6KFPBkRmbBx2NuYk7roVtvM8P16WouCZtnkhRCyKyQHSgHKyTY92t9aq2tyLdd diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset.txt new file mode 100644 index 000000000..774fe3909 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x9f2817615e1440416649df6d4c4f5d71895a754e75ddf59ae01307e758f6a964 +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 3 +tree_id | \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef +leaf | \xa0df0b8f5870c42cf5f000cb93ac2407dc05a7b0e5708027cea879deaf672b86 +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x9f2817615e1440416649df6d4c4f5d71895a754e75ddf59ae01307e758f6a964 +burnt | f +slot_updated | 232161591 +data_hash | 8wZ2jDVA3gdirM6QtZrQHBcuJsLM4TZusEAKEEfSvgKw +creator_hash | A8KEBkNKGsouiKAsE5ARHqNHGTb7ZzPi6LHesaZCL4Aw +owner_delegate_seq | 1 +leaf_seq | 3 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset_creators.txt new file mode 100644 index 000000000..48e8eba4c --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x9f2817615e1440416649df6d4c4f5d71895a754e75ddf59ae01307e758f6a964 +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 1 +slot_updated | 232161591 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x9f2817615e1440416649df6d4c4f5d71895a754e75ddf59ae01307e758f6a964 +creator | \x264a5d2758f44ed5e1ddd75d6d215a1eb1a58526fc9de24c1363d789ffeaa0e4 +share | 45 +verified | f +seq | 1 +slot_updated | 232161591 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset_grouping.txt new file mode 100644 index 000000000..167976aef --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x9f2817615e1440416649df6d4c4f5d71895a754e75ddf59ae01307e758f6a964 +group_key | collection +group_value | FhBQpV7TdZHZe6rrS9hVhkmBZbjE6RDkD5QJ8XgcYHYX +seq | +slot_updated | 232161593 +verified | f +group_info_seq | 3 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_cl_items.txt new file mode 100644 index 000000000..22983bb02 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_collection_unverify_collection_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 16384 | 0 | 3 | 0 | \xa0df0b8f5870c42cf5f000cb93ac2407dc05a7b0e5708027cea879deaf672b86 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 8192 | | 3 | 1 | \x26636b1d764882db28d344654e080f97c4e471d8078fdf90e77210df986844c4 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 4096 | | 3 | 2 | \x5a7eddee1704d208b2c9286f8f6f57e11fb4088b26b4490086d8e1f866220a1e + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 2048 | | 3 | 3 | \x514fb9d4695c72ca8976c59670fd7108ca2b01962837687856b445cca95a273e + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 1024 | | 3 | 4 | \x6765d6f0594bdb48d2fe2eff283e66c966e9751c64c9c6d54c9052a1da6cb3ba + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 512 | | 3 | 5 | \x55aebf7da4895b8336ed31a9cd2d3690813a5521fd0c06b98bee582aefb4e9b6 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 256 | | 3 | 6 | \x9bf9878fdb11dcf5409555da88815ea2fa36f6274bbf766396cbc115fbdc9971 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 128 | | 3 | 7 | \xc3b2fb6bfaa3572d89e585fc1c01c424526125ee4d61b0351dd171538d8656e7 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 64 | | 3 | 8 | \x1ddb72f4872089fe09e731304bb37abf087091d76b538de8337c2667bbf71771 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 32 | | 3 | 9 | \x7c550bff142bb8ea40dd8077f5ef107f59ddb41485b59f75cc79bf4a32f672d4 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 16 | | 3 | 10 | \xcf945e99644b0bce7a632f75d5583af3bd253347060b46cb4b9a6b37680f23e2 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 8 | | 3 | 11 | \x8f8437650f74136e93236fadbe982efe7a3c7242fe5e1a7dbb828df498085787 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 4 | | 3 | 12 | \x6ad32435b390970745116398cfdbafcefeb17d9593c95d395654454c897942a2 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 2 | | 3 | 13 | \x61d24822e4adb1eb6fcd15acb5af19cb87e7a7696f5feef168a7b26da4ca99a1 + \x5be27efa6443d455b8a30f07cccfe55ad425858aaab1f9bf958a9ee28a3e71ef | 1 | | 3 | 14 | \xfd63d7da0c2dda3f85d7c393a9c5b4ae1c1d953834c5371a67ee282e8cc47149 +(15 rows) \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator.scenario b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator.scenario new file mode 100644 index 000000000..25ad8a539 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator.scenario @@ -0,0 +1,2 @@ +37ts5SqpNazPTp26VfC4oeuXpXezKYkD9oarczPNaE8TUGG8msifnTYTBJiBZNBeAUGrNw85EEfwnR1t9SieKTdq +4xrw5UwQSxxPzVxge6fbtmgLNsT2amaGrwpZFE95peRbnHGpxWtS2fF7whXW2xma4i2KDXdneztJZCAtgGZKTw11 diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset.txt new file mode 100644 index 000000000..53b7dac0d --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset.txt @@ -0,0 +1,28 @@ +-[ RECORD 1 ]-------------+------------------------------------------------------------------- +id | \x482e7bf66656da08580e3e68051fc47817a836103ed90c67a12d71a2e40ce6da +alt_id | +specification_version | v1 +specification_asset_class | NFT +owner | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +owner_type | single +delegate | +frozen | f +supply | 1 +supply_mint | +compressed | t +compressible | f +seq | 2 +tree_id | \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 +leaf | \x55bb6cc4f75588666a32c06370e4b5653a05f5f1f86527f6c9c5f6fe0f1c72f0 +nonce | 0 +royalty_target_type | creators +royalty_target | +royalty_amount | 0 +asset_data | \x482e7bf66656da08580e3e68051fc47817a836103ed90c67a12d71a2e40ce6da +burnt | f +slot_updated | 226295481 +data_hash | 31vt7MSZzRykZN1FjQktuk8oaWCVL9SzfMyX9Q2RtTaa +creator_hash | 4GAv4MMcgC7xjLuLHSMxxoRpp2cCbz52f9vhYK7GNZMX +owner_delegate_seq | 2 +leaf_seq | 2 +base_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset_creators.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset_creators.txt new file mode 100644 index 000000000..ce2f62f42 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset_creators.txt @@ -0,0 +1,16 @@ +-[ RECORD 1 ]+------------------------------------------------------------------- +asset_id | \x482e7bf66656da08580e3e68051fc47817a836103ed90c67a12d71a2e40ce6da +creator | \xdc53343c46e5d7a1bd08f4780285621202f66b596f984e940a5eb423ac560fed +share | 55 +verified | f +seq | 2 +slot_updated | 226295484 +position | 0 +-[ RECORD 2 ]+------------------------------------------------------------------- +asset_id | \x482e7bf66656da08580e3e68051fc47817a836103ed90c67a12d71a2e40ce6da +creator | \x0cac282cf9edd5e592590263225c9424f64fe68a32021187a17d0df9dd464c44 +share | 45 +verified | t +seq | 2 +slot_updated | 226295484 +position | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset_grouping.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset_grouping.txt new file mode 100644 index 000000000..c0ade31ae --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_asset_grouping.txt @@ -0,0 +1,8 @@ +-[ RECORD 1 ]--+------------------------------------------------------------------- +asset_id | \x482e7bf66656da08580e3e68051fc47817a836103ed90c67a12d71a2e40ce6da +group_key | collection +group_value | +seq | +slot_updated | 226295481 +verified | f +group_info_seq | 1 \ No newline at end of file diff --git a/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_cl_items.txt b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_cl_items.txt new file mode 100644 index 000000000..128fa7b63 --- /dev/null +++ b/tools/txn_forwarder/bubblegum_tests/test_scenario_data/mint_verify_creator_cl_items.txt @@ -0,0 +1,18 @@ + tree | node_idx | leaf_idx | seq | level | hash +--------------------------------------------------------------------+----------+----------+-----+-------+-------------------------------------------------------------------- + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 16384 | 0 | 2 | 0 | \x55bb6cc4f75588666a32c06370e4b5653a05f5f1f86527f6c9c5f6fe0f1c72f0 + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 8192 | | 2 | 1 | \x2a9201456f427d4c29b41c89f492d75235c918e1c8eaf6400310e75632318802 + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 4096 | | 2 | 2 | \xc96766fbdcb9eb4c4ae8939595adb34066dc5cf9453a707ea7fd26729e231ccc + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 2048 | | 2 | 3 | \xf186e76c8633f893a9e99d108087e4de194ea7c4c1864d06309fe21bb350da5f + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 1024 | | 2 | 4 | \xa1056ad4a6ba2d7e836bf2beec305382f0b431cdbe9cf9fccc6ed078bd8ccd68 + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 512 | | 2 | 5 | \xb58becac8e5106a7b56362f3c526c5a210a093a168ace4788ba9e0e3adfc7fd2 + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 256 | | 2 | 6 | \xd7f345939b46e69df3e6db6303e1e8021264aa7448eda5c07176b852393f5d5d + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 128 | | 2 | 7 | \x73ea7f707a7a2c0423295f43ca4bc70e794e8f81641d81da751b19710950b24e + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 64 | | 2 | 8 | \x820272ee3e42619c9b900c9368270a75a8ff4cf28274d06dd83e130a15a5090b + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 32 | | 2 | 9 | \xdf85812c52811baa0da7e35562f800c2dc4637a9a54ddee041cae4c29cedbd5a + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 16 | | 2 | 10 | \xa60e02ba2e1473d096b1792abd93f4415f4961cb95d6c5ff8881e11ac36b7c92 + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 8 | | 2 | 11 | \x50a27c2a6942bd5cf64d8d3b74e8ccfd51fadc16ecb3dfd8e6200ea647b9f937 + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 4 | | 2 | 12 | \x6945ae75593b1f82975848caccbc647fb54ef27bbbbb866cd750e1c383ed57e7 + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 2 | | 2 | 13 | \x828ffbdfa1124da75e705bb31a501f523333a74b1d42d8ba3c7b096daaf6103a + \x520fb79c4473c67eef2052359dc15eec3d99acb23642b107badae49bc2dddb83 | 1 | | 2 | 14 | \x6236ef1da7487526e1e2e1bacc6b93689a5bae9fb46c5c1f766e4f60c25afb93 +(15 rows) \ No newline at end of file diff --git a/tree_backfiller/Cargo.toml b/tree_backfiller/Cargo.toml index 631c0ed16..e43bb7df2 100644 --- a/tree_backfiller/Cargo.toml +++ b/tree_backfiller/Cargo.toml @@ -1,8 +1,9 @@ [package] name = "das-tree-backfiller" -version = "0.1.0" -edition = "2021" -publish = false +version = { workspace = true } +edition = { workspace = true } +repository = { workspace = true } +publish = { workspace = true } # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html @@ -14,70 +15,67 @@ name = "das-tree-backfiller" [dependencies] +anchor-client = { workspace = true } +anchor-lang = { workspace = true } +anyhow = { workspace = true } backon = "0.4.1" -log = "0.4.17" -env_logger = "0.10.0" -anyhow = "1.0.75" -redis = { version = "0.22.3", features = [ +base64 = { workspace = true } +borsh = { workspace = true } +bs58 = { workspace = true } +cadence = { workspace = true } +cadence-macros = { workspace = true } +chrono = { workspace = true } +clap = { workspace = true, features = ["derive", "cargo", "env"] } +digital_asset_types = { workspace = true } +env_logger = { workspace = true } +figment = { workspace = true, features = ["env", "toml", "yaml"] } +flatbuffers = { workspace = true } +futures = { workspace = true } +futures-util = { workspace = true } +indicatif = "0.17.5" +lazy_static = { workspace = true } +log = { workspace = true } +mpl-bubblegum = { workspace = true } +plerkle_messenger = { workspace = true, features = ['redis'] } +plerkle_serialization = { workspace = true } +redis = { workspace = true, features = [ "aio", "tokio-comp", "streams", "tokio-native-tls-comp", ] } -futures = { version = "0.3.25" } -futures-util = "0.3.27" -base64 = "0.21.0" -indicatif = "0.17.5" -thiserror = "1.0.31" -serde_json = "1.0.81" -cadence = "0.29.0" -cadence-macros = "0.29.0" -anchor-client = "0.28.0" -tokio = { version = "1.26.0", features = ["full", "tracing"] } -sqlx = { version = "0.6.2", features = [ - "macros", - "runtime-tokio-rustls", - "postgres", - "uuid", - "offline", - "json", -] } -sea-orm = { version = "0.10.6", features = [ +regex = { workspace = true } +reqwest = { workspace = true } +rust-crypto = { workspace = true } +sea-orm = { workspace = true, features = [ "macros", "runtime-tokio-rustls", "sqlx-postgres", "with-chrono", "mock", ] } -sea-query = { version = "0.28.1", features = ["postgres-array"] } -chrono = "0.4.19" -tokio-postgres = "0.7.7" -serde = "1.0.136" -bs58 = "0.4.0" -reqwest = "0.11.11" -plerkle_messenger = { version = "1.6.0", features = ['redis'] } -plerkle_serialization = { version = "1.6.0" } -flatbuffers = "23.1.21" -lazy_static = "1.4.0" -regex = "1.5.5" -digital_asset_types = { path = "../digital_asset_types", features = [ - "json_types", - "sql_types", +sea-query = { workspace = true, features = ["postgres-array"] } +serde = { workspace = true } +serde_json = { workspace = true } +solana-account-decoder = { workspace = true } +solana-client = { workspace = true } +solana-sdk = { workspace = true } +solana-transaction-status = { workspace = true } +spl-account-compression = { workspace = true } +spl-concurrent-merkle-tree = { workspace = true } +sqlx = { workspace = true, features = [ + "macros", + "runtime-tokio-rustls", + "postgres", + "uuid", + "offline", + "json", ] } -mpl-bubblegum = "1.0.1-beta.3" -spl-account-compression = { version = "0.2.0", features = ["no-entrypoint"] } -spl-concurrent-merkle-tree = "0.2.0" -uuid = "1.0.0" -figment = { version = "0.10.6", features = ["env", "toml", "yaml"] } -solana-sdk = "~1.16.16" -solana-client = "~1.16.16" -solana-transaction-status = "~1.16.16" -solana-account-decoder = "~1.16.16" -rust-crypto = "0.2.36" -url = "2.3.1" -anchor-lang = "0.28.0" -borsh = "~0.10.3" -clap = { version = "4.2.2", features = ["derive", "cargo", "env"] } +thiserror = { workspace = true } +tokio = { workspace = true, features = ["full", "tracing"] } +tokio-postgres = { workspace = true } +url = { workspace = true } +uuid = { workspace = true } [lints] workspace = true diff --git a/tree_backfiller/src/tree.rs b/tree_backfiller/src/tree.rs index ba55b6b01..4cf458786 100644 --- a/tree_backfiller/src/tree.rs +++ b/tree_backfiller/src/tree.rs @@ -130,7 +130,7 @@ pub struct TreeGapFill { } impl TreeGapFill { - pub fn new(tree: Pubkey, before: Option, until: Option) -> Self { + pub const fn new(tree: Pubkey, before: Option, until: Option) -> Self { Self { tree, before, @@ -249,8 +249,7 @@ impl TreeResponse { gma_handles.push(async move { let accounts = client.get_multiple_accounts(batch).await?; - let results: Vec<(&Pubkey, Option)> = - batch.iter().zip(accounts).collect(); + let results: Vec<(&Pubkey, Option)> = batch.iter().zip(accounts).collect(); Ok::<_, TreeErrorKind>(results) })